Add option check for collect and remove

This commit is contained in:
Scipio Wright
2024-07-31 09:31:17 -04:00
committed by GitHub
parent 6084c51ac0
commit c24c43d62e

View File

@@ -351,14 +351,14 @@ class TunicWorld(World):
# cache whether you can get through combat logic areas
def collect(self, state: CollectionState, item: Item) -> bool:
change = super().collect(state, item)
if change:
if change and self.options.combat_logic:
if item.name in combat_items:
state.prog_items[self.player]["need_to_reset_combat_state_from_collect"] = 1
return change
def remove(self, state: CollectionState, item: Item) -> bool:
change = super().remove(state, item)
if change:
if change and self.options.combat_logic:
if item.name in combat_items:
state.prog_items[self.player]["need_to_reset_combat_state_from_remove"] = 1
return change