Clone
Clones an Instance and automatically adds the clone to the Vault.
- TypeScript
- Luau
const original = new Instance("Part")
const clone = vault.Clone(original)
clone.Parent = workspace
vault.Clean()
local original = Instance.new("Part")
local clone = vault:Clone(original)
clone.Parent = workspace
vault:Clean()
Parameters
| Parameter | Type | Description |
|---|---|---|
instance | Instance | The instance to clone |
Returns
Instance - The cloned instance (auto-added to vault)
Behavior
- Wraps
Instance:Clone() - Automatically adds the clone to the vault
- Returns the clone for immediate use
- Original instance remains unchanged