|
| 06 Oct 2013 01:35 PM |
How would I take all the descendants of an object. clone them destroy them and set the clones back where the originals were?
any1 know a function for that? |
|
|
| Report Abuse |
|
|
|
| 06 Oct 2013 01:39 PM |
local Backup,Parent={},Workspace.Model
for i,v in pairs(Parent:GetChildren()) do Backup[i]=v:clone() end
while wait(25) do Parent:ClearAllChildren() for i,v in pairs(Backup)do v:clone().Parent=Parent end end |
|
|
| Report Abuse |
|
|
|
| 06 Oct 2013 01:45 PM |
| a bit complex, but thanks :D |
|
|
| Report Abuse |
|
|
|
| 06 Oct 2013 09:56 PM |
hey is there any way I could make it not have to wait a whole 25 seconds?
|
|
|
| Report Abuse |
|
|
|
| 06 Oct 2013 09:59 PM |
time=10 --change the number 10 to how long you want it to wait
for i,v in pairs(Parent:GetChildren()) do Backup[i]=v:clone() end
while wait(time) do Parent:ClearAllChildren() for i,v in pairs(Backup)do v:clone().Parent=Parent end end |
|
|
| Report Abuse |
|
|
|
| 06 Oct 2013 10:02 PM |
| by that, I meant a time determined by once all the children are back as descendants of the parent |
|
|
| Report Abuse |
|
|
|
| 06 Oct 2013 10:04 PM |
| I don't understand what you're saying .-. |
|
|
| Report Abuse |
|
|
|
| 06 Oct 2013 10:07 PM |
something like
WaitForChild()
but I just also figured out, this won't work for my script. |
|
|
| Report Abuse |
|
|
| |
|
|
| 06 Oct 2013 10:10 PM |
I tried using this to immediately stop an animation script
I have tried stuff like
animationblablablah.Disabled = true repeat wait() until animationblablablahDisabled == true
|
|
|
| Report Abuse |
|
|