Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

I've tried everything but my part wont copy?

Asked by
zoo237 0
6 years ago

local Donkey = script.Parent

while true do wait(6.1) Donkey:Destroy()

wait(8)
local comeback = Donkey:Clone()
comeback.parent = game.Workspace
comeback.postion = Vector3.new(352, 9, -61)

end

0
it's probably that you CLONE it AFTER you've destroyed it. and spelling. everything's spelled wrong. RubenKan 3615 — 6y

2 answers

Log in to vote
1
Answered by 6 years ago

Well, you destroyed the Donkey before you cloned it.

while true do wait(6.1) 

Donkey:Destroy()

wait(8)

local comeback = Donkey:Clone()

You can't clone something that doesn't exist.

Ad
Log in to vote
0
Answered by
UgOsMiLy 1074 Moderation Voter
6 years ago

It's because of exactly what the first comment said; Destroying an object will lock its parent to nil. Also, the spelling isn't correct. The error was most likely parent is not a valid member of Part because the property is Parent, not parent. What the script should be is this:

local Donkey = script.Parent

while true do wait(6.1)
    Donkey.Parent = nil
    wait(8)
    Donkey.Parent = workspace
    Donkey.Position = Vector3.new(352, 9, -61)
end
0
So how do I make it comeback after it's cloned zoo237 0 — 6y

Answer this question