MORE WAS LOST IN CUBA

View Original

Art, Morale and Code


Weekly Summary

This week has been very busy: a lot of life-stuff, chores and appointments along with a couple of late days at work have resulted in very little time being invested into AIW. I’m working hard on getting my brain to understand that:

Little time AIW > No time in AIW

This sounds pretty obvious, yeah, but it’s very easy for me to fall into the trap of: “I’ve only got 1 hour, it ain’t worth doing anything now”. Anyway, this is a roundabout way of saying I did manage to squeeze in 3 hours of actual dev work (along with 4 extra-hours for other game-dev-adjacent work).

On a more personal level, I also spent some time working on a reward/motivation system to keep momentum going on the game - which I’m very excited about.


Daily Log

Wednesday - 09/02/2022

Time Spent: 1 Hour

I had a one hour chat with an artistically-inclined friend to start pinning down the aesthetic for the game. We’ve never worked together before but I’ve seen his stuff and am pretty excited to see what he can do. As a first test - and to see how well his style fits into what I had in mind without him having to design every single asset for the game - I asked him to design a sort of “cover art” for the game; this will become “branding” material if successful (it’ll be used in things like the web-sites banner, twitter profile pic, reddit, etc…).

To properly understand what I was looking for, he asked for examples of the art-style I was thinking of for the game (which you’ll find below) along with a list of games I’m inspired by (and examples of their branding/art-style/aesthetic). Hope I can show you what he comes up with soon!

Thursday - 10/02/2022

Time Spent: 1 Hour

I had a pretty late start because of my day job, some unexpected work and meetings came up and I had to stay a bit later than usual. I squeezed in 1 hour during which I started work on the morality system.

Dev-work basically involved planning and structuring what this morality system would look like: there’s quite a few ways in which morale for a unit can increase/decrease and it’s easy to fall into the if/else trap. In order keep the codebase clean (and avoid future bugs) I really wanted to come up with an elegant solution that allowed for easy composition (and addition) of multiple “morale modifiers”. TLDR: I spent most of the time designing a Single-Source-of-Truth (SSoT) for all morale-related logic to avoid having if/else statements all over the codebase that directly modify a units morale.

During this planning/design session I realised that SSoT hasn’t been much of a concern so far and it’s looking more and more like I’ll need to do a relatively major refactor of the codebase soonish to keep things maintainable and technical-debt in check.

Friday - 13/02/2022

Time Spent: 2 Hours

Started implementation of the Morale Damage work I designed the day prior. I created a MoraleModifier[] (which is an Array of Func<Unit, int>); each of those functions executes the logic for one particular modifier and, if the condition is met, it returns the corresponding modifier (+/- int). For example: if a unit does nothing for 1 turn, it receives +1 morale, if it does nothing for 2 rounds it receives no morale increase but, if it’s idle for 3 or more rounds, it’ll receive -1 morale every round it’s inactive; this results in the following function:

See this content in the original post

In the morale phase, we then iterate through all existing units in the battle field and execute all of the MoraleModifiers for each of them, we add the results together and then pass the result from that to ApplyMoraleDamage (which does exactly what it says in the box).

This solution allows for flexibility when adding new morale modifiers (we just need to add another function to the array), modifying existing ones (they’re all in the same array, no need to go hunting through the codebase to look for a specific logic) and centralizes all morale logic in one single place (UnitManager). While this may seem inefficient (it does involve a nested for, which I’m not a big fan of), I’m a big proponent of “late-optimisation” and YAGNI; that is to say: I’ll code a solution first and, later, if I’m encountering performance issues, I’ll optimize it (I do, however, miss Haskell’s ridiculously strict type system and functional programming).

I managed to get 5 morale modifiers coded (out of 12 I have come up with so far), I would have liked to get more done but they are pretty involved and require quite a bit of refactoring.

Saturday - 12/02/2022

Time Spent: 3 Hours

During the week, I found out Ángel Luis Sucasas (A Place for the Unwilling, Scarf) was going to be imparting a workshop on narrative design for video games. I thought it could be a good opportunity to start work on the narrative for AIW as well as, potentially, a good networking opportunity, so I bought a ticket.

The workshop started at 11:30 and there were quite a few people attending. It started as a pretty high-level overview of the “tools” narrative designers have to communicate a story (cinematics, VO, animation, design and sound/music) and then went on to analyse a sequence of events from “Ratchet and Clank: A Rift Apart”. I was hoping for some specifics (just as movies have a script, I was looking for something similar for video games) but it was pretty abstract when it came to the “how” you write/specify/design narrative.

At the same time, I’ve been very interested in the concept of “the language of video games” as of late: how do we use interactivity and immersion to tell stories - as opposed to the “language of cinema”, which is what the industry has been using historically. The workshop didn’t touch this subject at all, instead, focusing more in the “classic” concept of narrative in video games in which you use cinematics, barks, camera work and script to tell a story (which isn’t really what I’m looking for in AIW). It also didn’t talk approach modern concepts like “ludo-narrative dissonance” or “interactive-story-telling”.

My intention is to build on top of the work started by games like Undertale, Disco Elysium, Outer Wilds or even Dark Souls; which push the medium further along and attempt to mature it as an art form. I find what these games have done vastly improves what we’ve traditionally seen in video game narratives: they add a message to the game itself and not just the story, they promote a ludo-narrative harmony which is easier to fail at using the language of cinema and they further immerse the player by giving them agency and a deeper connection to the message the game is trying to transmit.

During the practical portion of the workshop, I did manage to start work on what will become the introduction to All Islands Wail: coming up with the sequence of events that will unfolds, how to introduce the player to specific mechanics and how to pull the player in. I feel this was a great investment of time and, I do look forward to sharing this document with Ángel to see what he thinks and what feedback he has. Finally, I was a bit disappointed to find there wasn’t a single break or opportunity for networking built into the event: there aren’t many events about game design in Barcelona (or Spain for that matter) so, having a room full of like-minded people and not giving them all an opportunity to interact or build relations, honestly, feels like a missed opportunity.


Progress

  • Started pinning down aesthetics and art-style for the game.

  • Designed a sustainable solution for morale modifiers and got half-way through implementing them.

  • Started work on the introduction for the game.


Issues

  • Coming up with a scalable solution for Morale was hard and took way longer than anticipated. I think I need to try and “code drunk, refactor sober” a bit more.

  • Lack of time was a big one this week, I need to push myself to make time more regularly (even if it’s just one hour a day). All progress, no matter how small, is progress.


Next Week

Next week feels a lot less stressful and jam-packed of stuff so, unless unexpected things pop-up, I should be able to make some solid progress in AIW.


Goals

  • Finish Morale Modifiers and Morale Damage.

  • Start work on (and potentially finish) Morale Effects/Consequences: the system by which the morale of a unit will buff/debuff said unit.