Zombitch 10 Posted September 14, 2013 Hi guys, I've done a lot of googling before posting but I don't succeed to make it work. So the thing I would like to do is the following : 1) Spawn a vehicle in the air 2) Attach a parachute to the vehicle. For the first step I make it doing this (and it works) : _vehicle = "C_SUV_01_F" createVehicle (getPos player); _vehicle setPosATL (_vehicle modelToWorld[0,0,200]); But when I want to attach a parachute to that vehicle it just does nothing; I tried to attach parachute doing this : _parachute = "ParachuteMediumWest" createVehicle (getpos _vehicle); _parachute setpos (_vehicle ModelToWorld [0,0,3]); _vehicle attachTo [_parachute, [0, 0, 0]]; When I run this code it does nothing : I don't see the parachute deploying. Any idea ? I really really would like to make it by scripting and not using the "supplyDrop BIS function". Thanks. Share this post Link to post Share on other sites
Zombitch 10 Posted September 14, 2013 nobody have an idea about my problem ? Share this post Link to post Share on other sites
zdowggg 1 Posted September 14, 2013 i hope some one does soon cause that would be asome Share this post Link to post Share on other sites
kylania 568 Posted September 14, 2013 (edited) _para = createVehicle ["B_Parachute_02_F", [0,0,100], [], 0, ""]; _para setPosATL (player modelToWorld[0,0,200]); _veh = createVehicle ["C_SUV_01_F", [0,0,80], [], 0, ""]; _veh attachTo [_para,[0,0,0]]; // Land safely WaitUntil {((((position _veh) select 2) < 0.6) || (isNil "_para"))}; detach _veh; _veh SetVelocity [0,0,-5]; sleep 0.3; _veh setPos [(position _veh) select 0, (position _veh) select 1, 1]; _veh SetVelocity [0,0,0]; Edited September 24, 2013 by kylania 1 Share this post Link to post Share on other sites
marker 1 Posted September 14, 2013 Wrong parachute name.. _para = "B_Parachute_02_F"; _vehicle = "C_SUV_01_F" createVehicle (getPos player); _vehicle setPosATL (_vehicle modelToWorld[0,0,200]); _DropPos1 = getpos _vehicle; _Chute1 = createVehicle [_para, _DropPos1, [], 0, "NONE"]; _chute1 attachTo [_vehicle, [0, 0, 1]]; As usual your man Kylania sets the tone :) Share this post Link to post Share on other sites
Zombitch 10 Posted September 14, 2013 Works really great thank you ! Share this post Link to post Share on other sites
Ghosthawk 10 Posted September 24, 2013 (edited) _para = createVehicle ["B_Parachute_02_F", [0,0,100], [], 0, ""]; _para setPosATL (player modelToWorld[0,0,200]); _veh = createVehicle ["C_SUV_01_F", [0,0,80], [], 0, ""]; _veh attachTo [_para,[0,0,0]]; // Land safely WaitUntil {((((position _veh) select 2) < 0.6) || (isNil "_para"))}; detach _veh; _veh SetVelocity [0,0,-5]; sleep 0.3; _veh setPos [(position _veh) select 0, (position _veh) select 1, 0.6]; Awesome. This works! I modified it a little bit to spawn a Hunter below the supply drop Helicopter (heli). I put this _para = createVehicle ["B_Parachute_02_F", [0,0,100], [], 0, ""]; _para setPosATL (heli modelToWorld[0,0,-15]); _veh = createVehicle ["B_MRAP_01_F", [0,0,80], [], 0, ""]; _veh attachTo [_para,[0,2,-0.3]]; WaitUntil {((((position _veh) select 2) < 0.6) || (isNil "_para"))}; detach _veh; _veh SetVelocity [0,0,-5]; sleep 0.3; _veh setPos [(position _veh) select 0, (position _veh) select 1, 0.6]; into the Init of the module. Everything seems to work but a ammobox spawns on the ground and a second parachute with nothing attached in the air. Furthermore sometimes I can't start the engine of the hunter but I can get in. Can you guys help me to delete the ammobox and the parachute and explain why I sometimes can't drive the Hunter? Ok now i can't start the hunters engine every time. I tried forcing it on and it does not work: _para = createVehicle ["B_Parachute_02_F", [0,0,100], [], 0, ""]; _para setPosATL (heli modelToWorld[0,0,-15]); _veh = createVehicle ["B_MRAP_01_F", [0,0,80], [], 0, ""]; _veh attachTo [_para,[0,2,-0.4]]; WaitUntil {((((position _veh) select 2) < 0.6) || (isNil "_para"))}; detach _veh; _veh SetVelocity [0,0,-5]; sleep 0.3; _veh setPos [(position _veh) select 0, (position _veh) select 1, 0.6]; _veh engineOn true; Edited September 24, 2013 by Ghosthawk Share this post Link to post Share on other sites
anthonyfromtheuk 6 Posted September 24, 2013 _para = createVehicle ["B_Parachute_02_F", [0,0,100], [], 0, ""]; _para setPosATL (player modelToWorld[0,0,200]); _veh = createVehicle ["C_SUV_01_F", [0,0,80], [], 0, ""]; _veh attachTo [_para,[0,0,0]]; // Land safely WaitUntil {((((position _veh) select 2) < 0.6) || (isNil "_para"))}; detach _veh; _veh SetVelocity [0,0,-5]; sleep 0.3; _veh setPos [(position _veh) select 0, (position _veh) select 1, 0.6]; The SUV is undrivable once it lands??? Share this post Link to post Share on other sites
kylania 568 Posted September 24, 2013 The SUV is undrivable once it lands??? Something changed and it's keeping the velocity that prevented it from bumping and exploding. Just add this as the last line: _veh SetVelocity [0,0,0]; I fixed the post above. Share this post Link to post Share on other sites
Ghosthawk 10 Posted September 24, 2013 Something changed and it's keeping the velocity that prevented it from bumping and exploding. Just add this as the last line: _veh SetVelocity [0,0,0]; I fixed the post above. Does not work for me. Still can't start the engine. Share this post Link to post Share on other sites
kylania 568 Posted September 24, 2013 Hmm, yeah where I was testing it it was working, but I moved and it got stuck again. Setting the final height to 1m up seemed to free it in 20 different locations on Altis, so change the 0.6 in the 2nd to last line to 1. Give that a shot. :) Share this post Link to post Share on other sites
Ghosthawk 10 Posted September 24, 2013 Hmm, yeah where I was testing it it was working, but I moved and it got stuck again.Setting the final height to 1m up seemed to free it in 20 different locations on Altis, so change the 0.6 in the 2nd to last line to 1. Give that a shot. :) _para = createVehicle ["B_Parachute_02_F", [0,0,100], [], 0, ""];_para setPosATL (heli modelToWorld[0,0,-15]); _veh = createVehicle ["C_SUV_01_F", [0,0,80], [], 0, ""]; _veh attachTo [_para,[0,2,-0.4]]; WaitUntil {((((position _veh) select 2) < 1) || (isNil "_para"))}; detach _veh; _veh SetVelocity [0,0,-5]; sleep 0.3; _veh setPos [(position _veh) select 0, (position _veh) select 1, 1]; _veh SetVelocity [0,0,0]; That does not work. Or what did you mean? Share this post Link to post Share on other sites
kylania 568 Posted September 24, 2013 That's what I'm using and it's working for me. How are you running that script? Share this post Link to post Share on other sites
Ghosthawk 10 Posted September 24, 2013 That's what I'm using and it's working for me. How are you running that script? I have it in the Init of the Support Heli Module. Share this post Link to post Share on other sites
kylania 568 Posted September 24, 2013 Ooooh, yeah, no, that's meant to be used standalone from a trigger or something instead of the support module. No idea how it would work within a module. :) Share this post Link to post Share on other sites
Ghosthawk 10 Posted September 24, 2013 Ooooh, yeah, no, that's meant to be used standalone from a trigger or something instead of the support module. No idea how it would work within a module. :) Everything works fine (the parachute etc..) but i sometimes can't drive the vehicle. I think it should be the same. Share this post Link to post Share on other sites
Ghosthawk 10 Posted September 26, 2013 _para = createVehicle ["B_Parachute_02_F", [0,0,100], [], 0, ""]; _para setPosATL (player modelToWorld[0,0,200]); _veh = createVehicle ["C_SUV_01_F", [0,0,80], [], 0, ""]; _veh attachTo [_para,[0,0,0]]; // Land safely WaitUntil {((((position _veh) select 2) < 0.6) || (isNil "_para"))}; detach _veh; _veh SetVelocity [0,0,-5]; sleep 0.3; _veh setPos [(position _veh) select 0, (position _veh) select 1, 1]; _veh SetVelocity [0,0,0]; I get a local variable error in my Trigger. How can I fix that? Share this post Link to post Share on other sites
kylania 568 Posted September 26, 2013 Remove all the _ or put that in a script and call the script from the trigger instead of the code. Share this post Link to post Share on other sites
wiggum2 31 Posted June 4, 2014 Still not working with: _veh setPos [(position _veh) select 0, (position _veh) select 1, 1];_veh SetVelocity [0,0,0]; You cant start the engine of the vehicle. Any idea ? Share this post Link to post Share on other sites
f2k sel 164 Posted June 4, 2014 I just copied and pasted the above script and it works fine here. I suspect the engine is flooded make sure your not spawning it in the sea. That will result in engine failure. Share this post Link to post Share on other sites
SilentSpike 84 Posted June 4, 2014 If you spawn the object in the air you can actually then just do: [objnull, _object] call BIS_fnc_curatorobjectedited; First parameter is curator object, second is the object to be given a parachute 1 Share this post Link to post Share on other sites
katipo66 94 Posted June 4, 2014 Great, looking for something like this. Share this post Link to post Share on other sites
wiggum2 31 Posted June 4, 2014 (edited) I just copied and pasted the above script and it works fine here.I suspect the engine is flooded make sure your not spawning it in the sea. That will result in engine failure. Then we have a differend "version" of ArmA3, it does not work for me...engine does not start. :( Ok, now it works with this code: _chuteType = "B_Parachute_02_F"; //parachute for blufor, for opfor and greenfor replace the 'B' with 'O' or 'G' respectively _chute = createVehicle [_chuteType, [100, 100, 200], [], 0, 'FLY']; _chute setPos [getMarkerPos "drop_target" select 0, getMarkerPos "drop_target" select 1, 100]; _drop = createVehicle [_supply, position _chute, [], 0, 'NONE']; _drop attachTo [_chute, [0, 0, -1.3]]; waitUntil {position _drop select 2 < 0.5 || isNull _chute}; detach _drop; _drop setPos [position _drop select 0, position _drop select 1, 0]; Edited June 4, 2014 by Wiggum Share this post Link to post Share on other sites
mech79 10 Posted July 14, 2014 all these do is place a Hunter right on top of the marker i placed. It does not attatch it to the chute. The chute is flying while Hunter is placed on the ground. Share this post Link to post Share on other sites
f2k sel 164 Posted July 14, 2014 Still working here do as follows place your marker "drop_target" place this in a gamelogic init or trigger null=["B_MRAP_01_F"] execvm "drop.sqf" save as drop.sqf _supply = _this select 0; _chuteType = "B_Parachute_02_F"; _chute = createVehicle [_chuteType, [100, 100, 200], [], 0, 'FLY']; _chute setPos [getMarkerPos "drop_target" select 0, getMarkerPos "drop_target" select 1, 100]; _drop = createVehicle [_supply, position _chute, [], 0, 'NONE']; _drop attachTo [_chute, [0, 0, -1.3]]; waitUntil {position _drop select 2 < 0.5 || isNull _chute}; detach _drop; _drop setPos [position _drop select 0, position _drop select 1, 0]; Share this post Link to post Share on other sites