Mercurial > wow > wowdb-profiler
comparison Main.lua @ 300:e5c2dc3c7f6f
PLAYER_GUID assignment fix.
author | James D. Callahan III <jcallahan@curse.com> |
---|---|
date | Mon, 01 Jul 2013 15:46:22 -0500 |
parents | 0946f1091810 |
children | 216f807df434 |
comparison
equal
deleted
inserted
replaced
299:0946f1091810 | 300:e5c2dc3c7f6f |
---|---|
36 local EVENT_DEBUG = false | 36 local EVENT_DEBUG = false |
37 local OBJECT_ID_ANVIL = 192628 | 37 local OBJECT_ID_ANVIL = 192628 |
38 local OBJECT_ID_FORGE = 1685 | 38 local OBJECT_ID_FORGE = 1685 |
39 local PLAYER_CLASS = _G.select(2, _G.UnitClass("player")) | 39 local PLAYER_CLASS = _G.select(2, _G.UnitClass("player")) |
40 local PLAYER_FACTION = _G.UnitFactionGroup("player") | 40 local PLAYER_FACTION = _G.UnitFactionGroup("player") |
41 local PLAYER_GUID = _G.UnitGUID("player") | 41 local PLAYER_GUID |
42 local PLAYER_NAME = _G.UnitName("player") | 42 local PLAYER_NAME = _G.UnitName("player") |
43 local PLAYER_RACE = _G.select(2, _G.UnitRace("player")) | 43 local PLAYER_RACE = _G.select(2, _G.UnitRace("player")) |
44 | 44 |
45 local ALLOWED_LOCALES = { | 45 local ALLOWED_LOCALES = { |
46 enUS = true, | 46 enUS = true, |
781 end | 781 end |
782 end | 782 end |
783 | 783 |
784 | 784 |
785 function WDP:OnEnable() | 785 function WDP:OnEnable() |
786 PLAYER_GUID = _G.UnitGUID("player") | |
787 | |
786 for event_name, mapping in pairs(EVENT_MAPPING) do | 788 for event_name, mapping in pairs(EVENT_MAPPING) do |
787 if EVENT_DEBUG then | 789 if EVENT_DEBUG then |
788 self:RegisterEvent(event_name, "EventDispatcher") | 790 self:RegisterEvent(event_name, "EventDispatcher") |
789 else | 791 else |
790 self:RegisterEvent(event_name, (_G.type(mapping) ~= "boolean") and mapping or nil) | 792 self:RegisterEvent(event_name, (_G.type(mapping) ~= "boolean") and mapping or nil) |