RobloxScripterAI
Discord ↗
Link Copied to Clipboard
×
"script a devil fruit tool that turns a player into a part when a players left click on equipped"
-- local script inside the devil fruit tool local tool = script.Parent local Players = game:GetService("Players") local player = Players.LocalPlayer local mouse = player:GetMouse() local function onMouseDown() local target = mouse.Target if target then local targetPlayer = Players:GetPlayerFromCharacter(target.Parent) if targetPlayer then local part = Instance.new("Part") part.Size = Vector3.new(2, 2, 2) part.BrickColor = BrickColor.new("Bright red") part.Position = targetPlayer.Character.HumanoidRootPart.Position part.Parent = workspace targetPlayer.Character:Destroy() end end end tool.Equipped:Connect(function() mouse.Button1Down:Connect(onMouseDown) end)