I would like help with this, the first time I skip it skips only one, next time two, and then three or more stages! Please help me find code that works.

function SkipStage(player)
	local teamnumber = tonumber(player.Team.Name)
	print(teamnumber.."current team")
	local newteam = tostring(teamnumber + 1)
	print(newteam.."future team")
	player.Team = game.Teams[newteam]
	print(player.Team.Name)
	player:LoadCharacter() -- Respawns the player without killing them
end

4 comments

0

gotta add more context, add the function SkipStage() to your code as well

0

ok

0

sorry I got the wrong code

0

fixed it