Clone (Function): Difference between revisions

From Goodblox Wiki
Jump to navigationJump to search
(Created page with "{| |<onlyinclude> {{Function| name = Clone |arguments = |returns = Instance object |description = Returns a copy of this...")
 
m (Pizzaboxer moved page Clone to Clone (Function))
(No difference)

Revision as of 06:54, 23 June 2020

Function
Syntax Clone( )
Returns Instance object
Description: Returns a copy of this Object and all its children. The copy's Parent is nil
In Object: Global


Example


while true do
 model = game.Workspace.Model:clone()
 model.Parent = game.Workspace
 wait(300)
end

or


while true do
 game.Workspace.Model:Clone().Parent = game.Workspace
 wait(300)
end

which does the same thing

Limitations

Objects with archivable set to false are not cloned.

These classes are known to be unclonable: Hats, Workspace