Open erkyrath opened 8 years ago
The updated CM does call glk_window_clear now, but it would be good to still fix this if possible, for older versions, and for other games.
Also, if this is related to autosaving, does it need to be stored at all? After restoring an auto save the terp should issue a rearrange and redraw event.
Hm. That does sound plausible, yes.
I removed the call to glk_window_clear because it made the map flicker on some interpreters. I guess I should put it back in.
To be precise, it causes Zoom and Lectrote to flash black once, but only the first time you enter a new room.
Turns out I never did put the glk_window_clear call back in, and I'm not a fan of the flickering it causes. Do you think I should? How bad is this issue currently?
I tried running Counterfeit Monkey both with and without the glk_window_clear call here, but didn't see much difference in performance or memory usage. The TEST ME command plays the entire game in about 15 minutes in Safari. However, with the glk_window_clear call, the map will be black while new map images are loading for the first time, i.e. when you enter a new room, sometimes for several seconds.
CM clears the graphics window every turn (or every move?), but it does this by filling a window-sized rectangle (rather than calling glk_window_clear). Quixe fails to recognize that this erases all previous content. Therefore the window reserve accumulates forever.
A redraw event should also wipe the reserve, since it signals that the window has been erased-to-background-color.