bin = script.Parent
function onButton1Down(mouse)
local model = bin.model:clone() model.Parent = game.Workspace model:MakeJoints() model:MoveTo(mouse.hit.p)
script.Parent:Remove()
end
function onSelected(mouse) mouse.Icon = "rbxasset://textures\GunCursor.png" mouse.Button1Down:connect(function() onButton1Down(mouse) end) end
bin.Selected:connect(onSelected)
Let's see..
wait(0.1) bin = script.Parent function onButton1Down(mouse) local model = bin.model:clone() model.Parent = game.Workspace model:MakeJoints() model:MoveTo(mouse.Hit.p) script.Parent:Destroy() end function onSelected(mouse) mouse.Icon = "rbxasset://textures\GunCursor.png" mouse.Button1Down:connect(function() onButton1Down(mouse) end) end bin.Selected:connect(onSelected)
Try it out, and say if it works or not.
Also, if it's a regular script, then the script won't work in a hopperbin because of an update 2-3 months ago (just noting that).
Use a LocalScript instead if it isn't already.