acklavidian Posted January 19, 2011 Share Posted January 19, 2011 (edited) ScriptName HumMod long IncomingDatalong ToGameFilelong OutgoingDatalong FromGameFilelong windedness Begin GameMode set IncomingData to CreateString set ToGameFile to CreateString set OutgoingData to CreateString set FromGameFile to CreateString SetString ToGameFile "ToGame.txt" SetString FromGameFile "FromGame.txt" setString IncomingData " " FileToString ToGameFile IncomingData StringMsgBox IncomingData //This reports 502.25 which is right. StringToFloat IncomingData Message "IncomingValue:%g", IncomingData //This reports 0 on the first run, 4 on the second, then 17, then 21, then 25, then 29, and so on... StringToInt OutgoingData set OutgoingData to Player.GetAVForBaseActor Fatigue Message "Current fatigue:% 10.10f", OutgoingData End////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// If it is not apparent from the above code I am pretty green when it comes to scripting for Oblivion so keep that in mind. Ok so, toGame.txt has 502.25 stored on the first line, and nothing else (not even white space), except maybe an endline. The message box reports this correctly as a string but when I try to turn it in to a float with StringToFloat from pluggy I get (from the Message function) 0 on the first run, 4 on the second, and so on as I commented above. Problem #1: I don't know why I am not getting something at least similar to what is in my file after I convert to a float. Problem #2: I don't know why it is changing without me manipulating its variable in the script. The next issue is that the Player.GetAVForBaseActor Fatigue doen't do anything. What I want is to get my Fatigue level, and store it in to a variable. Later I want to be able to "Damage" my fatigue in this script. I really don't know how to go about this. Edited January 19, 2011 by acklavidian Link to comment Share on other sites More sharing options...
Smooth613 Posted January 20, 2011 Share Posted January 20, 2011 You would have a much better chance at receiving proper help by posting in the Official Pluggy Thread. Link to comment Share on other sites More sharing options...
Recommended Posts