Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

edit:How do i make this model spawner tool work ?

Asked by 6 years ago

I have tried to modify parts from similar freemodels scripts but they work only in studio mode and not while playing the game from roblox client.The intended funtion is to spawn a model once when clicked with the tool.Here is what i have(note that this only works in studio testing and not in roblox client in-game):

bin = script.Parent

function onButton1Down(mouse)

1 local model = bin.tent:clone() 2

3 model.Parent = game.Workspace 4 model:MakeJoints() 5 model:MoveTo(mouse.hit.p) end

function onSelected(mouse) mouse.Icon = "rbxasset://textures\GunCursor.png" mouse.Button1Down:connect(function() onButton1Down(mouse) end) end

bin.Selected:connect(onSelected)

0
Is it a local or server script? piRadians 297 — 6y

Answer this question