Skip to content

Commit 97b2d26

Browse files
NewSoupViMagnemania
authored andcommitted
The Witness: Fix Logic Error for Keep Pressure Plates 2 EP in puzzle_randomization: none (ArchipelagoMW#2515)
1 parent 4d1300c commit 97b2d26

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

worlds/witness/WitnessLogicVanilla.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -430,7 +430,7 @@ Door - 0x04F8F (Tower Shortcut) - 0x0361B
430430
158705 - 0x03317 (Laser Panel Pressure Plates) - 0x033EA & 0x01BE9 & 0x01CD3 & 0x01D3F - Dots & Shapers & Black/White Squares & Rotated Shapers
431431
Laser - 0x014BB (Laser) - 0x0360E | 0x03317
432432
159240 - 0x033BE (Pressure Plates 1 EP) - 0x033EA - True
433-
159241 - 0x033BF (Pressure Plates 2 EP) - 0x01BE9 - True
433+
159241 - 0x033BF (Pressure Plates 2 EP) - 0x01BE9 & 0x01BEA - True
434434
159242 - 0x033DD (Pressure Plates 3 EP) - 0x01CD3 & 0x01CD5 - True
435435
159243 - 0x033E5 (Pressure Plates 4 Left Exit EP) - 0x01D3F - True
436436
159244 - 0x018B6 (Pressure Plates 4 Right Exit EP) - 0x01D3F - True

worlds/witness/items.py

+4-1
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,7 @@ def __init__(self, world: "WitnessWorld", logic: WitnessPlayerLogic, locat: Witn
115115
# Adjust item classifications based on game settings.
116116
eps_shuffled = self._world.options.shuffle_EPs
117117
come_to_you = self._world.options.elevators_come_to_you
118+
difficulty = self._world.options.puzzle_randomization
118119
for item_name, item_data in self.item_data.items():
119120
if not eps_shuffled and item_name in {"Monastery Garden Entry (Door)",
120121
"Monastery Shortcuts",
@@ -130,10 +131,12 @@ def __init__(self, world: "WitnessWorld", logic: WitnessPlayerLogic, locat: Witn
130131
"Monastery Laser Shortcut (Door)",
131132
"Orchard Second Gate (Door)",
132133
"Jungle Bamboo Laser Shortcut (Door)",
133-
"Keep Pressure Plates 2 Exit (Door)",
134134
"Caves Elevator Controls (Panel)"}:
135135
# Downgrade doors that don't gate progress.
136136
item_data.classification = ItemClassification.useful
137+
elif item_name == "Keep Pressure Plates 2 Exit (Door)" and not (difficulty == "none" and eps_shuffled):
138+
# PP2EP requires the door in vanilla puzzles, otherwise it's unnecessary
139+
item_data.classification = ItemClassification.useful
137140

138141
# Build the mandatory item list.
139142
self._mandatory_items: Dict[str, int] = {}

0 commit comments

Comments
 (0)