I have tried to modify parts from similar freemodels 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)
local model = bin.tent:clone() model.Parent = game.Workspace model:MakeJoints() 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)
Closed as Not Constructive by RubenKan
This question has been closed because it is not constructive to others or the asker. Most commonly, questions that are requests with no attempt from the asker to solve their problem will fall into this category.
Why was this question closed?