mirror of
https://github.com/parnic/ice-hud.git
synced 2025-06-16 14:50:13 -05:00
- fixed bars disappearing when they were set to reverse and they filled up
- also fixed an issue where deleting a custom cooldown bar while it was set to "always" display would cause it to get stuck on the screen until the next UI reload
This commit is contained in:
@ -793,11 +793,11 @@ function IceBarElement.prototype:Flip(side)
|
||||
end
|
||||
|
||||
|
||||
function IceBarElement.prototype:SetScale(scale, force)
|
||||
function IceBarElement.prototype:SetScale(inScale, force)
|
||||
local oldScale = self.CurrScale
|
||||
local min_y, max_y;
|
||||
|
||||
self.CurrScale = IceHUD:Clamp(self:LerpScale(scale), 0, 1)
|
||||
self.CurrScale = IceHUD:Clamp(self:LerpScale(inScale), 0, 1)
|
||||
|
||||
if force or oldScale ~= self.CurrScale then
|
||||
local scale = self.CurrScale
|
||||
@ -819,7 +819,7 @@ function IceBarElement.prototype:SetScale(scale, force)
|
||||
|
||||
self.barFrame:SetHeight(self.settings.barHeight * scale)
|
||||
|
||||
if self.CurrScale == 0 then
|
||||
if scale == 0 then
|
||||
self.barFrame.bar:Hide()
|
||||
else
|
||||
self.barFrame.bar:Show()
|
||||
|
@ -508,6 +508,7 @@ function IceCustomCDBar.prototype:IsReady()
|
||||
end
|
||||
|
||||
function IceCustomCDBar.prototype:Show(bShouldShow)
|
||||
if self.moduleSettings.enabled then
|
||||
if (self.moduleSettings.displayMode == "Always") then
|
||||
if not self.bIsVisible then
|
||||
IceCustomCDBar.super.prototype.Show(self, true)
|
||||
@ -521,6 +522,9 @@ function IceCustomCDBar.prototype:Show(bShouldShow)
|
||||
else
|
||||
IceCustomCDBar.super.prototype.Show(self, bShouldShow)
|
||||
end
|
||||
else
|
||||
IceCustomCDBar.super.prototype.Show(self, bShouldShow)
|
||||
end
|
||||
end
|
||||
|
||||
function IceCustomCDBar.prototype:UseTargetAlpha(scale)
|
||||
|
Reference in New Issue
Block a user