scn DANamiraPriestScript
float timer
short dead
short reactvar
Begin GameMode
set timer to ( timer - GetSecondsPassed )
if ( timer < -4 ) && ( reactvar == 0 ) && ( GetDead == 0 )
set timer to Say DANamiraSpeech
endif
if ( reactvar == 0 ) && ( GetItemCount Torch02 == 0 ) && ( GetDead == 0 )
Say DANamiraReactions
set reactvar to 1
endif
if ( GetStage DANamira == 30 )
If ( Priest1REF.IsSpellTarget DANamiraDarkness ) && ( DANamira.priest1 == 0 )
Set DANamira.priest1 to 1
Priest1REF.RemoveItem Torch02 1
Priest1REF.AddItem DATorch02 1
endif
If ( Priest2REF.IsSpellTarget DANamiraDarkness ) && ( DANamira.priest2 == 0 )
Set DANamira.priest2 to 1
Priest2REF.RemoveItem Torch02 1
Priest2REF.AddItem DATorch02 1
endif
If ( Priest3REF.IsSpellTarget DANamiraDarkness ) && ( DANamira.priest3 == 0 )
Set DANamira.priest3 to 1
Priest3REF.RemoveItem Torch02 1
Priest3REF.AddItem DATorch02 1
endif
If ( Priest4REF.IsSpellTarget DANamiraDarkness ) && ( DANamira.priest4 == 0 )
Set DANamira.priest4 to 1
Priest4REF.RemoveItem Torch02 1
Priest4REF.AddItem DATorch02 1
endif
endif
End
Begin OnDeath
set DANamira.priestsdead to ( DANamira.priestsdead + 1 )
set dead to 1
End
Begin OnDeath Player
SetStage DANamira 105
End |