parkm / oldbpm

A JavaScript game where you shoot at bubbles.
0 stars 1 forks source link

State Add/Remove Performance #49

Open parkm opened 10 years ago

parkm commented 10 years ago

Just noticed that adding/removing objects had gotten slower due to always creating an array every add or remove. The loop (even though it typically loops once) may also cause some slowness.

The performance is not very apparent until you start adding/removing thousands of objects. So this isn't very high priority but if the game starts to use more objects then we may want to consider improving these functions.