WoWInterface SVN RuneWatch

Compare Revisions

  • This comparison shows the changes necessary to convert path
    /trunk
    from Rev 14 to Rev 15
    Reverse comparison

Rev 14 → Rev 15

RuneWatch.lua
44,10 → 44,12
 
self:GuiUpdate();
--end
 
self.LastUpdate = 0;
end
 
function RuneWatch:OnEnable()
self:Print("Loaded...");
self:Print("Loaded, type /rune for options.");
 
--if (UnitClass("Player") == "DEATHKNIGHT") then
self:GuiUpdate();
61,10 → 63,8
 
local _, uclass = UnitClass("Player");
if (uclass ~= "DEATHKNIGHT") then
--self:Print("Not a Deathknight");
self.Gui.Anchor:Hide();
else
--self:Print("Deathknight");
self.Gui.Anchor:Show();
end
end
73,6 → 73,17
 
end
 
function RuneWatch:OnUpdate(self, elapsed)
RuneWatch.LastUpdate = RuneWatch.LastUpdate + elapsed;
 
if (RuneWatch.LastUpdate > 0.5) then
RuneWatch.LastUpdate = 0;
 
-- Update the GUI
RuneWatch:UNIT_RUNIC_POWER("UNIT_RUNIC_POWER", "player");
end
end
 
function RuneWatch:RUNE_POWER_UPDATE(event, ...)
local rune, usable = ...;
if not usable then
129,6 → 140,8
self.Gui.Anchor:SetHeight(100);
self.Gui.Anchor:SetPoint("CENTER", UIParent, "CENTER");
--self.Gui.Anchor:SetFrameStrata("LOW");
 
self.Gui.Anchor:SetScript("OnUpdate", function(self, elapsed) RuneWatch:OnUpdate(self, elapsed) end);
self.Gui.Anchor:Show();
 
 
230,8 → 243,6
--self.Gui.Art.Bar = artBar;
 
self:InitRPBar();
 
self:Print("Initialized Art...")
end
 
function RuneWatch:InitRPBar()