Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

How to make players teleport to their death point/previous location?

I have some ideas, but I doubt they'll work. Any ideas?

1 comment

0

At least post the ideas man

1 answer

✓ Accepted answer

Save their last position on Humanoid.Died, wait for their character to load using CharacterAdded:Wait() and then teleport them back to where they were.

game:GetService("Players").PlayerAdded:Connect(function(plr)
	plr.CharacterAdded:Connect(function(char)
		local hum = char:WaitForChild"Humanoid"
		hum.Died:Connect(function()
			local pos = char.HumanoidRootPart.Position
			plr.CharacterAdded:Wait():WaitForChild("HumanoidRootPart").CFrame = CFrame.new(pos)
		end)
	end)
end)

1 comment

0

Omg thank you!

This discussion is preserved as it was. New answers, comments, and votes are closed.