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 clone a model and set its position?

I have a box that is a model, but I want to know where to keep it. ReplicatedStorage? Also, how do I clone the whole model and set its position to a part's position?

2 answers

Assuming you have set the primary part for a model, you can use this as a reference and thereafter just use the SetPrimaryPartCFrame function of a cloned model - using the :Clone() function on the model.

For help on the :Clone() function use this as a guide.

Hope this helps!

Keeping models in ReplicatedStorage is a good idea because LocalScripts can also use it, i'd say either use ReplicatedStorage or ServerStorage.

model = game.YourModelsLocation:Clone() -- put the model's location after "model ="
model.Parent = workspace -- the model's parent, for example Workspace.
model.Part.Position = part.Position   -- you cannot use CFrame or Position on a model so you have to use a part inside the model as the CFrame or Position.

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