Need help with script for Vampire Lord transformation.

Post » Sat Nov 17, 2012 10:46 pm

So with the release of Dawnguard, we got a few new jewelry items that affect the Vampire Lord. However, Bethesda made it so we couldn't duplicate what they did with the creation kit. If you make an item similar to the Ring of the Beast/Erudite, your Vampire lord won't gain any effects. They simply become unequipped (much like the werewolf). I'm not much a fan of such things, so I'm working on some scripts that activate when the items are unequipped and you are in your Vampire Lord form. Here's what I have so far:
Spoiler
Scriptname VampireAmulet001 extends ObjectReferenceRace Property VampireBeastRace AutoEvent OnUnequipped(Actor akActor)   if akActor == Game.GetPlayer()	If Game.GetPlayer().GetRace()==VampireBeastRace	 Game.GetPlayer().ModAV("Health", 100)	endif   endIfendEvent

However after this I get stuck. The script activates everytime the player transforms into the Vampire Lord, boosting their health to ridiculous levels. Is there a way I can make it so the script only happens once, or perhaps resets the players health to it's original value when the item is equipped? Any help is appreciated!
User avatar
Multi Multi
 
Posts: 3382
Joined: Mon Sep 18, 2006 4:07 pm

Return to V - Skyrim