How to teleport someone on the same axis but in another place?

I want to make it so when the player says “david, david, david” and their touching a certian part they get teleported to a different bit in the map but in the same place.

local Players = game:GetService("Players")

local player = Players.LocalPlayer

local DavidsPart = game.Workspace["David'sPart"]

game.Players.PlayerAdded:Connect(function(player) 
	player.Chatted:Connect(function(msg) 
		if msg == "david, david, david" then 
			if DavidsPart.Touched:Wait() then
				-- This is were the code should be to teleport the player 
			end
		end
	end)
end)

I will show pictures.


I want them to be teleported to a different bit but in the same place.

The bit after were it says “if DavidsPart.Touched:Wait() then” is were nothing I do is working.

1 Like

Simply clone that destination room to a specific axis and offset the player’s torso CFrame to the exact same place.

(If you moved the destination room 1000 studs above, then you’d adjust it using:
x.CFrame += Vector3.new(0,1000,0)
Of course, you’ll need to replace x with the proper part to teleport.)

Good luck on your game!