diff options
author | Star Rauchenberger <fefferburbia@gmail.com> | 2025-10-22 19:27:09 -0400 |
---|---|---|
committer | Star Rauchenberger <fefferburbia@gmail.com> | 2025-10-22 19:27:09 -0400 |
commit | dcecbb87a19c47c7d00f773f8df6bf98d65410ef (patch) | |
tree | 9797c3eb1d5a9747d7106929a591468b7437472c /apworld/context.py | |
parent | 059f6426880d07b8d1d51eb681a33da0cbb60b63 (diff) | |
download | lingo2-archipelago-dcecbb87a19c47c7d00f773f8df6bf98d65410ef.tar.gz lingo2-archipelago-dcecbb87a19c47c7d00f773f8df6bf98d65410ef.tar.bz2 lingo2-archipelago-dcecbb87a19c47c7d00f773f8df6bf98d65410ef.zip |
Make icarus optional
Diffstat (limited to 'apworld/context.py')
-rw-r--r-- | apworld/context.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/apworld/context.py b/apworld/context.py index a0ee34d..d59bf9d 100644 --- a/apworld/context.py +++ b/apworld/context.py | |||
@@ -550,8 +550,11 @@ async def process_game_cmd(manager: Lingo2Manager, args: dict): | |||
550 | elif cmd == "CheckWorldport": | 550 | elif cmd == "CheckWorldport": |
551 | port_id = args["port_id"] | 551 | port_id = args["port_id"] |
552 | worldports = {port_id} | 552 | worldports = {port_id} |
553 | if str(port_id) in manager.client_ctx.slot_data["port_pairings"]: | 553 | |
554 | worldports.add(manager.client_ctx.slot_data["port_pairings"][str(port_id)]) | 554 | # Also check the reverse port if it's a two-way connection. |
555 | port_pairings = manager.client_ctx.slot_data["port_pairings"] | ||
556 | if str(port_id) in port_pairings and port_pairings.get(str(port_pairings[str(port_id)]), None) == port_id: | ||
557 | worldports.add(port_pairings[str(port_id)]) | ||
555 | 558 | ||
556 | updates = manager.update_worldports(worldports) | 559 | updates = manager.update_worldports(worldports) |
557 | if len(updates) > 0: | 560 | if len(updates) > 0: |