diff options
Diffstat (limited to 'Archipelago/client.gd')
| -rw-r--r-- | Archipelago/client.gd | 14 |
1 files changed, 9 insertions, 5 deletions
| diff --git a/Archipelago/client.gd b/Archipelago/client.gd index bb6d0a2..f805577 100644 --- a/Archipelago/client.gd +++ b/Archipelago/client.gd | |||
| @@ -98,10 +98,15 @@ func _ready(): | |||
| 98 | _client.connect("data_received", self, "_on_data") | 98 | _client.connect("data_received", self, "_on_data") |
| 99 | 99 | ||
| 100 | 100 | ||
| 101 | func _errored(): | 101 | func _reset_state(): |
| 102 | global._print("AP connection failed") | ||
| 103 | _should_process = false | 102 | _should_process = false |
| 104 | _authenticated = false | 103 | _authenticated = false |
| 104 | _map_loaded = false | ||
| 105 | |||
| 106 | |||
| 107 | func _errored(): | ||
| 108 | global._print("AP connection failed") | ||
| 109 | _reset_state() | ||
| 105 | 110 | ||
| 106 | emit_signal( | 111 | emit_signal( |
| 107 | "could_not_connect", | 112 | "could_not_connect", |
| @@ -109,10 +114,9 @@ func _errored(): | |||
| 109 | ) | 114 | ) |
| 110 | 115 | ||
| 111 | 116 | ||
| 112 | func _closed(): | 117 | func _closed(_was_clean = true): |
| 113 | global._print("Connection closed") | 118 | global._print("Connection closed") |
| 114 | _should_process = false | 119 | _reset_state() |
| 115 | _authenticated = false | ||
| 116 | 120 | ||
| 117 | if not _initiated_disconnect: | 121 | if not _initiated_disconnect: |
| 118 | emit_signal("could_not_connect", "Disconnected from Archipelago") | 122 | emit_signal("could_not_connect", "Disconnected from Archipelago") |
