How to make players spawn at a specific spawn point when first joining the game?

I keep having trouble with making players spawn at a specific spawn point when first joining the game, and also respawn at the same spawn point when dying or resetting.

My game has multiple spawn points because they will be able to teleport to and from different places. When rejoining the start place, I want them to spawn next to the location where they were teleported. The problem with this is that I want players to spawn at the entrance of the start place when first joining the game or if they decide to reset. Instead, players are able to spawn in the spawn points that are next to the teleport locations when they join/reset.

I have tried using team spawns so that players will be only be limited to the entrance spawn point since it will be the only one set to neutral, but that would force players to always use the entrance spawn point. When teleporting the players from one place back to the start place, I use TeleportToSpawnByName to teleport them to the spawn next to the brick that teleports them, but it no longer works once teams are applied. Even when players are assigned to the team that a spawn point is for, they spawn back at the neutral spawn point when rejoining the start place. So using teams wouldn’t work.

How can I make players spawn at a specific spawn point when they first join a game or reset, but when rejoining after teleporting back from another place, spawn at a different spawn point?

When they first join the game you can use teams and auto-assign team. But if you want it when they respawn, you can use CFrame.

3 Likes

Sorry for bumping, but this will help anyone who need this (including me).

I saw this video at youtube: How to Make User Specific Spawn Locations - Roblox Studio Tutorial (youtube.com)

And you could actually use player.RespawnLocation = SpawnLocation

Edit: make sure the spawn Neutral property is disabled

2 Likes