CarlGustaffa 4 Posted March 3, 2008 Hi I'm modding Domination for own use, and tried replacing the "mobilerespawn" M113 medic vehicles with MASH tents. System works ok for now, but I had this weird bug where the tent was stretched several meters into the air. Parts of the "script" goes something like: <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE"> _player = _this select 0; _worldpos = _player modelToWorld [0.0,7.0,0]; _dummy = "HeliHEmpty" createVehicle _worldpos; _worldpos = getPos _dummy; _object setDir (getDir _player)-180; _object setPos getPos _dummy; sleep 2; _object setDamage 0; hint format ["%1 has been moved to a new position.", _mashno]; Also, as a side "bug" (probably only having to do with my own limited knowlegde), why does the following not work in multiplayer, where only two medics are given the action: <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE"> _mashno = if(_player==uB3) then {"MASH Bravo"} else {"MASH Charlie"}; _object = if(_player==uB3) then {uMASH1} else {uMASH2}; ...while switch do seems to work just fine: <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE"> switch (_player) do { Â Â case uB3: Â Â { Â Â Â Â _mashno = "MASH Bravo"; Â Â Â Â _object = uMASH1; Â Â }; Â Â case uC3: Â Â { Â Â Â Â _mashno = "MASH Charlie"; Â Â Â Â _object = uMASH2; Â Â }; }; That is, when I'm playing uB3 in the first example, it does work also on dedi server, but when I'm playing uC3 all I'm getting is some scalar bool error in a hint referring to _mashno and nothing is moved. Any ideas? Here is a picture of the stretchy bug: Share this post Link to post Share on other sites
fasad 1 Posted March 3, 2008 SideBug: I think the syntax in your sqs if script code is invalid. It should be: if (condition) then {_variable = "STRING"} else {_variable = "STRING"} rather than _variable = if (condition) then {"STRING"} else {"STRING"} MainBug: Try deleting the helipad before placing the tent on it. Does the bug happen every time you move it, or just the first? Share this post Link to post Share on other sites
CarlGustaffa 4 Posted March 4, 2008 Not the first time, not everytime. Actually it's pretty hard to reproduce. We've had the bug once during online session, and once (this time) during self testing. Share this post Link to post Share on other sites