[StateDef 0];   Stand

[State 0, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 0, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = S
Physics    = S
IgnoreHitPause = 1

[State 0, SprPriority]
Type       = SprPriority
Trigger1   = 1
Value      = 0
IgnoreHitPause = 1

[State 0, ChangeAnim]
Type       = ChangeAnim
Trigger1   =  Anim     && Anim != 5
Trigger2   = !AnimTime && Anim  = 5
Value      = 0

[State 0, Turn]
Type       = Turn
Trigger1   = PalNo >= 7
Trigger1   = NumEnemy
Trigger1   = (Pos X - EnemyNear(!EnemyNear,Alive && NumEnemy > 1 && EnemyNear(NumEnemy > 1),Alive),Pos X) * Facing > 0

[State 0, CtrlSet]
Type       = CtrlSet
Trigger1   = RoundState = 2 && PrevStateNo != 190
Trigger2   = RoundState = 3 && Alive
Value      = 1

[State 0, VelSet]
Type       = VelSet
Trigger1   = Abs(Vel X) < 2
Trigger2   = Time = 4
X          = 0

[State 0, VelSet]
Type       = VelSet
Trigger1   = 1
Y          = 0

[State 0, ChangeState]
Type       = ChangeState
Trigger1   = !Alive
Trigger1   = Var(0) := 5050
Trigger2   = RoundState > 3
Trigger2   = Var(0) := 120
Value      = Var(0)
IgnoreHitpause = 1

[State 0, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 0, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 0, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X * Const(Movement.Stand.Friction) * (ABS(Vel X * Const(Movement.Stand.Friction)) > 1)

[State 0, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------
[StateDef 10];  Stand to Crouch

[State 10, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 10, CommandReset]
Type       = Null
Trigger1   = PalNo < 7
Trigger1   = Var(1) := 0
IgnoreHitPause = 1

[State 10, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = C
Physics    = C
IgnoreHitPause = 1

[State 10, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 10 + (!Var(1) * Command = "holddown" || Var(1) & 1)
Value      = 10 + (!Var(1) * Command = "holddown" || Var(1) & 1)

[State 10, Turn]
Type       = Turn
Trigger1   = PalNo >= 7
Trigger1   = NumEnemy
Trigger1   = (Pos X - EnemyNear(!EnemyNear,Alive && NumEnemy > 1 && EnemyNear(NumEnemy > 1),Alive),Pos X) * Facing > 0

[State 10, VelMul]
Type       = VelMul
Trigger1   = !AnimElemTime(1)
X          = .75

[State 10, ChangeState]
Type       = ChangeState
Trigger1   = !AnimTime
Value      = 11

[State 10, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 10, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 10, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X * Const(Movement.Crouch.Friction) * (ABS(Vel X * Const(Movement.Crouch.Friction)) > 1)

[State 10, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------
[StateDef 11];  Crouching

[State 11, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 11, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = C
Physics    = C
IgnoreHitPause = 1

[State 11, SprPriority]
Type       = SprPriority
Trigger1   = 1
Value      = 0
IgnoreHitPause = 1

[State 11, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 6 && Anim != 11
Trigger2   = Anim  = 6 && !AnimTime
Value      = 11

[State 11, Turn]
Type       = Turn
Trigger1   = PalNo >= 7
Trigger1   = NumEnemy
Trigger1   = (Pos X - EnemyNear(!EnemyNear,Alive && NumEnemy > 1 && EnemyNear(NumEnemy > 1),Alive),Pos X) * Facing > 0

[State 11, CtrlSet]
Type       = CtrlSet
Trigger1   = 1
Value      = 1

[State 11, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 11, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 11, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X * Const(Movement.Crouch.Friction) * (ABS(Vel X * Const(Movement.Crouch.Friction)) > 1)

[State 11, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------
[StateDef 12];  Crouch to Stand

[State 12, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 12, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = S
Physics    = S
IgnoreHitPause = 1

[State 12, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 12
Value      = 12

[State 12, Turn]
Type       = Turn
Trigger1   = PalNo >= 7
Trigger1   = NumEnemy
Trigger1   = (Pos X - EnemyNear(!EnemyNear,Alive && NumEnemy > 1 && EnemyNear(NumEnemy > 1),Alive),Pos X) * Facing > 0

[State 12, ChangeState]
Type       = ChangeState
Trigger1   = !AnimTime
Value      = 0

[State 12, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 12, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 12, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X * Const(Movement.Stand.Friction) * (ABS(Vel X * Const(Movement.Stand.Friction)) > 1)

[State 12, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------
[StateDef 20];  Walk

[State 20, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 20, CommandReset]
Type       = Null
Trigger1   = PalNo < 7
Trigger1   = Var(1) := 0
IgnoreHitPause = 1

[State 20, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = S
Physics    = S
IgnoreHitPause = 1

[State 20, SprPriority]
Type       = SprPriority
Trigger1   = 1
Value      = 0
IgnoreHitPause = 1

[State 20, VelSet]
Type       = VelSet
Trigger1   = !Var(1) * Command = "holdfwd"  || Var(1) & 8
Trigger1   = FVar(0) := IfElse(Vel X > Const(Velocity.Walk.Fwd.X), Vel X, Const(Velocity.Walk.Fwd.X))
Trigger2   = !Var(1) * Command = "holdback" || Var(1) & 4
Trigger2   = FVar(0) := Const(Velocity.Walk.Back.X)
X          = FVar(0)

[State 20, ChangeAnim]
Type       = ChangeAnim
TriggerAll = Vel X
TriggerAll = Var(0) := 20 + (Vel X < 0)
Trigger1   = Anim != Var(0) && Anim != 5
Trigger2   = !AnimTime      && Anim  = 5
Value      = Var(0)

[State 20, Turn]
Type       = Turn
Trigger1   = PalNo >= 7
Trigger1   = NumEnemy
Trigger1   = (Pos X - EnemyNear(!EnemyNear,Alive && NumEnemy > 1 && EnemyNear(NumEnemy > 1),Alive),Pos X) * Facing > 0

[State 20, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 20, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 20, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X * Const(Movement.Stand.Friction) * (ABS(Vel X * Const(Movement.Stand.Friction)) > 1)

[State 20, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------
[StateDef 40];  Jump Start

[State 40, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 40, CommandReset]
Type       = Null
Trigger1   = PalNo < 7
Trigger1   = Var(1) := 0
IgnoreHitPause = 1

[State 40, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = S
Physics    = S
IgnoreHitPause = 1

[State 40, SprPriority]
Type       = SprPriority
Trigger1   = 1
Value      = 1
IgnoreHitPause = 1

[State 40, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 40
Value      = 40

[State 40, Turn]
Type       = Turn
Trigger1   = PalNo >= 7
Trigger1   = NumEnemy
Trigger1   = (Pos X - EnemyNear(!EnemyNear,Alive && NumEnemy > 1 && EnemyNear(NumEnemy > 1),Alive),Pos X) * Facing > 0

[State 40, CtrlSet]
Type       = CtrlSet
Trigger1   = 1
Value      = 0

[State 40, VelSet]
Type       = VelSet
TriggerAll = !AnimTime
Trigger1   = SysVar(3) = 100
Trigger1   = !Var(1) * Command = "holdfwd" || Var(1) & 8 || !Var(1) * Command = "holdback" || Var(1) & 4
Trigger1   = FVar(0) := Const(Velocity.RunJump.Fwd.X) || 1
Trigger2   = !Var(1) * Command = "holdback" || Var(1) & 4
Trigger2   = FVar(0) := Const(Velocity.Jump.Back.X)   || 1
Trigger3   = !Var(1) * Command = "holdfwd" || Var(1) & 8
Trigger3   = FVar(0) := Const(Velocity.Jump.Fwd.X)    || 1
Trigger4   = FVar(0) := Const(Velocity.Jump.Neu.X)    || 1
X          = FVar(0)
Y          = Const(Velocity.Jump.Y)

[State 40, ChangeState]
Type       = ChangeState
Trigger1   = !AnimTime
Value      = 50
Ctrl       = 1

[State 40, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 40, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 40, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X * Const(Movement.Stand.Friction) * (ABS(Vel X * Const(Movement.Stand.Friction)) > 1)

[State 40, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------
[StateDef 45];  AirJump Start

[State 45, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 45, CommandReset]
Type       = Null
Trigger1   = PalNo < 7
Trigger1   = Var(1) := 0
IgnoreHitPause = 1

[State 45, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = A
Physics    = N
IgnoreHitPause = 1

[State 45, CtrlSet]
Type       = CtrlSet
Trigger1   = 1
Value      = 0

[State 45, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 44
Value      = 44

[State 45, VelSet]
Type       = VelSet
Trigger1   = !AnimElemTime(1)
X          = 0
Y          = 0

[State 45, VelSet]
Type       = VelSet
TriggerAll = AnimElemTime(1) = 2
Trigger1   = SysVar(3) = 110
Trigger1   = !Var(1) * Command = "holdfwd" || Var(1) & 8 || !Var(1) * Command = "holdback" || Var(1) & 4
Trigger1   = FVar(0) := Const(Velocity.RunJump.Fwd.X)  || 1
Trigger2   = !Var(1) * Command = "holdback" || Var(1) & 4
Trigger2   = FVar(0) := Const(Velocity.AirJump.Back.x) || 1
Trigger3   = !Var(1) * Command = "holdfwd" || Var(1) & 8
Trigger3   = FVar(0) := Const(Velocity.AirJump.Fwd.X)  || 1
Trigger4   = FVar(0) := Const(Velocity.AirJump.Neu.X)  || 1
X          = FVar(0)
Y          = Const(Velocity.AirJump.Y)

[State 45, AirJumpNumAdd]
Type       = VarSet
Trigger1   = !AnimElemTime(1)
sysvar(2)  = SysVar(2) + 256

[State 45, ChangeState]
Type       = ChangeState
Trigger1   = AnimElemTime(1) = 2
Value      = 50
Ctrl       = 1

[State 45, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 45, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 45, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 45, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------
[StateDef 50];  Jump Up

[State 50, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 50, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = A
Physics    = A
IgnoreHitPause = 1

[State 50, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 41 + (Vel Y > -2)
Value      = 41 + (Vel Y > -2)

[State 50, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 50, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 50, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 50, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y + Const(Movement.YAccel)


;---------------------------------------------------------------------------
[Statedef 51];  Jump Down (empty state for compatibility)

[State 51, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 51, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = A
Physics    = A
IgnoreHitPause = 1

[State 51, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 51, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 51, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 51, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y + Const(Movement.YAccel)


;---------------------------------------------------------------------------
[StateDef 52];  Jump Land

[State 52, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 52, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = S
Physics    = S
IgnoreHitPause = 1

[State 52, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 47
Value      = 47

[State 52, VelSet]
Type       = VelSet
Trigger1   = !AnimElemTime(1)
Y          = 0

[State 52, PosSet]
Type       = PosSet
Trigger1   = !AnimElemTime(1)
Y          = 0

[State 52, CtrlSet]
Type       = CtrlSet
Trigger1   = 1
Value      = AnimElemTime(1) >= 4 || NumTarget

[State 52, ChangeState]
Type       = ChangeState
Trigger1   = !AnimTime
Value      = 12
Ctrl       = 1

[State 52, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 52, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 52, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X * Const(Movement.Stand.Friction) * (ABS(Vel X * Const(Movement.Stand.Friction)) > 1)

[State 52, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------------
[StateDef 100]; RUN_FWD

[State 100, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 100, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = A
Physics    = N
IgnoreHitPause = 1

[State 100, CommandReset]
Type       = Null
Trigger1   = PalNo < 7
Trigger1   = Var(1) := 0
IgnoreHitPause = 1

[State 100, SprPriority]
Type       = SprPriority
Trigger1   = 1
Value      = 1

[State 100, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 100
Value      = 100

[State 100, VelSet]
Type       = VelSet
Trigger1   = 1
X          = Const(Velocity.Run.Fwd.X)

[State 100, AsseertSpecial]
Type       = AssertSpecial
Trigger1   = 1
Flag       = NoWalk
Flag2      = NoAutoTurn

[State 100, ChangeState]
Type       = ChangeState
Trigger1   = Var(1) + !Var(1) * Command != "holdfwd" && !(Var(1) & 8)
Value      = 0

[State 100, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 100, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 100, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 100, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------------
[StateDef 105]; RUN_BACK

[State 105, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 105, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = A
Physics    = A
IgnoreHitPause = 1

[State 105, SprPriority]
Type       = SprPriority
Trigger1   = 1
Value      = 1

[State 105, CtrlSet]
Type       = CtrlSet
Trigger1   = 1
Value      = 0

[State 105, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 105
Value      = 105

[State 105, VelSet]
Type       = VelSet
Trigger1   = !AnimElemTime(1)
X          = Const(Velocity.Run.Back.X)
Y          = Const(Velocity.Run.Back.Y)

[State 105, PlayerPush]
Type       = PlayerPush
Trigger1   = 1
Value      = 0

[State 105, HitBy]
Type       = HitBy
Trigger1   = 1
Value      =

[State 105, ChangeState]
Type       = ChangeState
Trigger1   = Vel Y >  0
Trigger1   = Pos Y >= 0
Value      = 106

[State 105, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 105, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 105, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 105, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y + Const(Movement.YAccel)

[State 105, ChangeState]
Type       = ChangeState
Trigger1   = Vel Y >  0
Trigger1   = Pos Y >= 0
Value      = 106


;---------------------------------------------------------------------------
[StateDef 106]; RUN_BACK2 (land)

[State 106, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 106, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = S
Physics    = S
IgnoreHitPause = 1

[State 106, CtrlSet]
Type       = CtrlSet
Trigger1   = 1
Value      = 0

[State 106, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 47
Value      = 47

[State 106, VelSet]
Type       = VelSet
Trigger1   = !AnimElemTime(1)
Y          = 0

[State 106, PosSet]
Type       = PosSet
Trigger1   = !AnimElemTime(1)
Y          = 0

[State 105, HitBy]
Type       = HitBy
Trigger1   = 1
Value      = SCA, AA,AP,AT

[State 106, MakeDust]
Type       = MakeDust
Trigger1   = AnimElemTime(1) = 2
Pos        = -10, -2
Spacing    = 1

[State 106, ChangeState]
Type       = ChangeState
Trigger1   = !AnimTime
Value      = 0
Ctrl       = 1

[State 106, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 106, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 106, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X * Const(Movement.Stand.Friction) * (ABS(Vel X * Const(Movement.Stand.Friction)) > 1)

[State 106, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 106, ChangeState]
Type       = ChangeState
Trigger1   = !AnimTime
Value      = 0
Ctrl       = 1


;---------------------------------------------------------------------------
[StateDef 110]; Boost

[State 110, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 110, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = A
Physics    = N
IgnoreHitPause = 1

[State 110, SprPriority]
Type       = SprPriority
Trigger1   = 1
Value      = 1

[State 110, Turn]
Type       = Turn
Trigger1   = !Var(1) * Command = "x" || Var(1) & 128
Trigger1   = NumEnemy
Trigger1   = (Pos X - EnemyNear(!EnemyNear,Alive && NumEnemy > 1 && EnemyNear(NumEnemy > 1),Alive),Pos X) * Facing > 0
IgnoreHitPause = 1

[State 110, VelSet_X]
Type       = VelSet
Trigger1   = !Var(1) * Command = "holdfwd"  || Var(1) & 8
Trigger1   = FVar(0) := Const(Velocity.Run.Fwd.X) * 1.5  || Var(0) := 100
Trigger2   = !Var(1) * Command = "holdback" || Var(1) & 4
Trigger2   = FVar(0) := Const(Velocity.Run.Back.X) * 1.2 || Var(0) := 105
Trigger3   = FVar(0) := 0                                || Var(0) := 0
X          = FVar(0)

[State 110, VelSet_Y]
Type       = VelSet
TriggerAll = FVar(0) := 0                                                               || 1
Trigger1   = !Var(1) * Command = "holdup" || Var(1) & 2
Trigger1   = FVar(0) := Const(Velocity.AirJump.Y) / (2 - !Var(0))                       || 1
Trigger1   =  Var(0) := 110   * !Var(0) + Var(0)
Trigger2   = !Var(1) * Command = "holddown" || Var(1) & 1
Trigger2   = FVar(0) := (Vel Y * !Var(0) - Const(Velocity.AirJump.Y) / 2) * (Pos Y < 0) || 1
Trigger2   =  Var(0) := 115   * !Var(0) + Var(0)
Trigger3   = FVar(0) := 2.5   * !Var(0)                                                 || 1
Trigger3   =  Var(0) := 116   * !Var(0) + Var(0)
Y          = FVar(0)

[State 110, AsseertSpecial]
Type       = AssertSpecial
Trigger1   = 1
Flag       = NoAirGuard

[State 110, CtrlSet]
Type       = CtrlSet
Trigger1   = 1
Value      = 1

[State 110, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != Var(0)
Value      = Var(0)

[State 110, Explod]
Type          = Explod
Trigger1      = !Var(1) * Command = "x" || Var(1) & 128
Trigger1      = Vel X || Vel Y
Anim          = 1110 + !!Vel X + 2 * !!Vel Y
ID            = 110
Vel           = -Vel X / 4, -Vel Y / 4
Facing        = IfElse(Vel X > 0, 1, -1)
VFacing       = IfElse(Vel Y <= 0 || Anim = 116, 1, -1)
BindTime      = 3
Pos           = 0, -40
Scale         = 0.8, 0.8
OnTop         = 1
OwnPal        = 1
SuperMoveTime = 2147483647 * (PalNo = 12)
PauseMoveTime = 2147483647 * (PalNo = 12)

[State 110, PlaySnd]
Type       = PlaySnd
Trigger1   = !Var(1) * Command = "x" || Var(1) & 128
Trigger1   = Vel X || Vel Y
Value      = 110, 0

[State 110 , PosAdd]
Type       = PosAdd
Trigger1   = !Pos Y
Trigger1   = Anim = 116
Trigger1   = !Var(1) * Command = "x" || Var(1) & 128
Y          = -60

[State 110, PosSet]
Type       = PosSet
Trigger1   = Pos Y > 0
Trigger1   = Var(0) := 0 || 1
Trigger2   = Pos Y < -2000
Trigger2   = Var(0) := -2000
Y          = Var(0)

[State 110, ChangeState]
Type       = ChangeState
Trigger1   = !Var(10) || Var(1) + !Var(1) * Command != "hold_x" && !(Var(1) & 524288)
Trigger2   = Anim = [115,116]
Trigger2   = !Pos Y
Value      = 11 * !Pos Y * (!Var(1) * Command = "holddown" || Var(1) & 1) + !!Pos Y * 50

[State 110, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 110, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 110, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 110, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------------
[StateDef 120]; GUARD (start)
Type    = U
Physics = U

[State 120, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Trigger2   = !IsHelper(10000) || Root,PalNo < 7
Value      = 25150
IgnoreHitPause = 1

[State 120, CommandReset]
Type       = Null
Trigger1   = !IsHelper
Trigger1   = PalNo < 7
Trigger1   = Var(1) := 0
IgnoreHitPause = 1

[State 120, ChangeAnim]
Type       = ChangeAnim
TriggerAll = !IsHelper
Trigger1   = Anim != (Var(0) := 0)
Trigger1   = RoundState = 3 && !Pos Y
Trigger2   = RoundState = 4
Trigger2   = Anim && Anim != 170 && Anim != 175 && Anim != 180
Trigger3   = RoundState < 3 || (RoundState = 3 && Anim)
Trigger3   = Anim != (Var(0) := 120 + (StateType = C) + 2 * (StateType = A))
Value      = Var(0)

[State 120, StateTypeSet]
Type       = StateTypeSet
Trigger1   = !IsHelper
Trigger1   = StateType = L
StateType  = A
IgnoreHitPause = 1

[State 120, StateTypeSet]
Type       = StateTypeSet
Trigger1   = !IsHelper
Trigger1   = !Time && StateType = S
Physics    = S
IgnoreHitPause = 1

[State 120, StateTypeSet]
Type       = StateTypeSet
Trigger1   = !IsHelper
Trigger1   = !Time && StateType = C
Physics    = C
IgnoreHitPause = 1

[State 120, StateTypeSet]
Type       = StateTypeSet
Trigger1   = !IsHelper
Trigger1   = !Time && StateType = A
Physics    = A
IgnoreHitPause = 1

[State 120, StateTypeSet]
Type       = StateTypeSet
Trigger1   = !IsHelper
Trigger1   = StateType = S && (!Var(1) * Command = "holddown" || Var(1) & 1)
StateType  = C
Physics    = C
IgnoreHitPause = 1

[State 120, StateTypeSet]
Type       = StateTypeSet
Trigger1   = !IsHelper
Trigger1   = StateType = C && (Var(1) + !Var(1) * Command != "holddown" && !(Var(1) & 1))
StateType  = S
Physics    = S
IgnoreHitPause = 1

[State 120, ChangeState]
Type       = ChangeState
TriggerAll = !IsHelper
TriggerAll = RoundState < 4
Trigger1   = !AnimTime
Trigger1   = VAr(0) := 130 + (StateType = C) + 2 * (StateType = A)
Trigger2   = Var(0) := 140
Trigger2   = Var(1) + !Var(1) * Command != "holdback" && !(Var(1) & 4)
Trigger3   = !InGuardDist
Value      = Var(0)

[State 120, SysVar(2)Set]
Type       = VarSet
Trigger1   = !IsHelper
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 120, SysVar(3)Set]
Type       = VarSet
Trigger1   = !IsHelper
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 120, SysFVar(3)Set]
Type       = VarSet
TriggerAll = !IsHelper
Trigger1   = StateType = S
Trigger1   = FVar(0) := Vel X * Const(Movement.Stand.Friction)  * (ABS(Vel X * Const(Movement.Stand.Friction))  > 1) || 1
Trigger2   = StateType = C
Trigger2   = FVar(0) := Vel X * Const(Movement.Crouch.Friction) * (ABS(Vel X * Const(Movement.Crouch.Friction)) > 1) || 1
Trigger3   = FVar(0) := Vel X                                                                                        || 1
sysfvar(3) = FVar(0)

[State 120, SysFVar(4)Set]
Type       = VarSet
TriggerAll = !IsHelper
Trigger1   = StateType = A
Trigger1   = FVar(0) := Vel Y + Const(Movement.YAccel) || 1
Trigger2   = FVar(0) := Vel Y                          || 1
sysfvar(4) = FVar(0)

[State 120, ChangeState::Helper]
Type       = ChangeState
Trigger1   = IsHelper
Trigger1   = !Root,Alive
Value      = 5150

[State 120, StateTypeSet::Helper]
Type       = StateTypeSet
Trigger1   = IsHelper
MoveType   = A

;---------------------------------------------------------------------------
[StateDef 130]; STAND GUARD (guarding)

[State 130, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 130, CommandReset]
Type       = Null
Trigger1   = PalNo < 7
Trigger1   = Var(1) := 0
IgnoreHitPause = 1

[State 130, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = S
Physics    = S
IgnoreHitPause = 1

[State 130, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 130
Value      = 130

[State 130, ChangeState]
Type       = ChangeState
Trigger1   = !Var(1) * Command = "holddown" || Var(1) & 1
Trigger1   = Var(0) := 131
Trigger2   = Var(0) := 140
Trigger2   = Var(1) + !Var(1) * Command != "holdback" && !(Var(1) & 4)
Trigger3   = !InGuardDist
Value      = Var(0)

[State 130, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 130, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 130, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X * Const(Movement.Stand.Friction) * (ABS(Vel X * Const(Movement.Stand.Friction)) > 1)

[State 130, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------------
[StateDef 131]; CROUCH GUARD (guarding)

[State 131, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 131, CommandReset]
Type       = Null
Trigger1   = PalNo < 7
Trigger1   = Var(1) := 0
IgnoreHitPause = 1

[State 131, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = C
Physics    = C
IgnoreHitPause = 1

[State 131, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 131
Value      = 131

[State 131, ChangeState]
Type       = ChangeState
Trigger1   = Var(1) + !Var(1) * Command != "holddown" && !(Var(1) & 1)
Trigger1   = Var(0) := 130
Trigger2   = Var(0) := 140
Trigger2   = Var(1) + !Var(1) * Command != "holdback" && !(Var(1) & 4)
Trigger3   = !InGuardDist
Value      = Var(0)

[State 131, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 131, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 131, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X * Const(Movement.Crouch.Friction) * (ABS(Vel X * Const(Movement.Crouch.Friction)) > 1)

[State 131, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------------
[StateDef 132]; AIR GUARD (guarding)

[State 132, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 132, CommandReset]
Type       = Null
Trigger1   = PalNo < 7
Trigger1   = Var(1) := 0
IgnoreHitPause = 1

[State 132, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = A
Physics    = N
IgnoreHitPause = 1

[State 132, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 132
Value      = 132

[State 132, VelAdd]
Type       = VelAdd
Trigger1   = 1
Y          = Const(Movement.YAccel)

[State 132, VelSet]
Type       = VelSet
Trigger1   = Var(0) := 0 || 1
Trigger1   = (Pos Y >= 0) && (Vel Y > 0)
Trigger1   = Var(0) := 1
Y          = 0

[State 132, PosSet]
Type       = PosSet
Trigger1   = Var(0)
Y          = 0

[State 132, ChangeState]
Type       = ChangeState
Trigger1   = Var(0)
Trigger1   = !Var(1) * Command = "holdback" || Var(1) & 4
Trigger1   = InGuardDist
Trigger1   = Var(0) := 130
Trigger2   = Var(0)
Trigger2   = Var(0) := 52
Trigger3   = Var(0) := 140
Trigger3   = Var(1) + !Var(1) * Command != "holdback" && !(Var(1) & 4)
Trigger4   = !InGuardDist
Value      = Var(0)

[State 132, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 132, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 132, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 132, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------------
[StateDef 140]; GUARD (end)
Type    = U
Physics = U

[State 140, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 140, CommandReset]
Type       = Null
Trigger1   = PalNo < 7
Trigger1   = Var(1) := 0
IgnoreHitPause = 1

[State 140, CtrlSet]
Type       = CtrlSet
Trigger1   = 1
Value      = 1

[State 140, ChangeAnim]
Type       = ChangeAnim
Trigger1   = RoundState > 2 && !Pos Y
Trigger1   = Anim != (Var(0) := 0)
Trigger2   = RoundState < 3 || (RoundState = 3 && Anim)
Trigger2   = Anim != (Var(0) := 140 + (StateType = C) + 2 * (StateType = A))
Value      = Var(0)

[State 140, StateTypeSet]
Type       = StateTypeSet
Trigger1   = !Time && StateType = S
Physics    = S
IgnoreHitPause = 1

[State 140, StateTypeSet]
Type       = StateTypeSet
Trigger1   = !Time && StateType = C
Physics    = C
IgnoreHitPause = 1

[State 140, StateTypeSet]
Type       = StateTypeSet
Trigger1   = !Time && StateType = A
Physics    = A
IgnoreHitPause = 1

[State 140, StateTypeSet]
Type       = StateTypeSet
Trigger1   = StateType = S && (!Var(1) * Command = "holddown" || Var(1) & 1)
StateType  = C
Physics    = C
IgnoreHitPause = 1

[State 140, StateTypeSet]
Type       = StateTypeSet
Trigger1   = StateType = C && (Var(1) + !Var(1) * Command != "holddown" && !(Var(1) & 1))
StateType  = S
Physics    = S
IgnoreHitPause = 1

[State 140, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 140, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 140, SysFVar(3)Set]
Type       = VarSet
Trigger1   = StateType = S
Trigger1   = FVar(0) := Vel X * Const(Movement.Stand.Friction)  * (ABS(Vel X * Const(Movement.Stand.Friction)) > 1)  || 1
Trigger2   = StateType = C
Trigger2   = FVar(0) := Vel X * Const(Movement.Crouch.Friction) * (ABS(Vel X * Const(Movement.Crouch.Friction)) > 1) || 1
Trigger3   = FVar(0) := Vel X                                                                                        || 1
sysfvar(3) = FVar(0)

[State 140, SysFVar(4)Set]
Type       = VarSet
Trigger1   = StateType = A
Trigger1   = FVar(0) := Vel Y + Const(Movement.YAccel) || 1
Trigger2   = FVar(0) := Vel Y                          || 1
sysfvar(4) = FVar(0)


;---------------------------------------------------------------------------
[StateDef 150]; SGUARDHIT (shaking)

[State 150, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 150, CommandReset]
Type       = Null
Trigger1   = PalNo < 7
Trigger1   = Var(1) := 0
IgnoreHitPause = 1

[State 150, StateTypeSet]
Type       = StateTypeSet
Trigger1   = PalNo != 12
StateType  = S
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 150, StateTypeSet]
Type       = StateTypeSet
Trigger1   = PalNo = 12
StateType  = S
MoveType   = I
Physics    = N
IgnoreHitPause = 1

[State 150, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 150
Value      = 150

[State 150, VelSet]
Type       = VelSet
Trigger1   = !AnimElemTime(1)
X          = 0
Y          = 0

[State 150, StateTypeSet]
Type       = StateTypeSet
Trigger1   = StateType = S && (!Var(1) * Command = "holddown" || Var(1) & 1)
StateType  = C
Physics    = C
IgnoreHitPause = 1

[State 150, StateTypeSet]
Type       = StateTypeSet
Trigger1   = StateType = C && (Var(1) + !Var(1) * Command != "holddown" && !(Var(1) & 1))
StateType  = S
Physics    = S
IgnoreHitPause = 1

[State 150, ChangeState]
Type       = ChangeState
Trigger1   = HitShakeOver
Value      = 151 + 2 * (!Var(1) * Command = "holddown" || Var(1) & 1)

[State 150, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 150, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 150, SysFVar(3)Set]
Type       = VarSet
Type       = VarSet
Trigger1   = StateType = S
Trigger1   = FVar(0) := Vel X * Const(Movement.Stand.Friction)  * (ABS(Vel X * Const(Movement.Stand.Friction)) > 1)  || 1
Trigger2   = StateType = C
Trigger2   = FVar(0) := Vel X * Const(Movement.Crouch.Friction) * (ABS(Vel X * Const(Movement.Crouch.Friction)) > 1) || 1
sysfvar(3) = FVar(0)

[State 150, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------------
[StateDef 151]; SGUARDHIT2 (knocked back)

[State 151, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 151, CommandReset]
Type       = Null
Trigger1   = PalNo < 7
Trigger1   = Var(1) := 0
IgnoreHitPause = 1

[State 151, StateTypeSet]
Type       = StateTypeSet
Trigger1   = PalNo != 12
StateType  = S
MoveType   = H
Physics    = S
IgnoreHitPause = 1

[State 151, StateTypeSet]
Type       = StateTypeSet
Trigger1   = PalNo = 12
StateType  = S
MoveType   = I
Physics    = N
IgnoreHitPause = 1

[State 151, ChangeAnim]
Type       = ChangeAnim
Trigger1   = SysVar(3) = 150 || Anim != 150
Value      = 150

[State 151, HitVelSet]
Type       = HitVelSet
Trigger1   = SysVar(3) = 150 && !AnimElemTime(1)
X          = 1

[State 151, VelSet]
Type       = VelSet
Trigger1   = SysVar(3) = 150 && AnimElemTime(1) = GetHitVar(SlideTime)
Trigger2   = HitOver
X          = 0

[State 151, CtrlSet]
Type       = CtrlSet
Trigger1   = AnimElemTime(1) = GetHitVar(CtrlTime)
Value      = 1

[State 151, StateTypeSet]
Type       = StateTypeSet
Trigger1   = StateType = S && (!Var(1) * Command = "holddown" || Var(1) & 1)
StateType  = C
Physics    = C
IgnoreHitPause = 1

[State 151, StateTypeSet]
Type       = StateTypeSet
Trigger1   = StateType = C && (Var(1) + !Var(1) * Command != "holddown" && !(Var(1) & 1))
StateType  = S
Physics    = S
IgnoreHitPause = 1

[State 151, ChangeState]
Type       = ChangeState
Trigger1   = HitOver
Value      = 130
Ctrl       = 1

[State 151, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 151, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 151, SysFVar(3)Set]
Type       = VarSet
Trigger1   = StateType = S
Trigger1   = FVar(0) := Vel X * Const(Movement.Stand.Friction)  * (ABS(Vel X * Const(Movement.Stand.Friction)) > 1)  || 1
Trigger2   = StateType = C
Trigger2   = FVar(0) := Vel X * Const(Movement.Crouch.Friction) * (ABS(Vel X * Const(Movement.Crouch.Friction)) > 1) || 1
sysfvar(3) = FVar(0)

[State 151, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------------
[StateDef 152]; CGUARDHIT (shaking)

[State 152, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 152, CommandReset]
Type       = Null
Trigger1   = PalNo < 7
Trigger1   = Var(1) := 0
IgnoreHitPause = 1

[State 152, StateTypeSet]
Type       = StateTypeSet
Trigger1   = PalNo != 12
StateType  = C
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 152, StateTypeSet]
Type       = StateTypeSet
Trigger1   = PalNo = 12
StateType  = C
MoveType   = I
Physics    = N
IgnoreHitPause = 1

[State 152, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 151
Value      = 151

[State 152, VelSet]
Type       = VelSet
Trigger1   = !AnimElemTime(1)
X          = 0
Y          = 0

[State 152, StateTypeSet]
Type       = StateTypeSet
Trigger1   = StateType = S && (!Var(1) * Command = "holddown" || Var(1) & 1)
StateType  = C
Physics    = C
IgnoreHitPause = 1

[State 152, StateTypeSet]
Type       = StateTypeSet
Trigger1   = StateType = C && (Var(1) + !Var(1) * Command != "holddown" && !(Var(1) & 1))
StateType  = S
Physics    = S
IgnoreHitPause = 1

[State 152, ChangeState]
Type       = ChangeState
Trigger1   = HitShakeOver
Value      = 151 + 2 * (!Var(1) * Command = "holddown" || Var(1) & 1)

[State 152, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 152, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 152, SysFVar(3)Set]
Type       = VarSet
Trigger1   = StateType = S
Trigger1   = FVar(0) := Vel X * Const(Movement.Stand.Friction)  * (ABS(Vel X * Const(Movement.Stand.Friction)) > 1)  || 1
Trigger2   = StateType = C
Trigger2   = FVar(0) := Vel X * Const(Movement.Crouch.Friction) * (ABS(Vel X * Const(Movement.Crouch.Friction)) > 1) || 1
sysfvar(3) = FVar(0)

[State 152, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------------
[StateDef 153]; CGUARDHIT2 (knocked back)

[State 153, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 153, CommandReset]
Type       = Null
Trigger1   = PalNo < 7
Trigger1   = Var(1) := 0
IgnoreHitPause = 1

[State 153, StateTypeSet]
Type       = StateTypeSet
Trigger1   = PalNo != 12
StateType  = C
MoveType   = H
Physics    = C
IgnoreHitPause = 1

[State 153, StateTypeSet]
Type       = StateTypeSet
Trigger1   = PalNo = 12
StateType  = C
MoveType   = I
Physics    = C
IgnoreHitPause = 1

[State 153, ChangeAnim]
Type       = ChangeAnim
Trigger1   = SysVar(3) = 152 || Anim != 151
Value      = 151

[State 153, HitVelSet]
Type       = HitVelSet
Trigger1   = SysVar(3) = 152 && !AnimElemTime(1)
X          = 1

[State 153, VelSet]
Type       = VelSet
Trigger1   = SysVar(3) = 152 && AnimElemTime(1) = GetHitVar(SlideTime)
Trigger2   = HitOver
X          = 0

[State 153, CtrlSet]
Type       = CtrlSet
Trigger1   = AnimElemTime(1) = GetHitVar(CtrlTime)
Value      = 1

[State 153, StateTypeSet]
Type       = StateTypeSet
Trigger1   = StateType = S && (!Var(1) * Command = "holddown" || Var(1) & 1)
StateType  = C
Physics    = C
IgnoreHitPause = 1

[State 153, StateTypeSet]
Type       = StateTypeSet
Trigger1   = StateType = C && (Var(1) + !Var(1) * Command != "holddown" && !(Var(1) & 1))
StateType  = S
Physics    = S
IgnoreHitPause = 1

[State 153, ChangeState]
Type       = ChangeState
Trigger1   = HitOver
Value      = 131
Ctrl       = 1

[State 153, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 153, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 153, SysFVar(3)Set]
Type       = VarSet
Trigger1   = StateType = S
Trigger1   = FVar(0) := Vel X * Const(Movement.Stand.Friction)  * (ABS(Vel X * Const(Movement.Stand.Friction)) > 1)  || 1
Trigger2   = StateType = C
Trigger2   = FVar(0) := Vel X * Const(Movement.Crouch.Friction) * (ABS(Vel X * Const(Movement.Crouch.Friction)) > 1) || 1
sysfvar(3) = FVar(0)

[State 153, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------------
[StateDef 154]; AGUARDHIT (shaking)

[State 154, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 154, StateTypeSet]
Type       = StateTypeSet
Trigger1   = PalNo != 12
StateType  = A
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 154, StateTypeSet]
Type       = StateTypeSet
Trigger1   = PalNo = 12
StateType  = A
MoveType   = I
Physics    = N
IgnoreHitPause = 1

[State 154, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 152
Value      = 152

[State 154, VelSet]
Type       = VelSet
Trigger1   = !AnimElemTime(1)
X          = 0
Y          = 0

[State 154, ChangeState]
Type       = ChangeState
Trigger1   = HitShakeOver
Value      = 155

[State 154, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 154, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 154, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 154, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------------
[StateDef 155]; AGUARDHIT2 (knocked away)

[State 155, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 155, CommandReset]
Type       = Null
Trigger1   = PalNo < 7
Trigger1   = Var(1) := 0
IgnoreHitPause = 1

[State 155, StateTypeSet]
Type       = StateTypeSet
Trigger1   = PalNo != 12
StateType  = A
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 155, StateTypeSet]
Type       = StateTypeSet
Trigger1   = PalNo = 12
StateType  = A
MoveType   = I
Physics    = N
IgnoreHitPause = 1

[State 155, ChangeAnim]
Type       = ChangeAnim
Trigger1   = SysVar(3) = 154 || Anim != 152
Value      = 152

[State 155, HitVelSet]
Type       = HitVelSet
Trigger1   = SysVar(3) = 154 && !AnimElemTime(1)
X          = 1
Y          = 1

[State 155, VelAdd]
Type       = VelAdd
Trigger1   = 1
Y          = Const(Movement.YAccel)

[State 155, CtrlSet]
Type       = CtrlSet
Trigger1   = AnimElemTime(1) = GetHitVar(CtrlTime)
Value      = 1

[State 155, VelSet]
Type       = VelSet
Trigger1   = Var(0) := 0 || 1
Trigger1   = (Pos Y >= 0) && (Vel Y > 0)
Trigger1   = Var(0) := 1
Y          = 0

[State 155, PosSet]
Type       = PosSet
Trigger1   = Var(0)
Y          = 0

[State 155, ChangeState]
Type       = ChangeState
TriggerAll = Var(0)
Trigger1   = !Var(1) * Command = "holdback" || Var(1) & 4
Trigger1   = InGuardDist
Trigger1   = Var(0) := 130
Trigger2   = Var(0) := 52
Value      = Var(0)

[State 155, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 155, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 155, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 155, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------------
[StateDef 170]; LOSE (Time over)

[State 170, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Trigger3   = RoundState != 4
Value      = 25150
IgnoreHitPause = 1

[State 170, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = S
IgnoreHitPause = 1

[State 170, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 170
Value      = 170

[State 170, VelSet]
Type       = VelSet
Trigger1   = 1
X          = 0
Y          = 0

[State 170, CtrlSet]
Type       = CtrlSet
Trigger1   = 1
Value      = 0

[State 170, NotHitBy]
Type       = NotHitBy
Trigger1   = 1
Value      = SCA
Time       = -1

[State 170, PlaySnd]
Type       = PlaySnd
Trigger1   = !AnimElemTime(1)
Value      = 5005, 0

[State 170, ChangeState]
Type       = ChangeState
Trigger1   = PalNo >= 7
Value      = 120
IgnoreHitPause = 1

[State 170, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 170, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 170, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 170, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------------
[StateDef 175]; DRAWGAME (Time over)

[State 175, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Trigger3   = RoundState != 4
Value      = 25150
IgnoreHitPause = 1

[State 175, ChangeState]
Type       = ChangeState
Trigger1   = !Time
Trigger1   = !SelfAnimExist(175)
Value      = 170
IgnoreHitPause = 1

[State 175, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = S
IgnoreHitPause = 1

[State 175, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 175
Value      = 175

[State 175, VelSet]
Type       = VelSet
Trigger1   = 1
X          = 0
Y          = 0

[State 175, CtrlSet]
Type       = CtrlSet
Trigger1   = 1
Value      = 0

[State 175, NotHitBy]
Type       = NotHitBy
Trigger1   = 1
Value      = SCA
Time       = -1

[State 175, ChangeState]
Type       = ChangeState
Trigger1   = PalNo >= 7
Value      = 120
IgnoreHitPause = 1

[State 175, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 175, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 175, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 175, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------------
[StateDef 180]; WINGAME

[State 180, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Trigger3   = RoundState != 4
Value      = 25150
IgnoreHitPause = 1

[State 180, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = S
IgnoreHitPause = 1

[State 180, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 180
Value      = 180

[State 180, VelSet]
Type       = VelSet
Trigger1   = 1
X          = 0
Y          = 0

[State 180, CtrlSet]
Type       = CtrlSet
Trigger1   = 1
Value      = 0

[State 180, NotHitBy]
Type       = NotHitBy
Trigger1   = 1
Value      = SCA
Time       = -1

[State 180, PlaySnd]
Type       = PlaySnd
Trigger1   = !AnimElemTime(1)
Value      = 180, 0

[State 180, ChangeState]
Type       = ChangeState
Trigger1   = PalNo >= 7
Value      = 120
IgnoreHitPause = 1

[State 180, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 180, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = StateNo
IgnoreHitPause = 1

[State 180, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 180, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------------
[StateDef 190]; PREINTRO

[State 190, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Trigger3   = RoundState > 1
Value      = 25150
IgnoreHitPause = 1

[State 190, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = S
IgnoreHitPause = 1

[State 190, VelSet]
Type       = VelSet
Trigger1   = !Time
X          = 0
Y          = 0

[State 190, CtrlSet]
Type       = CtrlSet
Trigger1   = 1
Value      = 0

[State 190, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 190
Value      = 190

[State 190, AssertSpecial]
Type       = AssertSpecial
Trigger1   = 1
Flag       = Intro
Flag2      = NoKO

[State 190, PlaySnd]
Type       = PlaySnd
Trigger1   = PalNo = [1,6]
Trigger1   = !AnimElemTime(2)
Trigger1   = Var(0) := 0 || 1
Trigger2   = PalNo = [7,11]
Trigger2   = !AnimElemTime(1)
Trigger2   = Var(0) := 1
Trigger3   = PalNo = 12
Trigger3   = !AnimElemTime(1)
Trigger3   = Var(0) := 3
Value      = 190, Var(0)

[State 190, ChangeState] 
Type       = ChangeState
Trigger1   = !AnimTime
Value      = 0

[State 190, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 + (StateType = L) * 3 | 4 * ((MoveType = A) + (MoveType = H) * 2) | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 190, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = 0
IgnoreHitPause = 1

[State 190, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 190, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y


;---------------------------------------------------------------------------
[StateDef 5000];HitG_Shake

[State 5000, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5000, StateTypeSet_1]
Type       = StateTypeSet
Trigger1   = 1
StateType  = S
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 5000, StateTypeSet_1]
Type       = StateTypeSet
Trigger1   = RoundState != 2
StateType  = S
MoveType   = I
Physics    = N
IgnoreHitPause = 1

[State 5000, StateTypeSet_2]
Type       = StateTypeSet
Trigger1   = GetHitVar(YVel) || GetHitVar(Fall)
Trigger2   = Pos Y
StateType  = A
IgnoreHitPause = 1

[State 5000, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Time
Trigger1   = Var(0) := Anim
Trigger2   = GetHitVar(AnimType) != [3,5]
Trigger2   = Var(0) := 5010 - (GetHitVar(GroundType) = 1) * 10 + GetHitVar(AnimType)
Trigger3   = Var(0) := 5030
Value      = Var(0)

[State 5000, VelSet]
Type       = VelSet
Trigger1   = !Time
X          = 0
Y          = 0

[State 5000, ChangeState]
Type       = ChangeState
TriggerAll = HitShakeOver
Trigger1   = !GetHitVar(YVel) && !GetHitVar(Fall)
Trigger1   = Var(0) := 5001
Trigger2   = Var(0) := 5030
Value      = Var(0)

[State 5000, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5000, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5000, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5000, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5001];HitG_Slide

[State 5001, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5001, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = S
MoveType   = H
Physics    = S
IgnoreHitPause = 1

[State 5001, ChangeAnim]
Type       = ChangeAnim
Trigger1   = !AnimTime
Value      = 5005 + GetHitVar(AnimType) + (GetHitVar(GroundType) = 2) * 10

[State 5001, HitVelSet]
Type       = HitVelSet
Trigger1   = !Time
X          = 1

[State 5001, VelMul]
Type       = VelMul
Trigger1   = Time >= GetHitVar(SlideTime)
X          = .6

[State 5001, VelSet]
Type       = VelSet
Trigger1   = HitOver
X          = 0

[State 5001, DefenceMulset]
Type       = DefenceMulset
Trigger1   = HitOver
Value      = 1

[State 5001, ChangeState]
Type       = ChangeState
Trigger1   = HitOver
Value      = 0
Ctrl       = 1

[State 5001, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X * Const(Movement.Stand.Friction) * (ABS(Vel X * Const(Movement.Stand.Friction)) > 1)

[State 5001, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5001, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5001, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5010];HitC_Shake

[State 5010, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5010, StateTypeSet_1]
Type       = StateTypeSet
Trigger1   = 1
StateType  = C
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 5010, StateTypeSet_1]
Type       = StateTypeSet
Trigger1   = RoundState != 2
StateType  = C
MoveType   = I
Physics    = N
IgnoreHitPause = 1

[State 5010, StateTypeSet_2]
Type       = StateTypeSet
Trigger1   = GetHitVar(YVel) || GetHitVar(Fall)
Trigger2   = Pos Y
StateType  = A
IgnoreHitPause = 1

[State 5010, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Time
Trigger1   = Var(0) := Anim
Trigger2   = GetHitVar(AnimType) != [3,5]
Trigger2   = Var(0) := 5020 + GetHitVar(AnimType)
Trigger3   = Var(0) := 5030
Value      = Var(0)

[State 5010, VelSet]
Type       = VelSet
Trigger1   = !Time
X          = 0
Y          = 0

[State 5010, ChangeState]
Type       = ChangeState
TriggerAll = HitShakeOver
Trigger1   = !GetHitVar(YVel) && !GetHitVar(Fall)
Trigger1   = Var(0) := 5011
Trigger2   = Var(0) := 5030
Value      = Var(0)

[State 5010, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5010, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5010, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5010, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5011];HitC_Slide

[State 5011, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5011, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = C
MoveType   = H
Physics    = C
IgnoreHitPause = 1

[State 5011, ChangeAnim]
Type       = ChangeAnim
Trigger1   = !AnimTime
Value      = 5025 + GetHitVar(AnimType)

[State 5011, HitVelSet]
Type       = HitVelSet
Trigger1   = !Time
X          = 1

[State 5011, VelMul]
Type       = VelMul
Trigger1   = Time >= GetHitVar(SlideTime)
X          = .6

[State 5011, VelSet]
Type       = VelSet
Trigger1   = HitOver
X          = 0

[State 5011, DefenceMulset]
Type       = DefenceMulset
Trigger1   = HitOver
Value      = 1

[State 5011, ChangeState]
Type       = ChangeState
Trigger1   = HitOver
Value      = 11
Ctrl       = 1

[State 5001, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X * Const(Movement.Stand.Friction) * (ABS(Vel X * Const(Movement.Stand.Friction)) > 1)

[State 5001, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5011, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5011, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5020];HitA_Shake

[State 5020, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5020, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = A
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 5020, StateTypeSet]
Type       = StateTypeSet
Trigger1   = RoundState != 2
StateType  = A
MoveType   = I
Physics    = N
IgnoreHitPause = 1

[State 5020, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Time
Trigger1   = Var(0) := Anim
Trigger2   = GetHitVar(AnimType) != [3,5]
Trigger2   = Var(0) := 5010 - (GetHitVar(AirType) = 1) * 10 + GetHitVar(AnimType)
Trigger3   = Var(0) := 5030
Value      = Var(0)

[State 5020, VelSet]
Type       = VelSet
Trigger1   = !Time
X          = 0
Y          = 0

[State 5020, ChangeState]
Type       = ChangeState
Trigger1   = HitShakeOver
Value      = 5030

[State 5020, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5020, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5020, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5020, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5030];HitA_Up (initial going up)

[State 5030, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5030, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = A
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 5030, StateTypeSet]
Type       = StateTypeSet
Trigger1   = RoundState != 2
StateType  = A
MoveType   = I
Physics    = N
IgnoreHitPause = 1

[State 5030, CtrlSet]
Type       = CtrlSet
Trigger1   = 1
Value      = 0

[State 5030, VelAdd]
Type       = VelAdd
Trigger1   = 1
Y          = GetHitVar(YAccel)

[State 5030, HitVelSet]
Type       = HitVelSet
Trigger1   = !Time
X          = 1
Y          = 1

[State 5030, ChangeState]
Type       = ChangeState
Trigger1   = Hitover || (Vel Y > 0 && Pos Y >= 10)
Trigger1   = Var(0) := 5040 + HitFall * 10
Trigger2   = !AnimTime
Trigger2   = Var(0) := 5035
Value      = Var(0)

[State 5030, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5030, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5030, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5030, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5035];Hita_Up_T (transition)

[State 5035, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5035, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = A
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 5035, ChangeAnim]
Type       = ChangeAnim
Trigger1   = !Time
Trigger1   = Anim != 5090
Value      = 5035

[State 5035, VelAdd]
Type       = VelAdd
Trigger1   = 1
Y          = GetHitVar(YAccel)

[State 5035, ChangeState]
Type       = ChangeState
Trigger1   = HitOver
Trigger2   = !AnimTime
Trigger3   = Vel Y > 0 && Pos Y >= 10
Trigger4   = !Time
Trigger4   = Anim != 5035
Value      = 5040 + HitFall * 10

[State 5035, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5035, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5035, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5035, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5040];HitA_Recov (recovering in air, not falling)

[State 5040, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5040, ChangeState]
Type       = ChangeState
Trigger1   = !Alive
Value      = 5050

[State 5040, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = A
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 5040, StateTypeSet]
Type       = StateTypeSet
Trigger1   = HitOver
MoveType   = I
IgnoreHitPause = 1

[State 5040, ChangeAnim]
Type       = ChangeAnim
Trigger1   = !AnimTime
Trigger1   = Anim != 5040
Trigger2   = !Time
Trigger2   = Anim != 5035
Value      = 5040

[State 5040, CtrlSet]
Type       = CtrlSet
Trigger1   = HitOver
Value      = 1

[State 5040, VelAdd]
Type       = VelAdd
Trigger1   = 1
Y          = GetHitVar(YAccel)

[State 5040, ChangeState]
Type       = ChangeState
Trigger1   = Vel Y > 0 && Pos Y >= 0
Value      = 52

[State 5040, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5040, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5040, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5040, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5050];HitA_Fall (knocked up, falling)

[State 5050, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5050, CommandReset]
Type       = Null
Trigger1   = PalNo < 7
Trigger1   = Var(1) := 0
IgnoreHitPause = 1

[State 5050, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = A
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 5050, ChangeAnim]
Type       = ChangeAnim
Trigger1   = !AnimTime
Trigger1   = Anim = 5035
Trigger2   = !Time
Trigger2   = Anim != 5035
Trigger2   = Anim != 5090
Value      = 5050

[State 5050, VelAdd]
Type       = VelAdd
Trigger1   = 1
Y          = GetHitVar(YAccel)

[State 5050, ChangeState]
Type       = ChangeState
Trigger1   = Alive
Trigger1   = Vel Y > 0 && Pos Y >= -20
Trigger1   = !Var(1) * Command = "recovery" || Var(1) & 1048576
Trigger1   = Var(0) := 5200
Trigger2   = Alive
Trigger2   = Vel Y > -1
Trigger2   = !Var(1) * Command = "recovery" || Var(1) & 1048576
Trigger2   = Var(0) := 5210
Trigger3   = Vel Y > 0 && Pos Y >= 25
Trigger3   = Var(0) := 5100
Value      = Var(0)

[State 5050, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5050, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5050, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5050, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5070];Hit_Trip (shaking)

[State 5070, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5070, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = A
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 5070, StateTypeSet]
Type       = StateTypeSet
Trigger1   = RoundState != 2
StateType  = A
MoveType   = I
Physics    = N
IgnoreHitPause = 1

[State 5070, VelSet]
Type       = VelSet
Trigger1   = 1
X          = 0
Y          = 0

[State 5070, ChangeAnim]
Type       = ChangeAnim 
Trigger1   = Anim != 5070
Value      = 5070

[State 5070, ChangeState]
Type       = ChangeState
Trigger1   = HitShakeOver
Value      = 5071

[State 5070, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5070, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5070, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5070, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5071];Hit_Trip2 (fall through air)

[State 5071, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5071, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = A
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 5071, HitVelSet]
Type       = HitVelSet
Trigger1   = !Time
X          = 1
Y          = 1

[State 5071, VelAdd]
Type       = VelAdd
Trigger1   = 1
Y          = GetHitVar(YAccel)

[State 5071, ChangeState]
Type       = ChangeState
Trigger1   = Vel Y > 0
Trigger1   = Pos Y >= 15
Value      = 5110

[State 5071, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5071, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5071, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5071, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5080];HitL_Shake

[State 5080, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5080, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = L
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 5080, StateTypeSet]
Type       = StateTypeSet
Trigger1   = RoundState != 2
StateType  = L
MoveType   = I
Physics    = N
IgnoreHitPause = 1

[State 5080, VelSet]
Type       = VelSet
Trigger1   = !Time
X          = 0
Y          = 0

[State 5080, ChangeAnim]
Type       = ChangeAnim
Trigger1   = !Time
Trigger1   = Var(0) := 5090 - !(GetHitVar(YVel)) * 10
Trigger2   = Var(0) := Anim
Value      = Var(0)

[State 5080, ChangeState]
Type       = ChangeState
Trigger1   = HitShakeOver
Value      = 5030 + !GetHitVar(YVel) * 51

[State 5080, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5080, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5080, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5080, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5081];HitL_Slide

[State 5081, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5081, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = L
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 5081, HitVelSet]
Type       = HitVelSet
Trigger1   = !Time
X          = 1

[State 5081, VelSet]
Type       = VelSet
Trigger1   = HitOver
X          = 0

[State 5081, ChangeState]
Type       = ChangeState
Trigger1   = HitOver
Value      = 5110

[State 5081, SysVar(0)Set]
Type       = VarSet
Trigger1   = !Time
sysvar(0)  = 1

[State 5081, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5081, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5081, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5081, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5100];Hit_Bounce (hit ground)

[State 5100, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5100, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = L
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 5100, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 5100
Value      = 5100

[State 5100, VelSet_X]
Type       = VelSet
Trigger1   = !Time
Trigger1   = !GetHitVar(Fall.YVel)
Trigger1   = Vel X > 1
X          = 1

[State 5100, VelSet_Y]
Type       = VelSet
Trigger1   = !Time
Y          = 0

[State 5100, VelMul_X]
Type       = VelMul
Trigger1   = !Time
X          = 0.75

[State 5100, PosSet]
Type       = PosSet
Trigger1   = !Time
Y          = 0

[State 5100, FallEnvShake]
Type       = FallEnvShake
Trigger1   = !Time

[State 5100, SysVar(0)Set]
Type       = Varset
TriggerAll = !Time
Trigger1   = Floor(Vel Y) <= 5
Trigger1   = Var(0) := 0               || 1
Trigger2   = Floor(Vel Y) <= 14
Trigger2   = Var(0) := 1
Trigger3   = Floor(Vel Y) >  14
Trigger3   = Var(0) := 2
sysvar(0)  = SysVar(0) | 2 * Var(0)

[State 5100, GameMakeAnim]
Type       = GameMakeAnim
Trigger1   = Time = 1
Value      = 60 + (SysVar(0) & 6 > 2) + (SysVar(0) & 6 = 4)
Pos        = 0, 0
Under      = SysVar(0) & 6 < 4

[State 5100, PlaySnd]
Type       = PlaySnd
Trigger1   = Time = 1
Value      = F7, (SysVar(0) & 6 > 2) + (SysVar(0) & 6 = 4)

[State 5100, HitFallDamage]
Type       = HitFallDamage
Trigger1   = Time = 3
Trigger1   = (GetHitVar(Fall.Damage) = [-2147483647 + Life,20 * (PalNo!=12)])

[State 5100, PosFreeze]
Type       = PosFreeze
Trigger1   = 1

[State 5100, ChangeState]
Type       = ChangeState
Trigger1   = !Time
Trigger1   = !GetHitVar(Fall.YVel)
Trigger1   = Var(0) := 5110
Trigger2   = !AnimTime
Trigger2   = Var(0) := 5101
Value      = Var(0)

[State 5100, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5100, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5100, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5100, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5101];Hit_Bounce (bounce into air)

[State 5101, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5101, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = L
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 5101, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 5160
Value      = 5160

[State 5101, Hitfallvel]
Type       = HitFallVel
Trigger1   = !AnimElemTime(1)

[State 5101, PosSet]
Type       = PosSet
Trigger1   = !AnimElemTime(1)
Y          = 20

[State 5101, VelAdd]
Type       = VelAdd
Trigger1   = 1
Y          = .4

[State 5101, ChangeState]
Type       = ChangeState
Trigger1   = Vel Y > 0
Trigger1   = Pos Y >= 12
Value      = 5110

[State 5101, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5101, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5101, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5101, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5110];Hit_LieDown

[State 5110, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5110, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = L
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 5110, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 5110 && Anim != 5170
Value      = 5170

[State 5110, VelSet]
Type       = VelSet
Trigger1   = Anim = 5170 && !AnimElemTime(1)
Y          = 0

[State 5110, PosSet]
Type       = PosSet
Trigger1   = Anim = 5170 && !AnimElemTime(1)
Y          = 0

[State 5110, HitFallDamage]
Type       = HitFallDamage
Trigger1   = Anim = 5170 && !AnimElemTime(1)
Trigger1   = (GetHitVar(Fall.Damage) = [-2147483647 + Life,20 * (PalNo != 12)])

[State 5110, FallEnvShake]
Type       = FallEnvShake
Trigger1   = Anim = 5170 && !AnimElemTime(1)

[State 5110, SysVar(0)Set]
Type       = VarSet
TriggerAll = Anim = 5170 && !AnimElemTime(1)
TriggerAll = GetHitVar(Fall.YVel)
Trigger1   = Floor(Vel Y) <= 5
Trigger1   = Var(0) := 0 || 1
Trigger2   = Floor(Vel Y) <= 14
Trigger2   = Var(0) := 1
Trigger3   = Floor(Vel Y) >  14
Trigger3   = Var(0) := 2
sysvar(0)  = SysVar(0) | 2 * Var(0)

[State 5110, PlaySnd]
Type       = PlaySnd
Trigger1   = Anim = 5170 && !AnimElemTime(1)
Trigger1   = !(SysVar(0) & 1)
Value      = F7, (SysVar(0) & 6 > 2) + (SysVar(0) & 6 = 4)

[State 5110, GameMakeAnim]
Type       = GameMakeAnim
Trigger1   = Anim = 5170 && !AnimElemTime(1)
Trigger1   = !(SysVar(0) & 1)
Value      = 60 + (SysVar(0) & 6 > 2) + (SysVar(0) & 6 = 4)
Pos        = 0, 0
Under      = SysVar(0) & 6 < 4

[State 5110, ChangeAnim]
Type       = ChangeAnim
Trigger1   = !AnimTime
Trigger2   = SysVar(0) & 1
Value      = 5110
Persistent = 0

[State 5110, VelMul]
Type       = VelMul
Trigger1   = 1
X          = 0.85

[State 5110, ChangeState]
Type       = ChangeState
TriggerAll = !Alive
Trigger1   = !AnimTime
Trigger2   = SysVar(0) & 1
Trigger3   = Anim = 5110
Value      = 5150

[State 5110, SysVar(0)set]
Type       = VarSet
Trigger1   = Anim = 5170 && !AnimElemTime(1) && Alive
Trigger1   = SysVar(0) & 1
sysvar(0)  = 0

[State 5110, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5110, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5110, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5110, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5120];Hit_GetUp

[State 5120, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5120, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = L
MoveType   = I
Physics    = N
IgnoreHitPause = 1

[State 5120, ChangeAnim]
Type       = ChangeAnim
Trigger1   = !Time
Value      = 5120

[State 5120, VelSet]
Type       = VelSet
Trigger1   = !Time
X          = 0

[State 5120, NotHitBy]
Type       = NotHitBy
Trigger1   = 1
Value      = SCA
Time       = 12

[State 5120, PlaySnd]
Type       = PlaySnd
Trigger1   = Alive
Trigger1   = !AnimElemTime(1)
Trigger1   = !(Random % 3)
Value      = 5120, 0

[State 5120, HitFallSet]
Type       = HitFallSet
Trigger1   = !AnimTime
Value      = 1

[State 5120, ChangeState]
Type       = ChangeState
Trigger1   = !AnimTime
Value      = 0
Ctrl       = 1

[State 5120, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5120, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5120, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5120, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5150];Hit_LieDead

[State 5150, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Trigger2   = !IsHelper(10000)
Trigger2   = !IsHelper(15501) && !IsHelper(15502) || Root,PalNo != 12
Value      = 25150
IgnoreHitPause = 1

[State 5150, ChangeState]
Type       = ChangeState
Trigger1   = !IsHelper
Trigger1   = Alive
Value      = SysVar(3)
IgnoreHitPause = 1

[State 5150, StateTypeSet]
Type       = StateTypeSet
Trigger1   = !IsHelper
Trigger1   = 1
StateType  = L
MoveType   = I
Physics    = N
IgnoreHitPause = 1

[State 5150, SprPriority]
Type       = SprPriority
Trigger1   = !IsHelper
Value      = -3

[State 5150, ChangeAnim]
Type       = ChangeAnim
Trigger1   = !IsHelper
Trigger1   = Anim != 5140 + 10 * MatchOver
Value      = 5140 + 10 * MatchOver

[State 5150, VelMul]
Type       = VelMul
Trigger1   = !IsHelper
X          = 0.85

[State 5150, VelSet]
Type       = VelSet
Trigger1   = !IsHelper
Trigger1   = Vel X < .05
X          = 0
Persistent = 0

[State 5150, NotHitBy]
Type       = NotHitBy
Trigger1   = !IsHelper
Value      = SCA

[State 5150, SysFVar(3)Set]
Type       = VarSet
Trigger1   = !IsHelper
sysfvar(3) = Vel X

[State 5150, SysFVar(4)Set]
Type       = VarSet
Trigger1   = !IsHelper
sysfvar(4) = Vel Y

[State 5150, SysVar(2)Set]
Type       = VarSet
Trigger1   = !IsHelper
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5150, SysVar(3)Set]
Type       = VarSet
Trigger1   = !IsHelper
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5200];Hit_FallRecover (still falling)

[State 5200, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5200, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = A
MoveType   = H
Physics    = N
IgnoreHitPause = 1

[State 5200, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim = 5035
Trigger1   = !AnimTime
Value      = 5050

[State 5200, VelAdd]
Type       = VelAdd
Trigger1   = 1
Y          = GetHitVar(YAccel)

[State 5200, ChangeState]
Type       = ChangeState
Trigger1   = Vel Y > 0
Trigger1   = Pos Y >= 10
Value      = 5201

[State 5200, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5200, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y

[State 5200, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5200, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5201];Hit_FallRecover (on the ground)

[State 5201, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5201, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = A
MoveType   = H
Physics    = A
IgnoreHitPause = 1

[State 5201, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 5200
Value      = 5200

[State 5201, Turn] 
Type       = Turn
Trigger1   = !Time
Trigger1   = P2Dist X < -5

[State 5201, VelSet]
Type       = VelSet
Trigger1   = !Time
X          = -.15
Y          = -3.5

[State 5201, PosSet]
Type       = PosSet
Trigger1   = !Time
Y           = 0

[State 5201, NotHitBy]
Type       = NotHitBy
Trigger1   = 1
Value      = SCA

[State 5201, PalFx]
Type       = PalFx
Trigger1   = !Time
Add        = 128,128,128
Time       = 3

[State 5201, GameMakeAnim]
Type       = GameMakeAnim
Trigger1   = Time = 1
Value      = 60
Under      = 1

[State 5201, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5201, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y + Const(Movement.YAccel)

[State 5201, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5201, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5210];Hit_AirFallRecover

[State 5210, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Value      = 25150
IgnoreHitPause = 1

[State 5210, CommandReset]
Type       = Null
Trigger1   = PalNo < 7
Trigger1   = Var(1) := 0
IgnoreHitPause = 1

[State 5210, StateTypeSet]
Type       = StateTypeSet
Trigger1   = 1
StateType  = A
MoveType   = I
Physics    = A
IgnoreHitPause = 1

[State 5210, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 5210
Value      = 5210

[State 5210, CtrlSet]
Type       = CtrlSet
Trigger1   = 1
Value      = 0

[State 5210, PalFx]
Type       = PalFx
Trigger1   = !Time
Add        = 128,128,128
Time       = 3

[State 5210, PosFreeze]
Type       = PosFreeze
Trigger1   = !Time
Value      = 4

[State 5210, Turn]
Type       = Turn
Trigger1   = !Time
Trigger1   = P2Dist X < -20

[State 5210, VelMul] 
Type       = VelMul
Trigger1   = Time = 4
X          = .8
Y          = .8

[State 5210, VelAdd]
Type       = VelAdd
Trigger1   = Time = 4
Y          = -4.5

[State 5210, VelMul] 
Type       = VelMul
Trigger1   = Time = 4
Trigger1   = Vel Y > 0
Y          = .5

[State 5210, VelAdd]
Type       = VelAdd
Trigger1   = Time = 4
Trigger1   = Vel Y > -3
Y          = -2

[State 5210, VelAdd]
Type       = VelAdd
Trigger1   = Time = 4
Trigger1   = Vel Y > -2
Y          = -1

[State 5210, VelAdd]
Type       = VelAdd
TriggerAll = Time = 4
Trigger1   = !Var(1) * Command = "holdup"   || Var(1) & 2
Trigger1   = FVar(0) := -2
Trigger2   = !Var(1) * Command = "holddown" || Var(1) & 1
Trigger2   = FVar(0) := 1.5
Y          = FVar(0)

[State 5210, VelMul]
Type       = VelMul
Trigger1   = Time = 4
Trigger1   = !Var(1) * Command = "holdfwd"  || Var(1) & 8
X          = 1

[State 5210, VelAdd]
Type       = VelAdd
Trigger1   = Time = 4
Trigger1   = !Var(1) * Command = "holdback" || Var(1) & 4
X          = -1

[State 5210, VelAdd]
Type       = VelAdd
Trigger1   = Time >= 4
Y          = .35

[State 5210, NotHitBy]
Type       = NotHitBy
Trigger1   = !Time
Value      = SCA
Time       = 15

[State 5210, CtrlSet]
Type       = CtrlSet
Trigger1   = Time = 20
Value      = 1

[State 5210, ChangeState]
Type       = ChangeState
Trigger1   = Vel Y > 0
Trigger1   = Pos Y >= 0
Value      = 52
Ctrl       = 1

[State 5210, SysFVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(3) = Vel X

[State 5210, SysFVar(4)Set]
Type       = VarSet
Trigger1   = 1
sysfvar(4) = Vel Y + Const(Movement.YAccel)

[State 5210, SysVar(2)Set]
Type       = VarSet
Trigger1   = 1
sysvar(2)  = (StateType = C) + (StateType = A) * 2 | 16 * !!Ctrl | 32 * (facing = 1) | (SysVar(2) & 64) | 128 * (!Var(1) * Command = "holdup" || !!(Var(1) & 2)) | (SysVar(2) & 2147483392)
IgnoreHitPause = 1

[State 5210, SysVar(3)Set]
Type       = VarSet
Trigger1   = 1
sysvar(3)  = (StateType = C) * 11 + (StateType = A) * 50
IgnoreHitPause = 1


;---------------------------------------------------------------------------
[StateDef 5500];Continue?

[State 5500, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Trigger3   = RoundState
Value      = 25150
IgnoreHitPause = 1

[State 5500, CtrlSet]
Type       = CtrlSet
Trigger1   = 1
Value      = 0

[State 5500, VelSet]
Type       = VelSet
Trigger1   = 1
X          = 0
Y          = 0

[State 5500, ChangeAnim]
Type       = ChangeAnim
Trigger1   = Anim != 170
Value      = 170


;---------------------------------------------------------------------------
[StateDef 5900];Initialize (at the start of the round)

[State 5900, ChangeState]
Type       = ChangeState
Trigger1   = P1Name != "Sino" || !AuthorName = "Hit"
Trigger2   = IsHelper
Trigger3   = RoundState
Value      = 25150
IgnoreHitPause = 1

[State 5900, VarSet]
Type       = NULL
Trigger1   = Var(10) := 1000
Trigger1   = Var(11) := 0
Trigger2   = NumEnemy
Trigger2   = Var(30) := Enemy,Life    && 0
Trigger3   = NumEnemy > 1
Trigger3   = Var(40) := Enemy(1),Life && 0
IgnoreHitPause = 1

[State 5900, ChangeState]
Type       = ChangeState
Trigger1   = 1
Value      = !RoundsExisted * 190
IgnoreHitPause = 1
