I want to create a spell that can toggle the Respawn Flag on NPCs. For now, for my testing purposes, the tag would switch between NoRespawn/IsEssential and Respawn/NoEssential. To avoid problems with NPCs for Level lists, there would be a fork to recognize if the NPC has "No Low Level Processing", if the flag is marked, the spell won't work. I picked a script from one of those mods that adds a spell that resurrects NPCs and my script looks like this:
begin ScriptEffectStartref myselfset myself to GetSelfif (Myself.HasLowLevelProcessing == 0) If (Myself.IsEssential == 1) Myself.SetEssential to 0 Myself.SetActorRespawns to 1 Elseif (Myself.IsEssential == 0) Myself.SetEssential to 1 Myself.SetActorRespawns to 0 Endif else MessageBox "This Actor may belong to Level Lists and won't be toggled" endifend
The CS also didn't accept this script. My OBSE is 18, I read their documentation quickly and I didn't find those commands on "New Features" chapter.
If I'm posting this question in the wrong place or, if there is another forum more appropriate to ask this, please, let me know. Thank you for your attention.
EDIT: Added code tags.