August Update

Spankers, Spankees, and Switches of All Ages (18 and above),

Sorry I missed last week’s update. RL got in the way. Anyway, as far as progress on the game goes, I have been working my ass off on the codebase. I started out refactoring my GUI code to make use of a very cool library ReactiveX. The Java implementation includes some very nice bindings into JavaFX, allowing me to write my GUI code using a paradigm that makes sense to me (message passing) rather than the utterly obfuscated callback-based approach that JavaFX encourages. This has allowed me to clean up my GUI code _massively_ including removing some of the bugs that came from various hacks I tossed in to get the whole thing working.

While debugging this refactor, I discovered that ReactiveX doesn’t like it when operations are not idempotent (in particular, if they have side-effects, weird things can happen). So I solved this problem by rewriting my entire codebase to make everything immutable except for the GUI, and a small stack of past commands  in the combat code (to make undoing easier).

Yyyyeahhhh. Did I go a little bit crazy and overboard? Fuck yes. But that’s the best part about being the sole coder on a project that you are spearheading. You can do all sorts of crazy shit, and nobody can stop you! Muahahahahhahaha!

Besides, this has forced to me clear up some techdebt that’s been bugging me almost from the moment I wrote it. It also makes a lot the code that was before hard to test much easier to test. So that’s a plus. Probably won’t be writing those tests now, but that’ll probably be something I poke at as time goes on. Add a test here, add a test there, and so on.

That being said, the refactor wasn’t really that crazy. It didn’t really affect the design of my code all that much. It just required a lot of mechanical “methods that inflict side-effects, now return modified copies of whatever they were modifying before.”  Some of my types are bit crazy now, and could probably stand to be reworked, but whatever. I’ll poke at that later.

Anyway, at this point my code compiles, so next I need to update all of my tests (I have about 200). Fortunately, these changes should dramatically simplify most of my tests. So I should have all of that modified by the end of the month.

As far as the actual game content goes, Chaosnova has been working on that, so it hasn’t stood completely still. Going a bit slowly, alas, but most people don’t have as much free time as I do. I’ve also been working on some of the planning for the rest of the season in between working on the codebase.

 

AKA

2 thoughts on “August Update

  1. Hey, I just tried to load a game and when I clicked on “Load Game” from the main menu, the game crashed. Is there a fix?

    1. I’m sorry to hear that!

      The game doesn’t crash for me when I load a saved game. What OS are you using? Are you playing the most recent version?

      There should be a file in the same directory as the executable called “Log.log.” Could you send me that, along with the save file that you are trying to load?

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.