mirror of
https://github.com/parnic/ice-hud.git
synced 2025-06-16 14:50:13 -05:00
The player health bar will now show a (by default) faded white bar above the health for the amount of absorption the player currently has. The incoming heal bar starts above both the player health and the absorb, if any is present. Also disabled the PlayerAbsorb bar by default since it's redundant. It can still be enabled separately if desired.
23 lines
614 B
Lua
23 lines
614 B
Lua
local PlayerAbsorb = IceCore_CreateClass(IceTargetAbsorb)
|
|
|
|
-- Constructor --
|
|
function PlayerAbsorb.prototype:init()
|
|
PlayerAbsorb.super.prototype.init(self, "PlayerAbsorb", "player", "PlayerAbsorb")
|
|
end
|
|
|
|
-- 'Public' methods -----------------------------------------------------------
|
|
|
|
-- OVERRIDE
|
|
function PlayerAbsorb.prototype:GetDefaultSettings()
|
|
local settings = PlayerAbsorb.super.prototype.GetDefaultSettings(self)
|
|
|
|
settings["side"] = IceCore.Side.Left
|
|
settings["offset"] = 3
|
|
settings["enabled"] = false
|
|
|
|
return settings
|
|
end
|
|
|
|
-- Load us up
|
|
IceHUD.PlayerAbsorb = PlayerAbsorb:new()
|