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

How do I summon blocks like as a weapon or attack then dissapear?.

I've been playing other games on roblox some of them are really good they might be Key-pressdown's and I wanted to do a tool attack so when you click with the tool it would summon a edited block then dissapear

1 answer

function onClicked(mouse)
local part = Instance.new('Part', game.Workspace)
-- Edit the properties of the part here
end

function onEquipped(mouse)
mouse.Button1Down:connect:(function() onClicked(mouse) end)
end

script.Parent.Equipped:connect(onEquipped)

This is for a Tool. Put this in a script, and put the script inside the Tool. If you want it in HopperBin form, just change 'OnEquipped' to 'Selected'. Hope this helps.

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