Devlog 2026-10-12

Dunno if I’ll do any programming today, but I’ve got the mindnumbingly boring task of sorting through receipts so I’ll think through the current task while at it.

Let’s recap the current situation.

The goal is to have a variable at a higher level affect something at a lower level. In this context “higher” and “lower” refers to when the objects in question are created. The control object that spawns everything else being the “higher level” one while the spawned objects are lower and lower level the more down the chain you go.

First I gotta question myself: Is this really necessary and/or is it necessary at this stage specifically? Am I getting sidetracked unnecessarily? The answer are yes and no in that order. This sort of thing will be relevant through every other element of the game.

So what’s the issue? simply put, it’s a matter of the communication from the higher to the lower levels not being there.

Let’s say I’ve got an object that stores where in the game you are (both in the location sense but also in the stage of progress sense). Out of the gate there’s no intrinsic link between the higher and lower levels. You can set it so when an object is created it copies a value, but it only copies it on creation.

You could set an update on every step of the process but that’s the sort of thing that adds up over time and is not good to do anyways.

Moreover it’s worth noting that this isn’t being considered specifically for strings, booleans, or integers, but instead for resources loaded onto memory as needed for each chapter. Meaning that we’re not even concerned with variables that will constantly change. It’s something that will be set at the start of a piece of content and nowhere else.

To explain it in a chart, the intent is this.

The problem here is then that Look Menu doesn’t have means to access information from Controller Object. At least it didn’t when I tried last time.

Here’s a list of approaches I’ll take for this ranked from seemingly easiest to seemingly hardest.

  • Get Parent chain
    • Create a chain of get parent commands that give each children node a reference to the object they spawned from all the way to the top. This sounds the simplest and I suspect will give me trouble.
  • Signals
    • Most likely to work on paper. The theory is that if the child emits a signal that’s received by the parent that points the child to its parent then it can get information from it. Regarless, if this method works I’ll need to give some hard thought to WHEN and HOW the signal is emitted and received. I THINK the development attempt last year forced me to try out signals, I know for a fact that signals are used by the dialog system, so it’s good to refresh how those work regardless.
  • Rethink the structure
    • If I get to this point I’ll need to take a long walk and think hard how everything’s structured. However, as mentioned, since this is such a pivotal element in the planned structure of the code that at least it won’t be for nothing.

Next time, we test this and update the plan in case I came up with any other alternative in the meantime.



Posted

in

by

Tags: