F
fratleyslaye
Guest
<3 Sooda =! ty
Untitled Trigger 001
Events
Map initialization
Conditions
Actions
Set Random_number = (Random integer number between 1 and 12)
If ((Player(Random_number)) Not equal to (Random player from Wolves)) then do (Player Group - Add (Player(Random_number)) to Wolves) else do (Do nothing)
Set wolves_count = (Number of players in Wolves)
If (wolves_count Not equal to 4) then do (Trigger - Run (This trigger) (ignoring conditions)) else do (Do nothing)
wolves spawn
Events
Time - Elapsed game time is 5.00 seconds
Conditions
Actions
[B]For each (Integer A) from 1 to 12, do (Player Group - Add (Player((Integer A))) to Sheeps)
Player Group - Pick every player in Wolves and do (Player Group - Remove (Picked player) from Sheeps)[/B]
Player Group - Pick every player in Wolves and do (Unit - Create 1 Farm for (Picked player) at (Center of (Playable map area)) facing Default building facing degrees)
Player Group - Pick every player in [B]Sheeps[/B] and do (Unit - Create 1 Farm for (Picked player) at [B](Center of Region 000 <gen>)[/B] facing Default building facing degrees)
(Random player from Wolves) should compare that player with all players in that player group, I' m sure of it. Random in this case means:> If ((Player(Random_number)) Not equal to (Random player from Wolves))
You would have to be very lucky for this condition to work.
Because even if the player is already in "Wolves", some random player of that group most likely isn't the selected one...
Untitled Trigger 001
Events
Map initialization
Conditions
Actions
Set Random_number = (Random integer number between 1 and 12)
If ((Player(Random_number)) Not equal to (Random player from Wolves)) then do (Player Group - Add (Player(Random_number)) to Wolves) else do (Do nothing)
Set wolves_count = (Number of players in Wolves)
If (wolves_count Not equal to 4) then do (Trigger - Run (This trigger) (ignoring conditions)) else do (Do nothing)
Untitled Trigger 002
Events
Time - Elapsed game time is 20.00 seconds
Conditions
Actions
For each (Integer A) from 1 to 12, do (Player Group - Add (Player((Integer A))) to Sheeps)
Player Group - Pick every player in (All players) and do (Player Group - Remove (Picked player) from Sheeps)
Player Group - Pick every player in Wolves and do (Unit - Create 1 The wolf for (Picked player) at (Center of (Playable map area)) facing Default building facing degrees)
Player Group - Pick every player in Sheeps and do (Unit - Create 1 Teh Sheep for (Picked player) at (Center of (Playable map area)) facing Default building facing degrees)
fratleyslaye said:Code:Untitled Trigger 001 Events Map initialization Conditions Actions Set Random_number = (Random integer number between 1 and 12) If ((Player(Random_number)) Not equal to (Random player from Wolves)) then do (Player Group - Add (Player(Random_number)) to Wolves) else do (Do nothing) Set wolves_count = (Number of players in Wolves) If (wolves_count Not equal to 4) then do (Trigger - Run (This trigger) (ignoring conditions)) else do (Do nothing)
NiKaNoRoU_Dr said:Malto's trigger owns!
fratleyslaye said:too early but I will try it out in the morning, thanks everyone. . . and shouldnt he be reported for spamming every topic??
Preloading
Events
Map initialization
Conditions
Actions
Player Group - Pick every player in (All players matching (((Matching player) slot status) Equal to Is playing)) and do (Player Group - Add (Picked player) to Playing_players)
Set Wolves_needed = ((Real((Number of players in Playing_players))) / 2.00)
[B]If ((Number of players in (All players controlled by a User player)) Equal to 1) then do (Trigger - Turn on Single player mode <gen>) else do (Trigger - Run Random wolve player group <gen> (ignoring conditions))
If ((Number of players in (All players controlled by a User player)) Equal to 1) then do (Trigger - Turn off wolves spawn <gen>) else do (Do nothing)[/B]
Trigger - Run Random wolve player group <gen> (ignoring conditions)
If (Wolves_needed Less than 1.00) then do (Set Wolves_needed = 1.00) else do (Do nothing)
Preloading
Events
Map initialization
Conditions
Actions
Player Group - Pick every player in (All players matching (((Matching player) slot status) Equal to Is playing)) and do (Player Group - Add (Picked player) to Playing_players)
Set Wolves_needed = ((Real((Number of players in Playing_players))) / 2.00)
If (Wolves_needed Less than 1.00) then do (Set Wolves_needed = 1.00) else do (Do nothing)
If ((Number of players in (All players controlled by a User player)) Equal to 1) then do (Trigger - Turn on Single Player Mode <gen>) else do (Trigger - Run Random wolf player group <gen> (ignoring conditions))
If ((Number of players in (All players controlled by a User player)) Equal to 1) then do (Trigger - Turn off Wolves Spawn <gen>) else do (Do nothing)
Trigger - Run Random wolf player group <gen> (ignoring conditions)
Random wolf player group
Events
Conditions
Actions
Set Random_number = (Random integer number between 1 and 12)
If ((((Player(Random_number)) is in Wolves) Not equal to True) and (((Player(Random_number)) slot status) Equal to Is playing)) then do (Player Group - Add (Player(Random_number)) to Wolves) else do (Do nothing)
If ((Integer(Wolves_needed)) Equal to (Number of players in Wolves)) then do (Do nothing) else do (Trigger - Run (This trigger) (ignoring conditions))
Wolves Spawn
Events
Time - Elapsed game time is 20.00 seconds
Conditions
Actions
For each (Integer A) from 1 to 12, do (Player Group - Add (Player((Integer A))) to Sheeps)
Player Group - Pick every player in Wolves and do (Player Group - Remove (Picked player) from Sheeps)
Player Group - Make Wolves treat Wolves as an Ally with shared vision
Player Group - Make Sheeps treat Sheeps as an Ally with shared vision
Player Group - Pick every player in Wolves and do (Unit - Create 1 The wolf for (Picked player) at (Center of (Playable map area)) facing Default building facing degrees)
Player Group - Pick every player in Sheeps and do (Unit - Create 1 Teh Sheep for (Picked player) at (Center of (Playable map area)) facing Default building facing degrees)
Single Player Mode
Events
Time - Elapsed game time is 5.00 seconds
Conditions
Actions
Player Group - Pick every player in (All players controlled by a User player) and do (Player Group - Add (Picked player) to Wolves)
Player Group - Make Wolves treat Wolves as an Ally with shared vision
Player Group - Pick every player in Wolves and do (Unit - Create 1 The wolf for (Picked player) at (Center of (Playable map area)) facing Default building facing degrees)
Set single_player = (Owner of (Last created unit))
If ((Player number of single_player) Less than or equal to 3) then do (For each (Integer A) from 1 to 2, do (Unit - Create 1 Teh Sheep for (Player((Player number of single_player))) at (Center of (Playable map area)) facing Default building facing degrees)) else do (Do nothing)
If ((Player number of single_player) Greater than or equal to 9) then do (For each (Integer A) from 1 to 2, do (Unit - Create 1 The wolf for (Player((Player number of single_player))) at (Center of (Playable map area)) facing Default building facing degrees)) else do (Do nothing)
Player Group - Pick every player in (All players controlled by a Computer player) and do (Player Group - Add (Picked player) to Sheeps)
Player Group - Make Sheeps treat Sheeps as an Ally with shared vision
Game - Display to (All players) the text: (Single player modes is enabled for + (Name of single_player))
If ((Number of players in (All players controlled by a User player)) Equal to 1) then do (Trigger - Turn on Single Player Mode <gen>) else do (Trigger - Run Random wolf player group <gen> (ignoring conditions))
If ((Number of players in (All players controlled by a User player)) Equal to 1) then do (Trigger - Turn off Wolves Spawn <gen>) else do (Do nothing)
[B]Trigger - Run Random wolf player group <gen> (ignoring conditions)[/B]
If ((Player number of Single_player) Less than or equal to 3) then do (For each (Integer A) from 1 to 2, do (Unit - Create 1 Farm for (Player(((Player number of Single_player) [B]+ (Integer A)[/B]))) at (Center of Region 000 <gen>) facing Default building facing degrees)) else do (Do nothing)
If ((Player number of Single_player) Greater than or equal to 9) then do (For each (Integer A) from 1 to 2, do (Unit - Create 1 Farm for (Player(((Player number of Single_player) [B]- (Integer A)[/B]))) at (Center of Region 000 <gen>) facing Default building facing degrees)) else do (Do nothing)