Entrance¶
- class BaseClasses.Entrance(player: int, name: str = '', parent: Region | None = None, randomization_group: int = 0, randomization_type: EntranceType = EntranceType.ONE_WAY)¶
Bases:
object
- static access_rule(state)¶
- can_connect_to(other: Entrance, dead_end: bool, er_state: ERPlacementState) bool ¶
Determines whether a given Entrance is a valid target transition, that is, whether the entrance randomizer is allowed to pair this Entrance to that Entrance. By default, only allows connection between entrances of the same type (one ways only go to one ways, two ways always go to two ways) and prevents connecting an exit to itself in coupled mode.
- Parameters:
other – The proposed Entrance to connect to
dead_end – Whether the other entrance considered a dead end by Entrance randomization
er_state – The current (partial) state of the ongoing entrance randomization
- can_reach(state: CollectionState) bool ¶
- hide_path: bool = False¶
- is_valid_source_transition(er_state: ERPlacementState) bool ¶
Determines whether this is a valid source transition, that is, whether the entrance randomizer is allowed to pair it to place any other regions. By default, this is the same as a reachability check, but can be modified by Entrance implementations to add other restrictions based on the placement state.
- Parameters:
er_state – The current (partial) state of the ongoing entrance randomization
- name: str¶
- player: int¶
- randomization_group: int¶
- randomization_type: EntranceType¶