WoWInterface SVN zz_Worldboss

Compare Revisions

  • This comparison shows the changes necessary to convert path
    /
    from Rev 62 to Rev 63
    Reverse comparison

Rev 62 → Rev 63

trunk/zz_Worldboss/core.lua
293,12 → 293,12
db['char_db'][player][questId] = IsQuestFlaggedCompleted(questId) and true or nil
end
end
if(questData['location']) then
--[[ if(questData['location']) then
local pin = addon['getPin'](name.."_quest_"..questId,questData['x'],questData['y'],questData['location'],questData['name'],questData['icon'] or 'Interface\\WorldMap\\TreasureChest_64')
if(db['char_db'][player][questId]) then
addon['removePin'](name.."_quest_"..questId)
end
end
end ]]--
end
end
end
632,6 → 632,6
end)
end
addon['updatePrefs']()
addon['RegisterFunc']({"PLAYER_LOGOUT","PLAYER_REGEN_DISABLED","PLAYER_REGEN_ENABLED"},"OnEvent", event)
addon['RegisterFunc']({"PLAYER_LOGOUT","PLAYER_REGEN_DISABLED","PLAYER_REGEN_ENABLED","QUEST_COMPLETE","QUEST_FINISHED"},"OnEvent", event)
end
addon['startup'](addon, name, childName, init, true, defaults)
trunk/zz_Worldboss/pins.lua
1,7 → 1,7
local _, addon = ...
local mapID
addon['pins'] = addon['pins'] or {}
 
local usedMaps = {}
local function mapTrans(x,y,btn)
local fr = WORLDMAP_SETTINGS['size']
local width = WorldMapButton:GetWidth() * fr
43,6 → 43,7
tex:SetAllPoints()
tex:SetTexture(addon['pins'][name][5])
addon['pins'][name][#addon['pins'][name]+1] = btn
usedMaps[addon['pins'][name][3]] = true
end
addon['removePin'] = function(name)
addon['pins'][name][#addon['pins'][name]]:Hide()
62,11 → 63,13
f:RegisterEvent("WORLD_MAP_UPDATE")
local function evnt(self)
mapID = GetCurrentMapAreaID()
for name, pin in pairs(addon['pins']) do
addon['updatePin'](name, mapID)
if(usedMaps[mapID]) then
for name, pin in pairs(addon['pins']) do
addon['updatePin'](name, mapID)
end
end
end
addon['RegisterEventThrottle'](f ,childName, "WORLD_MAP_UPDATE", 0.7, evnt)
addon['RegisterEventThrottle'](f ,childName, "WORLD_MAP_UPDATE", 2, evnt)
f:SetScript("OnUpdate", function(self, el)
self.lu = self.lu - el
if(self.lu < 0) then