im2awsm
|
  |
| Joined: 25 Aug 2010 |
| Total Posts: 2295 |
|
|
| 22 Aug 2013 10:13 PM |
| For example, if a model had MULTIPLE parts named "Virus" in it, how would I remove them both? |
|
|
| Report Abuse |
|
|
|
| 22 Aug 2013 10:14 PM |
repeat local Part = Model:FindFirstChild("PartName") if Part then Part:Destroy() end until not Model:FindFirstChild("PartName")
? |
|
|
| Report Abuse |
|
|
cntkillme
|
  |
| Joined: 07 Apr 2008 |
| Total Posts: 44956 |
|
| |
|
cntkillme
|
  |
| Joined: 07 Apr 2008 |
| Total Posts: 44956 |
|
|
| 22 Aug 2013 10:30 PM |
Just:
while blahblah:FindFirstChild("blah") do blahblah.blah:Destroy() end |
|
|
| Report Abuse |
|
|
|
| 22 Aug 2013 10:57 PM |
| ^ Because theres 2 of them |
|
|
| Report Abuse |
|
|
cntkillme
|
  |
| Joined: 07 Apr 2008 |
| Total Posts: 44956 |
|
|
| 22 Aug 2013 11:07 PM |
| madness, mine would keep removing them, faster and more efficient |
|
|
| Report Abuse |
|
|
Brycemlns
|
  |
| Joined: 28 Jan 2008 |
| Total Posts: 216 |
|
|
| 22 Aug 2013 11:32 PM |
| Would not a return(); work? |
|
|
| Report Abuse |
|
|