Skip to content
This repository has been archived by the owner on Jan 17, 2020. It is now read-only.

Only execute one layer of commands at once #110

Open
z0w0 opened this issue Dec 10, 2016 · 0 comments
Open

Only execute one layer of commands at once #110

z0w0 opened this issue Dec 10, 2016 · 0 comments
Milestone

Comments

@z0w0
Copy link
Owner

z0w0 commented Dec 10, 2016

Currently in stepModel, here, the engine will continously execute the update function of a game and recursively execute any commands returned by the engine user and then pass them to stepModel again. This would be fine if commands were executed on a separate thread, but in order to support the case of engines that have to be run on the main thread, they are not. To prevent the rendering process from being blocked, the stepModel function should only run the first Cmd returned from the update function, and queue the rest. This will cause some delay but will ensure that rendering always processes in the case of an engine user writing an infinitely-looping command tree.


Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

@z0w0 z0w0 added this to the 1.1.0 milestone Dec 10, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant