[critical] toggle_settings_screen spawns second ModalScrim while another modal is open #10
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
File
solitaire_engine/src/settings_plugin.rslines 496–527Description
toggle_settings_screenflips a resource bool andsync_settings_panel_visibilityspawns when it becomes true, guarded only bypanels.is_empty(). It does not check whether any otherModalScrimis live. PressingOor dispatchingToggleSettingsRequestEventwhile a Home, Help, Pause, or Profile modal is open produces two concurrentModalScrimentities and two stacked full-screen overlays.The Settings panel additionally uses a custom
SettingsPanelmarker rather thanspawn_modal, soModalScrim-based guards in other systems cannot protect it.Fix
Add
scrims: Query<(), With<ModalScrim>>tosync_settings_panel_visibilityand skip spawning when!scrims.is_empty().