Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Pick up Tool on Click?

Hi! So I am trying to make it so when you click on my tool (which has 3 unions inside and they are all named, "Handle") it puts the objects in the player's inventory. When I try it, it attaches my character to the tool, it basically teleports me to it then won't let me move.

local Donut = script.Parent
local ClickDetector = Donut.Handle.ClickDetector

if Donut.Handle:FindFirstChild("TouchInterest") then
	Donut.Handle.TouchInterest:Destroy()
end

	ClickDetector.MouseClick:Connect(function(Player)

	local DonutClone = Donut:Clone()
	
	DonutClone.Parent = Player.Backpack

	
	
	
end)

Does anybody have any idea why?

2 comments

0

this means your tool is probably anchored

0

I set it to after the function is called the parts unanchor, but it still does the same thing

1 answer

Tool is anchored, select all Parts in tool and unanchor them all

This discussion is preserved as it was. New answers, comments, and votes are closed.