Scriptname DAMolagBalScript
short hasmace
short maceequip
float playerhealth
float currenthealth
short doOnce
short melustalk
float fquestdelaytime
float timer
Begin GameMode
if ( meluspetilusref.GetItemCount DAMolagBalCursedMace > 0 )
if ( hasmace == 0 )
set hasmace to 1
endif
endif
if ( meluspetilusref.fightgreet == 4 )
if ( doOnce == 0 )
set playerhealth to player.getav health
set doOnce to 1
endif
endif
if ( doOnce == 2 ) && ( GetStage DAMolagBal >= 20 )
set timer to ( timer + GetSecondsPassed )
if ( timer > 1.0 )
SetStage DAMolagBal 60
set doOnce to 3
endif
endif
if ( meluspetilusref.fightgreet == 4 )
if ( GetStage DAMolagBal > 0 )
if ( player.GetAV Health < 20 )
if ( GetStage DAMolagBal < 60 )
if ( player.getav health < 0 )
player.resurrect
endif
;player.ModAV Health playerhealth
player.resethealth
MelusPetilusREF.StopCombat Player
set doOnce to 2
Player.MoveTo DAMolagShrineMarkerREF
;SetStage DAMolagBal 60
endif
endif
endif
endif
End |