I’m having difficulty understanding the easiest way to change the main window’s background and text colors dynamically during play (e.g. Photopia). I’m looking to export a game specifically for the web through Parchment. It looks like Basic Screen Effects won’t work in this case and I can’t find a working example using Flexible Windows. I’ve tried closing and reopening the main window during play, but that crashes inform. How can I achieve this?
Are you testing the game in the Inform IDE, or have you also tried releasing and playing in a glulx interpreter? Sometimes effects won’t occur in the play-test window.
Are you compiling to target .z8 or Glulx? Since you mention Flexible Windows, I assume Glulx?
The crash is a bug we should maybe report, Inform shouldn’t crash! Try changing from Glulxe to Git interpreter, do you get crash with both?
What version of Flexible Windows by Jon Ingold? Glk version of Inform has an open bug with background color of windows… what is your desktop running?
I’m testing with the InformIDE version 1.64.1 on OSX. I’m using version 15/161003 of Flexible Windows (for Glulx only) by Jon Ingold.
I’m able to set the color initially and have the test work correctly in the InformIDE, but if I close the main window at any time after play begins it crashes, in either Glulx interpreter (Glulxe and git).
Although, I did just realize attempting to set the background color initially doesn’t even work when viewed through Parchment. It doesn’t seem like it would be the right path even if I resolve the crashing issue, now that I’ve tested it further.
I can still set a custom background color and text styles through HTML/CSS initially, but it won’t give the dynamics I’m looking for. Are there any other ways to change colors which will work in Parchment? I’m set on having to use Parchment, there isn’t a way around it in my particular use case. Thank you for your suggestions so far.
Since you are talking Glulx, under the covers Parchment is running Quixe. I put together this demo regarding background colors in a previous discussion: eblong.com/zarf/glulx/quixe/quix … Play+it%21 discussion was here: https://intfiction.org/t/flexible-windows-example-with-figures-on-latest-v15-update/10591/8
Given some of the bugs and incomplete work, it does matter if you use just a single window or additional ones.
Thanks for your example allen. I have it running on my machine, but I’m not seeing any instance of the background changing during play within it. Or were you not actually saying this is possible yet?
Do you see a divider strip, colored, between the Side Window and the main window?
Follow-up on this. You know - I might be overlooking something. It is the graphics windows that seem to work correctly with the background color. it is the Text windows that do not. So I guess opening windows isn’t really a workaround.
How is Adam getting Parchment to do this in his online version of Photopia? The background switches from black to white in each chapter. Is he not writing it initially with Inform?
At least we can have a modern-day Technological Laugh due to Adam’s statement of the past “PHOTOPIA uses specially colored text. I think it enhances the story a
great deal, and think of the work as incomplete without it. However, I am aware that there is a segment of the IF community that abhors color.”
This is Z-Machine runtime, so there are more options and a lot of effort was given to reproducing the original legendary stories (Zork, etc).
I’m looking for the source code, so far what I found is a ‘making of’: adamcadre.ac/content/phaq.txt