diff options
Diffstat (limited to 'apworld/__init__.py')
| -rw-r--r-- | apworld/__init__.py | 13 |
1 files changed, 11 insertions, 2 deletions
| diff --git a/apworld/__init__.py b/apworld/__init__.py index 4ebf845..3d2f075 100644 --- a/apworld/__init__.py +++ b/apworld/__init__.py | |||
| @@ -77,7 +77,10 @@ class Lingo2World(World): | |||
| 77 | if self.options.shuffle_worldports: | 77 | if self.options.shuffle_worldports: |
| 78 | if hasattr(self.multiworld, "re_gen_passthrough") and "Lingo 2" in self.multiworld.re_gen_passthrough: | 78 | if hasattr(self.multiworld, "re_gen_passthrough") and "Lingo 2" in self.multiworld.re_gen_passthrough: |
| 79 | slot_value = self.multiworld.re_gen_passthrough["Lingo 2"]["port_pairings"] | 79 | slot_value = self.multiworld.re_gen_passthrough["Lingo 2"]["port_pairings"] |
| 80 | self.port_pairings = {int(fp): int(tp) for fp, tp in slot_value.items()} | 80 | self.port_pairings = { |
| 81 | self.static_logic.port_id_by_ap_id[int(fp)]: self.static_logic.port_id_by_ap_id[int(tp)] | ||
| 82 | for fp, tp in slot_value.items() | ||
| 83 | } | ||
| 81 | 84 | ||
| 82 | connect_ports_from_ut(self.port_pairings, self) | 85 | connect_ports_from_ut(self.port_pairings, self) |
| 83 | else: | 86 | else: |
| @@ -132,7 +135,9 @@ class Lingo2World(World): | |||
| 132 | "daedalus_roof_access", | 135 | "daedalus_roof_access", |
| 133 | "enable_gift_maps", | 136 | "enable_gift_maps", |
| 134 | "enable_icarus", | 137 | "enable_icarus", |
| 138 | "endings_requirement", | ||
| 135 | "keyholder_sanity", | 139 | "keyholder_sanity", |
| 140 | "masteries_requirement", | ||
| 136 | "shuffle_control_center_colors", | 141 | "shuffle_control_center_colors", |
| 137 | "shuffle_doors", | 142 | "shuffle_doors", |
| 138 | "shuffle_gallery_paintings", | 143 | "shuffle_gallery_paintings", |
| @@ -150,7 +155,11 @@ class Lingo2World(World): | |||
| 150 | } | 155 | } |
| 151 | 156 | ||
| 152 | if self.options.shuffle_worldports: | 157 | if self.options.shuffle_worldports: |
| 153 | slot_data["port_pairings"] = self.port_pairings | 158 | def get_port_ap_id(port_id): |
| 159 | return self.static_logic.objects.ports[port_id].ap_id | ||
| 160 | |||
| 161 | slot_data["port_pairings"] = {get_port_ap_id(from_id): get_port_ap_id(to_id) | ||
| 162 | for from_id, to_id in self.port_pairings.items()} | ||
| 154 | 163 | ||
| 155 | return slot_data | 164 | return slot_data |
| 156 | 165 | ||
