comparison WorldPlan.lua @ 64:876c3f0bfd0e

- script upvalues cleanup - add quest active status to pin metadata
author Nick@Zahhak
date Thu, 23 Mar 2017 05:26:51 -0400
parents 8e130c92698f
children e43e10c5576b
comparison
equal deleted inserted replaced
63:8e130c92698f 64:876c3f0bfd0e
1 -- WorldPlan.lua 1 -- WorldPlan.lua
2 -- Created: 8/16/2016 8:19 AM 2 -- Created: 8/16/2016 8:19 AM
3 -- %file-revision% 3 -- %file-revision%
4 local addonFileName, db = ... 4 local addonFileName, db = ...
5 local print = DEVIAN_WORKSPACE and function(...) _G.print('WP', ...) end or function() end 5 local print = DEVIAN_WORKSPACE and function(...) _G.print('WP', ...) end or function() end
6 local WP_VERSION = "1.0" 6 local WP_VERSION = "1.2"
7 local tinsert, pairs, floor = tinsert, pairs, floor 7 local tinsert, pairs, floor = tinsert, pairs, floor
8 local tremove, ipairs, wipe, unpack = tremove, ipairs, wipe, unpack 8 local tremove, ipairs, wipe, unpack = tremove, ipairs, wipe, unpack
9 local select, type, tostring, tonumber = select, type, tostring, tonumber 9 local select, type, tostring, tonumber = select, type, tostring, tonumber
10 local ITEM_QUALITY_COLORS = ITEM_QUALITY_COLORS 10 local ITEM_QUALITY_COLORS = ITEM_QUALITY_COLORS
11 local BROKEN_ISLES_ID = 1007 11 local BROKEN_ISLES_ID = 1007
566 function WorldPlanCore:RegisterDataCallback(func) 566 function WorldPlanCore:RegisterDataCallback(func)
567 self.callbacks = self.callbacks or {} 567 self.callbacks = self.callbacks or {}
568 self.callbacks[func] = func 568 self.callbacks[func] = func
569 end 569 end
570 function WorldPlanCore:FireCallbacks() 570 function WorldPlanCore:FireCallbacks()
571 self.callbacks = self.callbacks or {}
571 for func in pairs(self.callbacks) do 572 for func in pairs(self.callbacks) do
572 func() 573 func()
573 end 574 end
574 self.dataFlush = nil 575 self.dataFlush = nil
575 end 576 end