my train broke down this morning so I spent an extra hour poking at my spatial partitioning code that I've been struggling to optimize. I was able to make a small step forward. I rewrote the function that moves and re-categorizes the partitions an object is in and now it can handle ~1000 moving objects at 60fps when collision detection is disabled. the next, and more difficult, challenge will be to optimize the collision detection algorithm. as of now performance tanks with ~150 objects.
I think there's still another optimization pass or two needed after that because the GC is still running too often.
The social network of the future: No ads, no corporate surveillance, ethical design, and decentralization! Own your data with Mastodon!