View Single Post
11-03-12, 07:53 PM   #2
Phanx
Cat.
 
Phanx's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2006
Posts: 5,617
Replace the contents of the addon's Lua file with this:
Code:
local ignoreZones = {
	[806] = true, -- The Jade Forest
	[809] = true, -- Kun-Lai Summit
}

local f = CreateFrame("Frame")
f:RegisterEvent("UI_ERROR_MESSAGE")
f:SetScript("OnEvent", function(self, event, message)
	if (message == SPELL_FAILED_NOT_MOUNTED or message == ERR_TAXIPLAYERALREADYMOUNTED)
	and not ignoreZones[GetCurrentMapAreaID()]
	and (GetCVarBool("autoDismountFlying") or not IsFlying())
	then
		Dismount()
	end
end)
If you want to add more zones, you can find a list of Map IDs here:
http://www.wowpedia.org/MapID
__________________
Retired author of too many addons.
Message me if you're interested in taking over one of my addons.
Don’t message me about addon bugs or programming questions.
  Reply With Quote