Page 1 of 1

[Request] Redraw flag for vanilla gui's

Posted: Tue May 23, 2023 12:33 am
by Nagrom_17
Currently vanilla gui's do not update to reflect changes in data done through scripts (see viewtopic.php?p=585326#p585326). The workaround that is generally used in the modding community is to close the gui, wait a tick, and then reopen it to force a redraw. The issue is this causes flicker when the gui is closed for a tick, as well as the close/open sound to play, leading to a very non optimal experience.

Automatic determination of when to redraw is complicated and varies depending on the exact gui that is open, so my suggestion is a flag that causes the current vanilla gui to redraw sometime on the next tick. This would allow mods to cleanly show updates to vanilla gui's in real time without relying on the close/open that is needed currently.