Friday, October 27, 2017

Brittle Code

Ugh. There is nothing worse than brittle code. A block of complex logic that completely falls apart when you modify it. As I've written about previously, I had to revisit the primary parser of my text-based game engine to accommodate non-player movement.

That is a brittle piece of code. One wrong move and the client piece completely breaks down. To address it at this time I've added comments walking through its logic. In time however I will need to toughen it up (Probably in iteration two - right before I begin the networked multi-player version of the engine. For now it works, and the NPCs are moving correctly, but I hate how touchy it is.

No comments:

Post a Comment

5 VST Effects I Use in Every Song

VSTs are so great. I have a massive collection of free instruments and FX that I've tracked down. There are SOO many to choose from... B...