Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EngineStateMachine changing states during Engine update #39

Open
irinelpascu opened this issue Mar 2, 2016 · 1 comment
Open

EngineStateMachine changing states during Engine update #39

irinelpascu opened this issue Mar 2, 2016 · 1 comment

Comments

@irinelpascu
Copy link

Hi,

Shouldn't the engine stop updating the systems if inside a system's update function, a state change was requested?
Right now it doesn't and that triggers the update functions on wrong systems because the SystemList is updated on the spot.
Am I using the EngineStateMachine wrong?
Who should order a state change?

Thanks,
Irinel

@richardlord
Copy link
Owner

I have seen too many problems in too many libraries where the library decides when to apply a requested change. So in Ash the change happens when you request it. If you want to make the change after the update cycle listen for the updateComplete signal from the engine and make the change then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants