Blog and documentation for Game Off 2021 attempt.
November 12, 2021
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.
Time well spent?
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.
22.25 + 2.5hr