andersonsmith969 Posted May 4, 2012 Share Posted May 4, 2012 I tried attaching an object script with the commands "modcurrentcharge 1 " and "setcurrenthealth 1" to make a weapon self-recharge and never run out of health, but they don't do anything. I just stuck them under a gamemode block. Link to comment Share on other sites More sharing options...
DrakeTheDragon Posted May 4, 2012 Share Posted May 4, 2012 (edited) Hmm, as this seems to be the way those functions are used indeed, I need to ask if you're also starting your game via OBSE now, as those are OBSE functions and not doing so will just make the script terminate when it reaches a now-'unknown' function call. There will be no errors or warnings. If it helps, you could try using ref myself ... set myself to GetSelf myself.ModCurrentCharge 1 myself.SetCurrentHealth 1 so now it definitely "is" a reference there. But as a sidenote, a health of 1 will make your weapon almost broken already. It'd be better to set it to the Base Health or something as obtainable via GetObjectHealth, so it's always 100% intact, instead. edit: Oh, and in case all else fails, a little debugging via 'PrintToConsole "I just passed call XYZ"' to see if the script passed a function call at all could never hurt. Edited May 4, 2012 by DrakeTheDragon Link to comment Share on other sites More sharing options...
andersonsmith969 Posted May 4, 2012 Author Share Posted May 4, 2012 Thank you, I always wondered what all of the refself stuff was about in the vanilla scripts. And I was just using an example, I would never set the health to 1. I'll see what I can dig up. Link to comment Share on other sites More sharing options...
Recommended Posts