RobloxScripterAI
Discord ↗
Link Copied to Clipboard
×
"the player touched a part will die and add comment to code"
-- local script local part = script.Parent local function onTouch(otherPart) local player = game.Players:FindFirstChild(otherPart.Parent.Name) if player then player.Character:BreakJoints() -- Player died when touched the part end end part.Touched:Connect(onTouch)