summaryrefslogtreecommitdiff
path: root/client
diff options
context:
space:
mode:
Diffstat (limited to 'client')
-rw-r--r--client/global.gd4
-rw-r--r--client/menu/play.gd2
-rw-r--r--client/menu/setup.gd3
3 files changed, 6 insertions, 3 deletions
diff --git a/client/global.gd b/client/global.gd
index 59cc91de..b678f391 100644
--- a/client/global.gd
+++ b/client/global.gd
@@ -169,7 +169,6 @@ func set_profile(key: String, value):
return
if profile[key] != value:
profile[key] = value
- save_profile()
func set_hint(key: String, value: bool):
if !profile["hints"].has(key):
@@ -177,8 +176,9 @@ func set_hint(key: String, value: bool):
if profile["hints"][key] != value:
if value:
set_setting("tutorial_started", true)
+ save_settings()
profile["hints"][key] = value
- save_profile()
+ save_profile() # TODO avoid this call when bulk-unsetting hints
func get_hint(key: String):
if profile["hints"].has(key):
diff --git a/client/menu/play.gd b/client/menu/play.gd
index ded22f9a..ee35975e 100644
--- a/client/menu/play.gd
+++ b/client/menu/play.gd
@@ -46,9 +46,9 @@ func _on_connect_pressed():
url = url + ":27032"
connect_uri.text = url
Global.set_profile("last_server_url", url)
+ Global.save_profile()
connect_to(url)
-
func _on_quick_connect_pressed():
if OS.has_feature("web"):
connect_to(JavaScriptBridge.eval("""
diff --git a/client/menu/setup.gd b/client/menu/setup.gd
index c87e0112..0622d550 100644
--- a/client/menu/setup.gd
+++ b/client/menu/setup.gd
@@ -72,6 +72,9 @@ func _on_sign_pressed():
Global.set_profile("username", username.text)
Global.set_profile("character", character)
+ Global.save_profile()
Global.set_setting("gameplay.setup_completed", true)
+ Global.save_settings()
+
replace_menu("res://menu/main.tscn")