Fixes and patches

This commit is contained in:
iceroth
2006-12-08 02:19:21 +00:00
parent 7740ef9f74
commit 123dbf2542
7 changed files with 45 additions and 29 deletions

View File

@ -46,28 +46,9 @@ function IceCastBar.prototype:Enable(core)
self:RegisterEvent("UNIT_SPELLCAST_CHANNEL_STOP", "SpellCastChannelStop") -- unit
self.frame:Hide()
-- remove blizz cast bar
CastingBarFrame:UnregisterAllEvents()
end
function IceCastBar.prototype:Disable(core)
IceCastBar.super.prototype.Disable(self, core)
-- restore blizz cast bar
CastingBarFrame:RegisterEvent("SPELLCAST_START");
CastingBarFrame:RegisterEvent("SPELLCAST_STOP");
CastingBarFrame:RegisterEvent("SPELLCAST_FAILED");
CastingBarFrame:RegisterEvent("SPELLCAST_INTERRUPTED");
CastingBarFrame:RegisterEvent("SPELLCAST_DELAYED");
CastingBarFrame:RegisterEvent("SPELLCAST_CHANNEL_START");
CastingBarFrame:RegisterEvent("SPELLCAST_CHANNEL_UPDATE");
CastingBarFrame:RegisterEvent("SPELLCAST_CHANNEL_STOP");
end
-- 'Protected' methods --------------------------------------------------------
-- OVERRIDE
@ -275,8 +256,12 @@ function IceCastBar.prototype:SpellCastDelayed(unit, delay)
--IceHUD:Debug("SpellCastDelayed", unit, UnitCastingInfo(unit))
local spell, rank, displayName, icon, startTime, endTime, isTradeSkill = UnitCastingInfo(self.unit)
if (endTime and self.actionStartTime) then
-- apparently this check is needed, got nils during a horrible lag spike
self.actionDuration = endTime/1000 - self.actionStartTime
end
end
function IceCastBar.prototype:SpellCastSucceeded(unit, spell, rank)

View File

@ -477,7 +477,6 @@ StaticPopupDialogs["ICEHUD_RESET"] =
whileDead = 1,
hideOnEscape = 1,
OnAccept = function()
print("hellooo")
IceHUD.IceCore:ResetSettings()
end
}
@ -489,8 +488,6 @@ function IceHUD:OnInitialize()
self:Debug("IceHUD:OnInitialize()")
self.IceCore = IceCore:new()
end

View File

@ -3,7 +3,7 @@
## Name: IceHUD
## Title: IceHUD |cff7fff7f -Ace2-|r
## Notes: Another HUD addon
## Version: 0.8 ($Revision$)
## Version: 0.8.1 ($Revision$)
## SavedVariables: IceCoreDB
## OptionalDeps: Ace2, DewdropLib, DruidBar, SoleManax, MobHealth
## X-Embeds: Ace2, DewdropLib
@ -22,7 +22,6 @@ libs\AceConsole-2.0\AceConsole-2.0.lua
libs\AceAddon-2.0\AceAddon-2.0.lua
libs\Dewdrop-2.0\Dewdrop-2.0.lua
# IceHUD core functionality
IceCore.lua
IceHUD.lua
@ -31,7 +30,9 @@ IceBarElement.lua
IceUnitBar.lua
IceCastBar.lua
# IceHUD modules
# - Feel free to comment these out if you like
modules\PlayerHealth.lua
modules\PlayerMana.lua
modules\TargetHealth.lua

View File

@ -63,6 +63,34 @@ function CastBar.prototype:GetOptions()
return opts
end
function CastBar.prototype:Enable(core)
CastBar.super.prototype.Enable(self, core)
-- remove blizz cast bar
CastingBarFrame:UnregisterAllEvents()
end
function CastBar.prototype:Disable(core)
CastBar.super.prototype.Disable(self, core)
-- restore blizz cast bar
CastingBarFrame:RegisterEvent("UNIT_SPELLCAST_SENT");
CastingBarFrame:RegisterEvent("UNIT_SPELLCAST_START");
CastingBarFrame:RegisterEvent("UNIT_SPELLCAST_STOP");
CastingBarFrame:RegisterEvent("UNIT_SPELLCAST_FAILED");
CastingBarFrame:RegisterEvent("UNIT_SPELLCAST_INTERRUPTED");
CastingBarFrame:RegisterEvent("UNIT_SPELLCAST_DELAYED");
CastingBarFrame:RegisterEvent("UNIT_SPELLCAST_SUCCEEDED");
CastingBarFrame:RegisterEvent("UNIT_SPELLCAST_CHANNEL_START");
CastingBarFrame:RegisterEvent("UNIT_SPELLCAST_CHANNEL_UPDATE");
CastingBarFrame:RegisterEvent("UNIT_SPELLCAST_CHANNEL_STOP");
end
-------------------------------------------------------------------------------

View File

@ -48,6 +48,8 @@ function TargetCast.prototype:TargetChanged(unit)
self:StartBar(IceCastBar.Actions.Channel)
return
end
self:StopBar()
end
-------------------------------------------------------------------------------

View File

@ -412,7 +412,7 @@ function TargetInfo.prototype:CreateBuffFrame(redraw)
self.frame.buffFrame:SetHeight(1)
self.frame.buffFrame:ClearAllPoints()
self.frame.buffFrame:SetPoint("TOPRIGHT", self.frame, "TOPLEFT", -5, 0)
self.frame.buffFrame:SetPoint("TOPRIGHT", self.frame, "TOPLEFT", -10, 0)
self.frame.buffFrame:Show()
self.frame.buffFrame.buffs = {}
@ -433,7 +433,7 @@ function TargetInfo.prototype:CreateDebuffFrame(redraw)
self.frame.debuffFrame:SetHeight(1)
self.frame.debuffFrame:ClearAllPoints()
self.frame.debuffFrame:SetPoint("TOPLEFT", self.frame, "TOPRIGHT", 5, 0)
self.frame.debuffFrame:SetPoint("TOPLEFT", self.frame, "TOPRIGHT", 10, 0)
self.frame.debuffFrame:Show()
self.frame.debuffFrame.buffs = {}

View File

@ -401,9 +401,12 @@ function TargetOfTarget.prototype:BuffOnEnter(type)
return
end
if (this.unit and this.id) then
GameTooltip:SetOwner(this, "ANCHOR_BOTTOMRIGHT")
GameTooltip:SetUnitDebuff(this.unit, this.id)
end
end
-- load us up
IceHUD_Module_TargetOfTarget = TargetOfTarget:new()