From 4d2da5afe6a3ffad50ca5560c1dcceaddde2b9b0 Mon Sep 17 00:00:00 2001 From: Star Rauchenberger Date: Wed, 28 Feb 2024 12:35:45 -0500 Subject: Add pilgrimage allows roof access / paintings --- Archipelago/settings_screen.gd | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Archipelago/settings_screen.gd') diff --git a/Archipelago/settings_screen.gd b/Archipelago/settings_screen.gd index 0ae218e..1a1f5cc 100644 --- a/Archipelago/settings_screen.gd +++ b/Archipelago/settings_screen.gd @@ -24,6 +24,9 @@ func _ready(): apclient_instance.SCRIPT_mypainting = load("user://maps/Archipelago/mypainting.gd") apclient_instance.SCRIPT_notifier = load("user://maps/Archipelago/notifier.gd") apclient_instance.SCRIPT_panel = load("user://maps/Archipelago/panel.gd") + apclient_instance.SCRIPT_pilgrimage_terminator = load( + "user://maps/Archipelago/pilgrimage_terminator.gd" + ) apclient_instance.SCRIPT_uuid = load("user://maps/Archipelago/vendor/uuid.gd") var apdata = ResourceLoader.load("user://maps/Archipelago/gamedata.gd") @@ -39,6 +42,7 @@ func _ready(): # Let's also inject any scripts we need to inject now. installScriptExtension(apclient_instance.SCRIPT_doorControl) installScriptExtension(ResourceLoader.load("user://maps/Archipelago/load.gd")) + installScriptExtension(ResourceLoader.load("user://maps/Archipelago/painting.gd")) installScriptExtension(ResourceLoader.load("user://maps/Archipelago/painting_eye.gd")) installScriptExtension(ResourceLoader.load("user://maps/Archipelago/painting_scenery.gd")) installScriptExtension(ResourceLoader.load("user://maps/Archipelago/panelLevelSwitch.gd")) -- cgit 1.4.1 From 7bd48794b4aee542566eea1dce10adcb57f31b20 Mon Sep 17 00:00:00 2001 From: Star Rauchenberger Date: Sun, 17 Mar 2024 14:41:12 -0400 Subject: Fixed pilgrimage terminator load for compile --- Archipelago/settings_screen.gd | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'Archipelago/settings_screen.gd') diff --git a/Archipelago/settings_screen.gd b/Archipelago/settings_screen.gd index 1a1f5cc..1be32d9 100644 --- a/Archipelago/settings_screen.gd +++ b/Archipelago/settings_screen.gd @@ -24,9 +24,7 @@ func _ready(): apclient_instance.SCRIPT_mypainting = load("user://maps/Archipelago/mypainting.gd") apclient_instance.SCRIPT_notifier = load("user://maps/Archipelago/notifier.gd") apclient_instance.SCRIPT_panel = load("user://maps/Archipelago/panel.gd") - apclient_instance.SCRIPT_pilgrimage_terminator = load( - "user://maps/Archipelago/pilgrimage_terminator.gd" - ) + apclient_instance.SCRIPT_pilgrimage_terminator = load("user://maps/Archipelago/pilgrimage_terminator.gd") apclient_instance.SCRIPT_uuid = load("user://maps/Archipelago/vendor/uuid.gd") var apdata = ResourceLoader.load("user://maps/Archipelago/gamedata.gd") -- cgit 1.4.1 From ce831897b89974f38fd6f0583e5feac178643a14 Mon Sep 17 00:00:00 2001 From: Star Rauchenberger Date: Wed, 17 Apr 2024 12:30:18 -0400 Subject: Add connection history --- Archipelago/client.gd | 6 +++++- Archipelago/settings_screen.gd | 31 +++++++++++++++++++++++++++++++ archipelago.tscn | 25 +++++++++++++++++-------- 3 files changed, 53 insertions(+), 9 deletions(-) (limited to 'Archipelago/settings_screen.gd') diff --git a/Archipelago/client.gd b/Archipelago/client.gd index f15afe6..489fdb9 100644 --- a/Archipelago/client.gd +++ b/Archipelago/client.gd @@ -15,6 +15,7 @@ var ap_pass = "" var confusify_world = false var enable_multiplayer = false var track_player = false +var connection_history = [] const my_version = "2.1.1" const ap_version = {"major": 0, "minor": 4, "build": 5, "class": "Version"} @@ -161,6 +162,8 @@ func _init(): enable_multiplayer = data[5] if data.size() > 6: track_player = data[6] + if data.size() > 7: + connection_history = data[7] processDatapackages() @@ -485,7 +488,8 @@ func saveSettings(): _datapackages, confusify_world, enable_multiplayer, - track_player + track_player, + connection_history ] file.store_var(data, true) file.close() diff --git a/Archipelago/settings_screen.gd b/Archipelago/settings_screen.gd index de64214..453e3bf 100644 --- a/Archipelago/settings_screen.gd +++ b/Archipelago/settings_screen.gd @@ -67,6 +67,19 @@ func _ready(): self.get_node("Panel/multiplayer_box").pressed = apclient.enable_multiplayer self.get_node("Panel/position_box").pressed = apclient.track_player + var history_box = get_node("Panel/connection_history") + if apclient.connection_history.empty(): + history_box.disabled = true + else: + history_box.disabled = false + + var i = 0 + for details in apclient.connection_history: + history_box.get_popup().add_item("%s (%s)" % [details[1], details[0]], i) + i += 1 + + history_box.get_popup().connect("id_pressed", self, "historySelected") + # Show client version. self.get_node("Panel/title").text = "ARCHIPELAGO (%s)" % apclient.my_version @@ -109,6 +122,15 @@ func connectionStatus(message): func connectionSuccessful(): var apclient = global.get_node("Archipelago") + # Save connection details + var connection_details = [apclient.ap_server, apclient.ap_user, apclient.ap_pass] + if apclient.connection_history.has(connection_details): + apclient.connection_history.erase(connection_details) + apclient.connection_history.push_front(connection_details) + if apclient.connection_history.size() > 10: + apclient.connection_history.resize(10) + apclient.saveSettings() + # Switch to LL1 Input.set_mouse_mode(Input.MOUSE_MODE_CAPTURED) global.save_file = apclient.getSaveFileName() @@ -130,3 +152,12 @@ func connectionUnsuccessful(error_message): popup.popup_exclusive = true popup.get_ok().visible = true popup.popup_centered() + + +func historySelected(index): + var apclient = global.get_node("Archipelago") + var details = apclient.connection_history[index] + + self.get_node("Panel/server_box").text = details[0] + self.get_node("Panel/player_box").text = details[1] + self.get_node("Panel/password_box").text = details[2] diff --git a/archipelago.tscn b/archipelago.tscn index f0b8ab9..f063af9 100644 --- a/archipelago.tscn +++ b/archipelago.tscn @@ -86,9 +86,9 @@ align = 2 [node name="credit5" parent="Panel" instance=ExtResource( 1 )] margin_left = 1239.0 -margin_top = 271.0 +margin_top = 422.0 margin_right = 1829.0 -margin_bottom = 335.0 +margin_bottom = 486.0 custom_fonts/font = ExtResource( 2 ) custom_styles/normal = SubResource( 1 ) text = "OPTIONS" @@ -155,9 +155,9 @@ margin_bottom = 58.0 [node name="confusing_box" type="CheckBox" parent="Panel"] margin_left = 1227.0 -margin_top = 351.0 +margin_top = 502.0 margin_right = 1832.0 -margin_bottom = 439.0 +margin_bottom = 590.0 custom_fonts/font = ExtResource( 6 ) custom_icons/checked = ExtResource( 8 ) custom_icons/unchecked = ExtResource( 7 ) @@ -165,9 +165,9 @@ text = "Make world more confusing" [node name="multiplayer_box" type="CheckBox" parent="Panel"] margin_left = 1227.0 -margin_top = 461.0 +margin_top = 612.0 margin_right = 1832.0 -margin_bottom = 549.0 +margin_bottom = 700.0 custom_fonts/font = ExtResource( 6 ) custom_icons/checked = ExtResource( 8 ) custom_icons/unchecked = ExtResource( 7 ) @@ -175,13 +175,22 @@ text = "Show other players" [node name="position_box" type="CheckBox" parent="Panel"] margin_left = 1227.0 -margin_top = 571.0 +margin_top = 722.0 margin_right = 1832.0 -margin_bottom = 654.0 +margin_bottom = 810.0 custom_fonts/font = ExtResource( 6 ) custom_icons/checked = ExtResource( 8 ) custom_icons/unchecked = ExtResource( 7 ) text = "Send position to tracker" +[node name="connection_history" type="MenuButton" parent="Panel"] +margin_left = 1239.0 +margin_top = 276.0 +margin_right = 1829.0 +margin_bottom = 372.0 +custom_fonts/font = ExtResource( 6 ) +text = "connection history" +flat = false + [connection signal="pressed" from="Panel/connect_button" to="Panel/connect_button" method="_connect_pressed"] [connection signal="pressed" from="Panel/quit_button" to="Panel/quit_button" method="_back_pressed"] -- cgit 1.4.1 From 7c4d3b1dcee861c4fb4db2805e008e4d3f8d3b21 Mon Sep 17 00:00:00 2001 From: Star Rauchenberger Date: Thu, 18 Apr 2024 18:19:51 -0400 Subject: Prevent pilgrimage_terminator reformatting issue --- Archipelago/settings_screen.gd | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Archipelago/settings_screen.gd') diff --git a/Archipelago/settings_screen.gd b/Archipelago/settings_screen.gd index bf2c78f..79fdcc3 100644 --- a/Archipelago/settings_screen.gd +++ b/Archipelago/settings_screen.gd @@ -30,7 +30,8 @@ func _ready(): apclient_instance.SCRIPT_mypainting = load("user://maps/Archipelago/mypainting.gd") apclient_instance.SCRIPT_notifier = load("user://maps/Archipelago/notifier.gd") apclient_instance.SCRIPT_panel = load("user://maps/Archipelago/panel.gd") - apclient_instance.SCRIPT_pilgrimage_terminator = load("user://maps/Archipelago/pilgrimage_terminator.gd") + var pilg_term = load("user://maps/Archipelago/pilgrimage_terminator.gd") + apclient_instance.SCRIPT_pilgrimage_terminator = pilg_term apclient_instance.SCRIPT_uuid = load("user://maps/Archipelago/vendor/uuid.gd") var apdata = ResourceLoader.load("user://maps/Archipelago/gamedata.gd") -- cgit 1.4.1