enderalse/source/scripts/_00e_mq01_mushroomsfound.psc

35 lines
809 B
Plaintext

Scriptname _00E_MQ01_MushroomsFound extends ObjectReference
Event OnActivate(ObjectReference akActionRef)
if doOnce == 0 && !(MQ01_UnchartedLand.IsObjectiveCompleted(12))
_00E_MQ01_MushroomFound.SetValue(_00E_MQ01_MushroomFound.GetValue() + 1)
MQ01_UnchartedLand.UpdateCurrentInstanceGlobal(_00E_MQ01_MushroomFound)
int CurrentCount = _00E_MQ01_MushroomFound.GetValueInt()
if CurrentCount >= 3
MQ01_UnchartedLand.SetObjectiveCompleted(12,1)
_00E_EPHandler.GiveEP(50)
ElseIf CurrentCount < 3
MQ01_UnchartedLand.SetObjectiveCompleted(12,0)
MQ01_UnchartedLand.SetObjectiveDisplayed(12, True, True)
doOnce = 1
EndIf
ElseIf doOnce == 1
Return
EndIf
EndEvent
Quest Property MQ01_UnchartedLand Auto
GlobalVariable Property _00E_MQ01_MushroomFound Auto
import math
int doOnce
int done