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

How do i create clones from models from serverstorage that puts itself to workspace?

Im making a game where you collect coins underwater and i want to know how to clone a model from serverstorage and i want to clone to put itself in workspace.

1 answer

✓ Accepted answer

Alright, so let's say you have a model named Coin that has some parts in it.

After that, let's clone the model and set it's primary part, in case for whatever reason the primary part property didn't get copied over. In this case I assume that the primary part is called CoinBase.

local ModelClone = game.ServerStorage:WaitForChild("Coin"):Clone()
ModelClone.PrimaryPart = ModelClone.CoinBase

Now we have the clone of the model, so the first part of your question is done. Next, let's position and parent this model.

ModelClone:SetPrimaryPartCFrame(Whatever your cframe is)
ModelClone.parent = game.workspace

That should be it then.

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