def __call__(self, negate=False, condition=None, skip_lines=0, end_event=False, restart_event=False): try: value = self.value except AttributeError: value = self return get_value_test( value=value, negate=negate, condition=condition, skip_lines=skip_lines, end_event=end_event, restart_event=restart_event, skip_if_true_func=instr.SkipLinesIfObjectNotDestroyed, skip_if_false_func=instr.SkipLinesIfObjectDestroyed, if_true_func=instr.IfObjectNotDestroyed, if_false_func=instr.IfObjectDestroyed, end_if_true_func=instr.EndIfObjectNotDestroyed, end_if_false_func=instr.EndIfObjectDestroyed, restart_if_true_func=instr.RestartIfObjectNotDestroyed, restart_if_false_func=instr.RestartIfObjectDestroyed, )
def __call__(self, negate=False, condition=None, skip_lines=0, end_event=False, restart_event=False): from soulstruct.base.events.emevd.utils import get_value_test from soulstruct.base.events.emevd import instructions as instr try: value = self.value except AttributeError: value = self return get_value_test( value=value, negate=negate, condition=condition, skip_lines=skip_lines, end_event=end_event, restart_event=restart_event, skip_if_true_func=instr.SkipLinesIfObjectNotDestroyed, skip_if_false_func=instr.SkipLinesIfObjectDestroyed, if_true_func=instr.IfObjectNotDestroyed, if_false_func=instr.IfObjectDestroyed, end_if_true_func=instr.EndIfObjectNotDestroyed, end_if_false_func=instr.EndIfObjectDestroyed, restart_if_true_func=instr.RestartIfObjectNotDestroyed, restart_if_false_func=instr.RestartIfObjectDestroyed, )
def __call__(self, negate=False, condition=None, skip_lines=0): try: value = self.value except AttributeError: value = self return get_value_test(value=value, negate=negate, condition=condition, skip_lines=skip_lines, if_true_func=instr.IfObjectActivated)
def __call__(self, negate=False, condition=None): value = self if isinstance(self, (int, float, tuple)) else self.value return get_value_test( value=value, negate=negate, condition=condition, if_true_func=lambda c, i: getattr( instr, f"IfPlayerHas{self.item_enum.name}")(c, i, False), if_false_func=lambda c, i: getattr( instr, f"IfPlayerDoesNotHave{self.item_enum.name}") (c, i, False), )
def __call__(self, negate=False, condition=None, skip_lines=0): from soulstruct.base.events.emevd.utils import get_value_test from soulstruct.base.events.emevd import instructions as instr try: value = self.value except AttributeError: value = self return get_value_test(value=value, negate=negate, condition=condition, skip_lines=skip_lines, if_true_func=instr.IfObjectActivated)
def __call__(self, negate=False, condition=None, skip_lines=0): try: value = self.value except AttributeError: value = self return get_value_test( value=value, negate=negate, condition=condition, skip_lines=skip_lines, if_true_func=instr.IfCharacterAlive, if_false_func=instr.IfCharacterDead, )
def __call__(self, negate=False, condition=None, skip_lines=0): try: value = self.value except AttributeError: value = self return get_value_test( value=value, negate=negate, condition=condition, skip_lines=skip_lines, if_true_func=instr.IfPlayerInsideRegion, if_false_func=instr.IfPlayerOutsideRegion, )
def all(self, negate=False, condition=None, skip_lines=0, end_event=False, restart_event=False): from soulstruct.base.events.emevd.utils import get_value_test from soulstruct.base.events.emevd import instructions as instr return get_value_test( value=self, negate=negate, condition=condition, skip_lines=skip_lines, end_event=end_event, restart_event=restart_event, skip_if_true_func=instr.SkipLinesIfFlagRangeAnyOff, skip_if_false_func=instr.SkipLinesIfFlagRangeAllOn, if_true_func=instr.IfFlagRangeAllOn, if_false_func=instr.IfFlagRangeAnyOff, end_if_true_func=instr.EndIfFlagRangeAllOn, end_if_false_func=instr.EndIfFlagRangeAnyOff, restart_if_true_func=instr.RestartIfFlagRangeAllOn, restart_if_false_func=instr.RestartIfFlagRangeAnyOff, )
def __call__(self, negate=False, condition=None, skip_lines=0, end_event=False, restart_event=False): from soulstruct.base.events.emevd.utils import get_value_test from soulstruct.base.events.emevd import instructions as instr value = self if isinstance(self, (int, float, tuple)) else self.value return get_value_test( value=value, negate=negate, condition=condition, skip_lines=skip_lines, end_event=end_event, restart_event=restart_event, skip_if_true_func=instr.SkipLinesIfFlagOn, skip_if_false_func=instr.SkipLinesIfFlagOff, if_true_func=instr.IfFlagOn, if_false_func=instr.IfFlagOff, end_if_true_func=instr.EndIfFlagOn, end_if_false_func=instr.EndIfFlagOff, restart_if_true_func=instr.RestartIfFlagOn, restart_if_false_func=instr.RestartIfFlagOff, )
def any(self, negate=False, condition=None, skip_lines=0, end_event=False, restart_event=False): return get_value_test( value=self, negate=negate, condition=condition, skip_lines=skip_lines, end_event=end_event, restart_event=restart_event, skip_if_true_func=instr.SkipLinesIfFlagRangeAllOff, skip_if_false_func=instr.SkipLinesIfFlagRangeAnyOn, if_true_func=instr.IfFlagRangeAnyOn, if_false_func=instr.IfFlagRangeAllOff, end_if_true_func=instr.EndIfFlagRangeAnyOn, end_if_false_func=instr.EndIfFlagRangeAllOff, restart_if_true_func=instr.RestartIfFlagRangeAnyOn, restart_if_false_func=instr.RestartIfFlagRangeAllOff, )
def __call__(self, negate=False, condition=None, skip_lines=0, end_event=False, restart_event=False): value = self if isinstance(self, (int, float, tuple)) else self.value return get_value_test( value=value, negate=negate, condition=condition, skip_lines=skip_lines, end_event=end_event, restart_event=restart_event, skip_if_true_func=instr.SkipLinesIfFlagOn, skip_if_false_func=instr.SkipLinesIfFlagOff, if_true_func=instr.IfFlagOn, if_false_func=instr.IfFlagOff, end_if_true_func=instr.EndIfFlagOn, end_if_false_func=instr.EndIfFlagOff, restart_if_true_func=instr.RestartIfFlagOn, restart_if_false_func=instr.RestartIfFlagOff, )