aboutsummaryrefslogtreecommitdiff
path: root/game
diff options
context:
space:
mode:
author hop311 <hop3114@gmail.com>2024-03-03 14:23:21 +0100
committer hop311 <hop3114@gmail.com>2024-03-03 14:29:30 +0100
commitd45d6270c8924f571b53d71ac8eb9ce5a7788255 (patch)
treea617e5ff1f417797330e9a81abb478700b602ec4 /game
parent9e305db5e5090a1a24979c480d64eebfe2de65da (diff)
ProgressBar, StyleBoxTexture, Icon tweaks + current dir install check fix
Diffstat (limited to 'game')
-rw-r--r--game/assets/localisation/locales/en_GB/menus.csv2
-rw-r--r--game/assets/localisation/locales/ru_RU/menus.csv2
-rw-r--r--game/src/Game/GameSession/MapControlPanel/MapControlPanel.tscn2
-rw-r--r--game/src/Game/GameSession/ProvinceOverviewPanel.gd5
-rw-r--r--game/src/Game/GameSession/Topbar.gd4
-rw-r--r--game/src/Game/GameStart.gd2
6 files changed, 7 insertions, 10 deletions
diff --git a/game/assets/localisation/locales/en_GB/menus.csv b/game/assets/localisation/locales/en_GB/menus.csv
index 67e3519..e488996 100644
--- a/game/assets/localisation/locales/en_GB/menus.csv
+++ b/game/assets/localisation/locales/en_GB/menus.csv
@@ -132,7 +132,7 @@ VIC2_DIR_DIALOG_SELECT;Select
VIC2_DIR_DIALOG_CANCEL;Cancel
;; Province Overview Panel
-province_MISSING;No Province
+PROV_MISSING;No Province
region_MISSING;No Region
LIFE_RATING_TOOLTIP;Liferating: {life_rating}
terrain_type_MISSING;No Terrain Type
diff --git a/game/assets/localisation/locales/ru_RU/menus.csv b/game/assets/localisation/locales/ru_RU/menus.csv
index 76605d3..4e96f82 100644
--- a/game/assets/localisation/locales/ru_RU/menus.csv
+++ b/game/assets/localisation/locales/ru_RU/menus.csv
@@ -108,7 +108,7 @@ DIALOG_SAVE_AND_RESIGN;Сохраниться и выйти в главное м
DIALOG_SAVE_AND_QUIT;Сохраниться и выйти из игры
;; Province Overview Panel
-province_MISSING;Нет провинции
+PROV_MISSING;Нет провинции
region_MISSING;Нет региона
LIFE_RATING_TOOLTIP;Уровень жизни: {life_rating}
rgo_MISSING;Нет ДП
diff --git a/game/src/Game/GameSession/MapControlPanel/MapControlPanel.tscn b/game/src/Game/GameSession/MapControlPanel/MapControlPanel.tscn
index 2bb62f1..6731358 100644
--- a/game/src/Game/GameSession/MapControlPanel/MapControlPanel.tscn
+++ b/game/src/Game/GameSession/MapControlPanel/MapControlPanel.tscn
@@ -40,7 +40,7 @@ alignment = 1
[node name="MapmodesGrid" type="GridContainer" parent="MapPanelMargin/MapPanelList/MapDisplayList"]
editor_description = "UI-750"
layout_mode = 2
-columns = 11
+columns = 7
[node name="Minimap" type="PanelContainer" parent="MapPanelMargin/MapPanelList/MapDisplayList"]
editor_description = "UI-549"
diff --git a/game/src/Game/GameSession/ProvinceOverviewPanel.gd b/game/src/Game/GameSession/ProvinceOverviewPanel.gd
index 32f9600..54591a3 100644
--- a/game/src/Game/GameSession/ProvinceOverviewPanel.gd
+++ b/game/src/Game/GameSession/ProvinceOverviewPanel.gd
@@ -251,8 +251,7 @@ func _update_info() -> void:
if _province_info:
# Header
if _province_name_label:
- _province_name_label.text = "PROV" + _province_info.get(_province_info_province_key,
- _province_info_province_key + _missing_suffix)
+ _province_name_label.text = GUINode.format_province_name(_province_info.get(_province_info_province_key, _missing_suffix))
if _region_name_label:
_region_name_label.text = _province_info.get(_province_info_region_key,
@@ -294,7 +293,7 @@ func _update_info() -> void:
push_error("Failed to set terrain type texture: ", terrain_type)
if _life_rating_bar:
- _life_rating_bar.value = _province_info.get(_province_info_life_rating_key, 0)
+ _life_rating_bar.value = _province_info.get(_province_info_life_rating_key, 0) / 100.0
if _controller_flag_texture:
_controller_flag_texture.set_flag_country_name(_province_info.get(_province_info_controller_key, ""))
diff --git a/game/src/Game/GameSession/Topbar.gd b/game/src/Game/GameSession/Topbar.gd
index e660c6a..82dd4d3 100644
--- a/game/src/Game/GameSession/Topbar.gd
+++ b/game/src/Game/GameSession/Topbar.gd
@@ -73,7 +73,7 @@ func _ready() -> void:
button.pressed.connect(
Events.NationManagementScreens.toggle_nation_management_screen.bind(screen)
)
- var icon : GFXSpriteTexture = get_gfx_sprite_texture_from_node(button)
+ var icon : GFXSpriteTexture = GUINode.get_gfx_sprite_texture_from_node(button)
if icon:
_nation_management_buttons[screen] = button
_nation_management_button_textures[screen] = icon
@@ -107,7 +107,6 @@ func _update_speed_controls() -> void:
if not GameSingleton.is_paused():
index += GameSingleton.get_speed() + 1
_speed_indicator_texture.set_icon_index(index)
- _speed_indicator_button.queue_redraw()
# REQUIREMENTS:
# * UIFUN-71
@@ -130,4 +129,3 @@ func _on_decrease_speed_button_pressed() -> void:
func _on_update_active_nation_management_screen(active_screen : NationManagement.Screen) -> void:
for screen in _nation_management_buttons:
_nation_management_button_textures[screen].set_icon_index(1 + int(screen == active_screen))
- _nation_management_buttons[screen].queue_redraw()
diff --git a/game/src/Game/GameStart.gd b/game/src/Game/GameStart.gd
index 0aadbb9..6074df8 100644
--- a/game/src/Game/GameStart.gd
+++ b/game/src/Game/GameStart.gd
@@ -70,7 +70,7 @@ func _setup_compatibility_mode_paths() -> void:
else:
# Check if the program is being run from inside the install directory,
# and if not also search for a Steam install
- actual_base_path = GameSingleton.search_for_game_path("..")
+ actual_base_path = GameSingleton.search_for_game_path(".")
if not actual_base_path:
get_tree().paused = true
vic2_dir_dialog.popup_centered_ratio()