Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Pull Request Prelude
Changes Proposed
Because the global reload in luascript.cpp reloads the internal libraries of the revscript environment, the tables where the eventcallbacks are stored are cleaned up, so we must reload the scripts after the global reload.
I also modified the code of the
Game.relaod
method a bit so that it would return 1 or 2 values as the case may be, since previously a boolean was being pushed to the stack that was not even returned, because only 1 value was being returned.Issues addressed: #4304
According to the Issue lookAt fails, and yes, it's true, but so did all the related events, so it's a big problem if someone uses reloaded global 😩