It works at first but then 1 second later it teleports, even when I'm not touching it?
local table = { "Player1", "", "" } cooldown = false place = workspace.ToSpawn script.Parent.Touched:connect(function(hit) if game.Players:GetPlayerFromCharacter(hit.Parent) and (not cooldown) then cooldown = true local plr = game.Players:GetPlayerFromCharacter(hit.Parent) local chr = plr.Character for i,v in pairs(table) do if plr.Name == v then script.Parent.CanCollide = false script.Parent.Transparency = .3 wait(1) script.Parent.CanCollide = true script.Parent.Transparency = 0 cooldown = false else chr:WaitForChild("HumanoidRootPart") chr.HumanoidRootPart.CFrame = place.CFrame + Vector3.new(0,2,0) cooldown = false end end end end)
Not sure at all, is it waiting then going back to it?
In line 17 you have a wait for one second, to reduce the time, make it 0.0000001 seconds