Sorry for the bad scripting. I started 4 days ago.
game.ReplicatedStorage.KickTGR.OnServerEvent:Connect(function()
script.Parent.Touched:Connect(function(hitskid)
local player = game.Players:GetPlayerFromCharacter(hitskid.Parent)
local id =
local ts = game:GetService("TeleportService")
if player.Name ~= game.Players.LocalPlayer.Name then
ts:Teleport(id, player)
else
return
end
end)
end)
The script itself works fine, but when I try turning off CanCollide it stops working.
It should work fine, but it doesn't.
Note: The part is stored in ServerStorage and then it is moved to your character, through a script.
https://developer.roblox.com/en-us/articles/detecting-collisions
-- CryntoxB

4 comments
.Touched should always work with or without collisions enabled, maybe try welding the part to the character?
If you are not welding it, when it's CanCollide = true, it falls on the ground but not in the void, while when it's CanCollide = false it just falls into the void ignoring all collisions and destroys itself and the script inside, that's why you don't put scripts randomly in parts. Try using welds then as shadowstorm said
It has a weld btw
wait, actually the part is 1 x 1 x 2 studs and is place directly in the arm and then welded to the arm. is that bad?