You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would like to be able to set up a terminal, then later run one iteration of the update loop at a time, from a loop under my own control, rather than having to surrender control to main_loop and only get control back in my code during tick.
Naively imagined, this might involve moving the top part of main_loop into a initialization function, then the function inside el.run (the event handlers, including the one that calls tock) into a separate function. Then main_loop for hal/native would look something like this:
and roughly equivalent changes in the other implementations of main_loop.
I expect it would actually be a bit more complex than this, but I hope this illustrates the idea. My goal would be to call init_loop myself, then later call one_tick once per tick in my own game loop.
The text was updated successfully, but these errors were encountered:
sparr
changed the title
Request: Move terminal update logic out of main_loop
Request: Move terminal init and update logic out of main_loop
Oct 22, 2023
I would like to be able to set up a terminal, then later run one iteration of the update loop at a time, from a loop under my own control, rather than having to surrender control to
main_loop
and only get control back in my code duringtick
.Naively imagined, this might involve moving the top part of
main_loop
into a initialization function, then the function insideel.run
(the event handlers, including the one that callstock
) into a separate function. Thenmain_loop
forhal/native
would look something like this:and roughly equivalent changes in the other implementations of main_loop.
I expect it would actually be a bit more complex than this, but I hope this illustrates the idea. My goal would be to call
init_loop
myself, then later callone_tick
once per tick in my own game loop.The text was updated successfully, but these errors were encountered: