diff options
author | hop311 <hop3114@gmail.com> | 2024-03-05 01:19:27 +0100 |
---|---|---|
committer | hop311 <hop3114@gmail.com> | 2024-03-05 10:36:47 +0100 |
commit | 444134a93bd5c704f5201ff30371dc81d0669e46 (patch) | |
tree | 851a3ad589bab71364d4c6adcb1ee30235abc2c7 /game/src/Game/GameSession/Topbar.gd | |
parent | eaae420cd2aca224d15f6276624c2fab882c978a (diff) |
Move GDExtension menu-related functions to MenuSingletonmenu-singleton
Diffstat (limited to 'game/src/Game/GameSession/Topbar.gd')
-rw-r--r-- | game/src/Game/GameSession/Topbar.gd | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/game/src/Game/GameSession/Topbar.gd b/game/src/Game/GameSession/Topbar.gd index b61af28..92ee75a 100644 --- a/game/src/Game/GameSession/Topbar.gd +++ b/game/src/Game/GameSession/Topbar.gd @@ -91,40 +91,40 @@ func _notification(what : int) -> void: func _update_info() -> void: if _date_label: - _date_label.text = GameSingleton.get_longform_date() + _date_label.text = MenuSingleton.get_longform_date() func _update_speed_controls() -> void: # TODO - decide whether to disable these or not # (they don't appear to get disabled in the base game) #if _speed_up_button: - # _speed_up_button.disabled = not GameSingleton.can_increase_speed() + # _speed_up_button.disabled = not MenuSingleton.can_increase_speed() #if _speed_down_button: - # _speed_down_button.disabled = not GameSingleton.can_decrease_speed() + # _speed_down_button.disabled = not MenuSingleton.can_decrease_speed() if _speed_indicator_button and _speed_indicator_texture: var index : int = 1 - if not GameSingleton.is_paused(): - index += GameSingleton.get_speed() + 1 + if not MenuSingleton.is_paused(): + index += MenuSingleton.get_speed() + 1 _speed_indicator_texture.set_icon_index(index) # REQUIREMENTS: # * UIFUN-71 func _on_play_pause_button_pressed() -> void: print("Toggling pause!") - GameSingleton.toggle_paused() + MenuSingleton.toggle_paused() # REQUIREMENTS: # * UIFUN-72 func _on_increase_speed_button_pressed() -> void: print("Speed up!") - GameSingleton.increase_speed() + MenuSingleton.increase_speed() # REQUIREMENTS: # * UIFUN-73 func _on_decrease_speed_button_pressed() -> void: print("Speed down!") - GameSingleton.decrease_speed() + MenuSingleton.decrease_speed() func _on_update_active_nation_management_screen(active_screen : NationManagement.Screen) -> void: for screen : NationManagement.Screen in _nation_management_buttons: |