Home   Help Search Login Register  

Author Topic: Hi all, I've got a question...  (Read 344 times)

0 Members and 1 Guest are viewing this topic.

Banshee

  • Guest
Hi all, I've got a question...
« on: 26 Apr 2004, 07:15:21 »
How would I place a helicopter on support so that the player could call for it and have it placed under his command when it arrived?

Many thanks for any help.

Offline SEAL84

  • Members
  • *
  • Always lurking
Re:Hi all, I've got a question...
« Reply #1 on: 26 Apr 2004, 15:27:25 »
I don't think there's any easy way to do that, but give this a shot:

Place your chopper somewhere on the map - home base, whatever.  Name it chopper.  It doesn't matter if it's flying or on the ground to start, and it doesn't need any waypoints.

Place a trigger somewhere on the map and make it activated by "Radio Alpha" - you'll find this in a pull-down menu.  There's a text field there as well, so type in something like "Call chopper."

Now, in the "on activation" field, type
Code: [Select]
chopper domove getpos manwhere "chopper" is the name of the helo and "man" is the player.

The thing is that this will summon the chopper to your position at the point where you called it - so if you go somewhere else, the chopper will still go to the point where you were when you called for it.

Next, put another trigger on the map - doesn't matter where - and in the condition field type
Code: [Select]
(chopper distance man) < 150and in the "on activation" type
Code: [Select]
[chopper] join player
This trigger will check to see if "chopper" is less than 150 meters away, and when it is, it will join your group.  Of course, if you want to allow for some player movement, you can increase the number.  For example, if you called it and walked 200m away, it wouldn't join you, BUT, if you set the number to something like 250, it would.


That's a really rough (and probably poor :P) way to do it and I imagine that you'll get some other suggestions that are better - you should check the Editors Depot for scripts pertaining to air support.
« Last Edit: 26 Apr 2004, 15:28:49 by SEAL84 »

Banshee

  • Guest
Re:Hi all, I've got a question...
« Reply #2 on: 26 Apr 2004, 15:49:55 »
Oh, I'm sure it'll be fine. I'm a noob at scripting, having just starting playing with inits recently, so as I was running throguh my vast store of knowledge I realized I had no clue how to do what I wanted. :)

Quick and dirty was what I was looking for. Thanks again!