mirror of
https://github.com/ArchipelagoMW/Archipelago.git
synced 2026-03-29 15:23:21 -07:00
Remove unused safety thing
This commit is contained in:
@@ -544,18 +544,6 @@ def get_portal_outlet_region(portal: Portal, world: "TunicWorld") -> str:
|
||||
return world.er_regions[portal.region].outlet_region or portal.region
|
||||
|
||||
|
||||
def is_dead_end(portal: Portal, restricted: bool, world: "TunicWorld") -> bool:
|
||||
dead_end_status = world.er_regions[portal.region].dead_end
|
||||
if not dead_end_status:
|
||||
return False
|
||||
# for the purposes of this function, special can be treated as a dead end
|
||||
elif dead_end_status in [DeadEnd.all_cats, DeadEnd.special]:
|
||||
return True
|
||||
# last possibility is DeadEnd.restricted
|
||||
else:
|
||||
return restricted
|
||||
|
||||
|
||||
class DeadEnd(IntEnum):
|
||||
free = 0 # not a dead end
|
||||
all_cats = 1 # dead end in every logic category
|
||||
|
||||
@@ -2,7 +2,7 @@ from typing import Dict, List, Set, Tuple, TYPE_CHECKING
|
||||
from BaseClasses import Region, ItemClassification, Item, Location
|
||||
from .locations import location_table
|
||||
from .er_data import (Portal, portal_mapping, traversal_requirements, DeadEnd, Direction, RegionInfo,
|
||||
get_portal_outlet_region, is_dead_end)
|
||||
get_portal_outlet_region)
|
||||
from .er_rules import set_er_region_rules
|
||||
from Options import PlandoConnection
|
||||
from .options import EntranceRando, EntranceLayout
|
||||
@@ -608,14 +608,6 @@ def pair_portals(world: "TunicWorld", regions: Dict[str, Region]) -> Dict[Portal
|
||||
if should_continue:
|
||||
continue
|
||||
|
||||
# if decoupled is on, we need to make sure you aren't connecting two dead ends together both ways
|
||||
# todo: see if this ever actually gets triggered
|
||||
if decoupled:
|
||||
if portal1 in portal_pairs.keys() and portal_pairs[portal1] == portal:
|
||||
if (is_dead_end(portal1, not ice_grappling, world)
|
||||
and is_dead_end(portal, not ice_grappling, world)):
|
||||
continue
|
||||
|
||||
portal2 = portal
|
||||
connected_regions.add(get_portal_outlet_region(portal, world))
|
||||
two_plus2.remove(portal)
|
||||
|
||||
Reference in New Issue
Block a user