The TLDR is that I read Can an Inform 7 project hosted online communicate with an external file? and realized that what I wanted might be possible. That is, z-machine code that focuses on one byte and sends it to the external file once you solved an area. Or it reads the byte from the file once you start.
I’m a bit baffled as to how to do things here, though. The pseudocode needed would be
(read the external file to, say the Global_Vars–>25 variable, or binary-progress-number i7)
(write the Global_Vars–>25 variable to the external file)
Or, perhaps, writing and reading an array of booleans. But I think I could derive this from the example where we just read Global_Vars–>x.
special case: Fourdiopolis re-release
I was recently putting the finishing touches on a re-release of Fourdiopolis. It was glulxe, and I thought that was just due to 32-bit hashes to make searches for scenery go faster–so I set OMIT_UNUSED_CODE and even memory economy to make it build in z-machine in debug.
With that & other changes it was well within z-machine limits … except for one thing! I had an external file that saved progress. Now Glulxe has a command for that, but Z-Machine throws a runtime error.
My test case is as follows: Fourdiopolis wants to save one byte for progress to an external file. It is 6 bits or’d, depending on the progress you’ve made. So if you solved scenario 1, it’d write 1, or 2&3, it’d write 6, and so forth.
Obviously, having something fit in z-machine isn’t strictly necessary, but I’m proud of what I did, and I’d like to reduce the binary size if I can, especially since the final thing to do, where I’m clueless, seems a potentially trivial case. (If not, glulx it is!)
Thanks to all who can help!