Backfiring Intentions

Troy Corbin Developer Updates Leave a Comment

Whew. I had every intention of spending the entire night developing a kickass modular entity collision reaction scheme, but sadly I got a late start on that.

You see, organizing a project this size is important to do from the beginning. If you have hundreds of classes all laying in the same directory it can become a nightmare to find anything. I wasn’t there yet, but at 39 classes I figured I had better start now rather than later. Thing is… Java is very picky about Class Paths and file locations…. much more so than my old beloved C++. I spent a good 2-3 hours just reorganizing everything, declaring Packages, qualifying Class name references, etc. That was a much bigger project than I had anticipated.

Oh well, at least it’s done. I did manage to get some work done on the collision system. It distinguishes between entity and world collisions, I can declare an entity to be non-collidable ( for example, the exhaust ), it can assign damage to another entity, and can even play a collision sound.

Sadly, that work still needs some bug testing. The collision sound doesn’t always work, and honestly I wanted the solution to be a bit more elegant. On the plus side, I can also now declare that some sound effects receive a minor change in pitch. This keeps gunfire from sounding quite so repetitive. It’s a good thing.

Also, I discovered that my code to clean up used sounds was not working. OpenAL has a “Source” limit of 256 sounds. So once I’ve fired off that many sounds, no new ones are produced. Just one more silly quirk to fix. But what do we say to the God of death? “Not Today.”

Troy CorbinBackfiring Intentions

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.