-
-
Notifications
You must be signed in to change notification settings - Fork 4.4k
Fix FPS overlay system ordering ambiguity #22629
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
Fix FPS overlay system ordering ambiguity #22629
Conversation
|
Welcome, new contributor! Please make sure you've read our contributing guide and we look forward to reviewing your pull request shortly ✨ |
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.
Tried this with the fps_overlay example but still got a reported conflict with update_time_values over FpsOverlayConfig.
FpsOverlaySystems::Customize should be scheduled before update_time_values as well, I guess?
|
Good catch, thanks! Pushed a follow-up that adds update_frame_time_values to UpdateText as well - tested with the example and the conflict seems to be resolved now. |
ickshonpe
left a comment
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.
No more conflicts, looks good!
| .add_systems(Update, update_frame_time_values); | ||
| .add_systems( | ||
| Update, | ||
| update_frame_time_values.in_set(FpsOverlaySystems::UpdateText), |
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.
I don't think there are any remaining problems, but I'm a bit unclear as to whether FrameTimeGraphPlugin is meant to be able to run independently of FpsOverlayPlugin or not. I guess it doesn't matter for this PR.
Objective
Fixes #22571
Solution
Added
FpsOverlaySystemssystem set and explicitly orderedcustomize_overlayto run beforeupdate_text. This gets rid of the internal ambiguity warnings and also gives users a way to order their own systems against the overlay.Testing
Ran locally with ambiguity warnings enabled - no more internal overlay warnings. Didn't add a unit test since scheduling order is tricky to test in isolation.
To verify:
ScheduleBuildSettingsambiguity warnings.TextUiWriter.FpsOverlayPluginand confirm no overlay-related ambiguity warnings.