hidconsp Posted January 26, 2013 Share Posted January 26, 2013 Hi, I have just began scripting with papyrus, but I found it very hard. What I want to do is give a magic effect that keeps the player's magicka over 10 any time. So basically it is like infinite 10 magicka. But what is the condition that the script can notice change in magicka? I tried Event OnTrackedValue, Event OnUpdate, ... but nothing seems to work satisfactorily. This is what I was doing Event OnTrackedStatsEvent(string asStat, int aiStatValue) if (asStat == "Magicka") if (asStat < 10) Game.GetPlayer().modAV("Magicka", 10) endIf endIf endEvent Link to comment Share on other sites More sharing options...
scrivener07 Posted January 26, 2013 Share Posted January 26, 2013 Tracked stats dont have anything to do with magic, heres the list of tracked stats http://www.creationkit.com/ListOfTrackedStats Take a look at actor values or AVhttp://www.creationkit.com/Actorvalue I dont think theres an event for an AV change but you might be able to use the OnKeyDown or OnKeyUp event to listen for the attack/cast mouse button. Then check the AV in these events. I would attach the script to the player through an alias. Dont forget you have to register for the key you want a script to listen for. Link to comment Share on other sites More sharing options...
hidconsp Posted January 27, 2013 Author Share Posted January 27, 2013 Hmm... I don't know if it would work with magics like "flame" but it looks worth a try. Thanks a lot! Link to comment Share on other sites More sharing options...
Recommended Posts