KiloSwiss Posted February 19, 2015 Report Share Posted February 19, 2015 You're welcome Leigham. Link to comment Share on other sites More sharing options...
Leigham Posted February 19, 2015 Author Report Share Posted February 19, 2015 Im looking at making the actual spawning method so it gets dropped by a heli and costs krypto instead, obviously putting it in a config :D Link to comment Share on other sites More sharing options...
Leigham Posted February 19, 2015 Author Report Share Posted February 19, 2015 where would i have to put UD_Paraspawn = true; , would that be client or server side ?# Link to comment Share on other sites More sharing options...
KiloSwiss Posted February 19, 2015 Report Share Posted February 19, 2015 I guess where You use the variable. And don't forget to remove the item from the players inventory, or they will spawn a few hundrets of these bikes. And don't make it too complex, stick with a simple, but working script and improve it later with advanced functionality. Greez KiloSwiss Link to comment Share on other sites More sharing options...
Leigham Posted February 19, 2015 Author Report Share Posted February 19, 2015 Could i use Veh=[vehicle classname] then on the create vehicle use _veh ? so i could use one variable with multiple vehicles ? Link to comment Share on other sites More sharing options...
KiloSwiss Posted February 19, 2015 Report Share Posted February 19, 2015 These are scripting basics. _veh is a local variable, that only exists in the scope it gets created. veh is a global variable, that exists local on the machine where it get created. redefining a variable, will override its previous value or reference.Simple: _number = 3; // Variable "_number" is a number, with the value 3. _number = _number + 3; // Variable "_number" is a number, with the value 6. _number = _number + 2.1234; // Variable "_number" is a float, with the value 8.1234 _number = str _number; or _number = format["%1", _number]; // _number is now a string "8.1234" _number = "twelve"; // _number is now a string "twelve" etc.Advanced (using vehicle creation): _veh = "someClassName" createVehicle [x,y,z]; // _veh is referencing to the currently created vehicle. // (typeOf _veh) returns "someClassName" _veh setPos [x,y,z]; _veh setDamage .7; _veh setdir (random 360); _veh setFuel .3; _veh = "someOtherClassName" createVehicle [x,y,z]; // _veh is referencing to the new vehicle. // (typeOf _veh) returns "someOtherClassName" For more information read the official WIKI article: https://community.bistudio.com/wiki/Variables And KillzoneKids great articles about variables: http://killzonekid.com/arma-scripting-tutorials-variables-part-1/ http://killzonekid.com/arma-scripting-tutorials-variables-part-2/ http://killzonekid.com/arma-scripting-tutorials-variables-part-3/ Greez KiloSwiss Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now