• Hey! Register here to create your account, engage with the community, and talk about what is new!

how can i make it when one team is dead the other team wins?

AntiTheWarNeko

New member
Joined
Feb 23, 2022
Messages
17
Reaction score
4
When there are no more players on the other team i want them to just teleport back to the lobby ect.
if it helps here is some code i'm using for the matchmaking system that makes the teams:
 
Last edited:

ARMcPro

Forum adept
Overlord
Joined
Oct 20, 2020
Messages
1,253
Reaction score
351
first, create a list with the team's name using Set Variable: Create List, then whenever a player gets added to that team, add their name in the list of the team. Then, On Player Take Damage Event, add a Wait(1 tick) and check for the lengths of the lists, if one is 0 that means a team is eliminated (ofc there are more compact ways but they are complicated); and then you can check which team(s) are eliminated and declare the winner.
 

ARMcPro

Forum adept
Overlord
Joined
Oct 20, 2020
Messages
1,253
Reaction score
351
1646141248556.png
put your list variable in the 1st slot, and %victim or %default (depending on how you did it) in the 2nd slot 🥶
 

EarthMonkeyii

New member
Joined
Feb 27, 2022
Messages
6
Reaction score
1
When there are no more players on the other team i want them to just teleport back to the lobby ect.
if it helps here is some code i'm using for the matchmaking system that makes the teams:
first, create a list with the team's name using Set Variable: Create List, then whenever a player gets added to that team, add their name in the list of the team. Then, On Player Take Damage Event, add a Wait(1 tick) and check for the lengths of the lists, if one is 0 that means a team is eliminated (ofc there are more compact ways but they are complicated); and then you can check which team(s) are eliminated and declare the winner.
I don't think you should use the On Player Take Damage event for this, try the On Player Death event
 
Top Bottom