Game Off 2021 - YourWaifuIsALie

Blog and documentation for Game Off 2021 attempt.


Project maintained by YourWaifuIsALie Hosted on GitHub Pages — Theme by mattgraham

Game Off 2021 - Day 11

November 12, 2021

Study

JSON definitions

Finished a basic implementation for loading “battle actors” from JSON files. The most annoying part was realizing how json.net would deserialize into non-standard objects.

For my data structures, only the boolean logic related to when effects activate contains a arbitrarily nested dictionary. So, I only need to manually parse that single field and turn it into a proper structure.

The logic is fairly simple:

From there, it’s just a matter of recursively parsing the dictionary structure and bubbling the true/false determination up to the top. This allows me to create dumb rules that I probably won’t even get to use for the game jam portion of this game.

A split screenshot. The left side shows debug logs indicating one actor acting on another, and if the boolean logic condition related to the effect was met or not. The right side shows the JSON object describing the boolean logic condition.

Time well spent?

Re-scope

As all projects go, being a beginner takes a lot of time, tangling with a lot of small C#/Unity things, let alone game logic + assets.

In this case, I got caught up on making this JSON deserialization/tag system. It’s fine since I’m mostly doing this just to learn. However, in terms of the “goal” of completing a project and a time-limited game jam, I definitely should have just dropped the system and hard-coded things. These JSON specifications, deserializing, and boolean logic parsing are only useful if I’m making a real game full of assets.

In terms of game completion, there’s no benefit implementing this now instead of getting some hard-coded thing working instead. I spent something like 8 hours getting the kinks worked out of this which is vital time considering I have no gameplay yet.

Ultimately, I’ll need to look at re-scoping and prioritizing at the end of this week. It’s a conscious decision to be sloppier in order to get everything working.

Progress

TODO

Time Spent

22.25 + 2.5hr