aboutsummaryrefslogtreecommitdiff
path: root/game/src/Game/Menu/OptionMenu/OptionsMenu.gd
diff options
context:
space:
mode:
author Hop311 <hop3114@gmail.com>2023-06-10 21:48:17 +0200
committer Hop311 <hop3114@gmail.com>2023-06-23 22:33:15 +0200
commit206cafc8bba310e4d4f35f4898ef3ac289abe81a (patch)
treea662b03f0f3af03b0892e2c9987c4ae128e5790f /game/src/Game/Menu/OptionMenu/OptionsMenu.gd
parent6e26b948ea2a7632bcb7b795fe78f7169477eb6a (diff)
Localisation and UI focus cleanup
Updated Russian localisation Resolution, window_mode, monitor refactor Locale based number formatting
Diffstat (limited to 'game/src/Game/Menu/OptionMenu/OptionsMenu.gd')
-rw-r--r--game/src/Game/Menu/OptionMenu/OptionsMenu.gd12
1 files changed, 10 insertions, 2 deletions
diff --git a/game/src/Game/Menu/OptionMenu/OptionsMenu.gd b/game/src/Game/Menu/OptionMenu/OptionsMenu.gd
index 5f6a088..c74c458 100644
--- a/game/src/Game/Menu/OptionMenu/OptionsMenu.gd
+++ b/game/src/Game/Menu/OptionMenu/OptionsMenu.gd
@@ -5,9 +5,17 @@ extends Control
signal back_button_pressed
+@export var _tab_container : TabContainer
+
func _ready():
+ _tab_container.set_tab_title(0, "OPTIONS_GENERAL")
+ _tab_container.set_tab_title(1, "OPTIONS_VIDEO")
+ _tab_container.set_tab_title(2, "OPTIONS_SOUND")
+ _tab_container.set_tab_title(3, "OPTIONS_CONTROLS")
+ _tab_container.set_tab_title(4, "OPTIONS_OTHER")
+
# Prepare options menu before loading user settings
- var tab_bar : TabBar = $Margin/Tab.get_child(0, true)
+ var tab_bar : TabBar = _tab_container.get_child(0, true)
# This ends up easier to manage then trying to manually recreate the TabContainer's behavior
# These buttons can be accessed regardless of the tab
@@ -60,7 +68,7 @@ func _save_overrides() -> void:
var file := ConfigFile.new()
var err_ret := file.load(override_path)
if err_ret != OK: push_error("Failed to load overrides from %s" % override_path)
- file.set_value("display", "window/size/mode", get_viewport().get_window().mode)
+ file.set_value("display", "window/size/mode", Resolution.get_current_window_mode())
var resolution : Vector2i = Resolution.get_current_resolution()
file.set_value("display", "window/size/viewport_width", resolution.x)
file.set_value("display", "window/size/viewport_height", resolution.y)