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

What exactly is "Debris"?

Asked by
Kyokamii 133
9 years ago

Does game:GetService("Debris"):AddItem(workspace.Part, 10) create a part and remove it after 10 seconds or get an already exisiting part and remove it after 10 seconds? I already searched this topic on scripting helpers and somebody said that it removes an already existing part while another guy said it created one then remove it.

I'm confused

1 answer

Log in to vote
1
Answered by
Im_Kritz 334 Moderation Voter
9 years ago

No. it doesn't create a new part.

What game:GetService("Debris"):AddItem(workspace.Part, 10) does is wait 10 seconds then deletes the part. Debris is for removing objects from the DataModel after the specific amount of time

0
Thanks. Kyokamii 133 — 9y
1
Is there a way to add the item then remove it? Kyokamii 133 — 9y
0
^ make a variable local p = Instance.new("Part") p.Parent = workspace game:GetService("Debris"):AddItem(p, 1) --Removes the part in one second. --[[Sorry for posting an answer on the comments admins.--]] digitalzer3 123 — 9y
Ad

Answer this question