Skip to content

Add the "Settings dialog" example - #1149

Merged
4ian merged 5 commits into
mainfrom
settings-dialog
Dec 2, 2026
Merged

4ian merged 5 commits into
mainfrom
settings-dialog

Conversation

@4ian

@4ian 4ian commented Dec 2, 2026 •

Copy link
Copy Markdown
Contributor

Add the Settings dialog example showcasing the SettingsDialog extension (GDevelop-extensions#2401):

  • Full tabbed Settings Dialog (Jelly Pop style) with General (Master volume, Music volume, Sound effects toggle, Difficulty changing star orbit speed), Gameplay (Screen shake toggle, Show hints toggle, Camera zoom slider), and Display (Color theme changing the background live, Show FPS toggle) tabs.
  • Compact Settings Dialog (Hologram style) auto-shrunk to 3 quick settings (master, sfx, theme) sharing the same StorageName (SettingsDialogExample) so both dialogs stay automatically in sync without manual copy-back.
  • Single source of truth: scene events read active values via SettingsDialog::NumberValue, SettingsDialog::ChoiceValue, and SettingsDialog::IsToggleOn (which also work in any other scene).
  • Pause integration: opening Settings from PauseDialog while the game is paused (TimeScale = 0), and closing Settings with Escape without re-opening Pause.
  • Auto-save & Reset to defaults: changes merge-save to device storage and persist across scene reload; Reset to defaults restores everything.
  • Full mouse, touch, keyboard, and gamepad navigation.

Settings dialog example

Tests

Three gameplay tests in examples/settings-dialog/settings-dialog.json pass in GDevelop 5.6.287:

  • Full settings dialog with keyboard, live scene changes (SetGlobalVolume, SceneBackground, orbit speed, FPS badge), and Reset to defaults.
  • Opening Settings from PauseDialog while paused (TimeScale = 0) and verifying device-storage persistence across scene reload.
  • Shared source-of-truth sync between Settings and QuickSettings with simulated gamepad (navigator.getGamepads): changing theme and volume in Settings, opening QuickSettings with synced values, adjusting volume without losing theme, and verifying Settings reflects the updated volume.

npx jest scripts/ passes (99/99).

@github-actions

github-actions Bot commented Dec 2, 2026

Copy link
Copy Markdown
Contributor

Preview the game(s) changed or added in this Pull Request


This is an automatic message displaying links to the games in this PR - double check the JSON in case of doubt.

@4ian
4ian merged commit 1533575 into main Dec 2, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant