diff options
author | Star Rauchenberger <fefferburbia@gmail.com> | 2023-04-29 15:30:00 -0400 |
---|---|---|
committer | Star Rauchenberger <fefferburbia@gmail.com> | 2023-04-29 15:30:00 -0400 |
commit | 357e2f63581f606a032ce8886bc7137a50963aa1 (patch) | |
tree | f9f927e826ebc67c8cb2305a64c0c9f284a37698 /Archipelago/settings_screen.gd | |
parent | b393c9d6772c13177fd575cda8c76d96afc178d2 (diff) | |
download | lingo-archipelago-357e2f63581f606a032ce8886bc7137a50963aa1.tar.gz lingo-archipelago-357e2f63581f606a032ce8886bc7137a50963aa1.tar.bz2 lingo-archipelago-357e2f63581f606a032ce8886bc7137a50963aa1.zip |
Provide status updates on the connection process
Diffstat (limited to 'Archipelago/settings_screen.gd')
-rw-r--r-- | Archipelago/settings_screen.gd | 11 |
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 | ||
74 | func 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 | |||
73 | func connectionSuccessful(): | 83 | func 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() |