mirror of
https://github.com/processing/processing4.git
synced 2026-01-31 04:11:07 +01:00
fixing up ArrayLists for generics, also Kock curve updates
This commit is contained in:
@@ -15,12 +15,11 @@ class ParticleSystem {
|
||||
}
|
||||
|
||||
void run() {
|
||||
Iterator<Particle> it = particles.iterator();
|
||||
while (it.hasNext()) {
|
||||
Particle p = it.next();
|
||||
for (int i = particles.size()-1; i >= 0; i--) {
|
||||
Particle p = particles.get(i);
|
||||
p.run();
|
||||
if (p.isDead()) {
|
||||
it.remove();
|
||||
particles.remove(i);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user