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

[3.x] Clear pending function states when reloading GDScript #56296

Merged
merged 1 commit into from
Jan 12, 2022

Conversation

timothyqiu
Copy link
Member

Fixes #56116

Since reloading a GDScript frees previous GDScriptFunctions, pending GDScriptFunctionStates should also be cleared.

The MRP won't crash after this PR. The animations won't be working after reload because they're done via an infinite loop with yield() sleeps. I don't think we can remap the function states to resume inside newly created functions, as they could be completely different.

@akien-mga akien-mga merged commit 79aa64e into godotengine:3.x Jan 12, 2022
@akien-mga
Copy link
Member

Thanks!

@akien-mga
Copy link
Member

Cherry-picked for 3.4.3.

@timothyqiu timothyqiu deleted the pending-func-states branch January 12, 2022 16:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants