Skip to content

Commit b81e1a2

Browse files
authored
The Messenger: Fix lambda capture issue in add_closed_portal_reqs (#5816)
1 parent 5899920 commit b81e1a2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

worlds/messenger/portals.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -306,4 +306,4 @@ def add_closed_portal_reqs(world: "MessengerWorld") -> None:
306306
closed_portals = [entrance for entrance in PORTALS if f"{entrance} Portal" not in world.starting_portals]
307307
for portal in closed_portals:
308308
tower_exit = world.multiworld.get_entrance(f"ToTHQ {portal} Portal", world.player)
309-
tower_exit.access_rule = lambda state: state.has(portal, world.player)
309+
tower_exit.access_rule = lambda state, portal_item=portal: state.has(portal_item, world.player)

0 commit comments

Comments
 (0)