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/painting_eye.gd | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) (limited to 'Archipelago/painting_eye.gd') diff --git a/Archipelago/painting_eye.gd b/Archipelago/painting_eye.gd index 53d42b5..c6994b1 100644 --- a/Archipelago/painting_eye.gd +++ b/Archipelago/painting_eye.gd @@ -3,9 +3,23 @@ extends "res://scripts/painting_eye.gd" func _answer_correct(): var apclient = global.get_node("Archipelago") - if not apclient._door_shuffle or apclient.paintingIsVanilla(self.name): + if get_name() == "pilgrim_painting2": + # When pilgrimage is enabled, the HOT CRUST panel should actually move the sun painting. + if apclient._pilgrimage_enabled: + movePainting() + elif not apclient._door_shuffle or apclient.paintingIsVanilla(self.name): ._answer_correct() func movePainting(): ._answer_correct() + + +func _looked_at(var body, var painting): + ._looked_at(body, painting) + + if body.is_in_group("player") && (painting.get_name() == self.get_name()): + var apclient = global.get_node("Archipelago") + if !apclient._pilgrimage_allows_paintings: + global.sunwarp = 1 + body.get_node("pivot/camera/sunwarp_background").visible = false -- cgit 1.4.1 From e33ba8444d965ed903a0ca87d2824af334c4cdd9 Mon Sep 17 00:00:00 2001 From: Star Rauchenberger Date: Thu, 18 Apr 2024 16:38:15 -0400 Subject: Backwards compatibility with 0.4.5 --- Archipelago/client.gd | 12 ++++++++++++ Archipelago/painting_eye.gd | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) (limited to 'Archipelago/painting_eye.gd') diff --git a/Archipelago/client.gd b/Archipelago/client.gd index 13a7635..896673a 100644 --- a/Archipelago/client.gd +++ b/Archipelago/client.gd @@ -136,6 +136,7 @@ var _mastery_achievements = 21 var _level_2_requirement = 223 var _location_classification_bit = 0 var _early_color_hallways = false +var _pilgrimage_compatibility = false # set to true for pre-0.4.6 var _pilgrimage_enabled = false var _pilgrimage_allows_roof_access = false var _pilgrimage_allows_paintings = false @@ -313,6 +314,8 @@ func _on_data(): _panel_shuffle = _slot_data["shuffle_panels"] if _slot_data.has("sunwarp_access"): _sunwarp_access = _slot_data["sunwarp_access"] + else: + _sunwarp_access = kSUNWARP_ACCESS_NORMAL if _slot_data.has("seed"): _slot_seed = _slot_data["seed"] if _slot_data.has("painting_entrance_to_exit"): @@ -332,12 +335,21 @@ func _on_data(): _early_color_hallways = _slot_data["early_color_hallways"] if _slot_data.has("enable_pilgrimage"): _pilgrimage_enabled = _slot_data["enable_pilgrimage"] + else: + _pilgrimage_compatibility = true + _pilgrimage_enabled = true if _slot_data.has("pilgrimage_allows_roof_access"): _pilgrimage_allows_roof_access = _slot_data["pilgrimage_allows_roof_access"] + else: + _pilgrimage_allows_roof_access = true if _slot_data.has("pilgrimage_allows_paintings"): _pilgrimage_allows_paintings = _slot_data["pilgrimage_allows_paintings"] + else: + _pilgrimage_allows_paintings = true if _slot_data.has("shuffle_sunwarps"): _sunwarp_shuffle = _slot_data["shuffle_sunwarps"] + else: + _sunwarp_shuffle = false if _slot_data.has("sunwarp_permutation"): _sunwarp_mapping = _slot_data["sunwarp_permutation"] diff --git a/Archipelago/painting_eye.gd b/Archipelago/painting_eye.gd index c6994b1..b2e6973 100644 --- a/Archipelago/painting_eye.gd +++ b/Archipelago/painting_eye.gd @@ -3,7 +3,7 @@ extends "res://scripts/painting_eye.gd" func _answer_correct(): var apclient = global.get_node("Archipelago") - if get_name() == "pilgrim_painting2": + if !apclient._pilgrimage_compatibility and get_name() == "pilgrim_painting2": # When pilgrimage is enabled, the HOT CRUST panel should actually move the sun painting. if apclient._pilgrimage_enabled: movePainting() -- cgit 1.4.1