Home   Help Search Login Register  

Author Topic: doStop command, undoing  (Read 596 times)

0 Members and 1 Guest are viewing this topic.

kingneb

  • Guest
doStop command, undoing
« on: 20 Apr 2003, 21:24:49 »


- Here is my current situation, I have 2 triggers.  When the mission begins, A tank crew has the DoStop command to hold them in place, in a line. I set up another trigger synchronized with a GET IN waypoint to tell the crew to get into the tank if it spots an enemy.  However, the DoStop command prevents this from happening.  What command do you use to cancel the state of the crew being stopped.  The DoMove or CommandMove commands don't work because they just tell the crew to go to a position (cordinates), not to follow a waypoint. How do I get around this?
 
                                                                      I thank anyone who can assist.
« Last Edit: 20 Apr 2003, 22:37:33 by kingneb »

jojojoni

  • Guest
Re:unit arrays
« Reply #1 on: 20 Apr 2003, 21:50:29 »
An example:

not alive [unitname1,unitname2,...]

I have never used arrays with ALIVE command, but as far as i know it should work. If array donÂ't work with ALIVE command you could also use FOREACH function.

Bremmer

  • Guest
Re:unit arrays
« Reply #2 on: 20 Apr 2003, 21:55:13 »
Hello Kingneb

I think you need to use the count command, like this:

"alive _x" count unitarray == 0

Cheers

UberKreb

  • Guest
Re:doStop command, undoing
« Reply #3 on: 20 Apr 2003, 23:42:13 »
I had a problem with this sort of thing before.  Try using the stop command: unit stop true to get the units to stop and use unit stop false to get them moving again.  The only drawback to this method is that the stop command disables most of the AI.  The result is a stopped unit that can resume movement again, but won't fire at enemies until it moves.  I'm pretty sure it's impossible to get units using dostop and commandstop to move again.  Hope this helps.

UberKreb
« Last Edit: 20 Apr 2003, 23:43:36 by UberKreb »

Offline Sui

  • Former Staff
  • ****
    • OFPEC
Re:doStop command, undoing
« Reply #4 on: 21 Apr 2003, 02:34:20 »
Heya, Kingneb ;)

The opposite of the dostop command is dofollow. So you're looking at something like this:

unit dofollow (leader unit)

Which will make unit follow it's waypoints again. If you have a group of guys, use:

"_x dofollow (leader _x)" foreach (units group)

I tend to use the dostop/dofollow combination, as UberKreb points out, stop true/false tends to have adverse effects on the unit's AI ;)