Issue with Teleporter

Hello im making teleport door in my game

my issue is whenever someone gets in the teleporter his character disappear to others no one can see him until he restart his character .

before getting to teleporter everyone can see his character .

this is the script that I’m using right now

script.Parent.Touched:Connect(function(hit)
local player = hit.Parent
if player then
local torso = player.HumanoidRootPart
if torso then
torso.Position = Vector3.new(-17135.551, 8.496, -184.505)
end
end
end)

3 Likes

Are you using a local script or a script?

1 Like

anyway try that In a script, not a local script

local teleportposition = Vector3.new(-17135.551, 8.496, -184.505)
script.Parent.Touched:Connect(function(hit)

	if hit then
		local character = hit.Parent
		local humanoid = character:FindFirstChildWhichIsA("Humanoid")
		if humanoid then
			character:SetPrimaryPartCFrame(CFrame.new(teleportposition))
		end
	end
end)



3 Likes

yes it is script should i change it to local ?

1 Like

worked! thank you very much fixed the problem

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.