Maui Posted October 26, 2016 Posted October 26, 2016 For some reason this code doesn't work as it should. It does all the code. Normally, it should run one ' if ' statement per scriptrun. But it runs all the code at once. Any help?
Solution Tx606 Posted October 26, 2016 Solution Posted October 26, 2016 I guess it's because the script is read from top to bottom, right?Also if this is for MP purposes remember print needs an exclaimation point (!) before the message for it to appear. (Although that appears to everyone) If it may help you, here's something I used in MP for my map mods. A player gets their parm2 set to 1 at spawn and a scaler adds +0.1 every "use" until the limit is reached.The "2big" and "defaultsize uses are just target_prints I use to tell the user they're at the biggest size or the default size. Obviously you can use something similar for other map features like scaling objects/models/whatever, it's just to give you an alternative method. if ( $get( FLOAT, "SET_PARM2" ) > 2.900$ ) { use ( "2big" ); set ( "SET_PARM2", "3" ); set ( "SET_SCALE", $get( FLOAT, "SET_PARM2" )$ ); } else ( ) { if ( $get( FLOAT, "SET_PARM2" ) < 0.100$ ) { set ( "SET_PARM2", "0.1" ); set ( "SET_SCALE", $get( FLOAT, "SET_PARM2" )$ ); } else ( ) { set ( "SET_PARM2", "+0.1" ); set ( "SET_SCALE", $get( FLOAT, "SET_PARM2" )$ ); } if ( $get( FLOAT, "SET_PARM2" ) = 1.000$ ) { use ( "defaultsize" ); } } Maui likes this
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now