enderalse/source/scripts/_00e_mq01_gourdsscript.psc

31 lines
830 B
Plaintext
Raw Normal View History

Scriptname _00E_MQ01_GourdsScript extends ObjectReference
Event OnActivate(ObjectReference akActionRef)
If doOnce == 0 && !(MQ01_UnchartedLand.IsObjectiveCompleted(10))
_00E_MQ01_GourdsFound.SetValue(_00E_MQ01_GourdsFound.GetValue() + 1)
MQ01_UnchartedLand.UpdateCurrentInstanceGlobal(_00E_MQ01_GourdsFound)
int CurrentCount = _00E_MQ01_GourdsFound.GetValueInt()
If CurrentCount >= 5
MQ01_UnchartedLand.SetObjectiveCompleted(10, 1)
Levelsystem.GiveEP(50)
ElseIf CurrentCount < 5
MQ01_UnchartedLand.SetObjectiveCompleted(10,0)
MQ01_UnchartedLand.SetObjectiveDisplayed(10, True, True)
doOnce = 1
EndIf
ElseIf doOnce == 1
Return
EndIf
EndEvent
Quest Property MQ01_UnchartedLand Auto
GlobalVariable Property _00E_MQ01_GourdsFound Auto
_00E_QuestFunctions Property Levelsystem Auto
int doOnce