there are 6 players (Team 1 = 1, 2, 3 and Team 2 = 4, 5, 6). if all players in team 1 or team 2 have left the game, the game is over. how do I do this with triggers?
I have a trigger with event "Player Left Game" and inside I have all the necessary logic to check game state and determine if there is a need to change state. It sounds like you need to mark each player as "active" or not. I actually keep an array of records and each record refers to a player. One of the record properties is "boolInactive" and I set it to True when a player leaves the game. I can then check if there are any active players still on a team and, if not, take the appropriate action.
create two playergroups and put the players in them. on the player left event remove him from his group and and check if group is empty. if its empty, end the game
Here is a way
1.Create Two player groups (Using a Varible) and Put the Players You Want in Each Player Group Representing a team
2.Create a trigger
3.Make the Event a Periodic Event Saying: Every .001 seconds of Gametime
4.Create a "If Then Else" Action
5.Create a Condition (Comparison) for the If saying: If (Player Number) Leaves the Game
6.Create a Action as the Then saying: Then Remove (Player Number) From (Player Group)
Do Step 4-6 for Each Player
7. Create Another Trigger
8.Make the Event a Periodic Event Saying: Every .001 seconds of Gametime
9.Create a "If Then Else" Action
10. Create a Condition (Comparison) for the If saying: If (Player Group)= Empty Player Group
11.Create a Action for the Then Saying: Then End Game For (Player on The Oppisite Player Group) in Victory
12.Make a Action in Step 11 for each Player
13. Do Step 9-12 Agian for the Oppisite Player Group
Hope I helped obviously there are many ways to do this, this is just the way i would do it. Happy Map Making :)
there are 6 players (Team 1 = 1, 2, 3 and Team 2 = 4, 5, 6). if all players in team 1 or team 2 have left the game, the game is over. how do I do this with triggers?
@strhsxx: Go
I have a trigger with event "Player Left Game" and inside I have all the necessary logic to check game state and determine if there is a need to change state. It sounds like you need to mark each player as "active" or not. I actually keep an array of records and each record refers to a player. One of the record properties is "boolInactive" and I set it to True when a player leaves the game. I can then check if there are any active players still on a team and, if not, take the appropriate action.
@jcraigk: Go
I dont know how to do that. is there no more simple way? it is just 3 vs 3..
The first sentence of my post will still apply no matter what your approach, so I suggest you start with that and work your way toward the solution.
@jcraigk: Go
I don't know how to end the game when all players in the team 1 or team 2 has left the game.
create two playergroups and put the players in them. on the player left event remove him from his group and and check if group is empty. if its empty, end the game
@strhsxx: Go
Use "End Game for Player" action.
Here is a way
1.Create Two player groups (Using a Varible) and Put the Players You Want in Each Player Group Representing a team
2.Create a trigger
3.Make the Event a Periodic Event Saying: Every .001 seconds of Gametime
4.Create a "If Then Else" Action
5.Create a Condition (Comparison) for the If saying: If (Player Number) Leaves the Game
6.Create a Action as the Then saying: Then Remove (Player Number) From (Player Group)
Do Step 4-6 for Each Player
7. Create Another Trigger
8.Make the Event a Periodic Event Saying: Every .001 seconds of Gametime
9.Create a "If Then Else" Action
10. Create a Condition (Comparison) for the If saying: If (Player Group)= Empty Player Group
11.Create a Action for the Then Saying: Then End Game For (Player on The Oppisite Player Group) in Victory
12.Make a Action in Step 11 for each Player
13. Do Step 9-12 Agian for the Oppisite Player Group
Hope I helped obviously there are many ways to do this, this is just the way i would do it. Happy Map Making :)