It keeps on teleporting me to the 2nd game instead of the one im supposed to be on (the 4th one)
code is hidden, thanks to the person below : )
It keeps on teleporting me to the 2nd game instead of the one im supposed to be on (the 4th one)
code is hidden, thanks to the person below : )
Its teleporting you to the second place because youre teleporting them there the second it detects the badge for it.
Instead, what you want to do is check for the last badge first, and the first badge last. This will ensure that the player gets teleported to the right place.
thanks, will try this solution : D
These should not all the if statements, if someone has multiple badges it will teleport them to the last game (likely as the teleport service is slow). Try something like this:
if BadgeService:UserHasBadgeAsync(game.Players.LocalPlayer.UserId, 2127270082) then
-- Teleport them
else if BadgeService:UserHasBadgeAsync(game.Players.LocalPlayer.UserId, 2127304271) then
-- teleport them.
If you want them to be able to teleport to all the different places, then you should set this up another way, like a GUI or something.