ObLars Posted November 30, 2010 Share Posted November 30, 2010 Hi. Im working on a little something something, and i can't figure how to write a script to accomplish this. The idea is too setactorvalue to 0 when a specific item is worn, but set actor value back to what it was before the item got equipped. So; If legs has a condition of 25% when not equipped, then you wear the piece of armour, you get 0% mobility. Then when you unequipp it you regain the 25% condition. How could this be done? Is the engine compatible to save actor values? I dont know if im clear on what i mean. Help is appriciated. Setactorvalue LeftMobilityCondition 0 Setactorvalue RightMobilityCondition 0 Link to comment Share on other sites More sharing options...
Quetzlsacatanango Posted November 30, 2010 Share Posted November 30, 2010 create variables for the limb values on equip, set the variables to the limb values and cripple the legson unequip, set the limb values to the variables Link to comment Share on other sites More sharing options...
ObLars Posted November 30, 2010 Author Share Posted November 30, 2010 create variables for the limb values on equip, set the variables to the limb values and cripple the legson unequip, set the limb values to the variables I guess. So there is actually a way to do something like that? Im quite new to making complex scripts, could you possibly throw me a hint? :P Link to comment Share on other sites More sharing options...
Quetzlsacatanango Posted November 30, 2010 Share Posted November 30, 2010 I don't really have time to try it out but it will look something like scn myscriptname short leftleg ;stores left leg health short rightleg ;stores right leg health Begin OnEquip player ; assuming this is for the player... a little more voodoo for anyone set leftleg to player.getav leftmobilitycondition set rightleg to player.getav rightmoibilitycondition player.setav leftmobilitycondition 0 player.setav rightmobilitycondition End Begin OnUnequip player player.setav leftmobilitycondition leftleg player.setav rightmobilitycondition rightleg End Something like that. Hopefully you can get the idea. Link to comment Share on other sites More sharing options...
ObLars Posted November 30, 2010 Author Share Posted November 30, 2010 Hugely appriciated. Although i get a warning on this line, somehow; set rightleg to player.GetActorValue rightmoibilitycondition Says there is no value. Allthough if i paste 0 as a value infront of it, the warning still stands.. Link to comment Share on other sites More sharing options...
Quetzlsacatanango Posted November 30, 2010 Share Posted November 30, 2010 Maybe cuz I spelled it wrong :)moibility Link to comment Share on other sites More sharing options...
ObLars Posted November 30, 2010 Author Share Posted November 30, 2010 Maybe cuz I spelled it wrong :)moibility Hehe *blush* Im quite new at spotting, like everything else. Thanks a BUNCH! Worked out great. Love. Link to comment Share on other sites More sharing options...
Recommended Posts