//Darth Vader fighting obi state Base { Conditions { if FreePlay == 1 goto FreePlayWait if FreePlay == 0 goto FightObi } Actions { UseTimeBasedUpdate "FALSE" } } state FightObi { Conditions { if LocatorRange "Fight" > 1.0 goto GotoLoc if OpponentRange < 0.5 goto PauseAttack } Actions { SetOpponent "opponent=Obi" AttackOpponent "range 0.25" "jediGoodie_attack" } } state PauseAttack { Conditions { } Actions { Idle "mintime=1.0" "maxtime=2.0" SetState FightObi } } state GotoLoc { Conditions { } Actions { SetLocator "name=Fight_Darth" GoToLocator "RUN" "0.2" SetState FightObi } } state FreePlayWait { Conditions { if GotOpponent == 1 goto FreePlayFight } Actions { SetLocator "name=Fight_Darth" GoToLocator "RUN" "0.2" } } state FreePlayFight { Conditions { if GotOpponent == 0 goto FreePlayWait } Actions { AttackOpponent "range 0.25" } }