- Joined
- Jan 23, 2009
- Messages
- 74
hey guys its me again
the other day my friend gave me a "skeleton" of a map which hes to lazy to finish off, so while im doing the terrain (among some other tweaks) i was looking over the triggers.
The map itself was a brilliant concept but it was incomplete and i want to finish it, but to do that i need to find out a way to keep track of a winner of each round.
as they are some of the triggers look a bit "messy", to me at least i was wondering if i could get help cleaning them up. and then mabey if im lucky some help tips on keeping track of the players who win each round.
the other day my friend gave me a "skeleton" of a map which hes to lazy to finish off, so while im doing the terrain (among some other tweaks) i was looking over the triggers.
The map itself was a brilliant concept but it was incomplete and i want to finish it, but to do that i need to find out a way to keep track of a winner of each round.
as they are some of the triggers look a bit "messy", to me at least i was wondering if i could get help cleaning them up. and then mabey if im lucky some help tips on keeping track of the players who win each round.
-
Initialize
-
Events
-
Time - Elapsed game time is 1.00 seconds
-
-
Conditions
-
Actions
-
Set Game = True
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player 1 (Red) slot status) Equal to Is playing
-
-
Then - Actions
-
Set Player_Count = (Player_Count + 1)
-
Unit - Create 1 Catalog[(Random integer number between 1 and 67)] for Player 1 (Red) at (Random point in Arena <gen>) facing Default building facing degrees
-
Set Player_Unit[1] = (Last created unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player 2 (Blue) slot status) Equal to Is playing
-
-
Then - Actions
-
Set Player_Count = (Player_Count + 1)
-
Unit - Create 1 Catalog[(Random integer number between 1 and 67)] for Player 2 (Blue) at (Random point in Arena <gen>) facing Default building facing degrees
-
Set Player_Unit[2] = (Last created unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player 3 (Teal) slot status) Equal to Is playing
-
-
Then - Actions
-
Set Player_Count = (Player_Count + 1)
-
Unit - Create 1 Catalog[(Random integer number between 1 and 67)] for Player 3 (Teal) at (Random point in Arena <gen>) facing Default building facing degrees
-
Set Player_Unit[3] = (Last created unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player 4 (Purple) slot status) Equal to Is playing
-
-
Then - Actions
-
Set Player_Count = (Player_Count + 1)
-
Unit - Create 1 Catalog[(Random integer number between 1 and 67)] for Player 4 (Purple) at (Random point in Arena <gen>) facing Default building facing degrees
-
Set Player_Unit[4] = (Last created unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player 5 (Yellow) slot status) Equal to Is playing
-
-
Then - Actions
-
Set Player_Count = (Player_Count + 1)
-
Unit - Create 1 Catalog[(Random integer number between 1 and 67)] for Player 5 (Yellow) at (Random point in Arena <gen>) facing Default building facing degrees
-
Set Player_Unit[5] = (Last created unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player 6 (Orange) slot status) Equal to Is playing
-
-
Then - Actions
-
Set Player_Count = (Player_Count + 1)
-
Unit - Create 1 Catalog[(Random integer number between 1 and 67)] for Player 6 (Orange) at (Random point in Arena <gen>) facing Default building facing degrees
-
Set Player_Unit[6] = (Last created unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player 7 (Green) slot status) Equal to Is playing
-
-
Then - Actions
-
Set Player_Count = (Player_Count + 1)
-
Unit - Create 1 Catalog[(Random integer number between 1 and 67)] for Player 7 (Green) at (Random point in Arena <gen>) facing Default building facing degrees
-
Set Player_Unit[7] = (Last created unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player 8 (Pink) slot status) Equal to Is playing
-
-
Then - Actions
-
Set Player_Count = (Player_Count + 1)
-
Unit - Create 1 Catalog[(Random integer number between 1 and 67)] for Player 8 (Pink) at (Random point in Arena <gen>) facing Default building facing degrees
-
Set Player_Unit[8] = (Last created unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player 9 (Gray) slot status) Equal to Is playing
-
-
Then - Actions
-
Set Player_Count = (Player_Count + 1)
-
Unit - Create 1 Catalog[(Random integer number between 1 and 67)] for Player 9 (Gray) at (Random point in Arena <gen>) facing Default building facing degrees
-
Set Player_Unit[9] = (Last created unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player 10 (Light Blue) slot status) Equal to Is playing
-
-
Then - Actions
-
Set Player_Count = (Player_Count + 1)
-
Unit - Create 1 Catalog[(Random integer number between 1 and 67)] for Player 10 (Light Blue) at (Random point in Arena <gen>) facing Default building facing degrees
-
Set Player_Unit[10] = (Last created unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player 11 (Dark Green) slot status) Equal to Is playing
-
-
Then - Actions
-
Set Player_Count = (Player_Count + 1)
-
Unit - Create 1 Catalog[(Random integer number between 1 and 67)] for Player 11 (Dark Green) at (Random point in Arena <gen>) facing Default building facing degrees
-
Set Player_Unit[11] = (Last created unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player 12 (Brown) slot status) Equal to Is playing
-
-
Then - Actions
-
Set Player_Count = (Player_Count + 1)
-
Unit - Create 1 Catalog[(Random integer number between 1 and 67)] for Player 12 (Brown) at (Random point in Arena <gen>) facing Default building facing degrees
-
Set Player_Unit[12] = (Last created unit)
-
-
Else - Actions
-
-
Wait 10.00 seconds
-
Trigger - Run Unit Change <gen> (checking conditions)
-
-
-
Unit Change
-
Events
-
Conditions
-
Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player_Unit[1] is alive) Equal to True
-
-
Then - Actions
-
Unit - Replace Player_Unit[1] with a Catalog[(Random integer number between 1 and 67)] using The old unit's relative life and mana
-
Set Player_Unit[1] = (Last replaced unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player_Unit[2] is alive) Equal to True
-
-
Then - Actions
-
Unit - Replace Player_Unit[2] with a Catalog[(Random integer number between 1 and 67)] using The old unit's relative life and mana
-
Set Player_Unit[2] = (Last replaced unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player_Unit[3] is alive) Equal to True
-
-
Then - Actions
-
Unit - Replace Player_Unit[3] with a Catalog[(Random integer number between 1 and 67)] using The old unit's relative life and mana
-
Set Player_Unit[3] = (Last replaced unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player_Unit[4] is alive) Equal to True
-
-
Then - Actions
-
Unit - Replace Player_Unit[4] with a Catalog[(Random integer number between 1 and 67)] using The old unit's relative life and mana
-
Set Player_Unit[4] = (Last replaced unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player_Unit[5] is alive) Equal to True
-
-
Then - Actions
-
Unit - Replace Player_Unit[5] with a Catalog[(Random integer number between 1 and 67)] using The old unit's relative life and mana
-
Set Player_Unit[5] = (Last replaced unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player_Unit[6] is alive) Equal to True
-
-
Then - Actions
-
Unit - Replace Player_Unit[6] with a Catalog[(Random integer number between 1 and 67)] using The old unit's relative life and mana
-
Set Player_Unit[6] = (Last replaced unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player_Unit[7] is alive) Equal to True
-
-
Then - Actions
-
Unit - Replace Player_Unit[7] with a Catalog[(Random integer number between 1 and 67)] using The old unit's relative life and mana
-
Set Player_Unit[7] = (Last replaced unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player_Unit[8] is alive) Equal to True
-
-
Then - Actions
-
Unit - Replace Player_Unit[8] with a Catalog[(Random integer number between 1 and 67)] using The old unit's relative life and mana
-
Set Player_Unit[8] = (Last replaced unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player_Unit[9] is alive) Equal to True
-
-
Then - Actions
-
Unit - Replace Player_Unit[9] with a Catalog[(Random integer number between 1 and 67)] using The old unit's relative life and mana
-
Set Player_Unit[9] = (Last replaced unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player_Unit[10] is alive) Equal to True
-
-
Then - Actions
-
Unit - Replace Player_Unit[10] with a Catalog[(Random integer number between 1 and 67)] using The old unit's relative life and mana
-
Set Player_Unit[10] = (Last replaced unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player_Unit[11] is alive) Equal to True
-
-
Then - Actions
-
Unit - Replace Player_Unit[11] with a Catalog[(Random integer number between 1 and 67)] using The old unit's relative life and mana
-
Set Player_Unit[11] = (Last replaced unit)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Player_Unit[12] is alive) Equal to True
-
-
Then - Actions
-
Unit - Replace Player_Unit[12] with a Catalog[(Random integer number between 1 and 67)] using The old unit's relative life and mana
-
Set Player_Unit[12] = (Last replaced unit)
-
-
Else - Actions
-
-
Wait 10.00 seconds
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
Game Equal to True
-
-
Then - Actions
-
Trigger - Run (This trigger) (checking conditions)
-
-
Else - Actions
-
-
-
-
Next round
-
Events
-
Unit - A unit Dies
-
-
Conditions
-
Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
Or - Any (Conditions) are true
-
Conditions
-
(Dying unit) Equal to Player_Unit[1]
-
(Dying unit) Equal to Player_Unit[2]
-
(Dying unit) Equal to Player_Unit[3]
-
(Dying unit) Equal to Player_Unit[4]
-
(Dying unit) Equal to Player_Unit[5]
-
(Dying unit) Equal to Player_Unit[6]
-
(Dying unit) Equal to Player_Unit[7]
-
(Dying unit) Equal to Player_Unit[8]
-
(Dying unit) Equal to Player_Unit[9]
-
(Dying unit) Equal to Player_Unit[10]
-
(Dying unit) Equal to Player_Unit[11]
-
(Dying unit) Equal to Player_Unit[12]
-
-
-
-
Then - Actions
-
Set Player_Count = (Player_Count - 1)
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
Player_Count Equal to 1
-
-
Then - Actions
-
Set Game = False
-
Game - Display to (All players) for 11.00 seconds the text: Restarting game...
-
Wait 5.00 seconds
-
Unit Group - Pick every unit in (Units in (Playable map area)) and do (Actions)
-
Loop - Actions
-
Unit - Remove (Picked unit) from the game
-
-
-
Wait 6.00 seconds
-
Trigger - Run Initialize <gen> (checking conditions)
-
-
Else - Actions
-
-
-