allow pause key to be changeable

This commit is contained in:
Anthony Samms
2025-11-17 21:54:29 -05:00
parent aeb0d12e25
commit 24e0c8d980
3 changed files with 3 additions and 1 deletions

View File

@@ -35,6 +35,7 @@ video_path = ['Videos']
exit_key = 'Q'
borderless_key = 'F10'
fullscreen_key = 'F11'
pause_key = "SPACE"
back_key = 'ESCAPE'
restart_key = 'F1'

View File

@@ -55,6 +55,7 @@ class KeysConfig(TypedDict):
exit_key: int
fullscreen_key: int
borderless_key: int
pause_key: int
back_key: int
restart_key: int

View File

@@ -240,7 +240,7 @@ class GameScreen(Screen):
audio.stop_music_stream(self.song_music)
return self.on_screen_end('SONG_SELECT')
if ray.is_key_pressed(ray.KeyboardKey.KEY_SPACE):
if ray.is_key_pressed(global_data.config["keys"]["pause_key"]):
self.pause_song()
def spawn_ending_anims(self):