erkyrath / quixe

A Glulx VM interpreter written in Javascript
http://eblong.com/zarf/glulx/
MIT License
169 stars 33 forks source link

Graphics window reserve never gets trimmed in Counterfeit Monkey (autosave) #16

Open erkyrath opened 8 years ago

erkyrath commented 8 years ago

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.

curiousdannii commented 7 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.

curiousdannii commented 7 years ago

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.

erkyrath commented 7 years ago

Hm. That does sound plausible, yes.

angstsmurf commented 5 years ago

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.

angstsmurf commented 4 years ago

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?

angstsmurf commented 4 years ago

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.