about summary refs log tree commit diff stats
path: root/Archipelago/settings_screen.gd
diff options
context:
space:
mode:
Diffstat (limited to 'Archipelago/settings_screen.gd')
-rw-r--r--Archipelago/settings_screen.gd11
1 files changed, 11 insertions, 0 deletions
diff --git a/Archipelago/settings_screen.gd b/Archipelago/settings_screen.gd index 890afaa..efd301e 100644 --- a/Archipelago/settings_screen.gd +++ b/Archipelago/settings_screen.gd
@@ -30,6 +30,7 @@ func _ready():
30 var apclient = global.get_node("Archipelago") 30 var apclient = global.get_node("Archipelago")
31 apclient.connect("client_connected", self, "connectionSuccessful") 31 apclient.connect("client_connected", self, "connectionSuccessful")
32 apclient.connect("could_not_connect", self, "connectionUnsuccessful") 32 apclient.connect("could_not_connect", self, "connectionUnsuccessful")
33 apclient.connect("connect_status", self, "connectionStatus")
33 34
34 # Populate textboxes with AP settings. 35 # Populate textboxes with AP settings.
35 self.get_node("Panel/server_box").text = apclient.ap_server 36 self.get_node("Panel/server_box").text = apclient.ap_server
@@ -70,6 +71,15 @@ func installScriptExtension(childScriptPath: String):
70 childScript.take_over_path(parentScriptPath) 71 childScript.take_over_path(parentScriptPath)
71 72
72 73
74func connectionStatus(message):
75 var popup = self.get_node("Panel/AcceptDialog")
76 popup.window_title = "Connecting to Archipelago"
77 popup.dialog_text = message
78 popup.popup_exclusive = true
79 popup.get_ok().visible = false
80 popup.popup_centered()
81
82
73func connectionSuccessful(): 83func connectionSuccessful():
74 var apclient = global.get_node("Archipelago") 84 var apclient = global.get_node("Archipelago")
75 85
@@ -87,4 +97,5 @@ func connectionUnsuccessful(error_message):
87 popup.window_title = "Could not connect to Archipelago" 97 popup.window_title = "Could not connect to Archipelago"
88 popup.dialog_text = error_message 98 popup.dialog_text = error_message
89 popup.popup_exclusive = true 99 popup.popup_exclusive = true
100 popup.get_ok().visible = true
90 popup.popup_centered() 101 popup.popup_centered()