Home   Help Search Login Register  

Author Topic: Making it detect if all players are in a vehicle  (Read 611 times)

0 Members and 1 Guest are viewing this topic.

voodooserpent

  • Guest
Making it detect if all players are in a vehicle
« on: 06 Mar 2004, 21:25:29 »
Yah, how do I do that? There's three players max (they're called called player1, player2, player3) and the vehicle I want them in is m8jeep.

BibiPhoque

  • Guest
Re:Making it detect if all players are in a vehicle
« Reply #1 on: 06 Mar 2004, 22:40:51 »
Well, I think the command in should do it.

?(player1 in m8jeep or player2 in m8jeep or player3 in m8jeep)

Or else you could use :

?(player1 in m8jeep and player2 in m8jeep and player3 in m8jeep)

Either you want one of these players in the jeep, or all of these players (you can change this to whatever you want).

Harkonin

  • Guest
Re:Making it detect if all players are in a vehicle
« Reply #2 on: 07 Mar 2004, 01:15:55 »
Or if they're in the same group -

"_x in vehiclename" count units groupname == #ofunits

Offline macguba

  • Former Staff
  • ****
    • macguba's operation flashpoint page
Re:Making it detect if all players are in a vehicle
« Reply #3 on: 07 Mar 2004, 11:24:04 »
Or you could take a different approach and use the command vehicle

(vehicle player1 == m8jeep) and ....

syntax not guaranteed.
Plenty of reviewed ArmA missions for you to play

voodooserpent

  • Guest
Re:Making it detect if all players are in a vehicle
« Reply #4 on: 08 Mar 2004, 04:58:36 »
?(player1 in m8jeep and player2 in m8jeep and player3 in m8jeep)

Will that work if there's only two players, and hence player3 doesn't exist?

What is the ? for, does that check to see if it's true?

Offline Chris Death

  • Former Staff
  • ****
  • Finally Death's gonna get ya
    • OFPEC
Re:Making it detect if all players are in a vehicle
« Reply #5 on: 08 Mar 2004, 05:04:05 »
"vehicle _x == m8jeep" count [player1,player2,player3] == "alive _x" count [player1,player2,player3]

This as a trigger's condition should do the trick.

Now the condition checks if the vehicle of all guys from player1 to
player3 is equal to the number of alive guys from player1 to player3.


?"vehicle _x == m8jeep" count [player1,player2,player3] == "alive _x" count [player1,player2,player3]

The ? as seen above interpretes an IF statement, and is
used in scripts.

~S~ CD
Dont argue with idiots....they will bring you down to their level and beat you there with experience.

How to use Waypoint type Scripted