Apocalypse 83 47 Posted November 4, 2014 Hello everyone. There was a mission that I lost a while back, and now I can't remember the lengthy trigger code, or the thread where I found the info, so I'll try to explain as best I can. I have three groups waiting at an invisible helipad named LZ. So a1=group alpha. b1=group bravo. c1=group charlie. I use the extraction helicopter, named helo, to move to the LZ via script, with the following activation: (as well as some radio dialog, or whatever) helo doMove (getPos LZ) @ unitReady helo helo land "Get In" @ unitReady helo helo lock WP true exit This part works fine, and the helicopter stays grounded with the engine running until it is told otherwise. Then I would have a trigger that activates a script when all of the surviving units are on board. The trigger would count the number of alive of units from group alpha and group bravo that are on board the chopper, then activate my script in the activation code. I remember the trigger also used to count the pilot and gunner. It was so beautiful, and now I can't find it, or remember the code. If anyone can help me out, it would be great. Share this post Link to post Share on other sites
-rageQuit- 10 Posted November 4, 2014 Assuming this is for single-player, name the helicopter (eg. choppy).Condition for player's group being aboard: "alive _x" count (units player + [driver choppy] + [gunner choppy]) == "alive _x" count (crew choppy) If they're all going to be aboard the same helicopter, you can add the additional groups to the left side of the equation: "alive _x" count (units a1 + units b1 + units c1 + [driver choppy] + [gunner choppy]) == "alive _x" count (crew choppy) (on the presumption that you didn't leave out Group Charlie on purpose). Share this post Link to post Share on other sites
Apocalypse 83 47 Posted November 4, 2014 That's great, just the code I was looking for. I'm sure there are many other ways for extraction, but this works best for me. Thanks. Share this post Link to post Share on other sites