Victory/Defeat contidions

The-Maimer

New Member
Reaction score
0
I have 2 teams of players, both teams have a single none player building that they have to protect, if it is destroyed that team is supposed to lose. But I can't figure out how to make it work. But when I kill the building it causes a victory for both teams, the two teams of players are enemies, they aren't supposed to have a shared victory with each other.
 

polo2005

Wana start playing LoL? http://tinyurl.com/369as27
Reaction score
97
make a playergroup with array for each team and then make a trigger like:


Code:
Event:
Map init....
Conditions:
none
Actions:
add <players that is in team 1> to playergroup[0]
add <players that is in team 2> to playergroup[1]

Code:
Event:
<your unit nr1> dies
Conditions:
none
Actions:
pick every unit in playergroup[0] and do
     defeat picked player
pick every unit in playergroup[1] and do
     victory picked player
[/CODE]

or somwthing like that
 

Admit

New Member
Reaction score
25
press "Ctrl + b" in trigger edit. Then press the green "<X" buttom. Set variable type to "PlayerGroup".

Edit* If you don't want to use PlayerGroups (Variable), you could also do like this:
Trigger:
  • Victory
    • Events
      • Unit - A unit Dies
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Triggering unit) Equal to &quot;Your Unit1&quot;
        • Then - Actions
          • Player Group - Pick every player in (All allies of Player 1 (Red)) and do (Game - Victory (Picked player) (Show dialogs, Show scores))
          • Player Group - Pick every player in (All allies of Player 5 (Yellow)) and do (Game - Defeat (Picked player) with the message: Defeat!)
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Triggering unit) Equal to Your unit2
            • Then - Actions
              • Player Group - Pick every player in (All allies of Player 5 (Yellow)) and do (Game - Victory (Picked player) (Show dialogs, Show scores))
              • Player Group - Pick every player in (All allies of Player 1 (Red)) and do (Game - Defeat (Picked player) with the message: Defeat!)
            • Else - Actions
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top