-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Pause state setter for plugin API #22090
Conversation
You can try this feature out with this plugin: https://github.com/spacek531/ParkPauser/blob/master/src/ParkPauser.js |
9bff9d2
to
31fff18
Compare
8880c9c
to
2265d75
Compare
I'm not sure if we should introduce even more unsafe game state manipulations like this one, but it does not look too problematic. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for the delay but I have tested it and it all looks good to me! 😄
be ignored, and an empty message aborts the commit.
Rebased |
Are there any current blockers to merging this? |
It is impossible to set pause state on loading without losing 1 frame when hooked to
map.changed
and it is impossible to set pause state before park save when hooked tomap.save
. This PR fixes that by allowing plugins to set pause state directly.Setter is disabled in networked mode because it is not network-safe to call PauseToggle without extra stuff that the game action does perfectly well.