I have an item in-game that I'm trying to curse, so when equipped it kills the player (with fair warning!)
The item is armor. I select the armor, then I click "Add" in the scripts section of the item to add a new script. I then select new script, and type my script, which is:
Scriptname CurseScript extends ObjectReference {Event OnEquipped (Actor AkActor)if AkActor == Game.GetPlayer()Game.GetPlayer().SetActorValue("health", 0)endifEndEvent}I then click compile, and then save.
I then create a new magic effect (I call it CurseEffect) which has effect archetype paralysis, constant effect on self - so under magic item description I can have details about the curse as an additional warning before equipping. I don't mind if the paralysis effect takes place before killing, or if the killing happens straight away.
I then create a new enchantment and add the above CurseEffect to it (magnitude 50, for 5 seconds).
I then add this enchantment to my armor.
So now I should have two effects on my armor - the paralysis and the scripted papyrus effects. However when I go into game and try to wear the armor, I get the correct description from the armor, warning me about the curse - but all that happens is the paralysis - which seems to be permanent, even if I tell the CurseEffect to allow recovery...
I'm obviously doing something wrong, most probably a very simple mistake - any ideas? Thanks!
