Jump to content
Sign in to follow this  
HateDread

Helicopter Ocean Insertion

Recommended Posts

I was wondering how I can get a helicopter to fly from far off of the coast, up to a section of ocean, above which it hovers at low altitude (5), gets all the squad to disembark, then turns and flys away again.

I don't know how to set this up. I need the helicopter to hold and wait untill everyone is out, and in the water, and stay below the maximum height one can drop into water from (what is that, anyway?).

Thanks in advance,

- HateDread.

Share this post


Link to post
Share on other sites

Maybe you can play with ForceSpeed and LimitSpeed as well. I did not try it, but I guess that even if your chopper as a waypoint, you could force her an altitude and a very low speed for your drop ;)

Share this post


Link to post
Share on other sites

With a 'Transport Unload' waypoint, the chopper wants to let me out on the coast, not the water. I need to force it to stay above the water for a set time, then force it to forcefully eject the players, or wait untill all players are out before flying away.

How do I do all of this?

---------- Post added at 03:18 PM ---------- Previous post was at 02:54 PM ----------

For some reason, with the waypoint where I'd like the helicopter to hover, with only 'H1 flyinheight 6' in the 'On Act', with H1 being the name of the helicopter, it just sits there and doesn't proceed to its next move waypoint.

How do I force the players out at this point, and/or trigger the next waypoint based on all players being out of the heli?

Share this post


Link to post
Share on other sites

According to the wiki, if you use the land command you can add another instruction:

"GET OUT" (hovering low,for another unit to get out)

so the code would look like:

land "GET OUT";

Try it and let us know. Very curious.

Best, Splicer.

Share this post


Link to post
Share on other sites

In the move waypoint's 'On Act',

H1 land "GET OUT"; H1 flyinheight 6;
doesn't work. The helicopter hovers far too high above the waypoint (something like >25m).

Tried adding an invisible helipad, as the wiki says "Helos will land at the nearest "H" or "Invisible H", if there is one around (within 500m in ArmA). ". This doesn't work, even with the flyinheight command removed from the 'On Act' field. The heli still hovers far too high, and doesn't proceed to next waypoint.

Thoughts?

Share this post


Link to post
Share on other sites

Ahh... Got an idea.

Get the chopper low at the desired spot and then reposition (using the setPos command) you and the units in the team a bit out of the chopper.

This would place everybody in the air and then everybody should free fall to the water.

This may not look "nice" but would accomplish what you want.

Try it and let us know what happened.

Best, Splicer.

Share this post


Link to post
Share on other sites

In the 'Move' waypoint, I have this in 'On Act':

H1 flyinheight 5; sleep 4; P1 setPos [(getpos H1 select 0),(getpos H1 select 1),((getpos H1 select 2) - 1)]

This works, apart from the 'sleep' command not working - I still get spawned out of the heli straight away. Also, how do I execute "P1 setPos [(getpos H1 select 0),(getpos H1 select 1),((getpos H1 select 2) - 1)" for a group?

And from what I can see, the helicopter just waits forever after these commands are run, and refuses to proceed to the next waypoint.

Share this post


Link to post
Share on other sites

I just found this thread on halo jumping: see http://forums.bistudio.com/showthread.php?t=76201

Here the unassignVehicle command was applied to a group.

Give it a shot and let us know if you got it to work.

I'd like to figure this out too and perhaps even use it in a mission I'm putting together. :D

Best, Splicer.

Share this post


Link to post
Share on other sites

Gotten the script from that thread, and added a sleep command which doesn't appear to be working...

?!(isServer) : exit

_grp = _this select 0

_flz = _this select 1

_jmp = units _grp

_i = 0

_j = count _jmp

~(random 3)

#start

sleep 10;

unassignvehicle (_jmp select _i)

(_jmp select _i) action ["EJECT",_flz]

_i=_i+1

~.4

?_j>_i:goto "start"

exit;

Still launches players before waiting to stop.

Afterwards, it does not proceed to next move waypoint.

Cheers.

Edited by HateDread

Share this post


Link to post
Share on other sites

Hi HateDread,

I'm at a loss here too.

Confirmed: Having a chopper fly at low altitudes over the sea using the flyinheight command simply doesn't work. :(

If this is truly a limitation of the game then there's no point in trying any further.

Does anybody know if you can get a chopper fly at very low altitudes at sea?

Thanks. Splicer.

---------- Post added at 11:53 AM ---------- Previous post was at 10:44 AM ----------

Hi HateDread,

I made some progress! :D

1) Place an invisible object (e.g., H (Invisible)) at the shore, give it a name (e.g., LZ1).

2) Create a chopper, give it a nam (e.g., Chopper), and place it a few meters above LZ1 (6 meters in this case) by entering this in the "Initialization:" field:

this setpos [getpos LZ1 select 0, getpos LZ1 select 1, 6];

3) Place your unit (Player) or another playable unit (e.g., Grunt1) in the Chopper by entering this in the "Initialization:" field:

this moveInCargo Chopper;

4) Place another invisible object (e.g., H (Invisible)) at sea, give it a name (e.g., LZ2) and enter this in the "Initialization:" field:

this setPosASL [getposASL this select 0, getposASL this select 1, 0];

5) Place a waypoint near LZ2, "Select type:" set to "MOVE", "Speed" set to "Limited", and enter the following code in the "Initialization:" field:

Chopper setPosASL [ getPosASL LZ2 select 0, getPosASL LZ2 select 1 , (getPosASL LZ2 select 2) + 10]; Grunt1 action ["getout", Chopper];

You will see that the copper gets close to LZ2, then spawns above sea level and the unit (in this case Grunt1) is ejected from the chopper and survives hitting the water. :yay:

Now what it is needed is to figure out 2 things:

A) How to make the chopper get down above sea level not spawned but animated,

B) How to make the unit in the chopper wait until the chopper reaches the desired altitude above sea level to eject/jump.

Anybody? Suggestions/Ideas?

Thanks. Splicer.

Share this post


Link to post
Share on other sites

Im not sure about A since you said flyInHeight doesnt work but for B you could just use:

waitUntil {(getPos HELI select 2) <= 5};
//BAIL OUT CODE

Share this post


Link to post
Share on other sites

Hurray! I Got IT! 2 Waypoints are needed! :yay:

1) Set the first waypoint and enter: Chopper flyInHeight 6;

2) Set a second waypoint where you want to drop off the units and use the code: Grunt1 action ["getout", Chopper];

The animation is very cool and it worked for me like a charm! :D

Try it out and let me know.

Best, Splicer.

---------- Post added at 01:46 PM ---------- Previous post was at 01:43 PM ----------

@ mikeyb118,

Thanks!!! I'll try it out and see how it works.

Hopefully it'll be better than the obscure way I got it to work. :D

Best, Splicer.

Edited by Splicer

Share this post


Link to post
Share on other sites

I'm getting there...

"P1 action ["getout", H1];" in the second waypoint as you said, but with a timeout on it (added '10' to every 'timeout' box in the waypoint's menu). The player does not eject untill the heli has stopped moving.

Two problems;

1. The heli will not continue with its waypoints. Even "H1 domove/move/moveto getpos Pad1" doesn't work, with Pad1 being an invisible helipad far in the distance. Doesn't work for markers either, and it doesn't continue to next move waypoint.

2. Setting a trigger that ensure all alive players are out before proceeding. How do I do this?

Cheers.

Share this post


Link to post
Share on other sites

Have a look at my example mission. The helicopter flies to the drop zone without using setpos. The descent is moderated by a script and the helicopter is kept on course by a domove order to an invisible helipad. An eject script is activated by a trigger placed just before the stopping point.

Then I remove the invisible helipad and restrictions set on the helicopter's flight. Finally domove is used to fly the helicopter to an exit point where you can make a trigger to delete it from the mission.

Share this post


Link to post
Share on other sites
I'm getting there...

"P1 action ["getout", H1];" in the second waypoint as you said, but with a timeout on it (added '10' to every 'timeout' box in the waypoint's menu). The player does not eject untill the heli has stopped moving.

Two problems;

1. The heli will not continue with its waypoints. Even "H1 domove/move/moveto getpos Pad1" doesn't work, with Pad1 being an invisible helipad far in the distance. Doesn't work for markers either, and it doesn't continue to next move waypoint.

2. Setting a trigger that ensure all alive players are out before proceeding. How do I do this?

Cheers.

I don't know why it isn't working for you. In my case the chopper flies at 6 meters above sea level, barely stops when everybody is ejected, and then the chopper goes on to the next waypoint.

In other words, the chopper is still moving (not too much but some) when you get ejected.

I could send you offline the mission.sqm file for you to check it out.

And, although I haven't tried this yet, looks like mikeyb118's approach works and with more actions associated to the helo deploy. :D

- Splicer.

Share this post


Link to post
Share on other sites

Splicer, I'd still like to see your example, so I can see what I'm doing wrong in comparison - my helicopter just won't budge :/

---------- Post added at 01:24 PM ---------- Previous post was at 11:25 AM ----------

Mikey, I can't open your mission - says I need vops_c_guns, which I do not.

Any help with my earlier questions?

Share this post


Link to post
Share on other sites
Have a look at my example mission.

Hi mikeyb118,

I tried to open the mission file (and placed the 2 scripts in the same directory) and I get this error message:

You cannot play/edit this mission; it is dependent on downloadable content that has been deleted.vops_c_guns

Could you tell me how to access/open the mission?

Thanks. Splicer.

Share this post


Link to post
Share on other sites

COOL!!! Thanks Mikey!

I'll try it out and see how it works. :)

Best, Splicer.

Share this post


Link to post
Share on other sites

Tested, works well. Now I have to see what you did.

Splicer, I improved your version by adding a delay to the waypoint where the troops are ejected. A delay of 10 works very well - it allows the heli to stop and level out before forcing the troops out.

Share this post


Link to post
Share on other sites

I just tried it out and IT IS AWESOME!!!!

WOW!!! Brilliant!!!!!!!!!! :notworthy:

One question: If the invisible H were placed on land or a carrier, would the chopper land or just hover?

I want it to land, but in the humble, notworthy example I created, the chopper does not land unless I switch to one of the playable units in my group. And then I (player) says "get into that chopper".

Also, would you happen to know how to turn off the engine of a chopper? I've tried with the command "Chopper engineOn false" (without the quotation marks) and didn't work.

Still, I am really impressed with this simulation/action you put together!

Would you mind if I used it for my notworthy mission? Credit will be certainly given to you in the acknowledgments. :D

My best, a very very very impressed Splicer.

---------- Post added at 10:40 PM ---------- Previous post was at 10:37 PM ----------

Tested, works well. Now I have to see what you did.

Splicer, I improved your version by adding a delay to the waypoint where the troops are ejected. A delay of 10 works very well - it allows the heli to stop and level out before forcing the troops out.

Excellent HateDread! :yay:

Could you give me the exact command instruction (I've never used a wait command before) and where exactly you entered the code? :D

Splicer.

Edited by Splicer

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×