End Mission Triggers
|
Using Triggers throughout your mission is what makes a game more interesting and exciting. These are the functions we have covered on other pages that involve the use of triggers:
End Mission Triggers or
How to make your game end with Winners and Losers
The first thing to remember about using triggers is that each condition and action must be carefully written for each side. It may look like a lot of duplication, but if you miss one side or one action, the game will not perform as expected.
1. Decide what constitutes the end of the game for each player.
For example, if Side 1 has no units then Side 1 loses; or if Side 2 has no units then Side 1 wins (in a 2 player game); or if Side 2 has no units, and Side 3 has no units, and Side 4 has no units, then Side 1 wins (in a 4 player game). What follows is the code required to make this happen for just ONE side. It must be repeated with the appropriate changes in the side # for every side represented in the game.
2. In Settings / Triggers select Side 1 and click on New...
3. Sides = Side 1 Side 1 LOSES if he has 0 units of any type
Condition = Owns Units
Side: Make selected side True
quantity: Qualifier = Exactly; Value = 0
Unit Types: select All (meaning Any unit)
Now reads: Side 1 owns Exactly 0 Any Unit
Actions = End Mission
Result: select Lose
Now reads: End Mission: Lose
Condition = Owns Units
Side: Make sides 2, 3, 4 = True (or make Enemies = True)
quantity: Qualifier = Exactly; Value = 0
Unit Types: select All (meaning Any unit)
Now reads: Side2, Side3, Side4 owns 0 Any Unit
Actions = End Mision
Result: select Win
Now reads: End Mission: Win
NOTE: You can also use Allies and Enemies in the side selection under Conditions. Allies = the side you are focused on, that you select in the top window "Sides with triggers:" Enemies = all other sides. In the example below you will see it listed both as Allies and Enemies, and as Sides 1, or Sides 2,3,4. You only need to use one of those methods. This is just an example.
5. Repeat #3 & 4 for each side. Now one side will win when all other sides have 0 units of any type.
Allies Missions
If there are allies, the trigger condition should check for that. Both Allies and CurrentSide should be selected under Conditions in a Mission: Lose Action. This means that all allies and the current side must have lost (have 0 units) for the team to have lost. If just one player has 0 units, his team mate may still kill the other side and both the winning player and his team mate will WIN!
There may be other ways to end missions, but this is by far the most common.
|