rullstolskalas 0 Posted December 3, 2006 As topic title says, i was doing a mission in the editor and i was wondering how i could make soldiers eject from a helicopter that is in the air. Do i have to use a script or something? All help appreciated. Share this post Link to post Share on other sites
Lonewolf1980 0 Posted December 3, 2006 do u mean manually ?, press 0-6 to bring up the action commands then tell them to eject..otherwise i think it'll have to be a script,there's one at http://ofpec.com Share this post Link to post Share on other sites
rullstolskalas 0 Posted December 3, 2006 Yeah, i mean how do i make soldiers eject with the mission editor? I can't find any script on ofpec.com Share this post Link to post Share on other sites
Blanco 0 Posted December 3, 2006 This is the one I always use in OFP, I dunno it still works in ArmA. There might be some problems with the multiple gunners. Quote[/b] ]_helo = _this select 0 _allcrew = crew _helo ? (count crew _helo)<=2 && !isnull driver _helo && !isnull driver _helo :goto "DONE" _array = [] "if (_x != driver _helo && _x != gunner _helo) then {_array = _array + [_x]}" foreach _allcrew _allcrew = _array ? count _allcrew == 0 : goto "done" _c = 0 #eject _man = (_allcrew select _c) ?!alive _man : goto "skip" unassignvehicle _man _man action ["EJECT",_helo] ~0.5 #skip _c = _c + 1 ? _c != count _allcrew : goto "eject" #done exit Run it with [nameof the helo] exec "script.sqs" All passengers in the helo will eject except the crew Share this post Link to post Share on other sites
rullstolskalas 0 Posted December 3, 2006 i dont understand =/ i never worked with scripts before what do i have to do? Share this post Link to post Share on other sites
lethal 0 Posted December 3, 2006 create a txt file inside the mission folder, rename it to "helojump.sqs" or something and copy and paste the code above in it. next step depends on when/where/how you want to execute it: i assume you've set up a trigger that you want to make the crew jump? then you need to give your helo a specific name; for this purpose lets say you named the helo "dropship" (without the quotes of course=. now doubleclick the trigger you have set up and in the init field you type: <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">dropship exec "helojump.sqs". assuming the script above still works in arma (which it might not) it should have the desired effect Share this post Link to post Share on other sites
Blanco 0 Posted December 3, 2006 Quote[/b] ]dropship exec "helojump.sqs" [dropship] exec "helojump.sqs" Is there still no paradrop waypoint in ArmA? Share this post Link to post Share on other sites
H00t74 0 Posted December 3, 2006 Blanco, I was looking last night and no there is no Paradrop option for waypoints. I get an error w/ that script as well. Share this post Link to post Share on other sites
Blanco 0 Posted December 4, 2006 What's that error? It seems ArmA scripting is different, not only for the new commands but also for the syntax, I hope I don't have te re-learn everything Share this post Link to post Share on other sites
hoz 0 Posted December 4, 2006 I'm pretty sure that this <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">"if (_x != driver _helo && _x != gunner _helo) then {_array = _array + [_x]}" foreach _allcrew Needs to be like this <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">{if (_x != driver _helo && _x != gunner _helo) then {_array = _array + [_x]}} foreach _allcrew Edit: Tested and I was right you need to replace the "" with {} around the if statement. I made an example located at OFPEC here Its essentially the same script Blanco made with the correction to the "". Hoz Share this post Link to post Share on other sites
Hit_Sqd_Ack 0 Posted December 4, 2006 I messed around with this for a few hours over the weekend by locking the positions in the chopper so people could not bail out, upon landing the helo I tried "eject" like I would do in OFP but it's not working. I tried everything but I'm stumped. - Ack Share this post Link to post Share on other sites
hoz 0 Posted December 4, 2006 Try the example mission I made, the eject works Share this post Link to post Share on other sites
jack_oneill 0 Posted December 5, 2006 So I've got a chopper on the ground, with a squad of 8 guys in it (grp1). I have a radio trigger that does the following: chopper domove getpos guy1; [chopper] exec "heloinsert.sqs" heloinsert.sqs being the script hoz had in his example, and "guy1" being a squad leader for another squad located miles away from the chopper. The heloinsert script works, but it seems to execute while the chopper is starting its engine and taking off from the ground instead of when it reaches "guy1". How do I make the script execute when the chopper make it to the other squad's location? Share this post Link to post Share on other sites
Mr_Tea 0 Posted December 5, 2006 Work with two triggers. Havn`t tested any of "my" OFP scripts in ArmA until now, but it should work. Share this post Link to post Share on other sites
jack_oneill 0 Posted December 5, 2006 ah yes Hah, it didn't even occur to me to use 2 triggers, one to move the chopper and one to execute the script. It would be nice if I could do them both with one trigger, but that works. thanks. Now my next problem is after I hit the trigger that executes the eject script, I want the chopper to fly back to the landing pad and then land. I suppose I can do that with waypoints though, since the landing pad will always be in the same position. Share this post Link to post Share on other sites