Class: Health

Health()

new Health()

Source:

Members

Schema

Source:

damageVariant

Source:

hitpoints

Source:

hitpoints

Source:

hitpoints

Source:

hitpoints

Source:

hitpoints

Source:

idleRegenRate

Source:

idleRegenRate

Source:

maxHitpoints

Source:

maxHitpoints

Source:

regenRate

Source:

regenRate

Source:

regenTimer

Source:

regenTimer

Source:

Methods

CheckRegenTimer()

Source:

CreateCorpse()

Source:

CreateDeathSpawnedEntity()

Source:

ExecuteRegeneration()

Source:

GetHitpoints()

Returns the current hitpoint value. This is 0 if (and only if) the unit is dead.
Source:

GetIdleRegenRate()

Source:

GetMaxHitpoints()

Source:

GetRegenRate()

Source:

HandleDeath()

Handle what happens when the entity dies.
Source:

Increase()

Source:

Init()

Source:

IsInjured() → {boolean}

Source:
Returns:
Whether the units are injured. Dead units are not considered injured.
Type
boolean

IsRepairable()

Source:

IsUnhealable()

Source:

Kill()

Source:

KilledBy(attacker, attackerOwner)

Called when an entity kills us.
Parameters:
Name Type Description
attacker number The entityID of the killer.
attackerOwner number The playerID of the attacker.
Source:

Mirage()

Source:

OnOwnershipChanged()

Source:

OnValueModification()

Source:

RecalculateValues()

Source:

Reduce(amount) → {Object}

Parameters:
Name Type Description
amount number The amount of hitpoints to substract. Kills the entity if required.
Source:
Returns:
- Number of health points lost.
Type
Object

RegisterHealthChanged()

Source:

SetHitpoints()

Source:

TakeDamage(amount, attacker, attackerOwner)

Parameters:
Name Type Description
amount number The amount of damage to be taken.
attacker number The entityID of the attacker.
attackerOwner number The playerID of the owner of the attacker.
Source:

UpdateActor()

Source: