Character invisible after moving it to a spawn location

Hello!
So my script looks like this (not exactly, just an example)

player.CharacterAdded:Connect(function(char)
HumanoidRootPart = char:FindFirstChild("HumanoidRootPart") or char:WaitForChild("HumanoidRootPart")
--Some checks
HumanoidRootPart.Position = Teamspawn.Position
end)

After playing/testing, my character turns invisible after “teleporting” to this location.
Is there any way to fix this?

I tried adding a wait(10) after the CharacterAdded event, seems to fix it most of the time but not everytimes.
I think it’s because some connections are worse than other ones, so I have to add some type of wait that works for everyone.

Thank you!

You should try changing the CFrame value of the HumanoidRootPart instead of the position, this is a more robust way of teleporting characters about.

Also, you’re currently setting the position to the exact position of the SpawnLocation, which means the character will be teleported inside the block, when you probably want to offset this by about 6 studs upwards so they stand on top of it.

Hope this helps,
-Tom :slight_smile:

1 Like

Alright, I will try that.
I did offset them by around 3 studs, I just made this piece of code real quick, as the original one is way longer.

Try:

humanoidRootPart.CFrame = TeamSpawn.CFrame + Vector3.new(0,3,0)
1 Like