Enderal SE https://mod.pub/enderal-se/38-enderal-se
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
45 lines
1.3 KiB
45 lines
1.3 KiB
3 years ago
|
Scriptname _00E_HealthBarSummons extends Actor
|
||
|
{Attaches and detaches the health bar to summons}
|
||
|
|
||
|
_00E_FS_ForgottenStories_Functions Property ForgottenStoriesMiscDialogue Auto
|
||
|
Bool Property DiesOnBleedout = False Auto
|
||
|
|
||
3 years ago
|
; Enderal SE: marked obsolete
|
||
3 years ago
|
Bool bRegisteredHealthBars = True ; Default to True, not False, for version update
|
||
|
|
||
|
Event OnLoad()
|
||
|
ForgottenStoriesMiscDialogue.showActorHealthBars(self)
|
||
|
EndEvent
|
||
|
|
||
|
Event OnEnterBleedout()
|
||
|
If DiesOnBleedout
|
||
|
UnregisterHealthBars()
|
||
|
EndIf
|
||
|
EndEvent
|
||
|
|
||
|
Event OnDying(Actor akKiller)
|
||
|
UnregisterHealthBars()
|
||
|
EndEvent
|
||
|
|
||
|
Event OnDeath(Actor akKiller)
|
||
|
UnregisterHealthBars() ; In case OnDying fails to unregister the health bars
|
||
|
EndEvent
|
||
|
|
||
|
Event OnUnload()
|
||
|
UnregisterHealthBars() ; In case OnDying and OnDeath fail to unregister the health bars (see the essential oorbayas)
|
||
|
EndEvent
|
||
|
|
||
|
Function UnregisterHealthBars()
|
||
3 years ago
|
ForgottenStoriesMiscDialogue.hideActorHealthBars(self)
|
||
3 years ago
|
EndFunction
|
||
3 years ago
|
|
||
|
Event OnCombatStateChanged(Actor akTarget, int aeCombatState)
|
||
|
if aeCombatState == 1
|
||
|
ForgottenStoriesMiscDialogue.showActorHealthBars(self)
|
||
|
endif
|
||
|
endEvent
|
||
|
|
||
|
Event OnHit(ObjectReference akAggressor, Form akSource, Projectile akProjectile, Bool abPowerAttack, Bool abSneakAttack, Bool abBashAttack, Bool abHitBlocked)
|
||
|
ForgottenStoriesMiscDialogue.showActorHealthBars(self)
|
||
|
endEvent
|