043 - September 22, 2019


This week I worked on the skills interface where you can see your level and XP in different skills and disciplines within the game.

My user interface code is still a bit young - so it took a fair amount of work to get something that even still needs some work.

Rendered skills Our work in progress skill boxes. We still need to replace those black squares with icons.

This was my first user interface in the game that I built using test-driven development. It was pretty awesome - I didn't look at the game in the browser a single time while developing it. I just wrote tests and made them pass.

An interesting thing I'm seeing is that since I have full control over the layout engine for this WebGL interface I can very easily write tests such as "ensure that this "thing is fully contained by that thing". Or "ensure that this element is within 10 pixels of that element."

This made it easy to translate a drawing of the stats interface on a sheet of paper into code without needing to visualize it while I worked.

I'm excited to continue to advance the testability of the user interface.

Skill box tests Some of our unit tests for our skill box.

As we create more user interfaces we'll land on the abstractions that will help make it easier and easier to build well-tested user interfaces.

For now we'll just move a bit more slowly as we figure things out and make architectural mistakes.

This Week

This week I'll finish up v1 of the skills interface and start working on the equipment interface.

Cya next time!