1
0
Bifurcation 0

Merging wow-db-get back into the trunk. This is where r255 had ended up.

Cette révision appartient à :
Nathanial.C.Jones 2012-09-25 22:17:03 +00:00
révision c9fe3f99cc
46 fichiers modifiés avec 3010 ajouts et 881 suppressions

Voir le fichier

@ -103,7 +103,7 @@ then
fi
sub="s/\\\$svnversion\\\$/${release_string}/g"
sub2='s/4\.0\.1/4\.3\.0/'
sub2='s/4\.0\.1/5\.0\.5/'
for toc in `find . -iname "*.toc"`
do
echo Replacing version tag in ${toc}.
@ -128,7 +128,7 @@ done
echo ${release_string}
zip -qdgds 1m -r QuestHelper-4.3.0.${release_string}.zip QuestHelper/ QHData-*
zip -qdgds 1m -r QuestHelper-5.0.5.${release_string}.zip QuestHelper/ QHData-*
echo Moving the package up one directory level.
mv -v *.zip ..

Voir le fichier

@ -1,4 +1,4 @@
## Interface: 40300
## Interface: 50001
## Title: QuestHelper Data (Base)
## Author: zorbathut, smariot, vipersniper, nesher, nconantj
## Notes: Contains the data needed by QuestHelper

Voir le fichier

@ -1,4 +1,4 @@
## Interface: 40300
## Interface: 50001
## Title: QuestHelper Data (deDE)
## Author: zorbathut, smariot, vipersniper, nesher, nconantj
## Notes: Contains the data needed by QuestHelper

Voir le fichier

@ -1,4 +1,4 @@
## Interface: 40300
## Interface: 50001
## Title: QuestHelper Data (enUS)
## Author: zorbathut, smariot, vipersniper, nesher, nconantj
## Notes: Contains the data needed by QuestHelper

Voir le fichier

@ -1,4 +1,4 @@
## Interface: 40300
## Interface: 50001
## Title: QuestHelper Data (esES)
## Author: zorbathut, smariot, vipersniper, nesher, nconantj
## Notes: Contains the data needed by QuestHelper

Voir le fichier

@ -1,4 +1,4 @@
## Interface: 40300
## Interface: 50001
## Title: QuestHelper Data (esMX)
## Author: zorbathut, smariot, vipersniper, nesher, nconantj
## Notes: Contains the data needed by QuestHelper

Voir le fichier

@ -1,4 +1,4 @@
## Interface: 40300
## Interface: 50001
## Title: QuestHelper Data (frFR)
## Author: zorbathut, smariot, vipersniper, nesher, nconantj
## Notes: Contains the data needed by QuestHelper

Voir le fichier

@ -1,4 +1,4 @@
## Interface: 40300
## Interface: 50001
## Title: QuestHelper Data (koKR)
## Author: zorbathut, smariot, vipersniper, nesher, nconantj
## Notes: Contains the data needed by QuestHelper

Voir le fichier

@ -1,4 +1,4 @@
## Interface: 40300
## Interface: 50001
## Title: QuestHelper Data (ruRU)
## Author: zorbathut, smariot, vipersniper, nesher, nconantj
## Notes: Contains the data needed by QuestHelper

Voir le fichier

@ -1,4 +1,4 @@
## Interface: 40300
## Interface: 50001
## Title: QuestHelper Data (zhCN)
## Author: zorbathut, smariot, vipersniper, nesher, nconantj
## Notes: Contains the data needed by QuestHelper

Voir le fichier

@ -1,4 +1,4 @@
## Interface: 40300
## Interface: 50001
## Title: QuestHelper Data (zhTW)
## Author: zorbathut, smariot, vipersniper, nesher, nconantj
## Notes: Contains the data needed by QuestHelper

Voir le fichier

@ -0,0 +1,3 @@
assert(QuestHelper and type(QuestHelper) == "table", "Ooops, can't load right now.")
QuestHelper.LibMapData = LibStub("LibMapData-1.0")

Voir le fichier

@ -1,4 +1,4 @@
## Interface: 40300
## Interface: 50001
## Title: QuestHelper
## Author: zorbathut, smariot, vipersniper, nesher, nconantj
## Notes: Calculates an optimal route for you to follow while questing.
@ -62,13 +62,20 @@ libs\AceConfig-3.0\AceConfig-3.0.xml
bst_astrolabe.lua
libs\AstrolabeQH\Load.xml
#MapMonitor.lua
#AstroLabeToLibMapDataConversionStub.lua
bst_ctl.lua
libs\ChatThrottleLib\ChatThrottleLib.xml
bst_range.lua
libs\LibRangeCheck-2.0\CallbackHandler-1.0\CallbackHandler-1.0.xml
libs\LibRangeCheck-2.0\LibRangeCheck-2.0.lua
#-libs\LibRangeCheck-2.0\CallbackHandler-1.0\CallbackHandler-1.0.xml
#-libs\LibRangeCheck-2.0\LibRangeCheck-2.0.lua
bst_mapdata.lua
libs\LibMapData-1.0\Libs\CallbackHandler-1.0
libs\LibMapData-1.0\library.lua
LibMapDataInit.lua
changes.lua
@ -107,7 +114,7 @@ recycle.lua
pattern.lua
# Database module. Depends on nothing, calls no external functions.
db_get.lua
#-db_get.lua
# Timeslice module. Depends on nothing, calls no external functions besides a few basic system-API things.
timeslice.lua
@ -122,30 +129,30 @@ manager_achievement.lua
manager_completed.lua
# Graph module. Depends on nothing, calls no external functions.
graph_core.lua
graph_flightpath.lua
#-graph_core.lua
#-graph_flightpath.lua
# Routing module. Depends on Timeslice and Filters, calls almost no external functions (handles its own get-player-position stuff via RetrieveRawLocation, but that's it.)
routing_debug.lua
routing_loc.lua
routing_route.lua
routing_core.lua
routing_controller.lua
#-routing_debug.lua
#-routing_loc.lua
#-routing_route.lua
#-routing_core.lua
#-routing_controller.lua
# this segment uses the menu system as well
routing_hidden.lua
#-routing_hidden.lua
# Filters. Pays attention to QH_pref but not a lot more.
filter_core.lua
filter_base.lua
#-filter_core.lua
#-filter_base.lua
# New tooltip system. Depends on nothing, calls nothing besides WoW UI.
tooltip.lua
# Directors
# Quest module. Depends on Database, Routing, Patterns, Tooltip, and Event Manager, interfaces with WoW UI.
director_quest.lua
director_achievement.lua
director_find.lua
#-director_quest.lua
#-director_achievement.lua
#-director_find.lua
# Map and minimap dodads. Old code. Depends on nothing, interfaces with WoW UI.
dodads.lua
@ -160,21 +167,21 @@ core.lua
radar.lua
upgrade.lua
#-upgrade.lua
main.lua
objective.lua
quest.lua
teleport.lua
pathfinding.lua
#-pathfinding.lua
routing.lua
custom.lua
menu.lua
nag.lua
comm.lua
mapbutton.lua
#-mapbutton.lua
flightpath.lua
tracker.lua
#-tracker.lua
objtips.lua
textviewer.lua
help.lua

Voir le fichier

@ -198,6 +198,7 @@ OnUpdate = function()
self:Show()
local dist, dx, dy = QuestHelper.Astrolabe:ComputeDistance(QuestHelper.collect_rc, QuestHelper.collect_rz, QuestHelper.collect_rx, QuestHelper.collect_ry, active_point.c, active_point.z, active_point.x, active_point.y)
--print(QuestHelper.collect_rc, QuestHelper.collect_rz, QuestHelper.collect_rx, QuestHelper.collect_ry, active_point.c, active_point.z, active_point.x, active_point.y)
local text = ""

Voir le fichier

@ -4,8 +4,8 @@ local GetTime = QuestHelper_GetTime
QuestHelper_File["collect.lua"] = "4.0.1.$svnversion$"
QuestHelper_Loadtime["collect.lua"] = GetTime()
local --[[ static ]] MINSVNVERSION = 185
local --[[ static ]] PURGEDEV = false
local --[[ static ]] MINSVNVERSION = 255
local --[[ static ]] PURGEDEV = true
local debug_output = false
if QuestHelper_File["collect.lua"] == "Development Version" then debug_output = true end

Voir le fichier

@ -34,11 +34,11 @@ local invloc_lookup_proto = {
INVTYPE_2HWEAPON = {"MainHandSlot"},
INVTYPE_WEAPONMAINHAND = {"MainHandSlot"},
INVTYPE_WEAPONOFFHAND = {"SecondaryHandSlot"},
INVTYPE_HOLDABLE = {"RangedSlot"},
INVTYPE_RANGED = {"RangedSlot"},
INVTYPE_THROWN = {"RangedSlot"},
INVTYPE_RANGEDRIGHT = {"RangedSlot"},
INVTYPE_RELIC = {"RangedSlot"},
--INVTYPE_HOLDABLE = {"RangedSlot"},
--INVTYPE_RANGED = {"RangedSlot"},
--INVTYPE_THROWN = {"RangedSlot"},
--INVTYPE_RANGEDRIGHT = {"RangedSlot"},
--INVTYPE_RELIC = {"RangedSlot"},
}
local invloc_lookup = {}

Voir le fichier

@ -13,11 +13,63 @@ local function signed(c)
--return strchar(c)
end
local dec2hex = {[0] = "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "A", "B", "C", "D", "E", "F"}
local hex2dec = {}
for k, v in pairs(dec2hex) do hex2dec[v] = k end
local function tohex(c)
return dec2hex[c]
end
local function lgToDec(c, pos)
if not c or c == "" then return 0 end
local ret = 0
pos = pos or 0
if pos == 0 then c = string.reverse(c) end
ret = todec(string.sub(c,1,1)) * math.pow(16, pos) + lgToDec(string.sub(c, 2), pos + 1)
return ret
end
local function lgToHex(c, pos)
local ret, rem, hex
pos = pos or 0
c = c or 0
local minVal = math.pow(16, pos)
local maxVal = math.pow(16, pos+1) - 1
if c > maxVal then
rem, hex = lgToHex(c, pos + 1)
else
rem, hex = c, ""
end
local mult = 0
while rem >= minVal do
mult = mult + 1
rem = rem - minVal
end
return rem, hex .. tohex(mult)
end
local function todec(c)
return hex2dec[c]
end
local function float(c)
-- if not c then c = -128 end
-- QuestHelper: Assert( c >= -128, string.format("c is too small. It is %s.", tostring(c)))
-- QuestHelper: Assert( c < 128, string.format("c is too big. It is %s.", tostring(c)))
local ret = tostring(c):gsub(",",".") -- eliminate issues with locales that use a comma as the decimal separator.
local ret = tohex(math.floor(128 * c))
return ret
end
@ -26,9 +78,10 @@ local function BolusizeLocation(delayed, c, z, x, y, dl, mid, mf, f)
-- x and y are floating-point values, generally between 0 and 1. We'll dedicate 24 bits to the fractional part, largely because we can.
-- Overall we're using a weird 11 bytes on this. Meh.
-- Also, any nil values are being turned into MIN_WHATEVER.
local float_x = float(x)
local float_y = float(y)
local float_x = x
local float_y = y
local loc = {}
--local locStr = (delayed and 1 or 0) .. lgToHex(mid) .. tohex(dl) .. float(x) .. float(y)
loc["delayed"] = (delayed and 1 or 0)
loc["c"] = c
loc["z"] = z

Voir le fichier

@ -36,7 +36,7 @@ local function MembersUpdate()
--QuestHelper:TextOut("MU start")
members = {} -- we burn a table every time this updates, but whatever
members_count = 0
if GetNumRaidMembers() > 0 then
if IsInRaid() then
-- we is in a raid
for i = 1, 40 do
local ite = string.format("raid%d", i)
@ -47,7 +47,7 @@ local function MembersUpdate()
--QuestHelper:TextOut(string.format("raid member %s added", UnitName(ite)))
end
end
elseif GetNumPartyMembers() > 0 then
elseif GetNumGroupMembers() > 0 then
-- we is in a party
for i = 1, 4 do
local ite = string.format("party%d", i)
@ -531,9 +531,7 @@ local function LootOpened()
for i = 1, GetNumLootItems() do
tex, name, quant, qual, locked = GetLootSlotInfo(i)
link = GetLootSlotLink(i)
local curr = LootSlotIsCurrency(i)
local coin = LootSlotIsCoin(i)
local itm = LootSlotIsItem(i)
local slotType = GetLootSlotType(i)
if quant == 0 then
-- moneys
@ -544,7 +542,7 @@ local function LootOpened()
tot = (tonumber(gold) or 0) * 10000 + (tonumber(silver) or 0) * 100 + (tonumber(copper) or 0) * 1
items[PseudoIDs["gold"]] = tot
else
if curr then
if slotType == LOOT_SLOT_CURRENCY then
if not QHC.PseudoIDs[name] then
QHC.PseudoIDsMin = QHC.PseudoIDsMin - 1
QHC.PseudoIDs[name] = QHC.PseudoIDsMin
@ -553,9 +551,9 @@ local function LootOpened()
else
if not link and not name then
local msg = "Texture is " .. tostring(tex) .. " with a quantity of " .. tostring(quant) .. ", a quality of " .. qual .. "."
if coin then
if slotType == LOOT_SLOT_MONEY then
QuestHelper:Assert(false, "Loot slot " .. tostring(i) .. " is coin. " .. msg)
elseif itm then
elseif slotType == LOOT_SLOT_ITEM then
QuestHelper:Assert(false, "Loot slot " .. tostring(i) .. " is item. " .. msg)
else
QuestHelper_ErrorCatcher_ExplicitError(false, "Loot slot " .. tostring(i) .. " is ???. " .. msg)

Voir le fichier

@ -16,7 +16,8 @@ local classlookup = {
["ROGUE"] = "R",
["SHAMAN"] = "S",
["WARLOCK"] = "L",
["WARRIOR"] = "W"
["WARRIOR"] = "W",
["MONK"] = "O"
};
local racelookup = {
@ -32,7 +33,8 @@ local racelookup = {
["Tauren"] = "N",
["Undead"] = "U",
["BloodElf"] = "B",
["Goblin"] = "L"
["Goblin"] = "L",
["Pandaren"] = "P"
-- lol i spelled nub
}
@ -46,7 +48,7 @@ local function GetSpecBolus()
--local bso = Bitstream.Output(8)
local talents = {}
local points = (GetUnspentTalentPoints() or 0)
--local points = (GetUnspentTalentPoints() or 0)
local talents_learned = false
for t = 1, GetNumTalentTabs() do -- come on. Is this ever not going to be 3? Seriously? Perhaps someday, but not as of Cat.
local _, tab, _, _, p, _, _, yn = GetTalentTabInfo(t)

Voir le fichier

@ -9,6 +9,6 @@ QuestHelper.Astrolabe = QH_Astrolabe_Ready and DongleStub("Astrolabe-0.4-QuestHe
local walker = QuestHelper:CreateWorldMapWalker()
QuestHelper.minimap_marker = QuestHelper:CreateMipmapDodad()
QH_Route_RegisterNotification(function (route) walker:RouteChanged(route) end)
QH_Route_RegisterNotification(function (route) QH_Tracker_UpdateRoute(route) end)
QH_Route_RegisterNotification(function (route) QuestHelper.minimap_marker:SetObjective(route[2]) end)
--QH_Route_RegisterNotification(function (route) walker:RouteChanged(route) end)
--QH_Route_RegisterNotification(function (route) QH_Tracker_UpdateRoute(route) end)
--QH_Route_RegisterNotification(function (route) QuestHelper.minimap_marker:SetObjective(route[2]) end)

Voir le fichier

@ -308,8 +308,8 @@ local elders = {
["Silvervein"] = "Loch Modan 33 46",
["Ironband"] = "Searing Gorge 21 79",
["Obsidian"] = "Silverpine Forest 45 41",
["Starglade"] = "Stranglethorn Vale 63 22", -- Jungle 71 34
["Winterhoof"] = "Stranglethorn Vale 37 79", -- Cape 39 72
["Starglade"] = "Northern Stranglethorn 71 34",
["Winterhoof"] = "The Cape of Stranglethorn 39 72", -- Cape 39 72
["Graveborn"] = "Tirisfal Glades 61 53",
["Moonstrike"] = "Western Plaguelands 69 73",
["Meadowrun"] = "Western Plaguelands 63 36",
@ -334,7 +334,18 @@ local elders = {
["Muraco"] = "Storm Peaks 64 51",
["Stonebeard"] = "Storm Peaks 31 38",
["Tauros"] = "Zul'Drak 59 56"
}
},
["Cataclysm"] = {
["Moonlance"] = "Shimmering Expanse 57, 86", -- Biel'aran Ridge, Shimmering Expanse
["Windsong"] = "Mount Hyjal 27 62", -- Sanctuary of Malorne, Hyjal
["Evershade"] = "Mount Hyjal 63 23", -- Nordrassil, Hyjal
["Stonebrand"] = "Deepholm 50 55", -- Temple of Earth, Deepholm
["Deepforge"] = "Deepholm 28 69", -- Stonehearth, Deepholm
["Menkhaf"] = "Uldum 66 19", -- Khartut's Tomb, Uldum
["Sekhemi"] = "Uldum 32 63", -- Ruins of Ammon, Uldum
["Firebeard"] = "Twilight Highlands 51 71", -- Dunward Town Square, Dunward Ruins, Twilight Highlands
["Darkfeather"] = "Twilight Highlands 52 33" -- Thundermar Ruins, Twilight Highlands
},
}
local function searchItem(input, yield_countdown, yield_countdown_max)

Voir le fichier

@ -122,6 +122,12 @@ end
function DB_HasItem(group, id)
QuestHelper: Assert(initted)
if group == "quest" then
if type(id) == "number" and id > 0 then return true
else return false
end
end
for _, db in ipairs(QHDB) do
if db[group] then
@ -137,6 +143,159 @@ function DB_HasItem(group, id)
return false
end
local function GetBlizzardQuestInfoFrameMainLoop(qid)
local POIFrame, questFrame
QuestMapUpdateAllQuests()
QuestPOIUpdateIcons()
WorldMapFrame_UpdateQuests()
for i = 1, MAX_NUM_QUESTS do
questFrame = _G["WorldMapQuestFrame" .. i]
if questFrame then
if questFrame.questId == qid then
POIFrame = questFrame.poiIcon
break
end
end
end
return questFrame, POIFrame
end
local function GetBlizzardQuestInfoFrame(qid, map)
if map then SetMapByID(map) end
QuestMapUpdateAllQuests()
QuestPOIUpdateIcons()
WorldMapFrame_UpdateQuests()
local POIFrame
local questFrame
local dLvl
if map and GetNumDungeonMapLevels() > 0 then -- Suspicion is that each dungeon level has to be iterated.
for i = 1, GetNumDungeonMapLevels() do
SetDungeonMapLevel(i)
questFrame, POIFrame = GetBlizzardQuestInfoFrameMainLoop(qid)
if POIFrame then
dLvl = i
break
end
end
else -- Only need to call once
questFrame, POIFrame = GetBlizzardQuestInfoFrameMainLoop(qid)
end
return questFrame, POIFrame, dLvl or 0
end
local function GetBlizzardQuestInfo(qid)
local questFrame, POIFrame, qdLvl = GetBlizzardQuestInfoFrame(qid)
local mapId = GetCurrentMapAreaID()
local c, z
local dLvl = false
local qMapId
if GetNumDungeonMapLevels() > 0 then dLvl = GetCurrentMapDungeonLevel() end
if not POIFrame then
-- Iterate over all maps to try and find it (we are of course assuming that the player has the quest, otherwise we will be SOL.
local maps = QuestHelper.LibMapData:GetAllMapIDs()
for _, map in pairs(maps) do
if map >= 0 and not QuestHelper.LibMapData:IsContinentMap(map) then
questFrame, POIFrame, qdLvl = GetBlizzardQuestInfoFrame(qid, map)
if POIFrame then
qMapId = map
break
end
end
end
c, z = GetCurrentMapContinent(), GetCurrentMapZone()
SetMapByID(mapId)
if not POIFrame then return nil end -- At this point we either have the quest or we are SOL.
else
qMapId = mapId
c, z = GetCurrentMapContinent(), GetCurrentMapZone()
end
local _, _, _, x, y = POIFrame:GetPoint()
if not x or not y then return nil end
local frame = WorldMapDetailFrame
local width, height = frame:GetWidth(), frame:GetHeight()
local wm_scale, poi_scale = frame:GetScale(), POIFrame:GetScale()
-- Convert from yards to %
local cx = ((x / (wm_scale / poi_scale)) / width)
local cy = ((-y / (wm_scale / poi_scale)) / height)
if cx < 0 or cx > 1 or cy < 0 or cy > 1 then return nil end
-- Now we want to convert to proper format for QH.
-- Look at WoWPro:findBlizzCoords(qid) for remainder
local _, contX, contY = QuestHelper.Astrolabe:GetAbsoluteContinentPosition(c, z, cx, cy)
--contX, contY = contX / QuestHelper.Astrolabe:GetZoneWidth(c, 0), contY / QuestHelper.Astrolabe:GetZoneHeight(c, 0)
local solid = { ["continent"] = c, contX - 10, contY - 10, contX + 10, contY - 10, contX + 10, contY + 10, contX - 10, contY + 10 }
local ret = {}
ret.solid = solid
ret.criteria = {}
local questIdx = GetQuestLogIndexByID(qid)
local numCrit = GetNumQuestLeaderBoards(questIdx)
local loc = { ["loc"] = { { ["p"] = qMapId, ["x"] = contX, ["y"] = contY} } }
for i = 1, numCrit do
table.insert(ret.criteria, loc)
end
ret.name = GetQuestLogTitle(questIdx)
ret.Blizzard = true
return ret
end
local function GetLightHeadedQuestInfo(qid)
if not LightHeaded or type(LightHeaded) ~= "table" then return nil end -- LH not loaded
local npcid, npcname, stype
local coords = {}
_, _, _, _, _, _, _, stype, npcname, npcid = LightHeaded:GetQuestInfo(qid)
-- Note: If we want the quest giver, we need fields 5, 6 and 7 above, rather than what we have gotten.
--
if stype == "npc" then
local data = LightHeaded:LoadNPCData(tonumber(npcid))
if not data then return end -- LightHeaded has no clue about the given NPC, despite giving us the id.
for zid,x,y in data:gmatch("([^,]+),([^,]+),([^:]+):") do
table.insert(coords, {["p"] = zid, ["x"] = x, ["y"] = y})
end
end
--can't return coordinates until we know more about what we are getting and then convert accordingly.
for k, v in pairs(coords) do for k1, v1 in pairs(v) do print(k, k1, v1) end end
--return coords
return nil
end
local function GetSelfQuestInfo(qid)
return nil
end
-- Returns x and y in yards relative to something... Continent?
local function GetQuestInfo(qid)
assert(type(qid) == "number")
local coords = GetSelfQuestInfo(qid)
--if not coords then coords = GetLightHeadedQuestInfo(qid) end
if not coords then
coords = GetBlizzardQuestInfo(qid)
end
return coords -- Might still be nil, but if we don't have anything from Blizz, prolly nothing can be done.
end
function DB_GetItem(group, id, silent, register)
QuestHelper: Assert(initted)
@ -145,6 +304,15 @@ function DB_GetItem(group, id, silent, register)
QuestHelper: Assert(id, string.format("%s %s", tostring(group), tostring(id)))
local ite = DBC_Get(group, id)
if not ite and group == "flightpaths" then return nil end
if not ite and group == "quest" then
-- Loop over zones AND floors
-- see QuestRouterLite.lua for specific calls.
-- In the end, the item returned MUST be "formatted" the same as a true QHDB item.
ite = GetQuestInfo(id)
end
if not ite then
if type(id) == "string" then QuestHelper: Assert(not id:match("__.*")) end
@ -232,7 +400,9 @@ function DB_ReleaseItem(ite)
if frequencies[ite] == 0 then
--print("incinerating", freq_group[ite], freq_id[ite])
cache[freq_group[ite]][freq_id[ite]] = nil
if cache[freq_group[ite]] then
cache[freq_group[ite]][freq_id[ite]] = nil
end
freq_group[ite] = nil
freq_id[ite] = nil

Voir le fichier

@ -289,20 +289,12 @@ function GetAchievementMetaObjective(achievement)
if data.chunk then
ttx.solid = horribledupe(data.chunk.solid)
if data.chunk.loc then for _, v in ipairs(data.chunk.loc) do
-- Ugly database hack
if v.p == 26 then v.p = 48 end
if v.p == 38 then v.p = 168 end
-- end hack
table.insert(ttx, {loc = {x = v.x, y = v.y, c = QuestHelper_ParentLookup[v.p], p = v.p}})
end end
end
if data.loc then
ttx.solid = data.solid
-- Ugly database hack
if data.loc.p == 26 then data.loc.p = 48 end
if data.loc.p == 38 then data.loc.p = 168 end
-- end hack
table.insert(ttx, {loc = {x = data.loc.x, y = data.loc.y, c = QuestHelper_ParentLookup[data.loc.p], p = data.loc.p}})
end

Voir le fichier

@ -71,10 +71,6 @@ local function generate_objective(dbi)
for _, v in ipairs(dbi.loc) do
QuestHelper: Assert(QuestHelper_ParentLookup)
QuestHelper: Assert(QuestHelper_ParentLookup[v.p], v.p)
-- Ugly database hack
if v.p == 26 then v.p = 48 end
if v.p == 38 then v.p = 168 end
-- end hack
table.insert(clooster, {loc = {x = v.x, y = v.y, c = QuestHelper_ParentLookup[v.p], p = v.p}, cluster = clooster, tracker_hidden = true, why = why, map_desc = {QuestHelper:HighlightText(dbi.name)}, tracker_desc = dbi.name, map_suppress_ignore = true, map_custom_menu = function (menu) QuestHelper:CreateMenuItem(menu, QHText("FIND_REMOVE")):SetFunction(function () QH_Route_ClusterRemove(clooster) end) end})
end
@ -140,124 +136,214 @@ local function QH_FindLoc(locd)
end
local elders = {
["Alliance"] = {
["Bladeswift"] = {21, 39, 32}, --"Darnassus 39 32",
["Bronzebeard"] = {25, 29, 16}, --"Ironforge 29 16",
["Hammershout"] = {37, 2, 10}, --"Elwynn Forest 34 50"
["Alliance"] = { -- Achievement 915
["Bladeswift"] = {381, 39, 32, 8718, 1999}, --"Darnassus 39 32",
["Bronzebeard"] = {341, 29, 16, 8866, 1997}, --"Ironforge 29 16",
["Hammershout"] = { 30, 2, 10, 8646, 1998}, --"Elwynn Forest 34 50"
},
["Horde"] = {
["Darkhorn"] = {1, 52, 60}, --"Orgrimmar 52 60",
["Wheathoof"] = {23, 73.0, 23.3}, --"Thunder Bluff 73.0 23.3",
["Darkcore"] = {45, 67, 38}, --"Undercity 67 38"
["Horde"] = { -- Achievement 914
["Darkhorn"] = {321, 52, 60, 8677, 1991}, --"Orgrimmar 52 60",
["Wheathoof"] = {362, 73.0, 23.3, 8678, 1993}, --"Thunder Bluff 73.0 23.3",
["Darkcore"] = {382, 67, 38, 8648, 1992}, --"Undercity 67 38"
},
["Kalimdor"] = {
["Riversong"] = {2, 35.5, 48.9}, --"Ashenvale 35.5 48.9",
["Skygleam"] = {15, 64.8, 79.3}, --"Azshara 64.8 79.3",
["High Mountain"] = {203, 41.5, 47.5}, --"Southern Barrens 41.5 47.5",
["Moonwarden"] = {11, 48.5, 59.2}, --"Northern Barrens 48.5 59.2",
["Windtotem"] = {11, 68.4, 70}, --"Northern Barrens 68.4 70",
["Starweave"] = {16, 49.5, 19.0}, --"Darkshore 49.5 19.0", NOTE TO SELF -- CONVERTING TO LOOKUP VALUES DON'T FORGET TO CHANGE THE FUNCTION!!!!!!!
["Runetotem"] = {7, 53.2, 43.6}, --"Durotar 53.2 43.6",
["Nightwind"] = {13, 38.3, 52.9}, --"Felwood 38.3 52.9",
["Grimtotem"] = {17, 76.7, 37.9}, --"Feralas 76.7 37.9",
["Mistwalker"] = {17, 62.6, 31.1}, --"Feralas 62.6 31.1",
["Bloodhoof"] = {22, 48, 53}, --"Mulgore 48 53",
["Bladesing"] = {5, 53, 35}, --"Silithus 53 35",
["Primestone"] = {5, 30.7, 13.3}, --"Silithus 30.7 13.3",
["Dreamseer"] = {8, 50, 28}, --"Tanaris 50 28",
["Ragetotem"] = {8, 36, 80}, --"Tanaris 36 80",
["Bladeleaf"] = {24, 56.8, 53.1}, --"Teldrassil 56.8 53.1",
["Skyseer"] = {14, 46.3, 51.0}, --"Thousand Needles 46.3 51.0",
["Morningdew"] = {14, 77.0, 75.6}, --"Thousand Needles 77.0 75.6",
["Thunderhorn"] = {18, 51, 75}, --"Un'Goro Crater 51 75",
["Brightspear"] = {19, 53.0, 56.7}, --"Winterspring 53.0 56.7",
["Stonespire"] = {19, 60.0, 50.0}, --"Winterspring 60.0 50.0",
["Kalimdor"] = { -- Achievement 911
["Bladeleaf"] = { 41, 56.8, 53.1, 8715, 1951}, --"Teldrassil 56.8 53.1",
["Bladesing"] = {261, 53, 35, 8719, 1966}, --"Silithus 53 35",
["Bloodhoof"] = { 9, 48, 53, 8673, 1953}, --"Mulgore 48 53",
["Brightspear"] = {281, 53.0, 56.7, 8726, 1963}, --"Winterspring 53.0 56.7",
["Dreamseer"] = {161, 50, 28, 8684, 1961}, --"Tanaris 50 28",
["Grimtotem"] = {121, 76.7, 37.9, 8679, 1955}, --"Feralas 76.7 37.9",
["High Mountain"] = {607, 41.5, 47.5, 8686, 1919}, --"Southern Barrens 41.5 47.5",
["Mistwalker"] = {121, 62.6, 31.1, 8685, 1956}, --"Feralas 62.6 31.1",
["Moonwarden"] = { 11, 48.5, 59.2, 8717, 1918}, --"Northern Barrens 48.5 59.2",
["Morningdew"] = { 61, 77.0, 75.6, 8724, 1959}, --"Thousand Needles 77.0 75.6",
["Nightwind"] = {182, 38.3, 52.9, 8723, 1957}, --"Felwood 38.3 52.9",
["Primestone"] = {261, 30.7, 13.3, 8654, 1965}, --"Silithus 30.7 13.3",
["Ragetotem"] = {161, 36, 80, 8671, 1960}, --"Tanaris 36 80",
["Riversong"] = { 43, 35.5, 48.9, 8725, 1954}, --"Ashenvale 35.5 48.9",
["Runetotem"] = { 4, 53.2, 43.6, 8670, 1916}, --"Durotar 53.2 43.6",
["Skygleam"] = {181, 64.8, 79.3, 8720, 1917}, --"Azshara 64.8 79.3",
["Skyseer"] = { 61, 46.3, 51.0, 8682, 1958}, --"Thousand Needles 46.3 51.0",
["Starweave"] = { 42, 49.5, 19.0, 8721, 1952}, --"Darkshore 49.5 19.0",
["Stonespire"] = {281, 60.0, 50.0, 8672, 1964}, --"Winterspring 60.0 50.0",
["Thunderhorn"] = {201, 51, 75, 8681, 1962}, --"Un'Goro Crater 51 75",
["Windtotem"] = { 11, 68.4, 70, 8680, 1920}, --"Northern Barrens 68.4 70",
},
["Eastern Kingdoms"] = {
["Bellowrage"] = {33, 54, 49}, --"Blasted Lands 54 49",
["Rumblerock"] = {40, 70, 45}, --"Burning Steppes 70 45",
["Dawnstrider"] = {40, 53, 24}, --"Burning Steppes 53 24",
["Goldwell"] = {28, 53.9, 49.9}, --"Dun Morogh 53 49",
["Windrun"] = {34, 35.6, 68.8}, --"Eastern Plaguelands 35 68",
["Snowcrown"] = {34, 75.7, 54.5}, --"Eastern Plaguelands 75.7 54.5",
["Stormbrow"] = {37, 40, 63}, --"Elwynn Forest 40 63",
["Highpeak"] = {42, 50, 48}, --"Hinterlands 50 48",
["Silvervein"] = {29, 33, 46}, --"Loch Modan 33 46",
["Ironband"] = {32, 21, 79}, --"Searing Gorge 21 79",
["Obsidian"] = {35, 45, 41}, --"Silverpine Forest 45 41",
["Starglade"] = {38, 63, 22}, --"Stranglethorn Vale 63 22", -- Jungle 71 34
["Winterhoof"] = {38, 37, 39}, --"Stranglethorn Vale 37 79", -- Cape 39 72
["Graveborn"] = {43, 61, 53}, --"Tirisfal Glades 61 53",
["Moonstrike"] = {50, 69, 73}, --"Western Plaguelands 69 73",
["Meadowrun"] = {50, 63.5, 36.2}, --"Western Plaguelands 63 36",
["Skychaser"] = {49, 56, 47}, --"Westfall 56 47"
["Eastern Kingdoms"] = { -- Achievement 912
["Bellowrage"] = {19, 54, 49, 8647}, --"Blasted Lands 54 49",
["Rumblerock"] = {29, 70, 45, 8636}, --"Burning Steppes 70 45",
["Dawnstrider"] = {29, 53, 24, 8683}, --"Burning Steppes 53 24",
["Goldwell"] = {27, 53.9, 49.9, 8653}, --"Dun Morogh 53 49",
["Windrun"] = {23, 35.6, 68.8, 8688}, --"Eastern Plaguelands 35 68",
["Snowcrown"] = {23, 75.7, 54.5, 8650}, --"Eastern Plaguelands 75.7 54.5",
["Stormbrow"] = {30, 40, 63, 8649}, --"Elwynn Forest 40 63",
["Highpeak"] = {26, 50, 48, 8643}, --"Hinterlands 50 48",
["Silvervein"] = {35, 33, 46, 8642}, --"Loch Modan 33 46",
["Ironband"] = {28, 21, 79, 8651}, --"Searing Gorge 21 79",
["Obsidian"] = {21, 45, 41, 8645}, --"Silverpine Forest 45 41",
["Starglade"] = {37, 71, 34, 8716}, --"Northern Stranglethorn 71 34"
["Winterhoof"] = {673, 39, 72, 8674}, --"The Cape of Stranglethorn 39 72"
["Graveborn"] = {20, 61, 53, 8652}, --"Tirisfal Glades 61 53",
["Moonstrike"] = {22, 69, 73, 8714}, --"Western Plaguelands 69 73",
["Meadowrun"] = {22, 63.5, 36.2, 8722}, --"Western Plaguelands 63 36",
["Skychaser"] = {39, 56, 47, 8675}, --"Westfall 56 47"
},
["Northrend"] = {
["Arp"] = {65, 57, 44}, --"Borean Tundra 57 44",
["Northal"] = {65, 34, 34}, --"Borean Tundra 34 34",
["Pamuya"] = {65, 43, 50}, --"Borean Tundra 43 50",
["Sardis"] = {65, 59, 66}, --"Borean Tundra 59 66",
["Morthie"] = {68, 30, 56}, --"Dragonblight 30 56",
["Skywarden"] = {68, 35, 48}, --"Dragonblight 35 48",
["Thoim"] = {68, 49, 78}, --"Dragonblight 49 78",
["Beldak"] = {69, 61, 28}, --"Grizzly Hills 61 28",
["Lunaro"] = {69, 81, 37}, --"Grizzly Hills 81 37",
["Whurain"] = {69, 64, 47}, --"Grizzly Hills 64 47",
["Bluewolf"] = {74, 49, 14}, --"Wintergrasp 49 14",
["Sandrene"] = {72, 50, 64}, --"Sholazar Basin 50 64",
["Wanikaya"] = {72, 64, 49}, --"Sholazar Basin 64 49",
["Fargal"] = {73, 29, 74}, --"Storm Peaks 29 74",
["Graymane"] = {73, 41, 85}, --"Storm Peaks 41 85",
["Muraco"] = {73, 64, 51}, --"Storm Peaks 64 51",
["Stonebeard"] = {73, 31, 38}, --"Storm Peaks 31 38",
["Tauros"] = {75, 59, 56}, --"Zul'Drak 59 56"
["Northrend"] = { -- Achievement 1396
["Arp"] = {486, 57, 44, 13033, 5145}, --"Borean Tundra 57 44",
["Northal"] = {486, 34, 34, 13016, 5146}, --"Borean Tundra 34 34",
["Pamuya"] = {486, 43, 50, 13029, 5157}, --"Borean Tundra 43 50",
["Sardis"] = {486, 59, 66, 13012, 5141}, --"Borean Tundra 59 66",
["Morthie"] = {488, 30, 56, 13014, 5143}, --"Dragonblight 30 56",
["Skywarden"] = {488, 35, 48, 13031, 5159}, --"Dragonblight 35 48",
["Thoim"] = {488, 49, 78, 13019, 5154}, --"Dragonblight 49 78",
["Beldak"] = {490, 61, 28, 13013, 5142}, --"Grizzly Hills 61 28",
["Lunaro"] = {490, 81, 37, 13025, 5149}, --"Grizzly Hills 81 37",
["Whurain"] = {490, 64, 47, 13030, 5158}, --"Grizzly Hills 64 47",
["Bluewolf"] = {501, 49, 14, 13026, 5150}, --"Wintergrasp 49 14",
["Sandrene"] = {493, 50, 64, 13018, 5147}, --"Sholazar Basin 50 64",
["Wanikaya"] = {493, 64, 49, 13024, 5148}, --"Sholazar Basin 64 49",
["Fargal"] = {495, 29, 74, 13015, 5144}, --"Storm Peaks 29 74",
["Graymane"] = {495, 41, 85, 13028, 5155}, --"Storm Peaks 41 85",
["Muraco"] = {495, 64, 51, 13032, 5160}, --"Storm Peaks 64 51",
["Stonebeard"] = {495, 31, 38, 13020, 5156}, --"Storm Peaks 31 38",
["Tauros"] = {496, 59, 56, 13027, 5151}, --"Zul'Drak 59 56"
},
["Cataclysm"] = { -- Achievement 6006
["Moonlance"] = {615, 57, 86, 29738, 18154}, -- Biel'aran Ridge, Shimmering Expanse
["Windsong"] = {606, 27, 62, 29739, 18156}, -- Sanctuary of Malorne, Hyjal
["Evershade"] = {606, 63, 23, 29740, 18155}, -- Nordrassil, Hyjal
["Stonebrand"] = {640, 50, 55, 29735, 18157}, -- Temple of Earth, Deepholm
["Deepforge"] = {640, 28, 69, 29734, 18158}, -- Stonehearth, Deepholm
["Menkhaf"] = {720, 66, 19, 29742, 18159}, -- Khartut's Tomb, Uldum
["Sekhemi"] = {720, 32, 63, 29741, 18160}, -- Ruins of Ammon, Uldum
["Firebeard"] = {700, 51, 71, 29737, 18161}, -- Dunward Town Square, Dunward Ruins, Twilight Highlands
["Darkfeather"] = {700, 52, 33, 29736, 18162} -- Thundermar Ruins, Twilight Highlands
},
--[===[ Placeholder for Elders of the Dungeons. If enabled prior to 2013, stored coordinates should be the map ID of the zone where the instance is located and the coordinates of the entrance. With any luck, by 2013 dungeons will be mapable. Coordinates listed in comment after each elder need to have floor numbers determined, where necessary, ASAP.
["Dungeons"] = { -- Achievement 910
["Wildmane"] = {,,,8676, 1910}, -- Zul'Farrak 34.52 39.35
["Splitrock"] = {,,,8635, 1912}, -- Maraudon 51.47, 93.7
["Morndeep"] = {,,,8619, 1914}, -- Blackrock Depths 50.52 62.97
["Jarten"] = {,,,13017, 5259}, -- Utgarde Keep 47.4, 69.54
["Nurgen"] = {,,,13022, 5261}, -- Azjol-Nerub 21.78 43.62
["Ohanzee"] = {,,,13065, 5263}, -- Gundrak 45.7 61.55
["Chogan'gada"] = {,,,13067, 5265}, -- Utgarde Pinnacle 47.71 22.99
["Starsong"] = {,,,8713, 1911}, -- Sunken Temple 62.92 34.46
["Stonefort"] = {,,,8644, 1913}, -- Blackrock Spire 61.82 40
["Farwhisper"] = {,,,8727, 1915}, -- Stratholme 78.62 22.14
["Igasho"] = {,,,13021, 5260}, -- The Nexus 55.18 64.74
["Kilias"] = {,,,13023, 5262}, -- Drak'tharon Keep 68.85 79.17
["Yurauk"] = {,,,13066, 5264} -- Halls of Stone 29.39 62.03
}
--]===]
}
local function QH_FindElders(elder_or_achievement, all_elders)
trackedElders = {}
local function UpdateElders()
local elder, elderinfo
local qid = GetQuestID()
for elder, elderinfo in pairs(trackedElders) do
local z, x, y, id = unpack(elderinfo)
if id == qid then
QH_FindCoord(x, y, z, elder)
trackedElders[elder] = nil
return
end
end
end
QH_Event("QUEST_COMPLETE", UpdateElders)
local function QH_FindElders(elder_or_achievement, all_elders, forAchievement)
if elder_or_achievement == "CLEAR" then
for elder, elderinfo in pairs(trackedElders) do
local z, x, y = unpack(elderinfo)
QH_FindCoord(x, y, z, elder)
end
trackedElders = {}
return
end
local achievement_match, elder_match = false, false
local elderCount = 0
for achievement, eldrs in pairs(elders) do
if not all_elders then
if elder_or_achievement == string.upper(achievement) then achievement_match = true end
end
for elder, elder_loc in pairs(eldrs) do
if not all_elders then
if achievement_match then -- just add it
local locz, locx, locy = unpack(elder_loc)
for elder, elder_info in pairs(eldrs) do
local locz, locx, locy, qid, aid = unpack(elder_info)
local okToAdd = true
if forAchievement then
if aid then
local _, _, completed = GetAchievementCriteriaInfo(aid)
if completed then okToAdd = false end
end
elseif qid and QHQuestsCompleted and QHQuestsCompleted[qid] then
okToAdd = false
end
if okToAdd then
if not all_elders then
if achievement_match then -- just add it
QH_FindCoord(locx, locy, locz, elder)
if trackedElders[elder] then trackedElders[elder] = nil
else
trackedElders[elder] = elder_info
elderCount = elderCount + 1
end
elseif elder_or_achievement == string.upper(elder) then -- We have input and it's not an achievement, so it must be an elder.
elder_match = true
QH_FindCoord(locx, locy, locz, elder)
if trackedElders[elder] then trackedElders[elder] = nil
else
trackedElders[elder] = elder_info
elderCount = elderCount + 1
end
break -- We've found him or her.
end -- No need for else here. We alread know we don't need everything so we either have an achievement or we have an elder.
else -- We came in without an input, therefore we add all.
QH_FindCoord(locx, locy, locz, elder)
elseif elder_or_achievement == string.upper(elder) then -- We have input and it's not an achievement, so it must be an elder.
elder_match = true
local locz, locx, locy = unpack(elder_loc)
QH_FindCoord(locx, locy, locz, elder)
break -- We've found him or her.
end -- No need for else here. We alread know we don't need everything so we either have an achievement or we have an elder.
else -- We came in without an input, therefore we add all.
local locz, locx, locy = unpack(elder_loc)
QH_FindCoord(locx, locy, locz, elder)
if trackedElders[elder] then trackedElders[elder] = nil
else
trackedElders[elder] = elder_info
elderCount = elderCount + 1
end
end
end
end
if achievement_match or elder_match then break end -- We've done our match.
end
if elderCount == 0 then QuestHelper:TextOut("No elders were added.") end
end
function QH_FindName(name)
local locd = name:match("^loc (.+)")
local elder_loc
local forAchievement = false, elder_loc, temp
if not locd then
if name:find("^elders?") then
elder_loc = name:match("elders? (.+)")
if not elder_loc then elder_loc = true end
if name:find("^elders? achievement") then
forAchievement = true
elder_loc = name:match("elders? achievement (.+)")
else
elder_loc = name:match("elders? (.+)")
end
end
end
if locd then
QH_FindLoc(locd)
elseif elder_loc then
if elder_loc == true then QH_FindElders(nil, true)
else QH_FindElders(string.upper(elder_loc))
if elder_loc == true then QH_FindElders(nil, true, forAchievement)
else QH_FindElders(string.upper(elder_loc), false, forAchievement)
end
else
if not DB_Ready() then
@ -286,10 +372,6 @@ function QH_FindName(name)
--[[ assert(dbi) ]]
if dbi.loc then
-- Ugly database hack
if dbi.loc.p == 26 then dbi.loc.p = 48 end
if dbi.loc.p == 38 then dbi.loc.p = 168 end
-- end hack
table.insert(found_db, dbi)
if has_name[dbi.name] then needs_postfix[dbi.name] = true end

Voir le fichier

@ -48,10 +48,6 @@ local function AppendObjlinks(target, source, tooltips, icon, last_name, map_lin
for m, v in ipairs(source.loc) do
QuestHelper: Assert(target)
QuestHelper: Assert(QuestHelper_ParentLookup)
-- Ugly database hack
if v.p == 26 then v.p = 48 end -- Alterac Mountains merged to Hillsbrad Foothills
if v.p == 38 then v.p = 168 end -- Ditto Stranglethorn
-- end hack
QuestHelper: Assert(QuestHelper_ParentLookup[v.p], v.p)
table.insert(target, {loc = {x = v.x, y = v.y, c = QuestHelper_ParentLookup[v.p], p = v.p}, path_desc = copy(map_lines), icon_id = icon or 6})
end
@ -121,6 +117,7 @@ local function GetQuestMetaobjective(questid, lbcount, qindex)
if not quest_list[questid] then
local q = DB_GetItem("quest", questid, true, true)
--[==[
if not lbcount then
QuestHelper: TextOut("Missing lbcount, guessing wildly")
if q and q.criteria then
@ -132,16 +129,19 @@ local function GetQuestMetaobjective(questid, lbcount, qindex)
lbcount = 0 -- heh
end
end
--]==]
-- just doublechecking here
if not QuestCriteriaWarningBroadcast and q and q.criteria then for k, v in pairs(q.criteria) do
if type(k) == "number" and k > lbcount then
--QuestHelper:TextOut(string.format("Too many stored objectives for this quest, please report on the Questhelper homepage (%s %s %s)", questid, lbcount, k)) -- we're just going to hide this for now
QuestHelper:TextOut(string.format("Too many stored objectives for this quest, please report on the Questhelper homepage (%s %s %s)", questid, lbcount, k)) -- we're just going to hide this for now
--[==[
if qindex then
QuestHelper_ErrorCatcher_ExplicitError(false, string.format("Too many stored objectives (%s %s %s %s)", questid, lbcount, k, select(1, GetQuestLogTitle(qindex))))
else
QuestHelper_ErrorCatcher_ExplicitError(false, string.format("Too many stored objectives (%s %s %s %s)", questid, lbcount, k, v))
end
--]==]
QuestCriteriaWarningBroadcast = true
end
end end
@ -159,13 +159,6 @@ local function GetQuestMetaobjective(questid, lbcount, qindex)
if qindex < 0 or (desc and typ ~= "log") then -- Ignore if no description.
--QuestHelper:TextOut(string.format("critty %d %d", k, c.loc and #c.loc or -1))
--[[
if done then
print(string.format("Quest %s, Objective %s('%s') is done.", qindex, i, desc))
else
print(string.format("Quest %s, Objective %s('%s') is not done.", qindex, i, desc))
end
]]
ttx.tooltip_canned = {}
if q and q.criteria and q.criteria[i] then
@ -181,7 +174,7 @@ local function GetQuestMetaobjective(questid, lbcount, qindex)
end
if #ttx == 0 then
table.insert(ttx, {loc = {x = 5000, y = 5000, c = 0, p = 2}, icon_id = 7, type_quest_unknown = true, map_desc = {"Unknown"}}) -- this is Ashenvale, for no particularly good reason
table.insert(ttx, {loc = {x = 5000, y = 5000, c = 0, p = 43}, icon_id = 7, type_quest_unknown = true, map_desc = {"Unknown"}}) -- this is Ashenvale, for no particularly good reason
ttx.type_quest_unknown = true
end
@ -201,32 +194,29 @@ local function GetQuestMetaobjective(questid, lbcount, qindex)
end
do
local ttx = {type_quest_finish = true}
--QuestHelper:TextOut(string.format("finny %d", q.finish.loc and #q.finish.loc or -1))
if q and q.finish and q.finish.loc then
ttx.solid = horribledupe(q.finish.solid)
for m, v in ipairs(q.finish.loc) do
--print(v.rc, v.rz)
--print(QuestHelper_IndexLookup[v.rc])
--print(QuestHelper_IndexLookup[v.rc][v.rz])
-- Ugly database hack
if v.p == 26 then v.p = 48 end
if v.p == 38 then v.p = 168 end
-- end hack
table.insert(ttx, {desc = "Turn in quest", why = ite, loc = {x = v.x, y = v.y, c = QuestHelper_ParentLookup[v.p], p = v.p}, tracker_hidden = true, cluster = ttx, icon_id = 7, type_quest = ite.type_quest})
if q and q.finish and q.loc then
local ttx = {type_quest_finish = true}
--QuestHelper:TextOut(string.format("finny %d", q.finish.loc and #q.finish.loc or -1))
if q and q.finish and q.finish.loc then
ttx.solid = horribledupe(q.finish.solid)
for m, v in ipairs(q.finish.loc) do
--print(v.rc, v.rz)
--print(QuestHelper_IndexLookup[v.rc])
--print(QuestHelper_IndexLookup[v.rc][v.rz])
table.insert(ttx, {desc = "Turn in quest", why = ite, loc = {x = v.x, y = v.y, c = QuestHelper_ParentLookup[v.p], p = v.p}, tracker_hidden = true, cluster = ttx, icon_id = 7, type_quest = ite.type_quest})
end
end
end
if #ttx == 0 then
table.insert(ttx, {desc = "Turn in quest", why = ite, loc = {x = 5000, y = 5000, c = 0, p = 2}, tracker_hidden = true, cluster = ttx, icon_id = 7, type_quest = ite.type_quest, type_quest_unknown = true}) -- this is Ashenvale, for no particularly good reason
ttx.type_quest_unknown = true
end
if #ttx == 0 then
table.insert(ttx, {desc = "Turn in quest", why = ite, loc = {x = 5000, y = 5000, c = 0, p = 43}, tracker_hidden = true, cluster = ttx, icon_id = 7, type_quest = ite.type_quest, type_quest_unknown = true}) -- this is Ashenvale, for no particularly good reason
ttx.type_quest_unknown = true
end
ite.finish = ttx
ite.finish = ttx
end
end
quest_list[questid] = ite
if q then DB_ReleaseItem(q) end
end
@ -812,7 +802,9 @@ function QH_UpdateQuests(force)
end
end
db.finish.tooltip_defer_questname = title -- we're using this as our fallback right now
if db.finish then
db.finish.tooltip_defer_questname = title -- we're using this as our fallback right now
end
next_chunks[id] = chunk

Voir le fichier

@ -427,6 +427,26 @@ local function rightclick_menu(obj)
end
end
function QuestHelper:PlaceIconOnWorldMap( worldMapFrame, icon, map, dLvl, xPos, yPos )
assert(type(worldMapFrame) == "table")
assert(worldMapFrame.GetWidth and worldmapFrame.GetHeight)
assert(type(icon) == "table")
assert(icon.SetPoint and icon.ClearAllPoints)
assert(type(map) == "number")
assert(type(dLvl) == "number" or dLvl == nil)
assert(type(xPos) == "number")
assert(type(yPos) == "number")
if dLvl == nil then dLvl = 0 end
if map == -1 then return end -- Can't do anything without continent knowledge
local nMap, nFloor = GetCurrentMapAreaID(), GetCurrentMapDungeonLevel() or 0
local nCont
if nMap == -1 then cont = GetCurrentMapContinent() end
end
function QuestHelper:CreateWorldMapDodad(objective, nxt)
local icon = CreateFrame("Button", nil, QuestHelper.map_overlay)
icon:SetFrameStrata("FULLSCREEN")

Voir le fichier

@ -151,17 +151,8 @@ function QH_Graph_Pathmultifind(st, nda, reverse, make_path)
--stats.dests_complex = 0
--stats.dests_total = 0
-- Ugly database hack
if st.p == 26 then st.p = 48 end -- Alterac Mountains merged to Hillsbrad Foothills
if st.p == 38 then st.p = 168 end -- Ditto Stranglethorn
-- end hack
for k, v in ipairs(nda) do
QuestHelper: Assert(v.x and v.y and v.p)
-- Ugly database hack pt. 2
if v.p == 26 then v.p = 48 end -- Alterac Mountains merged to Hillsbrad Foothills
if v.p == 38 then v.p = 168 end -- Ditto Stranglethorn
-- end hack
local cpvp = canoplane(v.p)
if plane[cpvp] then
--print("Destination plane insertion")

Voir le fichier

@ -194,7 +194,6 @@ function Astrolabe:GetMapVirtualZones(zone)
return {[1] = k}
end
end
local curMapID = GetCurrentMapAreaID()
local zones = {GetMapZones(zone)}
@ -290,6 +289,8 @@ function Astrolabe:ComputeDistance( c1, z1, x1, y1, c2, z2, x2, y2 )
return dist, xDelta, yDelta;
end
local yards
function Astrolabe:TranslateWorldMapPosition( C, Z, xPos, yPos, nC, nZ )
--[[
argcheck(C, 2, "number");
@ -326,7 +327,7 @@ function Astrolabe:TranslateWorldMapPosition( C, Z, xPos, yPos, nC, nZ )
zoneData = WorldMapSize[C];
local parentContinent = zoneData.parentContinent;
xPos, yPos = getContPosition(zoneData, Z, xPos, yPos);
if not xPos or not yPos then return end -- there is no such zone. why are you asking me such silly things? you are a terrible person. leave me in my despair.
if not xPos or not yPos then return end -- there is no such zone. why are you asking me such silly things? you are a terrible person. leave me in my despair.
if ( C ~= parentContinent ) then
-- translate up to world map if we aren't there already
xPos = xPos + zoneData.xOffset;
@ -380,6 +381,14 @@ function Astrolabe:GetZoneWidth(c, z)
end
end
function Astrolabe:GetZoneHeight(c, z)
if z ~= 0 then
return WorldMapSize[c][z].height
else
return WorldMapSize[c].height
end
end
--*****************************************************************************
-- This function will do its utmost to retrieve some sort of valid position
-- for the specified unit, including changing the current map zoom (if needed).
@ -1197,8 +1206,8 @@ WorldMapSize = {
AhnQirajTheFallenKingdom = {
height = 2700.0,
width = 4049.99983215332,
xOffset = 0,
yOffset = 0,
xOffset = -3891.6665,
yOffset = -8033.333,
mapID = 772
},
Ashenvale = {
@ -1223,8 +1232,8 @@ WorldMapSize = {
mapID = 3524,
},
Barrens = {
height = 6756.202067150937,
width = 10133.44343943073,
height = 3831.24987792969,
width = 5745.83332824707,
xOffset = 14443.84117394525,
yOffset = 11187.32013604393,
mapID = 17,
@ -1288,15 +1297,15 @@ WorldMapSize = {
Hyjal = {
height = 2831.24975585938,
width = 4245.83337402344,
xOffset = 0,
yOffset = 0,
xOffset = 929.167,
yOffset = 6195.833,
mapID = 606
},
Hyjal_terrain1 = {
height = 2831.24975585938,
width = 4245.83337402344,
xOffset = 0,
yOffset = 0,
xOffset = 929.167,
yOffset = 6195.833,
mapID = 683
},
Moonglade = {
@ -1330,8 +1339,8 @@ WorldMapSize = {
SouthernBarrens = {
height = 4941.66665649414,
width = 7412.5,
xOffset = 0,
yOffset = 0,
xOffset = -1356.25,
yOffset = 204.167,
mapID = 607
},
StonetalonMountains = {
@ -1379,8 +1388,8 @@ WorldMapSize = {
Uldum = {
height = 4129.16650390625,
width = 6193.74975585938,
xOffset = 0,
yOffset = 0,
xOffset = -2441.667,
yOffset = -8029.1665,
mapID = 720
},
UngoroCrater = {
@ -1520,17 +1529,17 @@ WorldMapSize = {
mapID = 44,
},
RuinsofGilneas = {
height = 889.583251953125,
width = 593.749877929688,
xOffset = 0,
yOffset = 0,
height = 2097.916668701172,
width = 3145.83325195312,
xOffset = -3439.583,
yOffset = -533.333,
mapID = 611
},
RuinsofGilneasCity = {
height = 889.583251953125,
width = 593.749877929688,
xOffset = 0,
yOffset = 0,
xOffset = -1933.333,
yOffset = -1306.25,
mapID = 685
},
SearingGorge = {
@ -1562,8 +1571,8 @@ WorldMapSize = {
mapID = 1519,
},
StranglethornVale = { -- Split to Vale, Jungle and Cape
height = 4254.18312444072,
width = 6381.248484543122,
height = 4368.75,
width = 6552.0830078125,
xOffset = 15951.13375783437,
yOffset = 22345.18258706305,
mapID = 33,
@ -1571,8 +1580,8 @@ WorldMapSize = {
StranglethornJungle = {
height = 2733.3330078125,
width = 4099.99987792969,
xOffset = 0,
yOffset = 0,
xOffset = -1743.750,
yOffset = -11016.666,
mapID = 37
},
Sunwell = {
@ -1592,8 +1601,8 @@ WorldMapSize = {
TheCapeOfStranglethorn = {
height = 2631.25,
width = 3945.83312988281,
xOffset = 0,
yOffset = 0,
xOffset = -2108.333,
yOffset = -12516.666,
mapID = 673
},
Tirisfal = {
@ -1606,29 +1615,29 @@ WorldMapSize = {
TolBarad = {
height = 1343.75,
width = 2014.58329248428,
xOffset = 0,
yOffset = 0,
xOffset = -2010.417,
yOffset = -560.417,
mapID = 708
},
TolBaradDailyArea = {
height = 1224.99993896484,
width = 1837.5,
xOffset = 0,
yOffset = 0,
xOffset = -2412.5,
yOffset = 377.083,
mapID = 709
},
TwilightHighlands = {
height = 3514.5830078125,
width = 5270.8330078125,
xOffset = 0,
yOffset = 0,
xOffset = 2437.5,
yOffset = -2156.25,
mapID = 700
},
TwilightHighlands_terrain1 = {
height = 3514.5830078125,
width = 5270.8330078125,
xOffset = 0,
yOffset = 0,
xOffset = 2437.5,
yOffset = -2156.25,
mapID = 770
},
Undercity = {
@ -1641,29 +1650,29 @@ WorldMapSize = {
Vashjir = {
height = 4631.24975585938,
width = 6945.83276367188,
xOffset = 0,
yOffset = 0,
xOffset = -8754.166,
yOffset = -3720.833,
mapID = 613
},
VashjirDepths = {
height = 2716.66650390625,
width = 4075.0,
xOffset = 0,
yOffset = 0,
xOffset = -8233.333,
yOffset = -4906.25,
mapID = 614
},
VashjirKelpForest = {
height = 1868.75024414062,
width = 2802.0830078125,
xOffset = 0,
yOffset = 0,
xOffset = -5070.833,
yOffset = -4018.75,
mapID = 610
},
VashjirRuins = {
height = 3233.3330078125,
width = 4849.99963378906,
xOffset = 0,
yOffset = 0,
xOffset = -6681.25,
yOffset = -4756.25,
mapID = 615
},
WesternPlaguelands = {
@ -1841,10 +1850,10 @@ WorldMapSize = {
mapID = 66,
},
HrothgarsLanding = {
height = 2452.7,
width = 2452.7*1.5,
xOffset = 23967.599 - 17549.182,
yOffset = 1027.392 - 1215.431,
height = 2452.083984375,
width = 3677.08312988281,
xOffset = 6418.417,
yOffset = -188.039,
}
},
},
@ -1856,12 +1865,12 @@ WorldMapSize = {
xOffset = 0.0,
yOffset = 0.0,
zoneData = {
Deepholm = { height = 3399.999877929688, width = 5099.9987792969, xOffset = 0, yOffset = 0, mapID = 640 },
Kezan = { height = 900.00048828125, width = 1352.08319091797, xOffset = 0, yOffset = 0, mapID = 605 },
TheLostIsles = { height = 3010.41665649414, width = 4514.5830078125, xOffset = 0, yOffset = 0, mapID = 544 },
TheLostIsles_terrain1 = { height = 3010.41665649414, width = 4514.5830078125, xOffset = 0, yOffset = 0, mapID = 681 },
TheLostIsles_terrain2 = { height = 3010.41665649414, width = 4514.5830078125, xOffset = 0, yOffset = 0, mapID = 682 },
TheMaelstrom = { height = 1033.33325195312, width = 1550.0, xOffset = 0, yOffset = 0, mapID = 737 }
Deepholm = { height = 3399.999877929688, width = 5099.9987792969, xOffset = -3052.083, yOffset = 2795.833, mapID = 640 },
Kezan = { height = 900.00048828125, width = 1352.08319091797, xOffset = -2129.167, yOffset = -7731.25, mapID = 605 },
TheLostIsles = { height = 3010.41665649414, width = 4514.5830078125, xOffset = -4383.333, yOffset = 2881.25, mapID = 544 },
TheLostIsles_terrain1 = { height = 3010.41665649414, width = 4514.5830078125, xOffset = -4383.333, yOffset = 2881.25, mapID = 681 },
TheLostIsles_terrain2 = { height = 3010.41665649414, width = 4514.5830078125, xOffset = -4383.333, yOffset = 2881.25, mapID = 682 },
TheMaelstrom = { height = 1033.33325195312, width = 1550.0, xOffset = -1556.25, yOffset = 1370.833, mapID = 737 }
}
}
}
@ -1947,65 +1956,65 @@ VContinent(-118, "PitofSaron", 1022.3)
VirtualContinentIndexes = { -- Don't change values here, since programs might want to store them
["ScarletEnclave"] = -77,
["GilneasCity"] = -78,
["GilneasZone"] = -79,
-- ["GilneasCity"] = -78,
-- ["GilneasZone"] = -79,
["UtgardeKeep1"] = -80,
["UtgardeKeep2"] = -81,
["UtgardeKeep3"] = -82,
-- ["UtgardeKeep1"] = -80,
-- ["UtgardeKeep2"] = -81,
-- ["UtgardeKeep3"] = -82,
["TheNexus"] = -83,
-- ["TheNexus"] = -83,
["AzjolNerub1"] = -84,
["AzjolNerub2"] = -85,
["AzjolNerub3"] = -86,
-- ["AzjolNerub1"] = -84,
-- ["AzjolNerub2"] = -85,
-- ["AzjolNerub3"] = -86,
["Ahnkahet"] = -87,
-- ["Ahnkahet"] = -87,
["DrakTharonKeep1"] = -88,
["DrakTharonKeep2"] = -89,
-- ["DrakTharonKeep1"] = -88,
-- ["DrakTharonKeep2"] = -89,
["VioletHold"] = -90,
-- ["VioletHold"] = -90,
["Gundrak"] = -91,
-- ["Gundrak"] = -91,
["Ulduar77"] = -92, -- Halls of Stone
-- ["Ulduar77"] = -92, -- Halls of Stone
["HallsofLightning1"] = -93,
["HallsofLightning2"] = -94,
-- ["HallsofLightning1"] = -93,
-- ["HallsofLightning2"] = -94,
["Nexus801"] = -95, -- Oculus
["Nexus802"] = -96,
["Nexus803"] = -97,
["Nexus804"] = -98,
-- ["Nexus801"] = -95, -- Oculus
-- ["Nexus802"] = -96,
-- ["Nexus803"] = -97,
-- ["Nexus804"] = -98,
["CoTStratholme1"] = -99,
["CoTStratholme2"] = -100,
-- ["CoTStratholme1"] = -99,
-- ["CoTStratholme2"] = -100,
["UtgardePinnacle1"] = -101, -- hey they spelled it right
["UtgardePinnacle2"] = -102,
-- ["UtgardePinnacle1"] = -101, -- hey they spelled it right
-- ["UtgardePinnacle2"] = -102,
["VaultofArchavon"] = -103, -- Weirdly, Emalon is actually within the "Vault of Archavon"
-- ["VaultofArchavon"] = -103, -- Weirdly, Emalon is actually within the "Vault of Archavon"
["Naxxramas1"] = -104,
["Naxxramas2"] = -105,
["Naxxramas3"] = -106,
["Naxxramas4"] = -107,
["Naxxramas5"] = -108,
["Naxxramas6"] = -109,
-- ["Naxxramas1"] = -104,
-- ["Naxxramas2"] = -105,
-- ["Naxxramas3"] = -106,
-- ["Naxxramas4"] = -107,
-- ["Naxxramas5"] = -108,
-- ["Naxxramas6"] = -109,
["TheObsidianSanctum"] = -110,
-- ["TheObsidianSanctum"] = -110,
["TheEyeOfEternity"] = -111,
-- ["TheEyeOfEternity"] = -111,
["Ulduar"] = -112,
["Ulduar1"] = -113,
["Ulduar2"] = -114,
["Ulduar3"] = -115,
["Ulduar4"] = -116,
-- ["Ulduar"] = -112,
-- ["Ulduar1"] = -113,
-- ["Ulduar2"] = -114,
-- ["Ulduar3"] = -115,
-- ["Ulduar4"] = -116,
["TheForgeofSouls"] = -117,
["PitofSaron"] = -118
-- ["TheForgeofSouls"] = -117,
-- ["PitofSaron"] = -118
--[[
["AbyssalMaw"] = -120,
["ThroneOfTheTides"] = -130,

Voir le fichier

@ -0,0 +1,25 @@
------------------------------------------------------------------------
r100 | kagaro | 2011-12-02 00:28:58 +0000 (Fri, 02 Dec 2011) | 1 line
Changed paths:
A /tags/0.21-release (from /trunk:99)
Tagging as 0.21-release
------------------------------------------------------------------------
r99 | kagaro | 2011-12-02 00:27:41 +0000 (Fri, 02 Dec 2011) | 1 line
Changed paths:
M /trunk/library.lua
Updated lib from forum tests that shows game data incorrect
------------------------------------------------------------------------
r97 | kagaro | 2011-11-29 12:06:46 +0000 (Tue, 29 Nov 2011) | 1 line
Changed paths:
M /trunk/LibMapData-1.0.toc
toc bump
------------------------------------------------------------------------
r96 | kagaro | 2011-11-28 13:01:19 +0000 (Mon, 28 Nov 2011) | 1 line
Changed paths:
M /trunk/library.lua
Adding 4.3 zone data
------------------------------------------------------------------------

Voir le fichier

@ -0,0 +1,14 @@
## Interface: 40300
## Title: Lib: MapData-1.0
## Notes: Static library of wow map data
## Version: 1.0.99
## Author: kagaro
## X-Category: Library
## X-Curse-Packaged-Version: 0.21-release
## X-Curse-Project-Name: LibMapData-1.0
## X-Curse-Project-ID: libmapdata-1-0
## X-Curse-Repository-ID: wow/libmapdata-1-0/mainline
library.lua
Libs/LibStub/LibStub.lua
Libs/CallbackHandler-1.0/CallbackHandler-1.0.xml

Voir le fichier

@ -0,0 +1,240 @@
--[[ $Id: CallbackHandler-1.0.lua 14 2010-08-09 00:43:38Z mikk $ ]]
local MAJOR, MINOR = "CallbackHandler-1.0", 6
local CallbackHandler = LibStub:NewLibrary(MAJOR, MINOR)
if not CallbackHandler then return end -- No upgrade needed
local meta = {__index = function(tbl, key) tbl[key] = {} return tbl[key] end}
-- Lua APIs
local tconcat = table.concat
local assert, error, loadstring = assert, error, loadstring
local setmetatable, rawset, rawget = setmetatable, rawset, rawget
local next, select, pairs, type, tostring = next, select, pairs, type, tostring
-- Global vars/functions that we don't upvalue since they might get hooked, or upgraded
-- List them here for Mikk's FindGlobals script
-- GLOBALS: geterrorhandler
local xpcall = xpcall
local function errorhandler(err)
return geterrorhandler()(err)
end
local function CreateDispatcher(argCount)
local code = [[
local next, xpcall, eh = ...
local method, ARGS
local function call() method(ARGS) end
local function dispatch(handlers, ...)
local index
index, method = next(handlers)
if not method then return end
local OLD_ARGS = ARGS
ARGS = ...
repeat
xpcall(call, eh)
index, method = next(handlers, index)
until not method
ARGS = OLD_ARGS
end
return dispatch
]]
local ARGS, OLD_ARGS = {}, {}
for i = 1, argCount do ARGS[i], OLD_ARGS[i] = "arg"..i, "old_arg"..i end
code = code:gsub("OLD_ARGS", tconcat(OLD_ARGS, ", ")):gsub("ARGS", tconcat(ARGS, ", "))
return assert(loadstring(code, "safecall Dispatcher["..argCount.."]"))(next, xpcall, errorhandler)
end
local Dispatchers = setmetatable({}, {__index=function(self, argCount)
local dispatcher = CreateDispatcher(argCount)
rawset(self, argCount, dispatcher)
return dispatcher
end})
--------------------------------------------------------------------------
-- CallbackHandler:New
--
-- target - target object to embed public APIs in
-- RegisterName - name of the callback registration API, default "RegisterCallback"
-- UnregisterName - name of the callback unregistration API, default "UnregisterCallback"
-- UnregisterAllName - name of the API to unregister all callbacks, default "UnregisterAllCallbacks". false == don't publish this API.
function CallbackHandler:New(target, RegisterName, UnregisterName, UnregisterAllName, OnUsed, OnUnused)
-- TODO: Remove this after beta has gone out
assert(not OnUsed and not OnUnused, "ACE-80: OnUsed/OnUnused are deprecated. Callbacks are now done to registry.OnUsed and registry.OnUnused")
RegisterName = RegisterName or "RegisterCallback"
UnregisterName = UnregisterName or "UnregisterCallback"
if UnregisterAllName==nil then -- false is used to indicate "don't want this method"
UnregisterAllName = "UnregisterAllCallbacks"
end
-- we declare all objects and exported APIs inside this closure to quickly gain access
-- to e.g. function names, the "target" parameter, etc
-- Create the registry object
local events = setmetatable({}, meta)
local registry = { recurse=0, events=events }
-- registry:Fire() - fires the given event/message into the registry
function registry:Fire(eventname, ...)
if not rawget(events, eventname) or not next(events[eventname]) then return end
local oldrecurse = registry.recurse
registry.recurse = oldrecurse + 1
Dispatchers[select('#', ...) + 1](events[eventname], eventname, ...)
registry.recurse = oldrecurse
if registry.insertQueue and oldrecurse==0 then
-- Something in one of our callbacks wanted to register more callbacks; they got queued
for eventname,callbacks in pairs(registry.insertQueue) do
local first = not rawget(events, eventname) or not next(events[eventname]) -- test for empty before. not test for one member after. that one member may have been overwritten.
for self,func in pairs(callbacks) do
events[eventname][self] = func
-- fire OnUsed callback?
if first and registry.OnUsed then
registry.OnUsed(registry, target, eventname)
first = nil
end
end
end
registry.insertQueue = nil
end
end
-- Registration of a callback, handles:
-- self["method"], leads to self["method"](self, ...)
-- self with function ref, leads to functionref(...)
-- "addonId" (instead of self) with function ref, leads to functionref(...)
-- all with an optional arg, which, if present, gets passed as first argument (after self if present)
target[RegisterName] = function(self, eventname, method, ... --[[actually just a single arg]])
if type(eventname) ~= "string" then
error("Usage: "..RegisterName.."(eventname, method[, arg]): 'eventname' - string expected.", 2)
end
method = method or eventname
local first = not rawget(events, eventname) or not next(events[eventname]) -- test for empty before. not test for one member after. that one member may have been overwritten.
if type(method) ~= "string" and type(method) ~= "function" then
error("Usage: "..RegisterName.."(\"eventname\", \"methodname\"): 'methodname' - string or function expected.", 2)
end
local regfunc
if type(method) == "string" then
-- self["method"] calling style
if type(self) ~= "table" then
error("Usage: "..RegisterName.."(\"eventname\", \"methodname\"): self was not a table?", 2)
elseif self==target then
error("Usage: "..RegisterName.."(\"eventname\", \"methodname\"): do not use Library:"..RegisterName.."(), use your own 'self'", 2)
elseif type(self[method]) ~= "function" then
error("Usage: "..RegisterName.."(\"eventname\", \"methodname\"): 'methodname' - method '"..tostring(method).."' not found on self.", 2)
end
if select("#",...)>=1 then -- this is not the same as testing for arg==nil!
local arg=select(1,...)
regfunc = function(...) self[method](self,arg,...) end
else
regfunc = function(...) self[method](self,...) end
end
else
-- function ref with self=object or self="addonId" or self=thread
if type(self)~="table" and type(self)~="string" and type(self)~="thread" then
error("Usage: "..RegisterName.."(self or \"addonId\", eventname, method): 'self or addonId': table or string or thread expected.", 2)
end
if select("#",...)>=1 then -- this is not the same as testing for arg==nil!
local arg=select(1,...)
regfunc = function(...) method(arg,...) end
else
regfunc = method
end
end
if events[eventname][self] or registry.recurse<1 then
-- if registry.recurse<1 then
-- we're overwriting an existing entry, or not currently recursing. just set it.
events[eventname][self] = regfunc
-- fire OnUsed callback?
if registry.OnUsed and first then
registry.OnUsed(registry, target, eventname)
end
else
-- we're currently processing a callback in this registry, so delay the registration of this new entry!
-- yes, we're a bit wasteful on garbage, but this is a fringe case, so we're picking low implementation overhead over garbage efficiency
registry.insertQueue = registry.insertQueue or setmetatable({},meta)
registry.insertQueue[eventname][self] = regfunc
end
end
-- Unregister a callback
target[UnregisterName] = function(self, eventname)
if not self or self==target then
error("Usage: "..UnregisterName.."(eventname): bad 'self'", 2)
end
if type(eventname) ~= "string" then
error("Usage: "..UnregisterName.."(eventname): 'eventname' - string expected.", 2)
end
if rawget(events, eventname) and events[eventname][self] then
events[eventname][self] = nil
-- Fire OnUnused callback?
if registry.OnUnused and not next(events[eventname]) then
registry.OnUnused(registry, target, eventname)
end
end
if registry.insertQueue and rawget(registry.insertQueue, eventname) and registry.insertQueue[eventname][self] then
registry.insertQueue[eventname][self] = nil
end
end
-- OPTIONAL: Unregister all callbacks for given selfs/addonIds
if UnregisterAllName then
target[UnregisterAllName] = function(...)
if select("#",...)<1 then
error("Usage: "..UnregisterAllName.."([whatFor]): missing 'self' or \"addonId\" to unregister events for.", 2)
end
if select("#",...)==1 and ...==target then
error("Usage: "..UnregisterAllName.."([whatFor]): supply a meaningful 'self' or \"addonId\"", 2)
end
for i=1,select("#",...) do
local self = select(i,...)
if registry.insertQueue then
for eventname, callbacks in pairs(registry.insertQueue) do
if callbacks[self] then
callbacks[self] = nil
end
end
end
for eventname, callbacks in pairs(events) do
if callbacks[self] then
callbacks[self] = nil
-- Fire OnUnused callback?
if registry.OnUnused and not next(callbacks) then
registry.OnUnused(registry, target, eventname)
end
end
end
end
end
end
return registry
end
-- CallbackHandler purposefully does NOT do explicit embedding. Nor does it
-- try to upgrade old implicit embeds since the system is selfcontained and
-- relies on closures to work.

Voir le fichier

@ -0,0 +1,4 @@
<Ui xmlns="http://www.blizzard.com/wow/ui/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.blizzard.com/wow/ui/
..\FrameXML\UI.xsd">
<Script file="CallbackHandler-1.0.lua"/>
</Ui>

Voir le fichier

@ -0,0 +1,30 @@
-- LibStub is a simple versioning stub meant for use in Libraries. http://www.wowace.com/wiki/LibStub for more info
-- LibStub is hereby placed in the Public Domain Credits: Kaelten, Cladhaire, ckknight, Mikk, Ammo, Nevcairiel, joshborke
local LIBSTUB_MAJOR, LIBSTUB_MINOR = "LibStub", 2 -- NEVER MAKE THIS AN SVN REVISION! IT NEEDS TO BE USABLE IN ALL REPOS!
local LibStub = _G[LIBSTUB_MAJOR]
if not LibStub or LibStub.minor < LIBSTUB_MINOR then
LibStub = LibStub or {libs = {}, minors = {} }
_G[LIBSTUB_MAJOR] = LibStub
LibStub.minor = LIBSTUB_MINOR
function LibStub:NewLibrary(major, minor)
assert(type(major) == "string", "Bad argument #2 to `NewLibrary' (string expected)")
minor = assert(tonumber(strmatch(minor, "%d+")), "Minor version must either be a number or contain a number.")
local oldminor = self.minors[major]
if oldminor and oldminor >= minor then return nil end
self.minors[major], self.libs[major] = minor, self.libs[major] or {}
return self.libs[major], oldminor
end
function LibStub:GetLibrary(major, silent)
if not self.libs[major] and not silent then
error(("Cannot find a library instance of %q."):format(tostring(major)), 2)
end
return self.libs[major], self.minors[major]
end
function LibStub:IterateLibraries() return pairs(self.libs) end
setmetatable(LibStub, { __call = LibStub.GetLibrary })
end

Voir le fichier

@ -0,0 +1,13 @@
## Interface: 20400
## Title: Lib: LibStub
## Notes: Universal Library Stub
## Credits: Kaelten, Cladhaire, ckknight, Mikk, Ammo, Nevcairiel
## X-Website: http://jira.wowace.com/browse/LS
## X-Category: Library
## X-License: Public Domain
## X-Curse-Packaged-Version: 1.0
## X-Curse-Project-Name: LibStub
## X-Curse-Project-ID: libstub
## X-Curse-Repository-ID: wow/libstub/mainline
LibStub.lua

Fichier diff supprimé car celui-ci est trop grand Voir la Diff

Voir le fichier

@ -1,13 +1,13 @@
## Interface: 40000
## Interface: 50001
## Title: Lib: RangeCheck-2.0
## Notes: A library to determine estimated range.
## Author: mitch0
## Version: 3.6.0
## Version: v3.7.0
## LoadOnDemand: 1
## X-Category: Library
## X-AceLibrary-LibRangeCheck-2.0: true
## X-License: Public Domain
## X-Curse-Packaged-Version: v3.6.0
## X-Curse-Packaged-Version: v3.7.0
## X-Curse-Project-Name: LibRangeCheck-2.0
## X-Curse-Project-ID: librangecheck-2-0
## X-Curse-Repository-ID: wow/librangecheck-2-0/mainline

Voir le fichier

@ -1,6 +1,6 @@
--[[
Name: LibRangeCheck-2.0
Revision: $Revision: 113 $
Revision: $Revision: 124 $
Author(s): mitch0
Website: http://www.wowace.com/projects/librangecheck-2-0/
Description: A range checking library based on interact distances and spell ranges
@ -41,7 +41,7 @@ License: Public Domain
-- @class file
-- @name LibRangeCheck-2.0
local MAJOR_VERSION = "LibRangeCheck-2.0"
local MINOR_VERSION = tonumber(("$Revision: 113 $"):match("%d+")) + 100000
local MINOR_VERSION = tonumber(("$Revision: 124 $"):match("%d+")) + 100000
local lib, oldminor = LibStub:NewLibrary(MAJOR_VERSION, MINOR_VERSION)
if not lib then
@ -122,12 +122,11 @@ HarmSpells["MAGE"] = {
FriendSpells["PALADIN"] = {
635, -- ["Holy Light"], -- 40
20217, -- ["Blessing of Kings"], -- 30
20473, -- ["Holy Shock"], -- 20
}
HarmSpells["PALADIN"] = {
62124, -- ["Hand of Reckoning"], -- 30
20473, -- ["Holy Shock"], -- 20
20271, -- ["Judgement"], -- 10 (Improved Judgement: +10, +20; Elnightened Judgements: +5, +10)
-- 20473, -- ["Holy Shock"], -- 20
20271, -- ["Judgement"], -- 10 (Improved Judgement: +10, +20; Enlightened Judgements: +5, +10)
853, -- ["Hammer of Justice"], -- 10 (Glyph of Hammer of Justice: +5)
35395, -- ["Crusader Strike"], -- 5
}
@ -331,6 +330,8 @@ local tremove = tremove
local BOOKTYPE_SPELL = BOOKTYPE_SPELL
local GetSpellInfo = GetSpellInfo
local GetSpellBookItemName = GetSpellBookItemName
local GetNumSpellTabs = GetNumSpellTabs
local GetSpellTabInfo = GetSpellTabInfo
local GetItemInfo = GetItemInfo
local UnitCanAttack = UnitCanAttack
local UnitCanAssist = UnitCanAssist
@ -427,14 +428,16 @@ local function initItemRequests(cacheAll)
foundNewItems = nil
end
local function getNumSpells()
local _, _, offset, numSpells = GetSpellTabInfo(GetNumSpellTabs())
return offset + numSpells
end
-- return the spellIndex of the given spell by scanning the spellbook
local function findSpellIdx(spellName)
local i = 1
while true do
for i = 1, getNumSpells() do
local spell, rank = GetSpellBookItemName(i, BOOKTYPE_SPELL)
if not spell then return nil end
if spell == spellName then return i end
i = i + 1
end
return nil
end

Voir le fichier

@ -1,13 +1,22 @@
-- $Id: LibStub.lua 76 2007-09-03 01:50:17Z mikk $
-- LibStub is a simple versioning stub meant for use in Libraries. http://www.wowace.com/wiki/LibStub for more info
-- LibStub is hereby placed in the Public Domain Credits: Kaelten, Cladhaire, ckknight, Mikk, Ammo, Nevcairiel, joshborke
-- LibStub is hereby placed in the Public Domain
-- Credits: Kaelten, Cladhaire, ckknight, Mikk, Ammo, Nevcairiel, joshborke
local LIBSTUB_MAJOR, LIBSTUB_MINOR = "LibStub", 2 -- NEVER MAKE THIS AN SVN REVISION! IT NEEDS TO BE USABLE IN ALL REPOS!
local LibStub = _G[LIBSTUB_MAJOR]
-- Check to see is this version of the stub is obsolete
if not LibStub or LibStub.minor < LIBSTUB_MINOR then
LibStub = LibStub or {libs = {}, minors = {} }
_G[LIBSTUB_MAJOR] = LibStub
LibStub.minor = LIBSTUB_MINOR
-- LibStub:NewLibrary(major, minor)
-- major (string) - the major version of the library
-- minor (string or number ) - the minor version of the library
--
-- returns nil if a newer or same version of the lib is already present
-- returns empty library object or old library object if upgrade is needed
function LibStub:NewLibrary(major, minor)
assert(type(major) == "string", "Bad argument #2 to `NewLibrary' (string expected)")
minor = assert(tonumber(strmatch(minor, "%d+")), "Minor version must either be a number or contain a number.")
@ -18,6 +27,12 @@ if not LibStub or LibStub.minor < LIBSTUB_MINOR then
return self.libs[major], oldminor
end
-- LibStub:GetLibrary(major, [silent])
-- major (string) - the major version of the library
-- silent (boolean) - if true, library is optional, silently return nil if its not found
--
-- throws an error if the library can not be found (except silent is set)
-- returns the library object if found
function LibStub:GetLibrary(major, silent)
if not self.libs[major] and not silent then
error(("Cannot find a library instance of %q."):format(tostring(major)), 2)
@ -25,6 +40,12 @@ if not LibStub or LibStub.minor < LIBSTUB_MINOR then
return self.libs[major], self.minors[major]
end
function LibStub:IterateLibraries() return pairs(self.libs) end
-- LibStub:IterateLibraries()
--
-- Returns an iterator for the currently registered libraries
function LibStub:IterateLibraries()
return pairs(self.libs)
end
setmetatable(LibStub, { __call = LibStub.GetLibrary })
end

Voir le fichier

@ -1,11 +1,11 @@
## Interface: 20400
## Interface: 50001
## Title: Lib: LibStub
## Notes: Universal Library Stub
## Credits: Kaelten, Cladhaire, ckknight, Mikk, Ammo, Nevcairiel
## X-Website: http://jira.wowace.com/browse/LS
## X-Website: http://www.wowace.com/addons/libstub/
## X-Category: Library
## X-License: Public Domain
## X-Curse-Packaged-Version: 1.0
## X-Curse-Packaged-Version: 1.0.3-50001
## X-Curse-Project-Name: LibStub
## X-Curse-Project-ID: libstub
## X-Curse-Repository-ID: wow/libstub/mainline

Voir le fichier

@ -182,11 +182,21 @@ local please_submit_enabled = true
local please_submit_initted = false
local spawned = false
QHQuestsCompleted = false
QH_Event("ADDON_LOADED", function (addonid)
if addonid ~= "QuestHelper" then return end
-- ONLY FAST STUFF ALLOWED IN HERE
--[[
QH_Event("QUEST_QUERY_COMPLETE", function ()
QHQuestsCompleted = GetQuestsCompleted()
end)
QueryQuestsCompleted()
--]]
-- Use DefaultPref as fallback for unset preference keys.
setmetatable(QuestHelper_Pref, {__index=QuestHelper_DefaultPref})
QuestHelper: Assert(QuestHelper_Pref.perfload_scale) -- if this fails, something is very botched
@ -194,7 +204,7 @@ QH_Event("ADDON_LOADED", function (addonid)
if not QuestHelper_Pref.track or QuestHelper_Pref.hide then
QuestHelper:HideTracker()
else
QuestHelper:ShowTracker() -- to respect the minimized setting
--QuestHelper:ShowTracker() -- to respect the minimized setting
end
local self = QuestHelper -- whee hack hack hack
@ -215,7 +225,7 @@ QH_Event("ADDON_LOADED", function (addonid)
["manager_achievement.lua"] = true,
["manager_completed.lua"] = true,
["upgrade.lua"] = true,
-- ["upgrade.lua"] = true,
["main.lua"] = true,
["recycle.lua"] = true,
["objective.lua"] = true,
@ -224,17 +234,17 @@ QH_Event("ADDON_LOADED", function (addonid)
["dodads.lua"] = true,
["dodads_triangles.lua"] = true,
["teleport.lua"] = true,
["pathfinding.lua"] = true,
-- ["pathfinding.lua"] = true,
["routing.lua"] = true,
["custom.lua"] = true,
["menu.lua"] = true,
["nag.lua"] = true,
["comm.lua"] = true,
["mapbutton.lua"] = true,
-- ["mapbutton.lua"] = true,
["help.lua"] = true,
["pattern.lua"] = true,
["flightpath.lua"] = true,
["tracker.lua"] = true,
-- ["tracker.lua"] = true,
["objtips.lua"] = true,
["tomtom.lua"] = true,
["textviewer.lua"] = true,
@ -247,35 +257,6 @@ QH_Event("ADDON_LOADED", function (addonid)
["radar.lua"] = true,
["config.lua"] = true,
--[[
["static.lua"] = true,
["static_1.lua"] = true,
["static_2.lua"] = true,
["static_deDE.lua"] = true,
["static_deDE_1.lua"] = true,
["static_deDE_2.lua"] = true,
["static_enUS.lua"] = true,
["static_enUS_1.lua"] = true,
["static_enUS_2.lua"] = true,
["static_esES.lua"] = true,
["static_esES_1.lua"] = true,
["static_esES_2.lua"] = true,
["static_esMX.lua"] = true,
["static_esMX_1.lua"] = true,
["static_esMX_2.lua"] = true,
["static_frFR.lua"] = true,
["static_frFR_1.lua"] = true,
["static_frFR_2.lua"] = true,
["static_koKR.lua"] = true,
["static_koKR_1.lua"] = true,
["static_koKR_2.lua"] = true,
["static_ruRU.lua"] = true,
["static_ruRU_1.lua"] = true,
["static_ruRU_2.lua"] = true,
["static_zhTW.lua"] = true,
["static_zhTW_1.lua"] = true,
["static_zhTW_2.lua"] = true,
--]]
["collect.lua"] = true,
["collect_achievement.lua"] = true,
["collect_lzw.lua"] = true,
@ -300,24 +281,24 @@ QH_Event("ADDON_LOADED", function (addonid)
["collect_merchant.lua"] = true,
["collect_warp.lua"] = true,
["filter_core.lua"] = true,
["filter_base.lua"] = true,
-- ["filter_core.lua"] = true,
-- ["filter_base.lua"] = true,
["routing_debug.lua"] = true,
["routing_loc.lua"] = true,
["routing_route.lua"] = true,
["routing_core.lua"] = true,
["routing_controller.lua"] = true,
["routing_hidden.lua"] = true,
-- ["routing_debug.lua"] = true,
-- ["routing_loc.lua"] = true,
-- ["routing_route.lua"] = true,
-- ["routing_core.lua"] = true,
-- ["routing_controller.lua"] = true,
-- ["routing_hidden.lua"] = true,
["director_quest.lua"] = true,
["director_achievement.lua"] = true,
["director_find.lua"] = true,
-- ["director_quest.lua"] = true,
-- ["director_achievement.lua"] = true,
-- ["director_find.lua"] = true,
["db_get.lua"] = true,
-- ["db_get.lua"] = true,
["graph_core.lua"] = true,
["graph_flightpath.lua"] = true,
-- ["graph_core.lua"] = true,
-- ["graph_flightpath.lua"] = true,
["AstrolabeQH/Astrolabe.lua"] = true,
["AstrolabeQH/AstrolabeMapMonitor.lua"] = true,
@ -416,15 +397,15 @@ QH_Event("ADDON_LOADED", function (addonid)
-- 4.0.3a Breakage related
local datime = time() + 30 -- We're gonna wait 30 seconds, just in case.
--while datime >= time() do --[[sleep (busy wait)]] end
QuestHelper_BuildZoneLookup()
QH_Graph_Init()
load_graph_links()
--QuestHelper_BuildZoneLookup()
--QH_Graph_Init()
--load_graph_links()
if QuestHelper_Locale ~= GetLocale() then
self:TextOut(QHText("LOCALE_ERROR"))
return
end
--[[
if not self:ZoneSanity() then
self:TextOut(QHFormat("ZONE_LAYOUT_ERROR", expected_version))
QH_fixedmessage(QHFormat("ZONE_LAYOUT_ERROR", expected_version))
@ -439,7 +420,7 @@ QH_Event("ADDON_LOADED", function (addonid)
self:TextOut(QHFormat("NAG_POLLUTED"))
self:Purge(nil, true, true)
end
--]]
local signature = expected_version .. " on " .. GetBuildInfo()
QuestHelper_Quests[signature] = QuestHelper_Quests[signature] or {}
QuestHelper_Objectives[signature] = QuestHelper_Objectives[signature] or {}
@ -456,7 +437,7 @@ QH_Event("ADDON_LOADED", function (addonid)
QuestHelper.loading_init3:SetPercentage(0.1)
QH_Collector_Init()
QuestHelper.loading_init3:SetPercentage(0.5)
DB_Init()
--DB_Init()
QuestHelper.loading_init3:SetPercentage(0.9)
self.player_level = UnitLevel("player")
@ -527,14 +508,14 @@ QH_Event("ADDON_LOADED", function (addonid)
end
if QuestHelper_Pref.map_button then
QuestHelper:InitMapButton()
-- QuestHelper:InitMapButton()
end
if QuestHelper_Pref.tomtom_wp_new then
self:EnableTomTom()
-- self:EnableTomTom()
end
self.tracker:SetScale(QuestHelper_Pref.track_scale)
-- self.tracker:SetScale(QuestHelper_Pref.track_scale)
local version = GetAddOnMetadata("QuestHelper", "Version") or "Unknown"
@ -591,11 +572,11 @@ QH_Event("ADDON_LOADED", function (addonid)
QH_Event("TAXIMAP_OPENED", function ()
self:taxiMapOpened()
end)
--[[
QH_Event({"ZONE_CHANGED", "ZONE_CHANGED_INDOORS", "ZONE_CHANGED_NEW_AREA"}, function()
QH_Route_Filter_Rescan(nil, true)
end)
]]
QH_Event("CHAT_MSG_CHANNEL_NOTICE", function()
if please_submit_enabled and not please_submit_initted then
please_submit_enabled = QHNagInit()
@ -967,12 +948,12 @@ Thanks for testing!]], "QuestHelper " .. version_string, 500, 20, 10)
end
end
if nc and nz > 0 and QuestHelper_IndexLookup[nc] then -- QuestHelper_IndexLookup is only initialized after we've finished the preinit step
if nc and nz > 0 then --and QuestHelper_IndexLookup[nc] then -- QuestHelper_IndexLookup is only initialized after we've finished the preinit step
self.c, self.z, self.x, self.y = nc, nz, nx, ny
local upd_zone = false
if self.i ~= QuestHelper_IndexLookup[nc][nz] then upd_zone = true end
self.i = QuestHelper_IndexLookup[nc][nz]
if upd_zone then QH_Route_Filter_Rescan("filter_zone") end
--if self.i ~= QuestHelper_IndexLookup[nc][nz] then upd_zone = true end
--self.i = QuestHelper_IndexLookup[nc][nz]
--if upd_zone then QH_Route_Filter_Rescan("filter_zone") end
end
if nc and nz and nx and ny and tc and tx and ty then

Voir le fichier

@ -22,31 +22,32 @@ local dependancy_quest_list = GetQuestsCompleted()
local static_alliance_landings =
{
{12, 0.476, 0.598, "Exodar via portal"}, -- Exodar
{21, 0.435, 0.787, "Darnassus via portal"}, -- Darnassus
{36, 0.496, 0.865, "Stormwind via portal"}, -- Stormwind
{25, 0.255, 0.084, "Ironforge via portal"}, -- Ironforge
{10, 0.660, 0.490, "Theramore via portal"}, -- Theramore
{471, 0.476, 0.598, "Exodar via portal"}, -- Exodar
{381, 0.435, 0.787, "Darnassus via portal"}, -- Darnassus
{301, 0.496, 0.865, "Stormwind via portal"}, -- Stormwind
{341, 0.255, 0.084, "Ironforge via portal"}, -- Ironforge
{141, 0.660, 0.490, "Theramore via portal"}, -- Theramore, Dustwallow Marsh
}
local static_horde_landings =
{
{1, 0.483, 0.645, "Orgrimmar via portal"}, -- Orgrimmar
{23, 0.222, 0.169, "Thunder Bluff via portal"}, -- Thunder Bluff
{45, 0.845, 0.163, "Undercity via portal"}, -- Undercity
{52, 0.583, 0.192, "Silvermoon City via portal"}, -- Silvermoon City
{46, 0.498, 0.558, "Stonard via portal"}, -- Stonard
{321, 0.483, 0.645, "Orgrimmar via portal"}, -- Orgrimmar
{362, 0.222, 0.169, "Thunder Bluff via portal"}, -- Thunder Bluff
{382, 0.845, 0.163, "Undercity via portal"}, -- Undercity
{480, 0.583, 0.192, "Silvermoon City via portal"}, -- Silvermoon City
{38, 0.498, 0.558, "Stonard via portal"}, -- Stonard, Swamp of Sorrows
}
local static_shared_landings =
{
{67, 0.559, 0.468, "Dalaran via portal"}, -- Dalaran
{60, 0.550, 0.402, "Shattrath via portal"}, -- Shattrath
{504, 0.559, 0.468, "Dalaran via portal"}, -- Dalaran
{481, 0.550, 0.402, "Shattrath via portal"}, -- Shattrath
-- Need Tol Barad Port In coordinates
-- Highly doubtful that Tol Barad Port In Coordinates are the same.
}
if IsSpellKnown(18960) then
local static_druid_landings = {20,0.563,0.324, "Moonglade via spell"} -- Moonglade landing
local static_druid_landings = {241,0.563,0.324, "Moonglade via spell"} -- Moonglade landing
end
-- end whimsey
@ -55,33 +56,33 @@ end
-- More storage
-- Contingent on player's faction controlling the zone
-- {{74, 0.491, 0.153}, {67, 0.268, 0.447}, 5, true}, -- Wingergrasp Keep --> Dalaran
-- {{175, 0.472, 0.519}, ORGRIMMAR_CATPORTAL_IN, 60, true}, -- Tol Barad --> Orgrimmar (If Horde Controlled)
-- {{175, 0.472, 0.519}, STORMWIND_CATPORTAL_IN, 60, true}, -- Tol Barad --> Stormwind (If Alliance Controlled)
-- {{501, 0.491, 0.153}, {504, 0.268, 0.447}, 5, true}, -- Wingergrasp Keep --> Dalaran
-- {{708, 0.472, 0.519}, ORGRIMMAR_CATPORTAL_IN, 60, true}, -- Tol Barad --> Orgrimmar (If Horde Controlled)
-- {{708, 0.472, 0.519}, STORMWIND_CATPORTAL_IN, 60, true}, -- Tol Barad --> Stormwind (If Alliance Controlled)
-- end storage
local BLASTED_LANDS_PORTAL_IN = {33, 0.539, 0.461, "Blasted Lands via portal"}
local ORGRIMMAR_CATPORTAL_IN = {1, 0.500, 0.377, "Orgrimmar via portal"}
local BLASTED_LANDS_PORTAL_IN = {19, 0.539, 0.461, "Blasted Lands via portal"}
local ORGRIMMAR_CATPORTAL_IN = {321, 0.500, 0.377, "Orgrimmar via portal"}
-- local STORMWIND_CATPORTAL_IN
local static_horde_routes =
{
-- Portals
{{1, 0.471, 0.618}, BLASTED_LANDS_PORTAL_IN, 60, true, level_limit = 58}, -- Orgrimmar --> Dark Portal
{{45, 0.853, 0.171}, BLASTED_LANDS_PORTAL_IN, 5, true, level_limit = 58}, -- Undercity --> Dark Portal
{{23, 0.232, 0.135}, BLASTED_LANDS_PORTAL_IN, 60, true, level_limit = 58}, -- Thunder Bluff --> Dark Portal
{{52, 0.584, 0.210}, BLASTED_LANDS_PORTAL_IN, 60, true, level_limit = 58}, -- Silvermoon --> Dark Portal
{{321, 0.471, 0.618}, BLASTED_LANDS_PORTAL_IN, 60, true, level_limit = 58}, -- Orgrimmar --> Dark Portal
{{382, 0.853, 0.171}, BLASTED_LANDS_PORTAL_IN, 5, true, level_limit = 58}, -- Undercity --> Dark Portal
{{362, 0.232, 0.135}, BLASTED_LANDS_PORTAL_IN, 60, true, level_limit = 58}, -- Thunder Bluff --> Dark Portal
{{480, 0.584, 0.210}, BLASTED_LANDS_PORTAL_IN, 60, true, level_limit = 58}, -- Silvermoon --> Dark Portal
-- I'm really not concerned that the landing points are different. This is a self-contained method.
-- It won't affect anything that we don't have two one-way paths here.
{{45, 0.549, 0.113}, {52, 0.495, 0.148}, 60}, -- Undercity <--> Silvermoon City
{{382, 0.549, 0.113}, {480, 0.495, 0.148}, 60}, -- Undercity <--> Silvermoon City
{{56, 0.886, 0.477}, {1, 0.483, 0.645}, 60, true}, -- Hellfire Peninsula --> Orgrimmar
{{184, 0.736, 0.535}, ORGRIMMAR_CATPORTAL_IN, 60, true}, -- Twilight Highlands --> Orgrimmar
{{465, 0.886, 0.477}, {321, 0.483, 0.645}, 60, true}, -- Hellfire Peninsula --> Orgrimmar
{{700, 0.736, 0.535}, ORGRIMMAR_CATPORTAL_IN, 60, true}, -- Twilight Highlands --> Orgrimmar
{{1, 0.475, 0.392}, {176, 0.560, 0.799}, 60, false, level_limit = 85}, -- Orgrimmar <--> Tol Barad Peninsula
{{321, 0.475, 0.392}, {709, 0.560, 0.799}, 60, false, level_limit = 85}, -- Orgrimmar <--> Tol Barad Peninsula
-- Okay, I give. Since I haven't actually been through these portals, I don't really have a frame
@ -99,35 +100,35 @@ local static_horde_routes =
-- Orgrimmar --> Temple of Earth (Aqua)
-- Level limit because the quest to open requires level 82.
{{179, 0.509, 0.531}, ORGRIMMAR_CATPORTAL_IN, 60, true}, -- Temple of Earth (Aqua) --> Orgrimmar
{{640, 0.509, 0.531}, ORGRIMMAR_CATPORTAL_IN, 60, true}, -- Temple of Earth (Aqua) --> Orgrimmar
{{1, 0.508, 0.363}, {179, 0.506, 0.529}, 60, true, level_limit = 82}, -- Orgrimmar --> Deepholm
{{321, 0.508, 0.363}, {640, 0.506, 0.529}, 60, true, level_limit = 82}, -- Orgrimmar --> Deepholm
-- Level limit because the quest to open requires level 82.
{{1, 0.511, 0.383}, {198, 0.635, 0.234}, 60, true, level_limit = 80}, -- Orgrimmar --> Mount Hyjal
{{321, 0.511, 0.383}, {606, 0.635, 0.234}, 60, true, level_limit = 80}, -- Orgrimmar --> Mount Hyjal
-- Level limit because the quest to open requires level 80.
{{1, 0.502, 0.394}, {184, 0.736, 0.534}, 60, true, level_limit = 84}, -- Orgrimmar --> Twilight Highlands
{{321, 0.502, 0.394}, {700, 0.736, 0.534}, 60, true, level_limit = 84}, -- Orgrimmar --> Twilight Highlands
-- Level limit because the quest to open requires level 84.
{{1, 0.489, 0.386}, {164, 0.549, 0.342}, 5, true, level_limit = 83}, -- Orgrimmar --> Uldum
{{321, 0.489, 0.386}, {720, 0.549, 0.342}, 5, true, level_limit = 83}, -- Orgrimmar --> Uldum
-- Level limit because the quest to open requires level 83.
{{1, 0.492, 0.365}, {165, 0.514, 0.609}, 60, true, level_limit = 80}, -- Orgrimmar --> Vashj'ir
{{321, 0.492, 0.365}, {613, 0.514, 0.609}, 60, true, level_limit = 80}, -- Orgrimmar --> Vashj'ir
-- Level limit because the quest to open requires level 80.
-- Zepplins
{{1, 0.526, 0.529}, {168, 0.372, 0.525}, 210}, -- Orgrimmar <--> Grom'gol Base Camp
{{1, 0.506, 0.561}, {43, 0.607, 0.588}, 210}, -- Orgrimmar <--> Tirisfal Glades
{{1, 0.428, 0.653}, {23, 0.152, 0.257}, 210}, -- Orgrimmar <--> Thunder Bluff
{{1, 0.449, 0.619}, {65, 0.414, 0.536}, 210}, -- Orgrimmar <--> Warsong Hold
{{321, 0.526, 0.529}, {37, 0.372, 0.525}, 210}, -- Orgrimmar <--> Grom'gol Base Camp
{{321, 0.506, 0.561}, {20, 0.607, 0.588}, 210}, -- Orgrimmar <--> Tirisfal Glades
{{321, 0.428, 0.653}, {362, 0.152, 0.257}, 210}, -- Orgrimmar <--> Thunder Bluff
{{321, 0.449, 0.619}, {486, 0.414, 0.536}, 210}, -- Orgrimmar <--> Warsong Hold, Borean Tundra
{{43, 0.619, 0.591}, {168, 0.374, 0.509}, 210}, -- Tirisfal Glades <--> Grom'gol Base Camp
{{43, 0.590, 0.590}, {70, 0.777, 0.282}, 210}, -- Tirisfal Glades <--> Vengeance Landing
{{20, 0.619, 0.591}, {37, 0.374, 0.509}, 210}, -- Tirisfal Glades <--> Grom'gol Base Camp, Northern Stranglethorn
{{20, 0.590, 0.590}, {491, 0.777, 0.282}, 210}, -- Tirisfal Glades <--> Vengeance Landing
-- Ships
{{184, 0.735, 0.528}, {184, 0.767, 0.152}, 210}, -- Dragonmaw Port <--> Krazzworks
{{700, 0.735, 0.528}, {700, 0.767, 0.152}, 210}, -- Dragonmaw Port, Twilight Highlands <--> Krazzworks, Twilight Highlands
-- QuestHelper does not appear to like transitions from within the same zone. Gonna have to figure this out.
}
@ -136,20 +137,20 @@ local static_horde_routes =
local static_alliance_routes =
{
-- Portals
{{21,0.440,0.782}, BLASTED_LANDS_PORTAL_IN, 60, true, level_limit = 58}, -- Darnassus --> Dark Portal
{{12,0.482,0.630}, BLASTED_LANDS_PORTAL_IN, 60, true, level_limit = 58}, -- Exodar --> Dark Portal
{{25,0.273,0.070}, BLASTED_LANDS_PORTAL_IN, 5, true, level_limit = 58}, -- Ironforge --> Dark Portal
{{36,0.490,0.874}, BLASTED_LANDS_PORTAL_IN, 5, true, level_limit = 58}, -- Stormwind --> Dark Portal
{{381,0.440,0.782}, BLASTED_LANDS_PORTAL_IN, 60, true, level_limit = 58}, -- Darnassus --> Dark Portal
{{471,0.482,0.630}, BLASTED_LANDS_PORTAL_IN, 60, true, level_limit = 58}, -- Exodar --> Dark Portal
{{341,0.273,0.070}, BLASTED_LANDS_PORTAL_IN, 5, true, level_limit = 58}, -- Ironforge --> Dark Portal
{{301,0.490,0.874}, BLASTED_LANDS_PORTAL_IN, 5, true, level_limit = 58}, -- Stormwind --> Dark Portal
{{56, 0.886, 0.528}, {36, 0.496, 0.865}, 60, true}, -- Hellfire Peninsula --> Stormwind
{{21, 0.442, 0.788}, {12, 0.476, 0.598}, 5, true}, -- Darnassus --> Exodar
{{12, 0.476, 0.619}, {21, 0.435, 0.787}, 5, true}, -- Exodar --> Darnassus
{{465, 0.886, 0.528}, {301, 0.496, 0.865}, 60, true}, -- Hellfire Peninsula --> Stormwind
{{381, 0.442, 0.788}, {471, 0.476, 0.598}, 5, true}, -- Darnassus --> Exodar
{{471, 0.476, 0.619}, {381, 0.435, 0.787}, 5, true}, -- Exodar --> Darnassus
-- Stormwind --> Tol Barad?
{{36, 0.734, 0.195}, {179, 0.487, 0.536}, 60, true, level_limit = 82}, -- Stormwind --> Temple of Earth (Amber)
{{301, 0.734, 0.195}, {640, 0.487, 0.536}, 60, true, level_limit = 82}, -- Stormwind --> Temple of Earth (Amber)
-- Level limit because the quest to open requires level 82.
{{179, 0.486, 0.537}, {36, 0.745, 0.183}, 60, true}, -- Temple of Earth (Amber) --> Stormwind
{{640, 0.486, 0.537}, {301, 0.745, 0.183}, 60, true}, -- Temple of Earth (Amber) --> Stormwind
-- Stormwind <--> Deepholm
-- Stormwind <--> Mount Hyjal
@ -158,87 +159,79 @@ local static_alliance_routes =
-- Stormwind <--> Vashj'ir
-- Ships
{{36, 0.180, 0.285}, {65, 0.597, 0.694}, 210}, -- Stormwind <--> Valiance Keep
{{301, 0.180, 0.285}, {486, 0.597, 0.694}, 210}, -- Stormwind <--> Valiance Keep, Borean Tundra
-- Deeprun Tram (Wonder if this needs to be handled differently because of it's nature but this will suffice for now)
{{36, 0.696, 0.311}, {25, 0.770, 0.513}, 180}, -- Stormwind <--> Ironforge
-- Deeprun Tram (Wonder if this needs to be handled differently because of it's nature but this will suffice for now).
-- As it turns out, the mapid for deeprun tram is sw, so no need to do any special handling.
{{301, 0.696, 0.311}, {341, 0.770, 0.513}, 180}, -- Stormwind <--> Ironforge
-- Partially checked
-- Unchecked (Do these still exist?)
{{10, 0.718, 0.565}, {51, 0.047, 0.636}, 210}, -- Theramore Isle <--> Menethil Harbor
{{51, 0.047, 0.571}, {70, 0.612, 0.626}, 210}, -- Menethil <--> Daggercap Bay
-- Nate's Cataclysm content
{{207, 0.54, 0.60}, {205, 0.30, 0.72}, 10}, -- Gilneas Zone <--> Greymane Court, Gilneas City. Exists solely to fix some pathing crashes. (We want to make an adjustment to the coords though.)
{{207, 0.55, 0.42}, {205, 0.28, 0.21}, 5}, -- Gilneas Zone <--> Cathedral Square, Gilneas City. Exists solely to fix some pathing crashes. (We want to make an adjustment to the coords though.)
{{207, 0.66, 0.42}, {205, 0.67, 0.20}, 5}, -- Gilneas Zone <--> Merchant Square, Gilneas City. Exists solely to fix some pathing crashes. (We want to make an adjustment to the coords though.)
{{207, 0.68, 0.62}, {205, 0.69, 0.82}, 10}, -- Gilneas Zone <--> Military District, Gilneas City. Exists solely to fix some pathing crashes. (We want to make an adjustment to the coords though.)
{{207, 0.42, 0.36}, {24, 0.52, 0.89}, 86400}, -- Gilneas Zone <--> Teldrassil. Exists solely to fix some pathing crashes. 24-hour boat ride :D (This will be deleted later, when we can create the "official" path.)
{{684, 0.54, 0.60}, {685, 0.30, 0.72}, 10}, -- Gilneas Zone <--> Greymane Court, Gilneas City. Exists solely to fix some pathing crashes. (We want to make an adjustment to the coords though.)
{{684, 0.55, 0.42}, {685, 0.28, 0.21}, 5}, -- Gilneas Zone <--> Cathedral Square, Gilneas City. Exists solely to fix some pathing crashes. (We want to make an adjustment to the coords though.)
{{684, 0.66, 0.42}, {685, 0.67, 0.20}, 5}, -- Gilneas Zone <--> Merchant Square, Gilneas City. Exists solely to fix some pathing crashes. (We want to make an adjustment to the coords though.)
{{684, 0.68, 0.62}, {685, 0.69, 0.82}, 10}, -- Gilneas Zone <--> Military District, Gilneas City. Exists solely to fix some pathing crashes. (We want to make an adjustment to the coords though.)
{{684, 0.42, 0.36}, {41, 0.52, 0.89}, 86400}, -- Gilneas Zone <--> Teldrassil. Exists solely to fix some pathing crashes. 24-hour boat ride :D (This will be deleted later, when we can create the "official" path.)
}
local static_shared_routes =
{
-- Portals
{{67, 0.268, 0.447}, {67, 0.240, 0.394}, 5}, -- Dalaran (Violet Citadel) <--> Dalaran (Purple Parlor)
{{504, 0.268, 0.447}, {504, 0.240, 0.394}, 5}, -- Dalaran (Violet Citadel) <--> Dalaran (Purple Parlor)
{{67, 0.559, 0.468}, {66, 0.158, 0.428}, 5}, -- Dalaran <--> Crystalsong Forest
--{{67, 0.559, 0.468}, {66, 0.158, 0.428}, 5, false, level_limit = 68}, -- Dalaran <--> Crystalsong Forest
{{504, 0.559, 0.468}, {510, 0.158, 0.428}, 5}, -- Dalaran <--> Crystalsong Forest
--{{504, 0.559, 0.468}, {510, 0.158, 0.428}, 5, false, level_limit = 68}, -- Dalaran <--> Crystalsong Forest
{{24, 0.551, 0.885}, {21, 0.369, 0.584}, 5}, -- Rut'Theran Village <--> Darnassus
{{41, 0.551, 0.885}, {381, 0.369, 0.584}, 5}, -- Rut'Theran Village, Teldrassil <--> Darnassus
{{33, 0.550, 0.541}, {56, 0.898, 0.502}, 60}, -- Blasted Lands <--> Hellfire Peninsula (Dark Portal)
{{19, 0.550, 0.541}, {465, 0.898, 0.502}, 60}, -- Blasted Lands <--> Hellfire Peninsula (Dark Portal)
{{67, 0.255, 0.514}, {8, 0.652, 0.498}, 60, true}, -- Dalaran --> Caverns of Time
{{60, 0.486, 0.420}, {64, 0.482, 0.345}, 60, true}, -- Shattrath --> Isle of Quel'Danas
{{504, 0.255, 0.514}, {161, 0.652, 0.498}, 60, true}, -- Dalaran --> Caverns of Time
{{481, 0.486, 0.420}, {499, 0.482, 0.345}, 60, true}, -- Shattrath --> Isle of Quel'Danas
{{60, 0.747, 0.316}, {8, 0.652, 0.498}, 60, true}, -- Shattrath --> Caverns of Time
{{481, 0.747, 0.316}, {161, 0.652, 0.498}, 60, true}, -- Shattrath --> Caverns of Time
-- Requires Revered with Keepers of Time
{{179, 0.493, 0.504}, {179, 0.571, 0.135}, 5, false, level_limit = 81}, -- Temple of Earth <--> Therazane's Throne
{{640, 0.493, 0.504}, {640, 0.571, 0.135}, 5, false, level_limit = 81}, -- Temple of Earth <--> Therazane's Throne
-- Requires Honored with Therazane and dependant on quest #26709
-- Ships
{{68, 0.497, 0.784}, {70, 0.234, 0.578}, 210}, -- Moa'ki <--> Kamagua
{{68, 0.479, 0.788}, {65, 0.789, 0.537}, 210}, -- Moa'ki <--> Unu'pe
{{174, 0.390, 0.670}, {11, 0.702, 0.733}, 210}, -- Booty Bay <--> Ratchet
{{488, 0.497, 0.784}, {491, 0.234, 0.578}, 210}, -- Moa'ki <--> Kamagua
{{488, 0.479, 0.788}, {486, 0.789, 0.537}, 210}, -- Moa'ki <--> Unu'pe
{{673, 0.390, 0.670}, {11, 0.702, 0.733}, 210}, -- Booty Bay, Cape of Stranglethorn <--> Ratchet
-- Leave here to keep QH from self-destructing
{{24, 0.522, 0.895}, {3, 0.203, 0.540}, 210}, -- Teldrassil <--> Azuremyst Isle
{{24, 0.550, 0.938}, {36, 0.223, 0.560}, 210}, -- Teldrassil <--> Stormwind
{{41, 0.522, 0.895}, {464, 0.203, 0.540}, 210}, -- Teldrassil <--> Azuremyst Isle
{{41, 0.550, 0.938}, {301, 0.223, 0.560}, 210}, -- Teldrassil <--> Stormwind
-- Unchecked
{{40, 0.318, 0.503}, {32, 0.347, 0.84}, 130}, -- Burning Steppes <--> Searing Gorge
{{29, 0.318, 0.503}, {28, 0.347, 0.84}, 130}, -- Burning Steppes <--> Searing Gorge
-- Route to new zone. Not valid, exists only to keep routing from exploding if you don't have the flight routes there.
{{41, 0.5, 0.5}, {64, 0.484, 0.251}, 7200}, -- Eversong Woods <--> Sunwell
{{34, 0.817, 0.461}, {78, 0.492, 0.312}, 86400}, -- EPL Ebon Hold <--> Scarlet Enclave Ebon Hold. Exists solely to fix some pathing crashes. 24-hour boat ride :D
{{462, 0.5, 0.5}, {499, 0.484, 0.251}, 7200}, -- Eversong Woods <--> Sunwell
{{23, 0.817, 0.461}, {502, 0.492, 0.312}, 86400}, -- EPL Ebon Hold <--> Scarlet Enclave Ebon Hold. Exists solely to fix some pathing crashes. 24-hour boat ride :D
-- Nate's Cataclysm content
{{178, 0.83, 0.34}, {167, 0.45, 0.23}, 210, true}, -- Vash'jir --> Vash'jir Kelp Forest (One time, One way)
{{167, 0.69, 0.60}, {178, 0.80, 0.30}, 5}, -- Vash'jir Kelp Forest <--> Vash'jir
{{178, 0.84, 0.23}, {62, 0.37, 0.58}, 5}, -- Vash'jir <--> The Great Sea (EK Continent, zone 0)
{{62, 0.39, 0.60}, {28, 0.00, 0.20}, 5}, -- The Great Sea (EK Continent, zone 0) <--> Dun Morogh
{{167, 0.40, 0.64}, {171, 0.56, 0.14}, 5}, -- VKF <--> SE
{{178, 0.50, 0.28}, {165, 0.72, 0.04}, 5}, -- Vash <--> Vash'jir Depths
{{198, 0.85, 0.41}, {19, 0.58, 0.91}, 5}, -- Hyjal <--> Winterspring
{{185, 0.85, 0.41}, {19, 0.58, 0.91}, 5}, -- Hyjal <--> Winterspring
{{169, 0.5, 0.5}, {170, 0.5, 0.5}, 5}, -- Ruins of Gilneas <--> Ruins of Gilneas City (Meta info, map doesn't change properly as of 2010-12-11-0156UET)
{{179, 0.5, 0.5}, {180, 0.5, 0.5}, 86400}, -- DeepHolm <--> Kezan (Meta info for when major error is fixed.)
{{181, 0.24, 0.77}, {180, 0.22, 0.17}, 90}, -- The Lost Isles <--> Kezan (Meta info for when major error is fixed.)
{{208, 0.24, 0.77}, {180, 0.22, 0.17}, 90}, -- The Lost Isles <--> Kezan (Meta info for when major error is fixed.)
{{209, 0.24, 0.77}, {180, 0.22, 0.17}, 90}, -- The Lost Isles <--> Kezan (Meta info for when major error is fixed.)
{{181, 0.5, 0.5}, {182, 0.5, 0.5}, 86400}, -- The Lost Isles <--> The Maelstrom (Meta info for when major error is fixed.)
{{183, 0.5, 0.5}, {182, 0.5, 0.5}, 86400}, -- The Maelstrom Continent <--> The Maelstrom (Meta info for when major error is fixed.)
{{183, 0.5, 0.5}, {1, 0.5, 0.5}, 86400}, -- The Maelstrom Continent <--> Orgrimmar (Meta info for when major error is fixed.)
{{613, 0.83, 0.34}, {610, 0.45, 0.23}, 210, true}, -- Vash'jir --> Vash'jir Kelp Forest (One time, One way)
{{610, 0.69, 0.60}, {613, 0.80, 0.30}, 5}, -- Vash'jir Kelp Forest <--> Vash'jir
{{613, 0.84, 0.23}, {-1, 0.37, 0.58}, 5}, -- Vash'jir <--> The Great Sea (EK Continent, zone 0)
{{-1, 0.39, 0.60}, {27, 0.00, 0.20}, 5}, -- The Great Sea (EK Continent, zone 0) <--> Dun Morogh
{{610, 0.40, 0.64}, {615, 0.56, 0.14}, 5}, -- VKF <--> SE
{{613, 0.50, 0.28}, {614, 0.72, 0.04}, 5}, -- Vash <--> Vash'jir Depths
{{606, 0.85, 0.41}, {281, 0.58, 0.91}, 5}, -- Hyjal <--> Winterspring
{{684, 0.5, 0.5}, {685, 0.5, 0.5}, 5}, -- Ruins of Gilneas <--> Ruins of Gilneas City (Meta info, map doesn't change properly as of 2010-12-11-0156UET)
{{640, 0.5, 0.5}, {605, 0.5, 0.5}, 86400}, -- DeepHolm <--> Kezan (Meta info for when major error is fixed.)
{{544, 0.24, 0.77}, {605, 0.22, 0.17}, 90}, -- The Lost Isles <--> Kezan (Meta info for when major error is fixed.)
{{544, 0.5, 0.5}, {737, 0.5, 0.5}, 86400}, -- The Lost Isles <--> The Maelstrom (Meta info for when major error is fixed.)
{{751, 0.5, 0.5}, {737, 0.5, 0.5}, 86400}, -- The Maelstrom Continent <--> The Maelstrom (Meta info for when major error is fixed.)
{{751, 0.5, 0.5}, {321, 0.5, 0.5}, 86400}, -- The Maelstrom Continent <--> Orgrimmar (Meta info for when major error is fixed.)
{{164, 0.84, 0.41}, {8, 0.37, 0.82}, 5}, -- Uldum <--> Tanaris
{{164, 0.70, 0.22}, {8, 0.25, 0.66}, 5}, -- Uldum <--> Tanaris
{{210, 0.84, 0.41}, {8, 0.37, 0.82}, 5}, -- Uldum <--> Tanaris
{{210, 0.70, 0.22}, {8, 0.25, 0.66}, 5}, -- Uldum <--> Tanaris
{{35, 0.45, 0.85}, {169, 0.60, 0.09}, 5}, -- Silverpine <--> Ruins of Gilneas
{{720, 0.84, 0.41}, {161, 0.37, 0.82}, 5}, -- Uldum <--> Tanaris
{{720, 0.70, 0.22}, {161, 0.25, 0.66}, 5}, -- Uldum <--> Tanaris
{{21, 0.45, 0.85}, {684, 0.60, 0.09}, 5}, -- Silverpine <--> Ruins of Gilneas
--[==[
-- Wrath instance entrances
{{80, 0.693, 0.730}, {70, 0.573, 0.467}, 5}, -- UK
{{86, 0.362, 0.880}, {65, 0.275, 0.260}, 5}, -- Nexus
@ -299,16 +292,17 @@ local static_shared_routes =
{{144, 0.500, 0.500}, {148, 0.500, 0.500}, 5},
{{144, 0.500, 0.500}, {150, 0.500, 0.500}, 5},
{{144, 0.500, 0.500}, {152, 0.500, 0.500}, 5},
--]==]
}
-- Darkportal is handled specially, depending on whether or not you're level 58+ or not.
local dark_portal_route = {{33, 0.550, 0.541}, {56, 0.898, 0.502}, 60}
local dark_portal_route = {{19, 0.550, 0.541}, {465, 0.898, 0.502}, 60}
-- Waygate
local ridingLevel = (select(4,GetAchievementInfo(892)) and 300) or (select(4,GetAchievementInfo(890)) and 225) or (select(4,GetAchievementInfo(889)) and 150) or (select(4,GetAchievementInfo(891)) and 75) or 0 -- this is thanks to Maldivia, who is a fucking genius
local has_fmsl = not not GetSpellInfo(GetSpellInfo(90267))
if ridingLevel >= 225 and has_fmsl then
table.insert(static_shared_routes, {{18, 0.505, 0.078}, {72, 0.403, 0.830}, 60, false, level_limit = 77}) -- Un'Goro Crater <--> Sholozar Basin
table.insert(static_shared_routes, {{201, 0.505, 0.078}, {493, 0.403, 0.830}, 60, false, level_limit = 77}) -- Un'Goro Crater <--> Sholazar Basin
-- Dependant on completion of quest #12613
end
@ -332,119 +326,119 @@ local static_zone_transitions =
--Outland
--Northrend
{65, 72, 0.527, 0.322}, -- Borean Tundra <--> Scholazar Basin
{486, 493, 0.527, 0.322}, -- Borean Tundra <--> Scholazar Basin
--Cataclysm zones
-- Work
{7, 1, 0.117, 0.936}, -- Durotar <--> Orgrimmar (Front)
{7, 1, 0.366, 0.253}, -- Durotar <--> Orgrimmar (Side)
{15, 1, 0.792, 0.017}, -- Azshara <--> Orgrimmar (Back)
{158, 5, 0.687, 0.2}, -- Ahn'Qiraj <--> Silithus
{168, 174, 0.50, 0.61}, -- Northern Stranglethorn <--> Cape of Stranglethorn
{4, 321, 0.117, 0.936}, -- Durotar <--> Orgrimmar (Front)
{4, 321, 0.366, 0.253}, -- Durotar <--> Orgrimmar (Side)
{181, 321, 0.792, 0.017}, -- Azshara <--> Orgrimmar (Back)
{772, 261, 0.687, 0.2}, -- Ahn'Qiraj <--> Silithus
{37, 673, 0.50, 0.61}, -- Northern Stranglethorn <--> Cape of Stranglethorn
{38, 168, 0, 0}, -- Stranglethorn World Map Wonkiness
--{38, 168, 0, 0}, -- Stranglethorn World Map Wonkiness
{2, 11, 0.687, 0.872}, -- Ashenvale <--> Northern Barrens
{2, 6, 0.423, 0.711}, -- Ashenvale <--> Stonetalon Mountains
{2, 15, 0.954, 0.484}, -- Ashenvale <--> Azshara
{2, 16, 0.289, 0.144}, -- Ashenvale <--> Darkshore
{2, 13, 0.557, 0.29}, -- Ashenvale <--> Felwood
{21, 24, 0.894, 0.358}, -- Darnassus <--> Teldrassil
{22, 203, 0.697, 0.604}, -- Mulgore <--> Southern Barrens
{22, 23, 0.376, 0.33}, -- Mulgore <--> Thunder Bluff
{22, 23, 0.403, 0.193}, -- Mulgore <--> Thunder Bluff
{3, 12, 0.247, 0.494}, -- Azuremyst Isle <--> The Exodar
{3, 12, 0.369, 0.469}, -- Azuremyst Isle <--> The Exodar
{3, 12, 0.310, 0.487}, -- Azuremyst Isle <--> The Exodar
{3, 12, 0.335, 0.494}, -- Azuremyst Isle <--> The Exodar
{3, 9, 0.42, 0.013}, -- Azuremyst Isle <--> Bloodmyst Isle
{4, 6, 0.539, 0.032}, -- Desolace <--> Stonetalon Mountains
{4, 17, 0.428, 0.976}, -- Desolace <--> Feralas
{5, 18, 0.865, 0.115}, -- Silithus <--> Un'Goro Crater
{7, 11, 0.341, 0.424}, -- Durotar <--> Northern Barrens
{8, 18, 0.269, 0.516}, -- Tanaris <--> Un'Goro Crater
{8, 14, 0.512, 0.21}, -- Tanaris <--> Thousand Needles
{10, 14, 0.50, 0.94}, -- Dustwallow Marsh <--> Thousand Needles
{10, 203, 0.287, 0.472}, -- Dustwallow Marsh <--> Southern Barrens
{10, 203, 0.531, 0.104}, -- Dustwallow Marsh <--> Southern Barrens
{203, 11, 0.367, 0.048}, -- Southern Barrens <--> Northern Barrens
{203, 14, 0.43, 0.96}, -- Southern Barrens <--> Thousand Needles
{13, 19, 0.685, 0.06}, -- Felwood <--> Winterspring
{13, 20, 0.669, -0.063}, -- Felwood <--> Moonglade
{17, 14, 0.899, 0.46}, -- Feralas <--> Thousand Needles
{6, 11, 0.29, 0.08}, -- Stonetalon Mountains <--> Northern Barrens IS THIS ONE RIGHT?
{39, 51, 0.454, 0.89}, -- Arathi Highlands <--> Wetlands
{39, 48, 0.2, 0.293}, -- Arathi Highlands <--> Hillsbrad Foothills
{27, 29, 0.47, 0.071}, -- Badlands <--> Loch Modan
{27, 32, 0.05, 0.53}, -- Badlands <--> Searing Gorge
{33, 46, 0.519, 0.051}, -- Blasted Lands <--> Swamp of Sorrows
{40, 30, 0.79, 0.842}, -- Burning Steppes <--> Redridge Mountains
{47, 31, 0.324, 0.363}, -- Deadwind Pass <--> Duskwood
{47, 46, 0.605, 0.41}, -- Deadwind Pass <--> Swamp of Sorrows
{28, 25, 0.534, 0.349}, -- Dun Morogh <--> Ironforge
{28, 29, 0.863, 0.514}, -- Dun Morogh <--> Loch Modan
{28, 29, 0.844, 0.31}, -- Dun Morogh <--> Loch Modan
{31, 37, 0.801, 0.158}, -- Duskwood <--> Elwynn Forest
{31, 37, 0.15, 0.214}, -- Duskwood <--> Elwynn Forest
{31, 168, 0.447, 0.884}, -- Duskwood <--> Stranglethorn Vale
{31, 168, 0.209, 0.863}, -- Duskwood <--> Stranglethorn Vale
{31, 30, 0.941, 0.103}, -- Duskwood <--> Redridge Mountains
{31, 49, 0.079, 0.638}, -- Duskwood <--> Westfall
{34, 50, 0.077, 0.661}, -- Eastern Plaguelands <--> Western Plaguelands
{34, 44, 0.575, 0.000}, -- Eastern Plaguelands <--> Ghostlands
{37, 36, 0.321, 0.493}, -- Elwynn Forest <--> Stormwind City -- Don't need to convert because it's in Elwynn coordinates, not Stormwind coordinates
{37, 49, 0.202, 0.804}, -- Elwynn Forest <--> Westfall
{37, 30, 0.944, 0.724}, -- Elwynn Forest <--> Redridge Mountains
{41, 52, 0.567, 0.494}, -- Eversong Woods <--> Silvermoon City
{41, 44, 0.486, 0.916}, -- Eversong Woods <--> Ghostlands
{35, 43, 0.678, 0.049}, -- Silverpine Forest <--> Tirisfal Glades
{42, 50, 0.217, 0.264}, -- The Hinterlands <--> Western Plaguelands
{43, 45, 0.619, 0.651}, -- Tirisfal Glades <--> Undercity
{43, 50, 0.851, 0.703}, -- Tirisfal Glades <--> Western Plaguelands
{168, 49, 0.292, 0.024}, -- Stranglethorn Vale <--> Westfall
{48, 35, 0.137, 0.458}, -- Hillsbrad Foothills <--> Silverpine Forest
{48, 42, 0.899, 0.253}, -- Hillsbrad Foothills <--> The Hinterlands
{51, 184, 0.80, 0.47}, -- Wetlands <--> Twilight Highlands
{29, 51, 0.252, 0}, -- Loch Modan <--> Wetlands
{43, 11, 0.687, 0.872}, -- Ashenvale <--> Northern Barrens
{43, 81, 0.423, 0.711}, -- Ashenvale <--> Stonetalon Mountains
{43, 181, 0.954, 0.484}, -- Ashenvale <--> Azshara
{43, 42, 0.289, 0.144}, -- Ashenvale <--> Darkshore
{43, 182, 0.557, 0.29}, -- Ashenvale <--> Felwood
{381, 41, 0.894, 0.358}, -- Darnassus <--> Teldrassil
{9, 607, 0.697, 0.604}, -- Mulgore <--> Southern Barrens
{9, 362, 0.376, 0.33}, -- Mulgore <--> Thunder Bluff
{9, 362, 0.403, 0.193}, -- Mulgore <--> Thunder Bluff
{464, 471, 0.247, 0.494}, -- Azuremyst Isle <--> The Exodar
{464, 471, 0.369, 0.469}, -- Azuremyst Isle <--> The Exodar
{464, 471, 0.310, 0.487}, -- Azuremyst Isle <--> The Exodar
{464, 471, 0.335, 0.494}, -- Azuremyst Isle <--> The Exodar
{464, 476, 0.42, 0.013}, -- Azuremyst Isle <--> Bloodmyst Isle
{101, 81, 0.539, 0.032}, -- Desolace <--> Stonetalon Mountains
{101, 121, 0.428, 0.976}, -- Desolace <--> Feralas
{261, 201, 0.865, 0.115}, -- Silithus <--> Un'Goro Crater
{4, 11, 0.341, 0.424}, -- Durotar <--> Northern Barrens
{161, 201, 0.269, 0.516}, -- Tanaris <--> Un'Goro Crater
{161, 61, 0.512, 0.21}, -- Tanaris <--> Thousand Needles
{141, 61, 0.50, 0.94}, -- Dustwallow Marsh <--> Thousand Needles
{141, 607, 0.287, 0.472}, -- Dustwallow Marsh <--> Southern Barrens
{141, 607, 0.531, 0.104}, -- Dustwallow Marsh <--> Southern Barrens
{607, 11, 0.367, 0.048}, -- Southern Barrens <--> Northern Barrens
{607, 61, 0.43, 0.96}, -- Southern Barrens <--> Thousand Needles
{182, 281, 0.685, 0.06}, -- Felwood <--> Winterspring
{182, 241, 0.669, -0.063}, -- Felwood <--> Moonglade
{121, 61, 0.899, 0.46}, -- Feralas <--> Thousand Needles
{81, 11, 0.29, 0.08}, -- Stonetalon Mountains <--> Northern Barrens IS THIS ONE RIGHT?
{16, 40, 0.454, 0.89}, -- Arathi Highlands <--> Wetlands
{16, 24, 0.2, 0.293}, -- Arathi Highlands <--> Hillsbrad Foothills
{17, 35, 0.47, 0.071}, -- Badlands <--> Loch Modan
{17, 28, 0.05, 0.53}, -- Badlands <--> Searing Gorge
{19, 38, 0.519, 0.051}, -- Blasted Lands <--> Swamp of Sorrows
{29, 36, 0.79, 0.842}, -- Burning Steppes <--> Redridge Mountains
{32, 34, 0.324, 0.363}, -- Deadwind Pass <--> Duskwood
{32, 38, 0.605, 0.41}, -- Deadwind Pass <--> Swamp of Sorrows
{27, 341, 0.534, 0.349}, -- Dun Morogh <--> Ironforge
{27, 35, 0.863, 0.514}, -- Dun Morogh <--> Loch Modan
{27, 35, 0.844, 0.31}, -- Dun Morogh <--> Loch Modan
{34, 30, 0.801, 0.158}, -- Duskwood <--> Elwynn Forest
{34, 30, 0.15, 0.214}, -- Duskwood <--> Elwynn Forest
{34, 689, 0.447, 0.884}, -- Duskwood <--> Stranglethorn Vale
{34, 689, 0.209, 0.863}, -- Duskwood <--> Stranglethorn Vale
{34, 36, 0.941, 0.103}, -- Duskwood <--> Redridge Mountains
{34, 39, 0.079, 0.638}, -- Duskwood <--> Westfall
{23, 22, 0.077, 0.661}, -- Eastern Plaguelands <--> Western Plaguelands
{23, 463, 0.575, 0.000}, -- Eastern Plaguelands <--> Ghostlands
{30, 301, 0.321, 0.493}, -- Elwynn Forest <--> Stormwind City -- Don't need to convert because it's in Elwynn coordinates, not Stormwind coordinates
{30, 39, 0.202, 0.804}, -- Elwynn Forest <--> Westfall
{30, 36, 0.944, 0.724}, -- Elwynn Forest <--> Redridge Mountains
{462, 480, 0.567, 0.494}, -- Eversong Woods <--> Silvermoon City
{462, 463, 0.486, 0.916}, -- Eversong Woods <--> Ghostlands
{21, 20, 0.678, 0.049}, -- Silverpine Forest <--> Tirisfal Glades
{26, 22, 0.217, 0.264}, -- The Hinterlands <--> Western Plaguelands
{20, 382, 0.619, 0.651}, -- Tirisfal Glades <--> Undercity
{20, 22, 0.851, 0.703}, -- Tirisfal Glades <--> Western Plaguelands
{689, 39, 0.292, 0.024}, -- Stranglethorn Vale <--> Westfall
{24, 21, 0.137, 0.458}, -- Hillsbrad Foothills <--> Silverpine Forest
{24, 26, 0.899, 0.253}, -- Hillsbrad Foothills <--> The Hinterlands
{40, 700, 0.80, 0.47}, -- Wetlands <--> Twilight Highlands
{35, 40, 0.252, 0}, -- Loch Modan <--> Wetlands
-- Outland
{58, 60, 0.783, 0.545}, -- Nagrand <--> Shattrath City -- this is aldor-only
{60, 55, 0.782, 0.492}, -- Shattrath City <--> Terokkar Forest
{54, 59, 0.842, 0.284}, -- Blade's Edge Mountains <--> Netherstorm
{54, 57, 0.522, 0.996}, -- Blade's Edge Mountains <--> Zangarmarsh
{54, 57, 0.312, 0.94}, -- Blade's Edge Mountains <--> Zangarmarsh
{56, 55, 0.353, 0.901}, -- Hellfire Peninsula <--> Terokkar Forest
{56, 57, 0.093, 0.519}, -- Hellfire Peninsula <--> Zangarmarsh
{58, 55, 0.8, 0.817}, -- Nagrand <--> Terokkar Forest
{58, 57, 0.343, 0.159}, -- Nagrand <--> Zangarmarsh
{58, 57, 0.754, 0.331}, -- Nagrand <--> Zangarmarsh
{53, 55, 0.208, 0.271}, -- Shadowmoon Valley <--> Terokkar Forest
{55, 57, 0.341, 0.098}, -- Terokkar Forest <--> Zangarmarsh
{477, 481, 0.783, 0.545}, -- Nagrand <--> Shattrath City -- this is aldor-only
{481, 478, 0.782, 0.492}, -- Shattrath City <--> Terokkar Forest
{475, 479, 0.842, 0.284}, -- Blade's Edge Mountains <--> Netherstorm
{475, 467, 0.522, 0.996}, -- Blade's Edge Mountains <--> Zangarmarsh
{475, 467, 0.312, 0.94}, -- Blade's Edge Mountains <--> Zangarmarsh
{465, 478, 0.353, 0.901}, -- Hellfire Peninsula <--> Terokkar Forest
{465, 467, 0.093, 0.519}, -- Hellfire Peninsula <--> Zangarmarsh
{477, 478, 0.8, 0.817}, -- Nagrand <--> Terokkar Forest
{477, 467, 0.343, 0.159}, -- Nagrand <--> Zangarmarsh
{477, 467, 0.754, 0.331}, -- Nagrand <--> Zangarmarsh
{473, 478, 0.208, 0.271}, -- Shadowmoon Valley <--> Terokkar Forest
{478, 467, 0.341, 0.098}, -- Terokkar Forest <--> Zangarmarsh
-- Northrend
{65, 68, 0.967, 0.359}, -- Borean Tundra <--> Dragonblight
{74, 72, 0.208, 0.191}, -- Wintergrasp <--> Sholazar
{68, 74, 0.250, 0.410}, -- Dragonblight <--> Wintergrasp
{68, 71, 0.359, 0.155}, -- Dragonblight <--> Icecrown
{68, 66, 0.612, 0.142}, -- Dragonblight <--> Crystalsong
{68, 75, 0.900, 0.200}, -- Dragonblight <--> Zul'Drak
{68, 69, 0.924, 0.304}, -- Dragonblight <--> Grizzly Hills
{68, 69, 0.931, 0.634}, -- Dragonblight <--> Grizzly Hills
{70, 69, 0.540, 0.042}, -- Howling Fjord <--> Grizzly Hills
{70, 69, 0.233, 0.074}, -- Howling Fjord <--> Grizzly Hills
{70, 69, 0.753, 0.060}, -- Howling Fjord <--> Grizzly Hills
{69, 75, 0.432, 0.253}, -- Grizzly Hills <--> Zul'Drak
{69, 75, 0.583, 0.136}, -- Grizzly Hills <--> Zul'Drak
{66, 75, 0.967, 0.599}, -- Crystalsong <--> Zul'Drak
{66, 71, 0.156, 0.085}, -- Crystalsong <--> Icecrown
{66, 73, 0.706, 0.315}, -- Crystalsong <--> Storm Peaks
{66, 73, 0.839, 0.340}, -- Crystalsong <--> Storm Peaks
{71, 73, 0.920, 0.767}, -- Icecrown <--> Storm Peaks
{486, 488, 0.967, 0.359}, -- Borean Tundra <--> Dragonblight
{501, 493, 0.208, 0.191}, -- Wintergrasp <--> Sholazar
{488, 501, 0.250, 0.410}, -- Dragonblight <--> Wintergrasp
{488, 492, 0.359, 0.155}, -- Dragonblight <--> Icecrown
{488, 510, 0.612, 0.142}, -- Dragonblight <--> Crystalsong
{488, 496, 0.900, 0.200}, -- Dragonblight <--> Zul'Drak
{488, 490, 0.924, 0.304}, -- Dragonblight <--> Grizzly Hills
{488, 490, 0.931, 0.634}, -- Dragonblight <--> Grizzly Hills
{491, 490, 0.540, 0.042}, -- Howling Fjord <--> Grizzly Hills
{491, 490, 0.233, 0.074}, -- Howling Fjord <--> Grizzly Hills
{491, 490, 0.753, 0.060}, -- Howling Fjord <--> Grizzly Hills
{490, 496, 0.432, 0.253}, -- Grizzly Hills <--> Zul'Drak
{490, 496, 0.583, 0.136}, -- Grizzly Hills <--> Zul'Drak
{510, 496, 0.967, 0.599}, -- Crystalsong <--> Zul'Drak
{510, 492, 0.156, 0.085}, -- Crystalsong <--> Icecrown
{510, 495, 0.706, 0.315}, -- Crystalsong <--> Storm Peaks
{510, 495, 0.839, 0.340}, -- Crystalsong <--> Storm Peaks
{492, 495, 0.920, 0.767}, -- Icecrown <--> Storm Peaks
}
if QuestHelper:IsWrath32() then
table.insert(static_zone_transitions, {153, 71, 0.5, 0.5}) -- Hrothgar's Landing <--> Icecrown
table.insert(static_zone_transitions, {541, 492, 0.5, 0.5}) -- Hrothgar's Landing <--> Icecrown
end
local function convertLostIsles(current, other1, other2)
@ -457,7 +451,7 @@ end
function load_graph_links()
local function convert_coordinate(coord)
QuestHelper: Assert(coord[1] and coord[2] and coord[3])
--[==[
-- I hate Blizzard... They can't make up their mind weather we are on TwilightHighlands or TwilightHiglands_terrain1, but we only seem to be on one or the other.
if coord[1] == 177 and not QuestHelper_ZoneLookup[coord[1]] then
coord[1] = 184
@ -489,10 +483,8 @@ function load_graph_links()
-- Use the lookup table to get the real coordinate.
if converter[coord[1]] then coord[1] = converter[coord[1]]() end
]==]
local QHZL = QuestHelper_ZoneLookup
local test = QHZL[181] or QHZL[208] or QHZL[209]
QuestHelper: Assert(test, "Umm, something is seriously wrong... We're missing a LostIsles terrain.")
QuestHelper: Assert(QuestHelper_ZoneLookup[coord[1]], string.format("Coord[1] = %d", coord[1]))
local c, x, y = QuestHelper.Astrolabe:GetAbsoluteContinentPosition(QuestHelper_ZoneLookup[coord[1]][1], QuestHelper_ZoneLookup[coord[1]][2], coord[2], coord[3])
QuestHelper: Assert(c)

Voir le fichier

@ -375,7 +375,7 @@ Route_Core_Init(
rvv = QuestHelper:CreateTable("route controller path shunt returnvalue")
local rv = QH_Graph_Pathmultifind(loc1.loc, lt, reverse, true)
QuestHelper: Assert(#lt == #rv, string.format("lt has %d items, rt has %d items. Both should be the same.", #lt, #rv))
--QuestHelper: Assert(#lt == #rv, string.format("lt has %d items, rt has %d items. Both should be the same.", #lt, #rv))
-- We want to store the math.max(sqrt(#rv), 10) shortest paths
local tostore = complete_pass and math.max(sqrt(#rv), 10) or #rv

Voir le fichier

@ -1257,10 +1257,6 @@ function QH_Route_Core_ClusterAdd(clust, clustid_used)
-- if we're doing hackery, clust will just be an empty table and we'll retrofit stuff later
for _, v in ipairs(clust) do
-- Ugly database hack
if v.loc.p == 26 then v.loc.p = 48 end -- Somehow I doubt this is the problem location, but it IS a nice place to make a translation.
if v.loc.p == 38 then v.loc.p = 168 end -- Just following your lead.
-- end hack
local idx = QH_Route_Core_NodeAdd_Internal(v)
Storage_NodeAdded(idx)
ClusterLookup[idx] = clustid

Voir le fichier

@ -36,6 +36,10 @@ local last_stack = nil
local yield_ct = 0
local GetTime = GetTime
local unyieldable = 0
function QH_Timeslice_GetUnyieldable()
return unyieldable
end
function QH_Timeslice_PushUnyieldable()
unyieldable = unyieldable + 1
--print(unyieldable)
@ -193,7 +197,7 @@ function QH_Timeslice_Work(time_used, time_this_frame, bonus_time, verbose)
coroutine_running = true
QuestHelper: Assert(unyieldable == 0)
state, err = coroutine.resume(coro.coro)
QuestHelper: Assert(unyieldable == 0)
QuestHelper: Assert(unyieldable == 0, "Unyieldable was " .. unyieldable)
coroutine_running = false
end
local stop = GetTime()

Voir le fichier

@ -10,33 +10,34 @@ QuestHelper_Zones =
{
{[0]="Kalimdor",
[1]="Ahn'Qiraj: The Fallen Kingdom",
[2]="Ashenvale",
[3]="Azshara",
[4]="Azuremyst Isle",
[5]="Bloodmyst Isle",
[6]="Darkshore",
[7]="Darnassus",
[8]="Desolace",
[9]="Durotar",
[10]="Dustwallow Marsh",
[11]="Felwood",
[12]="Feralas",
[13]="Moonglade",
[14]="Mount Hyjal",
[15]="Mulgore",
[16]="Northern Barrens",
[17]="Orgrimmar",
[18]="Silithus",
[19]="Southern Barrens",
[20]="Stonetalon Mountains",
[21]="Tanaris",
[22]="Teldrassil",
[23]="The Exodar",
[24]="Thousand Needles",
[25]="Thunder Bluff",
[26]="Uldum",
[27]="Un'Goro Crater",
[28]="Winterspring"
[2]="Ammen Vale",
[3]="Ashenvale",
[4]="Azshara",
[5]="Azuremyst Isle",
[6]="Bloodmyst Isle",
[8]="Darkshore",
[9]="Darnassus",
[10]="Desolace",
[11]="Durotar",
[12]="Dustwallow Marsh",
[14]="Felwood",
[15]="Feralas",
[16]="Moonglade",
[17]="Mount Hyjal",
[18]="Mulgore",
[19]="Northern Barrens",
[20]="Orgrimmar",
[22]="Silithus",
[23]="Southern Barrens",
[24]="Stonetalon Mountains",
[25]="Tanaris",
[26]="Teldrassil",
[27]="The Exodar",
[28]="Thousand Needles",
[29]="Thunder Bluff",
[30]="Uldum",
[31]="Un'Goro Crater",
[33]="Winterspring"
},
{[0]="Eastern Kingdoms",
[1]="Abyssal Depths",
@ -44,40 +45,40 @@ QuestHelper_Zones =
[3]="Badlands",
[4]="Blasted Lands",
[5]="Burning Steppes",
[6]="Deadwind Pass",
[7]="Dun Morogh",
[8]="Duskwood",
[9]="Eastern Plaguelands",
[10]="Elwynn Forest",
[11]="Eversong Woods",
[12]="Ghostlands",
[13]="Hillsbrad Foothills",
[14]="Ironforge",
[15]="Isle of Quel'Danas",
[16]="Kelp'thar Forest",
[17]="Loch Modan",
[18]="Northern Stranglethorn",
[19]="Redridge Mountains",
[20]="Ruins of Gilneas",
[21]="Gilneas", -- Actually "Ruins of Gilneas City", but this fixes issues with some non-English clients that have the two zones named the same.
[22]="Searing Gorge",
[23]="Shimmering Expanse",
[24]="Silvermoon City",
[25]="Silverpine Forest",
[26]="Stormwind City",
[27]="Stranglethorn Vale",
[28]="Swamp of Sorrows",
[29]="The Cape of Stranglethorn",
[30]="The Hinterlands",
[31]="Tirisfal Glades",
[32]="Tol Barad",
[33]="Tol Barad Peninsula",
[34]="Twilight Highlands",
[35]="Undercity",
[36]="Vashj'ir",
[37]="Western Plaguelands",
[38]="Westfall",
[39]="Wetlands"
[7]="Deadwind Pass",
[9]="Dun Morogh",
[10]="Duskwood",
[11]="Eastern Plaguelands",
[12]="Elwynn Forest",
[13]="Eversong Woods",
[14]="Ghostlands",
[15]="Hillsbrad Foothills",
[16]="Ironforge",
[17]="Isle of Quel'Danas",
[18]="Kelp'thar Forest",
[19]="Loch Modan",
[21]="Northern Stranglethorn",
[23]="Redridge Mountains",
[24]="Ruins of Gilneas",
[25]="Gilneas", -- Actually "Ruins of Gilneas City", but this fixes issues with some non-English clients that have the two zones named the same.
[26]="Searing Gorge",
[27]="Shimmering Expanse",
[28]="Silvermoon City",
[29]="Silverpine Forest",
[30]="Stormwind City",
[31]="Stranglethorn Vale",
[33]="Swamp of Sorrows",
[34]="The Cape of Stranglethorn",
[35]="The Hinterlands",
[36]="Tirisfal Glades",
[37]="Tol Barad",
[38]="Tol Barad Peninsula",
[39]="Twilight Highlands",
[40]="Undercity",
[41]="Vashj'ir",
[42]="Western Plaguelands",
[43]="Westfall",
[44]="Wetlands"
},
{[0]="Outland",
[1]="Blade's Edge Mountains",
@ -110,66 +111,6 @@ QuestHelper_Zones =
[4]="The Maelstrom"
},
[-77]={[0]="ScarletEnclave_Continent", [1]="ScarletEnclave"},
[-78]={[0]="GilneasCity_Continent", [1]="GilneasCity"},
[-79]={[0]="GilneasZone_Continent", [1]="GilneasZone"},
[-80]={[0]="UtgardeKeep1_Continent", [1]="UtgardeKeep1"},
[-81]={[0]="UtgardeKeep2_Continent", [1]="UtgardeKeep2"},
[-82]={[0]="UtgardeKeep3_Continent", [1]="UtgardeKeep3"},
[-83]={[0]="TheNexus_Continent", [1]="TheNexus"},
[-84]={[0]="AzjolNerub1_Continent", [1]="AzjolNerub1"},
[-85]={[0]="AzjolNerub2_Continent", [1]="AzjolNerub2"},
[-86]={[0]="AzjolNerub3_Continent", [1]="AzjolNerub3"},
[-87]={[0]="Ahnkahet_Continent", [1]="Ahnkahet"},
[-88]={[0]="DrakTharonKeep1_Continent", [1]="DrakTharonKeep1"},
[-89]={[0]="DrakTharonKeep2_Continent", [1]="DrakTharonKeep2"},
[-90]={[0]="VioletHold_Continent", [1]="VioletHold"},
[-91]={[0]="Gundrak_Continent", [1]="Gundrak"},
[-92]={[0]="Ulduar77_Continent", [1]="Ulduar77"},
[-93]={[0]="HallsofLightning1_Continent", [1]="HallsofLightning1"},
[-94]={[0]="HallsofLightning2_Continent", [1]="HallsofLightning2"},
[-95]={[0]="Nexus801_Continent", [1]="Nexus801"},
[-96]={[0]="Nexus802_Continent", [1]="Nexus802"},
[-97]={[0]="Nexus803_Continent", [1]="Nexus803"},
[-98]={[0]="Nexus804_Continent", [1]="Nexus804"},
[-99]={[0]="CoTStratholme1_Continent", [1]="CoTStratholme1"},
[-100]={[0]="CoTStratholme2_Continent", [1]="CoTStratholme2"},
[-101]={[0]="UtgardePinnacle1_Continent", [1]="UtgardePinnacle1"},
[-102]={[0]="UtgardePinnacle2_Continent", [1]="UtgardePinnacle2"},
[-103]={[0]="VaultofArchavon_Continent", [1]="VaultofArchavon"},
[-104]={[0]="Naxxramas1_Continent", [1]="Naxxramas1"},
[-105]={[0]="Naxxramas2_Continent", [1]="Naxxramas2"},
[-106]={[0]="Naxxramas3_Continent", [1]="Naxxramas3"},
[-107]={[0]="Naxxramas4_Continent", [1]="Naxxramas4"},
[-108]={[0]="Naxxramas5_Continent", [1]="Naxxramas5"},
[-109]={[0]="Naxxramas6_Continent", [1]="Naxxramas6"},
[-110]={[0]="TheObsidianSanctum_Continent", [1]="TheObsidianSanctum"},
[-111]={[0]="TheEyeOfEternity_Continent", [1]="TheEyeOfEternity"},
[-112]={[0]="Ulduar_Continent", [1]="Ulduar"},
[-113]={[0]="Ulduar1_Continent", [1]="Ulduar1"},
[-114]={[0]="Ulduar2_Continent", [1]="Ulduar2"},
[-115]={[0]="Ulduar3_Continent", [1]="Ulduar3"},
[-116]={[0]="Ulduar4_Continent", [1]="Ulduar4"},
[-117]={[0]="TheForgeofSouls_Continent", [1]="TheForgeofSouls"},
[-118]={[0]="PitofSaron_Continent", [1]="PitofSaron"},
[-119]={[0]="DeeprunTram_Continent", [1]="DeeprunTram"},
}
@ -177,177 +118,110 @@ QuestHelper_Zones =
-- Additionally, [CONT_INDEX][ZONE_INDEX] = INDEX will also be added.
QuestHelper_IndexLookup =
{
["Orgrimmar"] = {1, 1, 17},
["Ashenvale"] = {2, 1, 2},
["AzuremystIsle"] = {3, 1, 4},
["Desolace"] = {4, 1, 8},
["Silithus"] = {5, 1, 18},
["StonetalonMountains"] = {6, 1, 20},
["Durotar"] = {7, 1, 9},
["Tanaris"] = {8, 1, 21},
["BloodmystIsle"] = {9, 1, 5},
["Dustwallow"] = {10, 1, 10},
["Orgrimmar"] = {321, 1, 17},
["Ashenvale"] = {43, 1, 2},
["AzuremystIsle"] = {464, 1, 4},
["Desolace"] = {101, 1, 8},
["Silithus"] = {261, 1, 18},
["StonetalonMountains"] = {81, 1, 20},
["Durotar"] = {4, 1, 9},
["Tanaris"] = {161, 1, 21},
["BloodmystIsle"] = {476, 1, 5},
["Dustwallow"] = {141, 1, 10},
["Barrens"] = {11, 1, 16},
["TheExodar"] = {12, 1, 23},
["Felwood"] = {13, 1, 11},
["ThousandNeedles"] = {14, 1, 24},
["Aszhara"] = {15, 1, 3},
["Darkshore"] = {16, 1, 6},
["Feralas"] = {17, 1, 12},
["UngoroCrater"] = {18, 1, 27},
["Winterspring"] = {19, 1, 28},
["Moonglade"] = {20, 1, 13},
["Darnassus"] = {21, 1, 7},
["Mulgore"] = {22, 1, 15},
["ThunderBluff"] = {23, 1, 25},
["Teldrassil"] = {24, 1, 22},
["Ironforge"] = {25, 2, 14},
["Badlands"] = {27, 2, 3},
["DunMorogh"] = {28, 2, 7},
["LochModan"] = {29, 2, 17},
["Redridge"] = {30, 2, 19},
["Duskwood"] = {31, 2, 8},
["SearingGorge"] = {32, 2, 22},
["BlastedLands"] = {33, 2, 4},
["EasternPlaguelands"] = {34, 2, 9},
["Silverpine"] = {35, 2, 25},
["StormwindCity"] = {36, 2, 26},
["Elwynn"] = {37, 2, 10},
["StranglethornVale"] = {38, 2, 27},
["Arathi"] = {39, 2, 2},
["BurningSteppes"] = {40, 2, 5},
["EversongWoods"] = {41, 2, 11},
["Hinterlands"] = {42, 2, 30},
["Tirisfal"] = {43, 2, 31},
["Ghostlands"] = {44, 2, 12},
["Undercity"] = {45, 2, 35},
["SwampOfSorrows"] = {46, 2, 28},
["DeadwindPass"] = {47, 2, 6},
["HillsbradFoothills"] = {48, 2, 13},
["Westfall"] = {49, 2, 38},
["WesternPlaguelands"] = {50, 2, 37},
["Wetlands"] = {51, 2, 39},
["SilvermoonCity"] = {52, 2, 24},
["ShadowmoonValley"] = {53, 3, 5},
["BladesEdgeMountains"] = {54, 3, 1},
["TerokkarForest"] = {55, 3, 7},
["Hellfire"] = {56, 3, 2},
["Zangarmarsh"] = {57, 3, 8},
["Nagrand"] = {58, 3, 3},
["Netherstorm"] = {59, 3, 4},
["ShattrathCity"] = {60, 3, 6},
["Kalimdor"] = {61, 1, 0},
["Azeroth"] = {62, 2, 0},
["Expansion01"] = {63, 3, 0},
["Sunwell"] = {64, 2, 15},
["BoreanTundra"] = {65, 4, 1},
["CrystalsongForest"] = {66, 4, 2},
["Dalaran"] = {67, 4, 3},
["Dragonblight"] = {68, 4, 4},
["GrizzlyHills"] = {69, 4, 5},
["HowlingFjord"] = {70, 4, 6},
["IcecrownGlacier"] = {71, 4, 8},
["SholazarBasin"] = {72, 4, 9},
["TheStormPeaks"] = {73, 4, 10},
["LakeWintergrasp"] = {74, 4, 11},
["ZulDrak"] = {75, 4, 12},
["Northrend"] = {76, 4, 0},
["TheExodar"] = {471, 1, 23},
["Felwood"] = {182, 1, 11},
["ThousandNeedles"] = {61, 1, 24},
["Aszhara"] = {181, 1, 3},
["Darkshore"] = {42, 1, 6},
["Feralas"] = {121, 1, 12},
["UngoroCrater"] = {201, 1, 27},
["Winterspring"] = {281, 1, 28},
["Moonglade"] = {241, 1, 13},
["Darnassus"] = {381, 1, 7},
["Mulgore"] = {9, 1, 15},
["ThunderBluff"] = {362, 1, 25},
["Teldrassil"] = {41, 1, 22},
["Ironforge"] = {341, 2, 14},
["Badlands"] = {17, 2, 3},
["DunMorogh"] = {27, 2, 7},
["LochModan"] = {35, 2, 17},
["Redridge"] = {36, 2, 19},
["Duskwood"] = {34, 2, 8},
["SearingGorge"] = {28, 2, 22},
["BlastedLands"] = {19, 2, 4},
["EasternPlaguelands"] = {23, 2, 9},
["Silverpine"] = {21, 2, 25},
["StormwindCity"] = {301, 2, 26},
["Elwynn"] = {30, 2, 10},
["StranglethornVale"] = {689, 2, 27},
["Arathi"] = {16, 2, 2},
["BurningSteppes"] = {29, 2, 5},
["EversongWoods"] = {462, 2, 11},
["Hinterlands"] = {26, 2, 30},
["Tirisfal"] = {20, 2, 31},
["Ghostlands"] = {463, 2, 12},
["Undercity"] = {382, 2, 35},
["SwampOfSorrows"] = {38, 2, 28},
["DeadwindPass"] = {32, 2, 6},
["HillsbradFoothills"] = {24, 2, 13},
["Westfall"] = {39, 2, 38},
["WesternPlaguelands"] = {22, 2, 37},
["Wetlands"] = {40, 2, 39},
["SilvermoonCity"] = {480, 2, 24},
["ShadowmoonValley"] = {473, 3, 5},
["BladesEdgeMountains"] = {475, 3, 1},
["TerokkarForest"] = {478, 3, 7},
["Hellfire"] = {465, 3, 2},
["Zangarmarsh"] = {467, 3, 8},
["Nagrand"] = {477, 3, 3},
["Netherstorm"] = {479, 3, 4},
["ShattrathCity"] = {481, 3, 6},
["Kalimdor"] = {13, 1, 0},
["Azeroth"] = {-1, 2, 0},
["Expansion01"] = {466, 3, 0},
["Sunwell"] = {499, 2, 15},
["BoreanTundra"] = {486, 4, 1},
["CrystalsongForest"] = {510, 4, 2},
["Dalaran"] = {504, 4, 3},
["Dragonblight"] = {488, 4, 4},
["GrizzlyHills"] = {490, 4, 5},
["HowlingFjord"] = {491, 4, 6},
["IcecrownGlacier"] = {492, 4, 8},
["SholazarBasin"] = {493, 4, 9},
["TheStormPeaks"] = {495, 4, 10},
["LakeWintergrasp"] = {501, 4, 11},
["ZulDrak"] = {496, 4, 12},
["Northrend"] = {485, 4, 0},
["HrothgarsLanding"] = {153, 4, 7}, -- wooo consecutive numbering
["AhnQirajTheFallenKingdom"] = {158, 1, 1},
["Hyjal"] = {198, 1, 14}, -- Check
["SouthernBarrens"] = {203, 1, 19},
["Uldum"] = {164, 1, 26}, -- Check
["Uldum_terrain1"] = {210, 1, 26}, -- Check
["VashjirDepths"] = {165, 2, 1}, -- Check
["VashjirKelpForest"] = {167, 2, 16}, -- Check
["StranglethornJungle"] = {168, 2, 18},
["RuinsofGilneas"] = {169, 2, 20},
["RuinsofGilneasCity"] = {170, 2, 21},
["VashjirRuins"] = {171, 2, 23}, -- Check
["TheCapeOfStranglethorn"] = {174, 2, 29},
["TolBarad"] = {175, 2, 32},
["TolBaradDailyArea"] = {176, 2, 33},
["TwilightHighlands_terrain1"] = {177, 2, 34},
["Vashjir"] = {178, 2, 36}, -- Check
["Deepholm"] = {179, 5, 1},
["Kezan"] = {180, 5, 2},
["TheLostIsles"] = {181, 5, 3},
["TheLostIsles_terrain1"] = {208, 5, 3},
["TheLostIsles_terrain2"] = {209, 5, 3},
["TheMaelstrom"] = {182, 5, 4},
["TheMaelstromContinent"] = {183, 5, 0},
["TwilightHighlands"] = {184, 2, 34},
["Hyjal_terrain1"] = {185, 1, 14},
["ScarletEnclave_Continent"] = {77, -77, 0}, ["ScarletEnclave"] = {78, -77, 1},
["UtgardeKeep1_Continent"] = {79, -80, 0}, ["UtgardeKeep1"] = {80, -80, 1},
["UtgardeKeep2_Continent"] = {81, -81, 0}, ["UtgardeKeep2"] = {82, -81, 1},
["UtgardeKeep3_Continent"] = {83, -82, 0}, ["UtgardeKeep3"] = {84, -82, 1},
["TheNexus_Continent"] = {85, -83, 0}, ["TheNexus"] = {86, -83, 1},
["AzjolNerub1_Continent"] = {87, -84, 0}, ["AzjolNerub1"] = {88, -84, 1},
["AzjolNerub2_Continent"] = {89, -85, 0}, ["AzjolNerub2"] = {90, -85, 1},
["AzjolNerub3_Continent"] = {91, -86, 0}, ["AzjolNerub3"] = {92, -86, 1},
["Ahnkahet_Continent"] = {93, -87, 0}, ["Ahnkahet"] = {94, -87, 1},
["DrakTharonKeep1_Continent"] = {95, -88, 0}, ["DrakTharonKeep1"] = {96, -88, 1},
["DrakTharonKeep2_Continent"] = {97, -89, 0}, ["DrakTharonKeep2"] = {98, -89, 1},
["VioletHold_Continent"] = {99, -90, 0}, ["VioletHold"] = {100, -90, 1},
["Gundrak_Continent"] = {101, -91, 0}, ["Gundrak"] = {102, -91, 1},
["Ulduar77_Continent"] = {103, -92, 0}, ["Ulduar77"] = {104, -92, 1}, -- HoS
["HallsofLightning1_Continent"] = {105, -93, 0}, ["HallsofLightning1"] = {106, -93, 1},
["HallsofLightning2_Continent"] = {107, -94, 0}, ["HallsofLightning2"] = {108, -94, 1},
["Nexus801_Continent"] = {109, -95, 0}, ["Nexus801"] = {110 , -95, 1},
["Nexus802_Continent"] = {111, -96, 0}, ["Nexus802"] = {112, -96, 1},
["Nexus803_Continent"] = {113, -97, 0}, ["Nexus803"] = {114, -97, 1},
["Nexus804_Continent"] = {115, -98, 0}, ["Nexus804"] = {116, -98, 1},
["CoTStratholme1_Continent"] = {117, -99, 0}, ["CoTStratholme1"] = {118, -99, 1},
["CoTStratholme2_Continent"] = {119, -100, 0}, ["CoTStratholme2"] = {120, -100, 1},
["UtgardePinnacle1_Continent"] = {121, -101, 0}, ["UtgardePinnacle1"] = {122, -101, 1},
["UtgardePinnacle2_Continent"] = {123, -102, 0}, ["UtgardePinnacle2"] = {124, -102, 1},
["VaultofArchavon_Continent"] = {125, -103, 0}, ["VaultofArchavon"] = {126, -103, 1},
["Naxxramas1_Continent"] = {127, -104, 0}, ["Naxxramas1"] = {128, -104, 1},
["Naxxramas2_Continent"] = {129, -105, 0}, ["Naxxramas2"] = {130, -105, 1},
["Naxxramas3_Continent"] = {131, -106, 0}, ["Naxxramas3"] = {132, -106, 1},
["Naxxramas4_Continent"] = {133, -107, 0}, ["Naxxramas4"] = {134, -107, 1},
["Naxxramas5_Continent"] = {135, -108, 0}, ["Naxxramas5"] = {136, -108, 1},
["Naxxramas6_Continent"] = {137, -109, 0}, ["Naxxramas6"] = {138, -109, 1},
["TheObsidianSanctum_Continent"] = {139, -110, 0}, ["TheObsidianSanctum"] = {140, -110, 1},
["TheEyeOfEternity_Continent"] = {141, -111, 0}, ["TheEyeOfEternity"] = {142, -111, 1},
["Ulduar_Continent"] = {143, -112, 0}, ["Ulduar"] = {144, -112, 1},
["Ulduar1_Continent"] = {145, -113, 0}, ["Ulduar1"] = {146, -113, 1},
["Ulduar2_Continent"] = {147, -114, 0}, ["Ulduar2"] = {148, -114, 1},
["Ulduar3_Continent"] = {149, -115, 0}, ["Ulduar3"] = {150, -115, 1},
["Ulduar4_Continent"] = {151, -116, 0}, ["Ulduar4"] = {152, -116, 1},
["TheForgeofSouls_Continent"] = {154, -117, 0}, ["TheForgeofSouls"] = {155, -117, 1},
["PitofSaron_Continent"] = {156, -118, 0}, ["PitofSaron"] = {157, -118, 1},
["GilneasCity_Continent"] = {204, -78, 0}, ["GilneasCity"] = {205, -78, 1},
["GilneasZone_Continent"] = {206, -79, 0}, ["GilneasZone"] = {207, -79, 1},
["DeeprunTram_Continent"] = {208, -119, 0}, ["DeeprunTram"] = {209, -119, 1},
-- yes virginia 183 is currently the end
["HrothgarsLanding"] = {541, 4, 7}, -- wooo consecutive numbering
["AhnQirajTheFallenKingdom"] = {772, 1, 1},
["Hyjal"] = {606, 1, 14}, -- Check
["SouthernBarrens"] = {607, 1, 19},
["Uldum"] = {720, 1, 26}, -- Check
["Uldum_terrain1"] = {720, 1, 26}, -- Check
["VashjirDepths"] = {614, 2, 1}, -- Check
["VashjirKelpForest"] = {610, 2, 16}, -- Check
["StranglethornJungle"] = {37, 2, 18},
["RuinsofGilneas"] = {684, 2, 20},
["RuinsofGilneasCity"] = {685, 2, 21},
["VashjirRuins"] = {615, 2, 23}, -- Check
["TheCapeOfStranglethorn"] = {673, 2, 29},
["TolBarad"] = {708, 2, 32},
["TolBaradDailyArea"] = {709, 2, 33},
["TwilightHighlands_terrain1"] = {700, 2, 34},
["Vashjir"] = {613, 2, 36}, -- Check
["Deepholm"] = {640, 5, 1},
["Kezan"] = {605, 5, 2},
["TheLostIsles"] = {544, 5, 3},
["TheLostIsles_terrain1"] = {544, 5, 3},
["TheLostIsles_terrain2"] = {544, 5, 3},
["TheMaelstrom"] = {737, 5, 4},
["TheMaelstromContinent"] = {751, 5, 0},
["TwilightHighlands"] = {700, 2, 34},
["Hyjal_terrain1"] = {606, 1, 14},
["ScarletEnclave_Continent"] = {-502, -77, 0}, ["ScarletEnclave"]={502,-77,1},
}
QuestHelper_RestrictedZones = { -- Everything defaults to "nil"

Voir le fichier

@ -1,4 +1,5 @@
function QuestHelper_GetTime()
if inWorld then return theTime end
if IsMacClient() then return debugprofilestop()
else return debugprofilestop() / 1000
end
@ -9,7 +10,14 @@ local GetTime = QuestHelper_GetTime
QuestHelper_File["utility.lua"] = "4.0.1.$svnversion$"
QuestHelper_Loadtime["utility.lua"] = GetTime()
local theTime = GetTime()
local inWorld = false
QuestHelper = CreateFrame("Frame", "QuestHelper", nil)
local TimeUpdater = CreateFrame("Frame", "TimeUpdater", nil)
TimeUpdater:SetScript("OnUpdate", function () theTime = GetTime() end)
TimeUpdater:RegisterEvent("PLAYER_ENTERING_WORLD")
TimeUpdater:SetScript("OnEvent", function () inWorld = true end)
--[[ static ]] ALLIANCE = 1
--[[ static ]] HORDE = 2
@ -131,7 +139,7 @@ function QuestHelper:TextOut(text)
local theme = self:GetColourTheme()
DEFAULT_CHAT_FRAME:AddMessage(string.format("|cff%2x%2x%2xQuestHelper: |r%s", theme.message_prefix[1]*255,
theme.message_prefix[2]*255,
theme.message_prefix[3]*255, text),
theme.message_prefix[3]*255, tostring(text)),
theme.message[1],
theme.message[2],
theme.message[3])