Skip to content

Commit

Permalink
SoE: use self.options for trap chances
Browse files Browse the repository at this point in the history
  • Loading branch information
black-sliver committed Jan 10, 2024
1 parent defe144 commit 15db6fb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions worlds/soe/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
from worlds.generic.Rules import add_item_rule, set_rule
from . import logic # load logic mixin
from .logic import SoEPlayerLogic
from .options import AvailableFragments, Difficulty, EnergyCore, RequiredFragments, SoEOptions
from .options import AvailableFragments, Difficulty, EnergyCore, RequiredFragments, SoEOptions, TrapChance
from .patch import SoEDeltaPatch, get_base_rom_path

if typing.TYPE_CHECKING:
Expand Down Expand Up @@ -322,7 +322,7 @@ def is_ingredient(item: pyevermizer.Item) -> bool:
trap_names = {}
if trap_count > 0:
for trap_type in self.trap_types:
trap_option = getattr(self.multiworld, f'trap_chance_{trap_type}')[self.player]
trap_option: TrapChance = getattr(self.options, f'trap_chance_{trap_type}')
trap_chances[trap_type] = trap_option.value
trap_names[trap_type] = trap_option.item_name
trap_chances_total = sum(trap_chances.values())
Expand Down

0 comments on commit 15db6fb

Please sign in to comment.