This week went in some unexpected directions. I still don’t have the Release 3 feature set finalized; it got put on the backburner for some other items that I probably spent too much time on.
- Learning material science. I spent way too much time reading about material science and researching different materials and properties of those materials. I was going to use this information to build a model governing how different objects interacted in the game. I haven’t been able to distill the complexity into a simple model yet, and will likely end up explicitly defining the material-to-material interactions. This was actually something I was working on in my previous game project, and it became a deep rabbit hole and one of the reasons why I abandoned that game.
- Material-based logic. Actors and items can now have immunity to status effects based on their material. This fixed some bugs, like wooden doors getting poisoned.
- Modified the UI to work on PC screens. Originally, Legend was going to be released on mobile devices first and PC/Mac second. I’ve since decided to reverse that sequence. As such, I had to resize and reposition the UI to work on a higher resolution, landscape-oriented screen.
- Message log improvements. The message log now writes to a file in addition to the screen, enabling me to see the complete history of messages. I also cleaned up the code.
- Debug log improvements. The debug log now writes to a file as well. It’s in a comma-delimited format so that it can be imported into a spreadsheet app or log viewer. Each debug log entry contains a timestamp, Unity log message type (Error/Warning/Info), category, the class and method that generated the message (using Reflection), and the message itself.
- Using the unit tests I wrote last week. The new unit tests are already paying for the time it took to write them. They caught a few bugs introduced by refactoring this week.
Next week I need to finalize the Release 3 scope, but I’m feeling compelled to keep working on a solution for object interactions. The current solution involves an ugly switch statement (if object is X, execute code block Y) that needs to go away. I want these mappings to be done in the Unity Inspector, so I will probably refactor this into a solution using UnityEvents. More to come on that next week. I also need to change the ratio of time spent on new features and refactoring. I’m spending a bit too much time on the latter, and there are a lot of new features to add for Release 3 over the next 6 months.