You haven't actually described what is it you want it to do, but I'll assume that there's a single spawn point for every player in the game, and you want to move the player to their spawn.
"workspace.Spawns[i]" simply chooses which spawn point to use. You probably store somewhere the information about which spawn point belongs to which player, so you need to use that instead. I can't tell what exactly you need to do since I don't know anything about how you store that information.
Maybe "workspace.Spawns" is a folder that uses player Ids as keys. In that case "workspace.Spawns[player.UserId]" should work.
Also note that "i" in "TPevent.OnClientEvent:Connect" is not the same variable as the "i" in "for i,v in pairs..." |