summary refs log tree commit diff stats
path: root/static_logic.py
diff options
context:
space:
mode:
Diffstat (limited to 'static_logic.py')
-rw-r--r--static_logic.py15
1 files changed, 14 insertions, 1 deletions
diff --git a/static_logic.py b/static_logic.py index d122169..f6690f9 100644 --- a/static_logic.py +++ b/static_logic.py
@@ -63,6 +63,8 @@ class Painting(NamedTuple):
63 required_door: Optional[RoomAndDoor] 63 required_door: Optional[RoomAndDoor]
64 disable: bool 64 disable: bool
65 move: bool 65 move: bool
66 req_blocked: bool
67 req_blocked_when_no_doors: bool
66 68
67 69
68class Progression(NamedTuple): 70class Progression(NamedTuple):
@@ -471,6 +473,16 @@ def process_painting(room_name, painting_data):
471 else: 473 else:
472 enter_only = False 474 enter_only = False
473 475
476 if "req_blocked" in painting_data:
477 req_blocked = painting_data["req_blocked"]
478 else:
479 req_blocked = False
480
481 if "req_blocked_when_no_doors" in painting_data:
482 req_blocked_when_no_doors = painting_data["req_blocked_when_no_doors"]
483 else:
484 req_blocked_when_no_doors = False
485
474 required_door = None 486 required_door = None
475 if "required_door" in painting_data: 487 if "required_door" in painting_data:
476 door = painting_data["required_door"] 488 door = painting_data["required_door"]
@@ -480,7 +492,8 @@ def process_painting(room_name, painting_data):
480 ) 492 )
481 493
482 painting_obj = Painting(painting_id, room_name, enter_only, exit_only, orientation, 494 painting_obj = Painting(painting_id, room_name, enter_only, exit_only, orientation,
483 required_painting, rwnd, required_door, disable_painting, move_painting) 495 required_painting, rwnd, required_door, disable_painting, move_painting, req_blocked,
496 req_blocked_when_no_doors)
484 PAINTINGS[painting_id] = painting_obj 497 PAINTINGS[painting_id] = painting_obj
485 PAINTINGS_BY_ROOM[room_name].append(painting_obj) 498 PAINTINGS_BY_ROOM[room_name].append(painting_obj)
486 499