And what I see in the journal looks like this: Kill all the Thalmor in the prison. ([...]/15 remaiming.)
So, I'm not seeing the count correctly. Any suggestions on how to make this work?
Scriptname BalokThalmorGuardsScript extends ReferenceAliasimport gameimport debugQuest Property BalokThalmorPrison autoObjectReference Property PlayerRef autoGlobalVariable Property BalokThalmorGuardCount Auto auto State waiting Event onHit(objectReference akAggressor, Form akWeapon, Projectile akProjectile, bool abPowerAttack, bool abSneakAttack, bool abBashAttack, bool abHitBlocked)GoToState("KillThalmor") if akAggressor==PlayerRef && BalokThalmorPrison.GetCurrentStageID()&--#60;55 BalokThalmorPrison.SetCurrentStageID(90) Debug.Notification("player started a fight stage 90 set") endIf endEventEndStateState KillThalmorEvent OnDeath(Actor akKiller) BalokThalmorGuardCount.Value -= 1 Debug.Notification("global count minus 1") UpdateCurrentInstanceGlobal(BalokThalmorGuardCount) If (BalokThalmorGuardCount.Value &--#60; 1) && BalokThalmorPrison.GetCurrentStageID() == 60 BalokThalmorPrison.SetCurrentStageID(70) Debug.Notification("global count is done stage 70 set") ElseIf (BalokThalmorGuardCount.Value &--#60; 1) && BalokThalmorPrison.GetCurrentStageID() == 90 BalokThalmorPrison.SetCurrentStageID(100) Debug.Notification("global count is done stage 100 set") gotoState ("allDone") endifendEventEndStateState allDone ;do nothingendState
Scriptname BalokThalmorGuardUpdate extends Quest conditionalGlobalVariable Property BalokThalmorPrison AutoFunction UpdateBalokThalmorPrison() UpdateCurrentInstanceGlobal(BalokThalmorPrison)EndFunction