Home   Help Search Login Register  

Author Topic: Chopper go to specific player  (Read 1811 times)

0 Members and 3 Guests are viewing this topic.

Offline Arctic

  • Members
  • *
  • In Utero
Chopper go to specific player
« on: 27 Sep 2002, 01:58:12 »
I am working on a script for an MP mission. An action menu appears on all of the players' screens which will bring up the choices for support.

How can I make it so that when player 3 calls for support, the chopper wont go to player 1. Is there a special command I should use? Or is there a code section I should put in the init of all of my scripts?

bn880

  • Guest
Re:Chopper go to specific player
« Reply #1 on: 07 Oct 2002, 21:02:17 »
Best think to do is to make the Action menu appear on only one users machine.

Actually, can you post the description.ext for your dialog?  I will see what I can find out then.

Offline Sui

  • Former Staff
  • ****
    • OFPEC
Re:Chopper go to specific player
« Reply #2 on: 08 Oct 2002, 02:27:43 »
Welcome to the forums, guys

When a player activates a custom action, arguements are passed to the script. The player who called the action will be:

_this select 1

So if you use the line:

_unit = _this select 1

in your script, then make your chopper go to _unit.
However, I would definately put a piece of code at the start of the script that removes everyone's action to call the chopper... otherwise you may get more than one person calling it... and as a result get conflicting movement commands ;)

bn880

  • Guest
Re:Chopper go to specific player
« Reply #3 on: 08 Oct 2002, 18:55:27 »
Welcome to the forums, guys

Actually I'm not new to the forum  :)  Been around since old OFPEC site, jsut don't post much cuz I don't see a New Msg search feature in YABB.

Offline Sui

  • Former Staff
  • ****
    • OFPEC
Re:Chopper go to specific player
« Reply #4 on: 09 Oct 2002, 01:48:17 »
All right then... welcome to the new forums ;D