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
7 years ago

local Donkey = script.Parent

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

1wait(8)
2local comeback = Donkey:Clone()
3comeback.parent = game.Workspace
4comeback.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 — 7y

2 answers

Log in to vote
1
Answered by 7 years ago

Well, you destroyed the Donkey before you cloned it.

1while true do wait(6.1)
2 
3Donkey:Destroy()
4 
5wait(8)
6 
7local comeback = Donkey:Clone()

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

Ad
Log in to vote
0
Answered by
UgOsMiLy 1074 Moderation Voter
7 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:

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

Answer this question