In Inform7 an action can’t be about two variables, which is a pain as that’s what I want an action to be. Specifically, I’m trying to write a general purpose action that allows (let’s say for testing purposes) the player to set a variable to whatever number they want.
Obviously the following doesn’t work:
Adjusting is an action applying to two numbers. Understand “change [number] by [number]” as adjusting.
Carry out adjusting:
now the number is the second number.
Sorry I could have been more clearer than ‘named number’. I meant only the latter case. Being able to give your foos, bars etc. new numerical variables on the fly.
I’m aware that I could literally create an object corresponding to every variable in the game, but that seems like as much work as creating a custom action for every variable in the game. Is there a more scaleable way of doing this?
You can do something like this, though with numerical values rather than boolean ones: if you set it up right, you can just say “foo is a numerical option” instead of “foo is a number that varies” and “the value of foo” instead of “foo”, which isn’t much more work.