;-| Hypers |-----------------------------------------------------------------------------------
;-[SHINING GOU SHOCK]------
[Command]
name = "ShinGoSh"
command = x, x, F, a, z
time = 50

;-[TAMEIKI WARI]------
[Command]
name = "Tameiki Wari"
command = ~s, s, s
time = 15

;-[SCRAMBLE GOU RASSEN]------
[Command]
name = "QCB2_b"
command = ~D, DB, B, a+b
time = 30

[Command]
name = "QCB2_b"
command = ~D, DB, B, a+c

[Command]
name = "QCB2_b"
command = ~D, DB, B, c+b

[Command]
name = "QCB2_b"
command = ~D, DB, B, a+b+c

;-[SCRAMBLE GOU PUNCH (Tierra)//THUNDER GOU SHOWER (Aire)]------
[Command]
name = "QCF2_z"
command = ~D, DF, F, z+y

[Command]
name = "QCF2_z"
command = ~D, DF, F, x+y

[Command]
name = "QCF2_z"
command = ~D, DF, F, z+x

;-[HIGH MEGA GOU BEAM ]--en AIRE y TIERRA------ 
[Command]
name = "QCB2_y"
command = ~D, DB, B, y+z
time = 22

[Command]
name = "QCB2_y"
command = ~D, DB, B, y+x
time = 22

[Command]
name = "QCB2_y"
command = ~D, DB, B, z+x
time = 22

;-| Especiales |-------------------------------------------------------------------------------
; Asura Senkuu Forward
[Command]
name = "asuraf_a"
command = ~F, D, DF, a+b

[Command]
name = "asuraf_b"
command = ~F, D, DF, b+c

[Command]
name = "asuraf_c"
command = ~F, D, DF, a+c

[Command]
name = "asuraf_x"
command = ~F, D, DF, x+y

[Command]
name = "asuraf_y"
command = ~F, D, DF, y+z

[Command]
name = "asuraf_z"
command = ~F, D, DF, x+z

;-----------------
; Asura Senkuu Backward
[Command]
name = "asurab_a"
command = ~B, D, DB, a+b

[Command]
name = "asurab_b"
command = ~B, D, DB, b+c

[Command]
name = "asurab_c"
command = ~B, D, DB, a+c

[Command]
name = "asurab_x"
command = ~B, D, DB, x+y

[Command]
name = "asurab_y"
command = ~B, D, DB, y+z

[Command]
name = "asurab_z"
command = ~B, D, DB, x+z

;-----------------
; QCF
[Command]
name = "QCF_a"
command = ~D, DF, F, a

[Command]
name = "QCF_b"
command = ~D, DF, F, b

[Command]
name = "QCF_c"
command = ~D, DF, F, c

[Command]
name = "QCF_x"
command = ~D, DF, F, x

[Command]
name = "QCF_y"
command = ~D, DF, F, y

[Command]
name = "QCF_z"
command = ~D, DF, F, z

;-----------------
; QCB
[Command]
name = "QCB_a"
command = ~D, DB, B, a

[Command]
name = "QCB_b"
command = ~D, DB, B, b

[Command]
name = "QCB_c"
command = ~D, DB, B, c

[Command]
name = "QCB_x"
command = ~D, DB, B, x

[Command]
name = "QCB_y"
command = ~D, DB, B, y

[Command]
name = "QCB_z"
command = ~D, DB, B, z

;-----------------
; QCD
[Command]
name = "QCD_a"
command = ~B, DB, D, a

[Command]
name = "QCD_b"
command = ~B, DB, D, b

[Command]
name = "QCD_c"
command = ~B, DB, D, c

[Command]
name = "QCD_x"
command = ~B, DB, D, x

[Command]
name = "QCD_y"
command = ~B, DB, D, y

[Command]
name = "QCD_z"
command = ~B, DB, D, z

;-----------------
; Uppercut
[Command]
name = "uppercut_a"
command = ~F, D, DF, a

[Command]
name = "uppercut_b"
command = ~F, D, DF, b

[Command]
name = "uppercut_c"
command = ~F, D, DF, c

[Command]
name = "uppercut_x"
command = ~F, D, DF, x

[Command]
name = "uppercut_y"
command = ~F, D, DF, y

[Command]
name = "uppercut_z"
command = ~F, D, DF, z

;-| Doble Tipeo |------------------------------------------------------------------------------
;Correr
[Command]
name = "FF";-----[No Remover]
command = F, F
time = 10

;Retroceder
[Command]
name = "BB";-----[No Remover]
command = B, B
time = 10

;-| Otros |------------------------------------------------------------------------------------
;Super Salto
[Command]
name = "SuperJump"
command = ~D, U
time = 10

[Command]
name = "PT"
command = a+z
time = 1

;Zero/Alpha Counter A
[Command]
name = "ff_c"
command = y+b
time = 1

[Command]
name = "ff_z"
command = z+c
time = 1

[Command]
name = "ff_a"
command = F, F, a
time = 15

[Command]
name = "ff_b"
command = F, F, b
time = 15

[Command]
name = "ff_c"
command = F, F, c
time = 15

[Command]
name = "ff_x"
command = F, F, x
time = 15

[Command]
name = "ff_y"
command = F, F, y
time = 15

[Command]
name = "ff_z"
command = F, F, z
time = 15
 
;-| 2/3 Combinaciones |------------------------------------------------------------------------
;Recuperacion
[Command]
name = "recovery";-----[No Remover]
command = s
time = 1

[Command]
name = "ab"
command = a+b
time = 1

[Command]
name = "xy"
command = x+y
time = 1

[Command]
name = "xz"
command = x+z
time = 1

[Command]
name = "yz"
command = y+z
time = 1

[Command]
name = "ac"
command = a+c
time = 1

[Command]
name = "bc"
command = b+c
time = 1

;Guard Push---------------------
[Command]
name = "xyz"
command = x+y+z
time = 1

[Command]
name = "xyz"
command = x+y
time = 1

[Command]
name = "xyz"
command = z+y
time = 1

;-| Dir + Button |-----------------------------------------------------------------------------
[Command]
name = "fwd_a"
command = /F,a
time = 1

[Command]
name = "fwd_b"
command = /F,b
time = 1

[Command]
name = "fwd_c"
command = /F,c
time = 1

[Command]
name = "fwd_x"
command = /F,x
time = 1

[Command]
name = "fwd_y"
command = /F,y
time = 1

[Command]
name = "fwd_z"
command = /F,z
time = 1

[Command]
name = "back_a"
command = /B,a
time = 1

[Command]
name = "back_b"
command = /B,b
time = 1

[Command]
name = "back_c"
command = /B,c
time = 1

[Command]
name = "down_a"
command = /$D,a
time = 1

[Command]
name = "down_b"
command = /$D,b
time = 1

[Command]
name = "down_c"
command = /$D,c
time = 1

[Command]
name = "fwd_ab"
command = /F, a+b
time = 1

[Command]
name = "back_ab"
command = /B, a+b
time = 1

;-| Button |-----------------------------------------------------------------------------------
[Command]
name = "a"
command = a
time = 1

[Command]
name = "b"
command = b
time = 1

[Command]
name = "c"
command = c
time = 1

[Command]
name = "x"
command = x
time = 1

[Command]
name = "y"
command = y
time = 1

[Command]
name = "z"
command = z
time = 1

[Command]
name = "s"
command = s
time = 1

;-| Hold Button |------------------------------------------------------------------------------
[Command]
name = "hold_x"
command = /x
time = 1

[Command]
name = "hold_y"
command = /y
time = 1

[Command]
name = "hold_z"
command = /z
time = 1

[Command]
name = "hold_a"
command = /a
time = 1

[Command]
name = "hold_b"
command = /b
time = 1

[Command]
name = "hold_c"
command = /c
time = 1

[Command]
name = "hold_s"
command = /s
time = 1

;-| Hold Dir |---------------------------------------------------------------------------------
[Command]
name = "holdfwd";-----[No Remover]
command = /$F
time = 1

[Command]
name = "holdback";-----[No Remover]
command = /$B
time = 1

[Command]
name = "holdup";-----[No Remover]
command = /$U
time = 1

[Command]
name = "holddown";-----[No Remover]
command = /$D
time = 1

;-| AI |--------------------------------------------------------------
[Command]
name = "AI1"
command = U,D,B,F,U,D,B,F,b,b,a,a,s
time = 0

[Command]
name = "AI2"
command = U,D,U,D,U,D,U,D,U,D,U,D,a+b+c+x+y+z
time = 0

[Command]
name = "AI3"
command = U,F,B,D,B,F,U,x,x,x,y,y,y,z,z,z
time = 0

[Command]
name = "AI4"
command = x,x,x,x,x,x,x,x,x,x,x,x,x,x,x,x
time = 0

[Command]
name = "AI5"
command = y,y,y,y,y,y,y,y,y,y,y,y,y,y,y,y
time = 0

[Command]
name = "AI6"
command = z,z,z,z,z,z,z,z,z,z,z,z,z,z,z,z
time = 0

[Command]
name = "AI7"
command = x+y+z,x+y+z,x+y+z,x+y+z,x+y+z,x+y+z,x+y+z
time = 0

[Command]
name = "AI8"
command = a+b+c,a+b+c,a+b+c,a+b+c,a+b+c,a+b+c,a+b+c
time = 0

[Command]
name = "AI9"
command = y,a,B,B,a,D,a,B,B,a
time = 0

[Command]
name = "AI10"
command = c,U,B,B,y,B,U,D,D,y
time = 0

[Command]
name = "AI11"
command = x,x
time = 0

[Command]
name = "AI12"
command = y,y
time = 0

[Command]
name = "AI13"
command = z,z
time = 0

[Command]
name = "AI14"
command = a,a
time = 0

[Command]
name = "AI15"
command = b,b
time = 0

[Command]
name = "AI16"
command = c,c
time = 0

[Command]
name = "AI17"
command = U,x
time = 0

[Command]
name = "AI18"
command = D,x
time = 0

[Command]
name = "AI19"
command = B,x
time = 0

[Command]
name = "AI20"
command = F,x
time = 0

[Command]
name = "AI0"
command = U,U,D,D,B,F,B,F,b,a,s
time = 0

;---------------------------------------------------------------------------
; 2. State entry
; --------------
; This is where you define what commands bring you to what states.
;
; Each state entry block looks like:
;   [State -1]                  ;Don't change this
;   type = ChangeState          ;Don't change this
;   value = new_state_number
;   trigger1 = command = "command_name"
;   . . .  (any additional triggers)
;
; - new_state_number is the number of the state to change to
; - command_name is the name of the command (from the section above)
; - Useful triggers to know:
;   - statetype
;       S, C or A : current state-type of player (stand, crouch, air)
;   - ctrl
;       0 or 1 : 1 if player has control. Unless "interrupting" another
;                move, you'll want ctrl = 1
;   - stateno
;       number of state player is in - useful for "move interrupts"
;   - movecontact
;       0 or 1 : 1 if player's last attack touched the opponent
;                useful for "move interrupts"
;
; For reference on triggers, see CNS documentation.
;
; Just for your information (skip if you're not interested):
; This part is an extension of the CNS. "State -1" is a special state
; that is executed once every game-tick, regardless of what other state
; you are in. 


; Don't remove the following line. It's required by the CMD standard.
[Statedef -1]
;===========================================================================
;---------------------------------------------------------------------------
;Activate AI
[State -1, Activate AI]
type = VarSet
triggerall = var(59) = 0
trigger1 = IsHomeTeam
trigger1 = TeamSide = 2
trigger2 = command = "AI0"
trigger3 = command = "AI1"
trigger4 = command = "AI2"
trigger5 = command = "AI3"
trigger6 = command = "AI4"
trigger7 = command = "AI5"
trigger8 = command = "AI6"
trigger9 = command = "AI7"
trigger10 = command = "AI8"
trigger11 = command = "AI9"
trigger12 = command = "AI10"
trigger13 = command = "AI11"
trigger14 = command = "AI12"
trigger15 = command = "AI13"
trigger16 = command = "AI14"
trigger17 = command = "AI15"
trigger18 = command = "AI16"
trigger19 = command = "AI17"
trigger20 = command = "AI18"
trigger21 = command = "AI19"
trigger22 = command = "AI20"
v = 59
value = 1

;---------------------------------------------------------------------------
;Activate AI
[State -1, Activate AI]
type = VarSet
trigger1 = var(59) = 2
trigger1 = RoundState != 3
v = 59
value = 1

;---------------------------------------------------------------------------
;Deactivate AI
[State -1, Deactivate AI]
type = VarSet
triggerall = var(59) != 0
trigger1 = RoundState = 3
v = 59
value = 2

;---------------------------------------------------------------------------
;Liedown AI
[State -1, Liedown AI]
type = VarSet
triggerall = var(59) = 1
trigger1 = p2statetype = L
trigger2 = p2stateno = [5050,5079]
v = 59
value = 4

;---------------------------------------------------------------------------
;Liedown AI Off
[State -1, Liedown AI Off]
type = VarSet
triggerall = var(59) = 4
trigger1 = p2statetype != L
trigger1 = p2stateno != [5050,5079]
v = 59
value = 1

;---------------------------------------------------------------------------
;Check Miss AI Begin Attack
[State -1, Check Miss AI Begin Attack]
type = VarSet
triggerall = var(59) != 0
triggerall = var(58) <= 0
trigger1 = movetype = A
v = 58
value = stateno

;---------------------------------------------------------------------------
;Check Miss AI Hit
[State -1, Check Miss AI Hit]
type = VarSet
triggerall = var(59) != 0
triggerall = var(58) != 0
trigger1 = movecontact
trigger2 = movetype = I
trigger2 = random < 10
trigger3 = stateno = [150,159]
v = 58
value = 0

;---------------------------------------------------------------------------
;Check Miss AI End Attack
[State -1, Check Miss AI End Attack]
type = VarSet
triggerall = var(59) != 0
triggerall = var(58) > 0
trigger1 = ctrl = 1
v = 58
value = var(58)*(-1)

;===========================================================================
; AI hiper
;===========================================================================
[State -1, HIGH MEGA GOU BEAM]
type = ChangeState
value = 2010
triggerall = (abs(var(58)) != 2010) || (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = stateno != [5000,5120]
triggerall = statetype = S
triggerall = power >= 1000
triggerall = numhelper(2012) = 0
trigger1 = p2bodydist x > 260
trigger1 = p2bodydist x < 280
trigger1 = p2bodydist y = [-50,30]
trigger1 = random < 600
triggerall = var(59) = 1
triggerall = power != [999,0]
triggerall = stateno != [4000,4001] 
triggerall = stateno != [4005,4006] 
triggerall = stateno != [4010,4011] 
triggerall = stateno != [4015,4016] 
triggerall = stateno != [4030,4031]
triggerall = stateno != 2700 
triggerall = stateno != 4500
triggerall = stateno != 2010
triggerall = stateno != 3600
triggerall = stateno != 198
triggerall = stateno != 1170
triggerall = stateno != 4900
triggerall = Prevstateno != 2700 
triggerall = Prevstateno != 4500
triggerall = Prevstateno != 2010
triggerall = Prevstateno != 3600
triggerall = Prevstateno != 198
triggerall = Prevstateno != 1170
triggerall = Prevstateno != 4900
ctrl = 0

[State -1, SCRAMBLE GOU PUNCH]
type = ChangeState
value = 1170
triggerall = (abs(var(58)) != 1170)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = stateno != [5000,5120]
triggerall = statetype = S
triggerall = power >= 1000
trigger1 = p2bodydist x > 80
trigger1 = p2bodydist x < 100
trigger1 = p2bodydist y = 0
trigger1 = random < 600
triggerall = var(59) = 1
triggerall = stateno != [4000,4001] 
triggerall = stateno != [4005,4006] 
triggerall = stateno != [4010,4011] 
triggerall = stateno != [4015,4016] 
triggerall = stateno != [4030,4031]
triggerall = stateno != 2700 
triggerall = stateno != 4500
triggerall = stateno != 2010
triggerall = stateno != 3600
triggerall = stateno != 198
triggerall = stateno != 1170
triggerall = stateno != 4900
triggerall = Prevstateno != 2700 
triggerall = Prevstateno != 4500
triggerall = Prevstateno != 2010
triggerall = Prevstateno != 3600
triggerall = Prevstateno != 198
triggerall = Prevstateno != 1170
triggerall = Prevstateno != 4900
ctrl = 0

;===========================================================================
; AI Agarre
;===========================================================================
;---------------------------------------------------------------------------

;===========================================================================
; AI Guard-La proteccion
;===========================================================================
;---------------------------------------------------------------------------
;Guard (ChangeToCrouching)
[State -1, Guard (ChangeToCrouching)]
type = ChangeState
value = 152
triggerall = var(59) = 1
triggerall = stateno = 150
triggerall = p2statetype = C
trigger1 = p2movetype = A
trigger2 = enemy, NumProj != 0

;---------------------------------------------------------------------------
;Guard (ChangeToStanding)
[State -1, Guard (ChangeToStanding)]
type = ChangeState
value = 150
triggerall = var(59) = 1
triggerall = stateno = 152
triggerall = p2statetype = A
trigger1 = p2movetype = A
trigger2 = enemy, NumProj != 0

;---------------------------------------------------------------------------
;Guard (Crouching)
[State -1, Guard (Crouching)]
type = ChangeState
value = 131
triggerall = var(59) = 1
triggerall = (ctrl && statetype != A) || (stateno = 100) || (stateno = 105)
triggerall = p2statetype != A
trigger1 = p2movetype = A
trigger1 = enemy, MoveGuarded = 0
trigger2 = enemy, NumProj != 0
triggerall = ctrl = 1

;;---------------------------------------------------------------------------
;Guard (Standing)
[State -1, Guard (Standing)]
type = ChangeState
value = 130
triggerall = var(59) = 1
triggerall = statetype != A
triggerall = (ctrl && statetype != A) || (stateno = 100) || (stateno = 105)
triggerall = p2statetype != C
trigger1 = p2movetype = A
trigger1 = enemy, MoveGuarded = 0
trigger2 = enemy, NumProj != 0

;;---------------------------------------------------------------------------
;Guard (Air)
[State -1, Guard (Air)]
type = ChangeState
value = 132
triggerall = var(59) = 1
triggerall = statetype = A
triggerall = ctrl
trigger1 = p2movetype = A
trigger1 = enemy, MoveGuarded = 0
trigger2 = enemy, NumProj != 0

;===========================================================================
; AI Combo en tierra
;===========================================================================
;---------------------------------------------------------------------------
;Stand X
[State -1]
type = ChangeState
value = 200
triggerall = (abs(var(58)) != 200)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = var(59) = 1
triggerall = statetype = S
triggerall = stateno != 200
triggerall = stateno != 201
triggerall = stateno != 205
triggerall = stateno != 206
trigger1 = p2dist X < 50
trigger1 = p2dist Y = [-55,10]
;triggerall = random < 100
trigger2 = stateno = 946
trigger3 = stateno = 560
trigger3 = movecontact = 1
trigger2 = movehit = 1
triggerall = stateno != 2700 
triggerall = stateno != 4500
triggerall = stateno != 2010
triggerall = stateno != 3600
triggerall = stateno != 198
triggerall = stateno != 1170
triggerall = stateno != 4900
triggerall = Prevstateno != 2700 
triggerall = Prevstateno != 4500
triggerall = Prevstateno != 2010
triggerall = Prevstateno != 3600
triggerall = Prevstateno != 198
triggerall = Prevstateno != 1170
triggerall = Prevstateno != 4900
triggerall = stateno = 4000

;---------------------------------------------------------------------------
;Stand Y
[State -1]
type = ChangeState
value = 201
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 201)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = statetype = S
triggerall = stateno != 201
triggerall = stateno != 205
triggerall = stateno != 206
trigger1 = movecontact = 1
trigger1 = stateno = 200

;---------------------------------------------------------------------------
;Stand A
[State -1]
type = ChangeState
value = 204
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 204)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = statetype = S
triggerall = stateno != 204
trigger1 = movecontact = 1
trigger1 = stateno = 404

;---------------------------------------------------------------------------
;Stand B
[State -1]
type = ChangeState
value = 205
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 205)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = statetype = S
triggerall = stateno != 200
triggerall = stateno != 205
triggerall = stateno != 206
trigger1 = movecontact = 1
trigger1 = stateno = 201

;---------------------------------------------------------------------------
;Stand C
[State -1]
type = ChangeState
value = 206
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 206)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = statetype = S
trigger1 = movecontact = 1
trigger1 = stateno = 205
triggerall = stateno != 206
triggerall = stateno != 200
triggerall = stateno != 201

;---------------------------------------------------------------------------
;Crouch X
[State -1]
type = ChangeState
value = 400
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 400)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = statetype = C
trigger1 = movecontact = 1
trigger1 = stateno = 405
triggerall = stateno != 400

;---------------------------------------------------------------------------
;Crouch Y
[State -1]
type = ChangeState
value = 401
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 401)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = statetype = C
trigger1 = movecontact = 1
trigger1 = stateno = 400
triggerall = stateno != 401

;---------------------------------------------------------------------------
;Crouch Z
[State -1]
type = ChangeState
value = 402
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 402)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
trigger1 = movecontact = 1
triggerall = stateno != 402
trigger1 = stateno = 206
trigger1 = p2dist X < 50
trigger1 = p2dist Y = [-55,10]
triggerall = stateno != 2700 
triggerall = stateno != 4500
triggerall = stateno != 2010
triggerall = stateno != 3600
triggerall = stateno != 198
triggerall = stateno != 1170
triggerall = stateno != 4900
triggerall = Prevstateno != 2700 
triggerall = Prevstateno != 4500
triggerall = Prevstateno != 2010
triggerall = Prevstateno != 3600
triggerall = Prevstateno != 198
triggerall = Prevstateno != 1170
triggerall = Prevstateno != 490
triggerall = stateno != 4000

;---------------------------------------------------------------------------
;Crouch B
[State -1]
type = ChangeState
value = 405
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 405)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = statetype = C
trigger1 = movecontact = 1
trigger1 = stateno = 206
triggerall = stateno != 405
trigger1 = p2dist X > 51
trigger1 = p2dist Y = [-55,10]
triggerall = stateno != 2700 
triggerall = stateno != 4500
triggerall = stateno != 2010
triggerall = stateno != 3600
triggerall = stateno != 198
triggerall = stateno != 1170
triggerall = stateno != 4900
triggerall = Prevstateno != 2700 
triggerall = Prevstateno != 4500
triggerall = Prevstateno != 2010
triggerall = Prevstateno != 3600
triggerall = Prevstateno != 198
triggerall = Prevstateno != 1170
triggerall = Prevstateno != 490
triggerall = stateno != 4000

;---------------------------------------------------------------------------
;Crouch C
[State -1]
type = ChangeState
value = 406
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 406)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = statetype = C
trigger1 = movecontact = 1
trigger1 = stateno = 401
triggerall = stateno != 406

;---------------------------------------------------------------------------
;
[State -1, ??]
type = ChangeState
value = 3021
triggerall = stateno != 500
triggerall = (abs(var(58)) != 3021)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
trigger1 = stateno = 550  
trigger1 = movecontact
trigger1 = var(59) = 1

;===========================================================================
; AI Aerial Rave
;===========================================================================
;Super Jump
[State -1, Jump]
type = ChangeState
value = 60
triggerall = var(59) = 1
trigger1 = StateNo = 402
trigger1 = AnimElem >= 1 
trigger1 = AnimElem <= 3
trigger1 = Movecontact

;===========================================================================
;Super Jump
[State -1, Jump]
type = ChangeState
value = 50
triggerall = var(59) = 1
trigger1 = StateNo = 402
trigger1 = AnimElem >= 4 
trigger1 = AnimElem <= 16
trigger1 = Movecontact

;---------------------------------------------------------------------------
;Jump Forwards
;[State 110, 3]
;type = VelSet 
;triggerall = var(59) = 1
;trigger1 = StateNo = 61
;x = 3

;---------------------------------------------------------------------------
;Jump Light Punch
[State -1, Jump Light Punch]
type = ChangeState
value = 600
triggerall = var(59) = 1
triggerall = P2BodyDist X = [0,50]
triggerall = P2BodyDist Y = [-50,30]
triggerall = Pos Y = [-70,-500]
trigger1 = statetype = A
trigger1 = ctrl
trigger1 = stateno = 61
trigger2 = stateno = 61
trigger3 = stateno = 50
trigger2 = statetype = A
trigger3 = statetype = A
ctrl = 0

;---------------------------------------------------------------------------
;Jump Punch
[State -1, Jump Punch]
type = ChangeState
value = 601
triggerall = var(59) = 1
triggerall = movecontact
trigger1 = stateno = 600
trigger2 = stateno = 604
trigger3 = stateno = 704

;---------------------------------------------------------------------------
;Jump Medium Punch
[State -1, Jump Medium Punch]
type = ChangeState
value = 705
triggerall = var(59) = 1
trigger1 = movecontact
trigger1 = stateno = 601
trigger1 = vel x = 0

;---------------------------------------------------------------------------
;Jump Medium Punch
[State -1, Jump Medium Punch]
type = ChangeState
value = 706
triggerall = var(59) = 1
trigger1 = movecontact
trigger1 = stateno = 705
trigger1 = vel x = 0

;---------------------------------------------------------------------------
;Jump Medium Punch
[State -1, Jump Medium Punch]
type = ChangeState
value = 605
triggerall = var(59) = 1
trigger1 = movecontact
trigger1 = stateno = 601
trigger1 = vel x > 0

;---------------------------------------------------------------------------
;Jump Medium Punch
[State -1, Jump Medium Punch]
type = ChangeState
value = 606
triggerall = var(59) = 1
trigger1 = movecontact
trigger1 = stateno = 705
trigger1 = vel x > 0

;---------------------------------------------------------------------------
;Jump Light Kick
[State -1, Jump Light Kick]
type = ChangeState
value = 604
triggerall = var(59) = 1
trigger1 = P2BodyDist X = [0,50]
trigger1 = P2BodyDist Y = [-50,30]
triggerall = Pos Y = [-51,-500]
trigger1 = statetype = A
triggerall = Vel x > 0
triggerall = stateno != 604

;---------------------------------------------------------------------------
[State -1, Jump Light Punch]
type = ChangeState
value = 704
triggerall = var(59) = 1
triggerall = P2BodyDist X = [0,50]
triggerall = P2BodyDist Y = [-50,30]
triggerall = statetype = A
trigger1 = ctrl
trigger1 = stateno = 61
trigger2 = stateno = 61
trigger3 = stateno = 50
triggerall = Vel x = 0

;---------------------------------------------------------------------------
;Jump Strong Kick
[State -1, Jump Strong Kick]
type = ChangeState
value = 602
triggerall = var(59) = 1
trigger1 = movecontact
trigger1 = stateno = 601

;===========================================================================
; AI Special Moves
;===========================================================================
;---------------------------------------------------------------------------
;Adoken
[State -1, MS]
type = ChangeState
value = 1000
triggerall = var(59) = 1
triggerall = statetype != A
triggerall = NumProj = 0
triggerall = (abs(var(58)) != 1002)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
trigger1 = ctrl
trigger1 = p2dist X > 200
trigger1 = p2dist Y = [-50,0]
;trigger2 = (stateno = [200,201])  || (stateno = [204,206])
trigger1 = random < 500

;---------------------------------------------------------------------------
;GOU SHO RYU
[State -1, GOU SHO RYU]
type = ChangeState
value = 1100
triggerall = var(59) = 1
triggerall = statetype = S
triggerall = (abs(var(58)) != 1120)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
trigger1 = ctrl
triggerall = p2dist X < 81
triggerall = p2dist Y = [-130,80]
trigger1 = (stateno = [200,201])  || (stateno = [204,206])
trigger1 = random < 400
trigger2 = Stateno = 0
Trigger2 = PrevStateNo = [3020,3022]

;---------------------------------------------------------------------------
;TENMA GOU KUU JIN KYAKU A
[State -1, TENMA GOU KUU JIN KYAKU A]
type = ChangeState
value = 848
triggerall = var(59) = 1
triggerall = statetype = A
triggerall = (abs(var(58)) != 848)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
trigger1 = ctrl
trigger1 = ctrl = 1 &&  (stateno = 50) || (stateno = 61)
trigger1 = P2bodydist X = [40,80]
trigger1 = P2Bodydist Y = [40,100]
trigger1 = p2movetype != A && random <= 200
trigger2 = ctrl = 1 && (stateno = 50) || (stateno = 61)
trigger2 = P2bodydist X = [30,70]
trigger2 = P2Bodydist Y = [30,90]
trigger2 = p2movetype != A && random <= 200

;---------------------------------------------------------------------------
;TATSU MAKI ZANKUU KYAKU
[State -1, TATSU MAKI ZANKUU KYAKU]
type = ChangeState
value = 3000
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 3020)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
trigger1 = statetype = S
trigger1 = ctrl
trigger1 = p2dist X < 100
trigger1 = p2dist Y = [-100,30]
trigger1 = (stateno = 400)  || (stateno = 205)

;---------------------------------------------------------------------------
;TATSU MAKI ZANKUU KYAKU
[State -1, TATSU MAKI ZANKUU KYAKU]
type = ChangeState
value = 3030
triggerall = var(59) = 1
triggerall = statetype = A
triggerall = (abs(var(58)) != 3050)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
trigger1 = ctrl
triggerall = p2dist X < 70
triggerall = p2dist Y = [-100,30]
trigger1 = (stateno = 601)  || (stateno = 705)
trigger1 = random < 400
trigger1 = movecontact = 1

;===========================================================================
; AI Normal Moves
;===========================================================================
;---------------------------------------------------------------------------
;Crouching Medium Kick
[State -1, Crouching Medium Kick]
type = ChangeState
value = 405
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 405)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = (ctrl && statetype != A) || (stateno = 100) || (stateno = 105)
trigger1 = (p2statetype = C && Random < 333) || (p2statetype = S && Random < 667)
trigger1 = p2bodydist x = [0,33]
trigger1 = enemy, pos y = 0

;---------------------------------------------------------------------------
;Crouching Strong Kick
[State -1, Crouching Strong Kick]
type = ChangeState
value = 406
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 406)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = (ctrl && statetype != A) || (stateno = 100) || (stateno = 105)
trigger1 = (p2statetype = C && Random < 333) || (p2statetype = S && Random < 667)
trigger1 = p2bodydist x = [0,40]
trigger1 = enemy, pos y = 0

;---------------------------------------------------------------------------
;Crouching Light Punch
[State -1, Crouching Light Punch]
type = ChangeState
value = 400
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 400)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = (ctrl && statetype != A) || (stateno = 100) || (stateno = 105)
trigger1 = (p2statetype = C && Random < 333) || (p2statetype = S && Random < 667)
trigger1 = p2bodydist x = [0,30]
trigger1 = enemy, pos y = 0

;---------------------------------------------------------------------------
;Crouching Medium Punch
[State -1, Crouching Medium Punch]
type = ChangeState
value = 401
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 401)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = (ctrl && statetype != A) || (stateno = 100) || (stateno = 105)
trigger1 = (p2statetype = C && Random < 333) || (p2statetype = S && Random < 667)
trigger1 = p2bodydist x = [0,32]
trigger1 = enemy, pos y = 0

;---------------------------------------------------------------------------
;Crouching Strong Punch
[State -1, Crouching Strong Punch]
type = ChangeState
value = 402
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 402)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = (ctrl && statetype != A) || (stateno = 100) || (stateno = 105)
trigger1 = (p2statetype = C && Random < 333) || (p2statetype = S && Random < 667)
trigger1 = p2bodydist x = [0,20]
trigger1 = enemy, pos y = [-250,0]

;---------------------------------------------------------------------------
;Stand Light Punch
[State -1, Stand Light Punch]
type = ChangeState
value = 200
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 200)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = (ctrl && statetype != A) || (stateno = 100) || (stateno = 105)
trigger1 = (p2statetype = C && Random < 667) || (p2statetype = S && Random < 333)
trigger1 = p2bodydist x = [0,50]
trigger1 = enemy, pos y = [-30,0]

;---------------------------------------------------------------------------
;Stand Medium Punch
[State -1, Stand Medium Punch]
type = ChangeState
value = 201
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 201)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = (ctrl && statetype != A) || (stateno = 100) || (stateno = 105)
trigger1 = (p2statetype = C && Random < 667) || (p2statetype = S && Random < 333)
trigger1 = p2bodydist x = [0,70]
trigger1 = enemy, pos y = [-30,0]

;---------------------------------------------------------------------------
;Stand Buster
[State -1, Stand Buster]
type = ChangeState
value = 667
triggerall = var(59) = 1
triggerall = statetype = S
triggerall = stateno != 970
triggerall = (abs(var(58)) != 667)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = (ctrl && statetype != A) || (stateno = 100) || (stateno = 105)
trigger1 = (p2statetype = C && Random < 667) || (p2statetype = S && Random < 400)
trigger1 = p2bodydist x = [0,2260]
trigger1 = enemy, pos y = [-200,0]

;---------------------------------------------------------------------------
;Stand Light Kick
[State -1, Stand Light Kick]
type = ChangeState
value = 204
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 204)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = (ctrl && statetype != A) || (stateno = 100) || (stateno = 105)
trigger1 = (p2statetype = C && Random < 667) || (p2statetype = S && Random < 333)
trigger1 = p2bodydist x = [0,70]
trigger1 = enemy, pos y = [-30,0]

;---------------------------------------------------------------------------
;Standing Medium Kick
[State -1, Standing Medium Kick]
type = ChangeState
value = 205
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 205)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = (ctrl && statetype != A) || (stateno = 100) || (stateno = 105)
trigger1 = (p2statetype = C && Random < 667) || (p2statetype = S && Random < 333)
trigger1 = p2bodydist x = [0,70]
trigger1 = enemy, pos y = [-30,0]

;---------------------------------------------------------------------------
;Standing Strong Kick
[State -1, Standing Strong Kick]
type = ChangeState
value = 206
triggerall = var(59) = 1
triggerall = (abs(var(58)) != 206)|| (Random < 100)
triggerall = (var(58) != [200,499]) || (Random < 200)
triggerall = (var(58) != [1000,3999]) || (Random < 300)
triggerall = (ctrl && statetype != A) || (stateno = 100) || (stateno = 105)
trigger1 = (p2statetype = C && Random < 667) || (p2statetype = S && Random < 333)
trigger1 = p2bodydist x = [0,70]
trigger1 = enemy, pos y = [-30,0]

;---------------------------------------------------------------------------
;Jump Light Punch
[State -1, Jump Light Punch]
type = ChangeState
value = 600
triggerall = var(59) = 1
triggerall = statetype = A
triggerall = ctrl
triggerall = stateno != 600
trigger1 = p2bodydist x = [0,30]
trigger1 = p2bodydist y = [-50,20]

;---------------------------------------------------------------------------
;Jump Medium Punch
[State -1, Jump Medium Punch]
type = ChangeState
value = 601
triggerall = var(59) = 1
triggerall = statetype = A
triggerall = ctrl
trigger1 = p2bodydist x = [0,32]
trigger1 = p2bodydist y = [-50,20]

;---------------------------------------------------------------------------
;
[State -1, buster air]
type = ChangeState
value = 602
triggerall = var(59) = 1
triggerall = statetype = A
triggerall = ctrl
trigger1 = p2bodydist x = [0,34]
trigger1 = p2bodydist y = [-50,20]

;---------------------------------------------------------------------------
;Jump Light Kick
[State -1, Jump Light Kick]
type = ChangeState
value = 603
triggerall = var(59) = 1
triggerall = statetype = A
triggerall = ctrl
trigger1 = p2bodydist x = [0,31]
trigger1 = p2bodydist y = [-50,20]

;---------------------------------------------------------------------------
;Jump Medium Kick
[State -1, Jump Medium Kick]
type = ChangeState
value = 604
triggerall = var(59) = 1
triggerall = statetype = A
triggerall = ctrl
trigger1 = p2bodydist x = [0,33]
triggerall = stateno != 604
trigger1 = p2bodydist y = [-50,20]
triggerall = Vel x > 0

;---------------------------------------------------------------------------
;Jump Medium Kick
[State -1, Jump Medium Kick]
type = ChangeState
value = 704
triggerall = var(59) = 1
triggerall = statetype = A
triggerall = ctrl
trigger1 = p2bodydist x = [0,33]
triggerall = stateno != 604
trigger1 = p2bodydist y = [-50,20]
triggerall = Vel x = 0

;---------------------------------------------------------------------------
;Jump Strong Kick Up
[State -1, Jump Strong Kick]
type = ChangeState
value = 800
triggerall = var(59) = 1
triggerall = statetype = A
triggerall = ctrl
trigger1 = p2bodydist x = [0,38]
trigger1 = p2bodydist y = [-50,20]

;---------------------------------------------------------------------------
;Jump Strong Kick
[State -1, Jump Strong Kick]
type = ChangeState
value = 605
triggerall = var(59) = 1
triggerall = statetype = A
triggerall = ctrl
trigger1 = p2bodydist x = [0,36]
trigger1 = p2bodydist y = [-50,20]
triggerall = Vel x > 0

;---------------------------------------------------------------------------
;Jump Strong Kick
[State -1, Jump Strong Kick]
type = ChangeState
value = 705
triggerall = var(59) = 1
triggerall = statetype = A
triggerall = ctrl
trigger1 = p2bodydist x = [0,36]
trigger1 = p2bodydist y = [-50,20]
triggerall = Vel x = 0

;===========================================================================
; AI Misc
;===========================================================================
;---------------------------------------------------------------------------
; Jump
[State -1, Jump]
type = ChangeState
value = 40
triggerall = var(59) = 1
triggerall = statetype != A
trigger1 = ctrl
trigger1 = random < 50

;---------------------------------------------------------------------------
;Super Jump
[State -1, Super Jump]
type = ChangeState
value = 60
triggerall = var(59) = 1
triggerall = statetype != A
trigger1 = ctrl
trigger1 = p2bodydist x > 120
trigger1 = random < 80

;---------------------------------------------------------------------------
;Run Fwd
[State -1, Run Fwd]
type = ChangeState
value = 100
triggerall = var(59) = 1
triggerall = statetype != A
trigger1 = ctrl
trigger1 = stateno != 100
trigger1 = stateno != 105
trigger1 = Random < 50

;---------------------------------------------------------------------------
;Run Back
[State -1, Run Back]
type = ChangeState
value = 105
triggerall = var(59) = 1
triggerall = statetype = S
trigger1 = ctrl
trigger1 = stateno != 100
trigger1 = stateno != 105
trigger1 = Random < 20

;---------------------------------------------------------------------------
;===========================================================================
; Comman2 sin AI
;===========================================================================
;---------------------------------------------------------------------------
[State -1, Scramble Gou Rassen]
type = ChangeState
value = 4500
triggerall = command = "QCB2_b"
triggerall = var(59) = 0
triggerall = power >= 1000
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,799]

;---------------------------------------------------------------------------
[State -1, SHINING GOU SHOCK]
type = ChangeState
value = 4900
triggerall = command = "ShinGoSh"
triggerall = var(59) = 0
triggerall = power >= 1000
triggerall = stateno != 2010 
triggerall = stateno != 4900 
triggerall = stateno != 4952 
trigger1 = Statetype = S && (stateno = [200,406]) || ctrl;
trigger2 = MoveContact && stateno = [200,406]

;---------------------------------------------------------------------------
; THUNDER GOU SHOWER
[State -1]
type = ChangeState
value = 2700
triggerall = var(59) = 0
triggerall = command = "QCF2_z"
triggerall = power >= 1000
trigger1 = statetype = A
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [600,799]

;---------------------------------------------------------------------------
; HIGH MEGA GOU BEAM
[State -1]
type = ChangeState
value = 2010
triggerall = var(59) = 0
triggerall = command = "QCB2_y"
triggerall = power >= 1000 
triggerall = stateno !=  [4900,4952]
triggerall = statetype != A
triggerall = numhelper(2012) = 0
trigger1 = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,599]

;---------------------------------------------------------------------------
; SCRAMBLE GOU PUNCH
[State -1]
type = ChangeState
value = 1170
triggerall = command = "QCF2_z"
triggerall = var(59) = 0
triggerall = power >= 1000
trigger1 = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,599]

;------------------------------------------------------------
; HIGH MEGA GOU BEAM-AIRE
[State -1]
type = ChangeState
value = 3600
triggerall = var(59) = 0
triggerall = command = "QCB2_y"
triggerall = power >= 1000 
triggerall = stateno !=  [4900,4952]
triggerall = statetype != S
triggerall = numhelper(2012) = 0
trigger1 = statetype = A
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [600,799]

;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
; Asura Senkuu Forward X
[State -1]
type = ChangeState
value = 960
triggerall = var(59) = 0
triggerall = command = "asuraf_x"
trigger1 = statetype = S
trigger1 = ctrl = 1
trigger2 = statetype = C
trigger2 = ctrl = 1
trigger3 = stateno = 100
trigger4 = stateno = 950
trigger5 = stateno = 951
trigger6 = stateno = 952

;---------------------------------------------------------------------------
; Asura Senkuu Forward Y
[State -1]
type = ChangeState
value = 960
triggerall = command = "asuraf_y"
triggerall = var(59) = 0
trigger1 = statetype = S
trigger1 = ctrl = 1
trigger2 = statetype = C
trigger2 = ctrl = 1
trigger3 = stateno = 100
trigger4 = stateno = 950
trigger5 = stateno = 951
trigger6 = stateno = 952

;---------------------------------------------------------------------------
; Asura Senkuu Forward Z
[State -1]
type = ChangeState
value = 960
triggerall = command = "asuraf_z"
triggerall = var(59) = 0
trigger1 = statetype = S
trigger1 = ctrl = 1
trigger2 = statetype = C
trigger2 = ctrl = 1
trigger3 = stateno = 100
trigger4 = stateno = 950
trigger5 = stateno = 951
trigger6 = stateno = 952

;---------------------------------------------------------------------------
; Asura Senkuu Forward A
[State -1]
type = ChangeState
value = 970
triggerall = command = "asuraf_a"
triggerall = var(59) = 0
trigger1 = statetype = S
trigger1 = ctrl = 1
trigger2 = statetype = C
trigger2 = ctrl = 1
trigger3 = stateno = 100
trigger4 = stateno = 950
trigger5 = stateno = 951
trigger6 = stateno = 952

;---------------------------------------------------------------------------
; Asura Senkuu Forward B
[State -1]
type = ChangeState
value = 970
triggerall = command = "asuraf_b"
triggerall = var(59) = 0
trigger1 = statetype = S
trigger1 = ctrl = 1
trigger2 = statetype = C
trigger2 = ctrl = 1
trigger3 = stateno = 100
trigger4 = stateno = 950
trigger5 = stateno = 951
trigger6 = stateno = 952

;---------------------------------------------------------------------------
; Asura Senkuu Forward C
[State -1]
type = ChangeState
value = 970
triggerall = command = "asuraf_c"
triggerall = var(59) = 0
trigger1 = statetype = S
trigger1 = ctrl = 1
trigger2 = statetype = C
trigger2 = ctrl = 1
trigger3 = stateno = 100
trigger4 = stateno = 950
trigger5 = stateno = 951
trigger6 = stateno = 952

;===========================================================================
;---------------------------------------------------------------------------
; Asura Senkuu Backward X
[State -1]
type = ChangeState
value = 980
triggerall = command = "asurab_x"
triggerall = var(59) = 0
trigger1 = statetype = S
trigger1 = ctrl = 1
trigger2 = statetype = C
trigger2 = ctrl = 1
trigger3 = stateno = 100

;---------------------------------------------------------------------------
; Asura Senkuu Backward Y
[State -1]
type = ChangeState
value = 980
triggerall = command = "asurab_y"
triggerall = var(59) = 0
trigger1 = statetype = S
trigger1 = ctrl = 1
trigger2 = statetype = C
trigger2 = ctrl = 1
trigger3 = stateno = 100

;---------------------------------------------------------------------------
; Asura Senkuu Backward Z
[State -1]
type = ChangeState
value = 980
triggerall = command = "asurab_z"
triggerall = var(59) = 0
trigger1 = statetype = S
trigger1 = ctrl = 1
trigger2 = statetype = C
trigger2 = ctrl = 1
trigger3 = stateno = 100

;---------------------------------------------------------------------------
; Asura Senkuu Backward A
[State -1]
type = ChangeState
value = 990
triggerall = command = "asurab_a"
triggerall = var(59) = 0
trigger1 = statetype = S
trigger1 = ctrl = 1
trigger2 = statetype = C
trigger2 = ctrl = 1
trigger3 = stateno = 100

;---------------------------------------------------------------------------
; Asura Senkuu Backward B
[State -1]
type = ChangeState
value = 990
triggerall = command = "asurab_b"
triggerall = var(59) = 0
trigger1 = statetype = S
trigger1 = ctrl = 1
trigger2 = statetype = C
trigger2 = ctrl = 1
trigger3 = stateno = 100

;---------------------------------------------------------------------------
; Asura Senkuu Backward C
[State -1]
type = ChangeState
value = 990
triggerall = command = "asurab_c"
triggerall = var(59) = 0
trigger1 = statetype = S
trigger1 = ctrl = 1
trigger2 = statetype = C
trigger2 = ctrl = 1
trigger3 = stateno = 100

;---------------------------------------------------------------------------
;===========================================================================
;---------------------------------------------------------------------------
; Tenma Gou Kuu Jin Kyaku A
[State -1]
type = ChangeState
value = 848
triggerall = command = "QCF_a"
triggerall = var(59) = 0
trigger1 = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact
trigger3 = (stateno = 601) && MoveContact
trigger4 = (stateno = 604) && MoveContact
trigger5 = (stateno = 605) && MoveContact
trigger6 = (stateno = 704) && MoveContact
trigger7 = (stateno = 705) && MoveContact
trigger9 = stateno = 706 && MoveContact
trigger10 = stateno = 550 && MoveContact
trigger11 = stateno = 800 && MoveContact

;---------------------------------------------------------------------------
; Tenma Gou Kuu Jin Kyaku B
[State -1]
type = ChangeState
value = 849
triggerall = command = "QCF_b"
triggerall = var(59) = 0
trigger1 = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact
trigger3 = (stateno = 601) && MoveContact
trigger4 = (stateno = 604) && MoveContact
trigger5 = (stateno = 605) && MoveContact
trigger6 = (stateno = 704) && MoveContact
trigger7 = (stateno = 705) && MoveContact
trigger9 = stateno = 706 && MoveContact
trigger10 = stateno = 550 && MoveContact
trigger11 = stateno = 800 && MoveContact

;---------------------------------------------------------------------------
; Tenma Gou Kuu Jin Kyaku C
[State -1]
type = ChangeState
value = 850
triggerall = command = "QCF_c"
triggerall = var(59) = 0
trigger1 = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact
trigger3 = (stateno = 601) && MoveContact
trigger4 = (stateno = 604) && MoveContact
trigger5 = (stateno = 605) && MoveContact
trigger6 = (stateno = 704) && MoveContact
trigger7 = (stateno = 705) && MoveContact
trigger9 = stateno = 706 && MoveContact
trigger10 = stateno = 550 && MoveContact
trigger11 = stateno = 800 && MoveContact

;===========================================================================
;---------------------------------------------------------------------------
; Kuuchuu Tatsu Maki Zankuu Kyaku A 
[State -1]
type = ChangeState
value = 3030
triggerall = command = "QCB_a"
triggerall = var(59) = 0
trigger1 = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact
trigger3 = (stateno = 601) && MoveContact
trigger4 = (stateno = 604) && MoveContact
trigger5 = (stateno = 605) && MoveContact
trigger6 = (stateno = 704) && MoveContact
trigger7 = (stateno = 705) && MoveContact
trigger10 = stateno = 1350
trigger10 = time >= 39
trigger11 = stateno = 1360
trigger11 = time >= 39
trigger12 = stateno = 1370
trigger12 = time >= 39
trigger13 = stateno = 2500
trigger13 = time >= 131
trigger14 = stateno = 2600
trigger14 = time >= 131
trigger15 = stateno = 2700
trigger15 = time >= 131
trigger16 = movecontact = 1
trigger16 = stateno = 706
trigger17 = stateno = 550
trigger18 = stateno = 800
trigger19 = movecontact = 1
trigger19 = stateno = 3520

;---------------------------------------------------------------------------
; Kuuchuu Tatsu Maki Zankuu Kyaku B
[State -1]
type = ChangeState
value = 3040
triggerall = command = "QCB_b"
triggerall = var(59) = 0
trigger1 = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact
trigger3 = (stateno = 601) && MoveContact
trigger4 = (stateno = 604) && MoveContact
trigger5 = (stateno = 605) && MoveContact
trigger6 = (stateno = 704) && MoveContact
trigger7 = (stateno = 705) && MoveContact
trigger10 = stateno = 1350
trigger10 = time >= 39
trigger11 = stateno = 1360
trigger11 = time >= 39
trigger12 = stateno = 1370
trigger12 = time >= 39
trigger13 = stateno = 2500
trigger13 = time >= 131
trigger14 = stateno = 2600
trigger14 = time >= 131
trigger15 = stateno = 2700
trigger15 = time >= 131
trigger16 = movecontact = 1
trigger16 = stateno = 706
trigger17 = stateno = 550
trigger18 = stateno = 800
trigger19 = movecontact = 1
trigger19 = stateno = 3520

;---------------------------------------------------------------------------
; Kuuchuu Tatsu Maki Zankuu Kyaku C
[State -1]
type = ChangeState
value = 3050
triggerall = command = "QCB_c"
triggerall = var(59) = 0
trigger1 = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact
trigger3 = (stateno = 601) && MoveContact
trigger4 = (stateno = 604) && MoveContact
trigger5 = (stateno = 605) && MoveContact
trigger6 = (stateno = 704) && MoveContact
trigger7 = (stateno = 705) && MoveContact
trigger10 = stateno = 1350
trigger10 = time >= 39
trigger11 = stateno = 1360
trigger11 = time >= 39
trigger12 = stateno = 1370
trigger12 = time >= 39
trigger13 = stateno = 2500
trigger13 = time >= 131
trigger14 = stateno = 2600
trigger14 = time >= 131
trigger15 = stateno = 2700
trigger15 = time >= 131
trigger16 = movecontact = 1
trigger16 = stateno = 706
trigger18 = stateno = 800
trigger19 = movecontact = 1
trigger19 = stateno = 3520

;===========================================================================
;---------------------------------------------------------------------------
; Zankuu Hado Ken X
[State -1]
type = ChangeState
value = 1300
triggerall = command = "QCF_x"
triggerall = var(59) = 0
trigger1 = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact
trigger3 = (stateno = 601) && MoveContact
trigger4 = (stateno = 604) && MoveContact
trigger5 = (stateno = 605) && MoveContact
trigger6 = (stateno = 704) && MoveContact
trigger7 = (stateno = 705) && MoveContact

;---------------------------------------------------------------------------
; Zankuu Hado Ken Y
[State -1]
type = ChangeState
value = 1301
triggerall = command = "QCF_y"
triggerall = var(59) = 0
trigger1 = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact
trigger3 = (stateno = 601) && MoveContact
trigger4 = (stateno = 604) && MoveContact
trigger5 = (stateno = 605) && MoveContact
trigger6 = (stateno = 704) && MoveContact
trigger7 = (stateno = 705) && MoveContact

;---------------------------------------------------------------------------
; Zankuu Hado Ken Z
[State -1]
type = ChangeState
value = 1302
triggerall = command = "QCF_z"
triggerall = var(59) = 0
trigger1 = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact
trigger3 = (stateno = 601) && MoveContact
trigger4 = (stateno = 604) && MoveContact
trigger5 = (stateno = 605) && MoveContact
trigger6 = (stateno = 704) && MoveContact
trigger7 = (stateno = 705) && MoveContact

;===========================================================================
;---------------------------------------------------------------------------
; Hyakki Gou Sai
[State -1]
type = ChangeState
value = 3540
triggerall = time >= 12
triggerall = p2bodydist x <= 0
triggerall = p2bodydist x >= -35
triggerall = var(59) = 0
trigger1 = command = "x"
trigger1 = command = "holdfwd"
trigger1 = stateno = 3500
trigger2 = command = "x"
trigger2 = command = "holdfwd"
trigger2 = stateno = 3501
trigger3 = command = "x"
trigger3 = command = "holdfwd"
trigger3 = stateno = 3502
trigger4 = command = "y"
trigger4 = command = "holdfwd"
trigger4 = stateno = 3500
trigger5 = command = "y"
trigger5 = command = "holdfwd"
trigger5 = stateno = 3501
trigger6 = command = "y"
trigger6 = command = "holdfwd"
trigger6 = stateno = 3502
trigger7 = command = "z"
trigger7 = command = "holdfwd"
trigger7 = stateno = 3500
trigger8 = command = "z"
trigger8 = command = "holdfwd"
trigger8 = stateno = 3501
trigger9 = command = "z"
trigger9 = command = "holdfwd"
trigger9 = stateno = 3502
trigger10 = command = "x"
trigger10 = command = "holdback"
trigger10 = stateno = 3500
trigger11 = command = "x"
trigger11 = command = "holdback"
trigger11 = stateno = 3501
trigger12 = command = "x"
trigger12 = command = "holdback"
trigger12 = stateno = 3502
trigger13 = command = "y"
trigger13 = command = "holdback"
trigger13 = stateno = 3500
trigger14 = command = "y"
trigger14 = command = "holdback"
trigger14 = stateno = 3501
trigger15 = command = "y"
trigger15 = command = "holdback"
trigger15 = stateno = 3502
trigger16 = command = "z"
trigger16 = command = "holdback"
trigger16 = stateno = 3500
trigger17 = command = "z"
trigger17 = command = "holdback"
trigger17 = stateno = 3501
trigger18 = command = "z"
trigger18 = command = "holdback"
trigger18 = stateno = 3502

;---------------------------------------------------------------------------
; Hyakki Gou Tsui A
[State -1]
type = ChangeState
value = 3550
triggerall = time >= 12
triggerall = p2bodydist x < 8
triggerall = var(59) = 0
trigger1 = command = "a"
trigger1 = command = "holdfwd"
trigger1 = stateno = 3500
trigger2 = command = "a"
trigger2 = command = "holdfwd"
trigger2 = stateno = 3501
trigger3 = command = "a"
trigger3 = command = "holdfwd"
trigger3 = stateno = 3502
trigger4 = command = "b"
trigger4 = command = "holdfwd"
trigger4 = stateno = 3500
trigger5 = command = "b"
trigger5 = command = "holdfwd"
trigger5 = stateno = 3501
trigger6 = command = "b"
trigger6 = command = "holdfwd"
trigger6 = stateno = 3502
trigger7 = command = "c"
trigger7 = command = "holdfwd"
trigger7 = stateno = 3500
trigger8 = command = "c"
trigger8 = command = "holdfwd"
trigger8 = stateno = 3501
trigger9 = command = "c"
trigger9 = command = "holdfwd"
trigger9 = stateno = 3502

;---------------------------------------------------------------------------
; Hyakki Gou Tsui B
[State -1]
type = ChangeState
value = 3555
triggerall = time >= 12
triggerall = p2bodydist x < 8
triggerall = var(59) = 0
trigger1 = command = "a"
trigger1 = command = "holdback"
trigger1 = stateno = 3500
trigger2 = command = "a"
trigger2 = command = "holdback"
trigger2 = stateno = 3501
trigger3 = command = "a"
trigger3 = command = "holdback"
trigger3 = stateno = 3502
trigger4 = command = "b"
trigger4 = command = "holdback"
trigger4 = stateno = 3500
trigger5 = command = "b"
trigger5 = command = "holdback"
trigger5 = stateno = 3501
trigger6 = command = "b"
trigger6 = command = "holdback"
trigger6 = stateno = 3502
trigger7 = command = "c"
trigger7 = command = "holdback"
trigger7 = stateno = 3500
trigger8 = command = "c"
trigger8 = command = "holdback"
trigger8 = stateno = 3501
trigger9 = command = "c"
trigger9 = command = "holdback"
trigger9 = stateno = 3502

;---------------------------------------------------------------------------
; Hyakki Gou Shou
[State -1]
type = ChangeState
value = 3520
triggerall = time >= 12
triggerall = var(59) = 0
trigger1 = command = "x"
trigger1 = stateno = 3500
trigger2 = command = "x"
trigger2 = stateno = 3501
trigger3 = command = "x"
trigger3 = stateno = 3502
trigger4 = command = "y"
trigger4 = stateno = 3500
trigger5 = command = "y"
trigger5 = stateno = 3501
trigger6 = command = "y"
trigger6 = stateno = 3502
trigger7 = command = "z"
trigger7 = stateno = 3500
trigger8 = command = "z"
trigger8 = stateno = 3501
trigger9 = command = "z"
trigger9 = stateno = 3502

;---------------------------------------------------------------------------
; Hyakki Gou Sen
[State -1]
type = ChangeState
value = 3530
triggerall = time >= 12
triggerall = var(59) = 0
trigger1 = command = "a"
trigger1 = stateno = 3500
trigger2 = command = "a"
trigger2 = stateno = 3501
trigger3 = command = "a"
trigger3 = stateno = 3502
trigger4 = command = "b"
trigger4 = stateno = 3500
trigger5 = command = "b"
trigger5 = stateno = 3501
trigger6 = command = "b"
trigger6 = stateno = 3502
trigger7 = command = "c"
trigger7 = stateno = 3500
trigger8 = command = "c"
trigger8 = stateno = 3501
trigger9 = command = "c"
trigger9 = stateno = 3502

;===========================================================================
;---------------------------------------------------------------------------
; Gou Sho Ryu X
[State -1]
type = ChangeState
value = 1100
triggerall = command = "uppercut_x"
triggerall = var(59) = 0
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,599]

;---------------------------------------------------------------------------
; Gou Sho Ryu Y
[State -1]
type = ChangeState
value = 1110
triggerall = command = "uppercut_y"
triggerall = var(59) = 0
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,599]

;---------------------------------------------------------------------------
; Gou Sho Ryu Z
[State -1]
type = ChangeState
value = 1120
triggerall = command = "uppercut_z"
triggerall = var(59) = 0
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,599]

;===========================================================================
;===========================================================================
;---------------------------------------------------------------------------
; Zenpou Tenshin X
[State -1]
type = ChangeState
value = 950
triggerall = command = "QCB_x"
triggerall = var(59) = 0
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,599]

;---------------------------------------------------------------------------
; Zenpou Tenshin Y
[State -1]
type = ChangeState
value = 951
triggerall = command = "QCB_y"
triggerall = var(59) = 0
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,599]

;---------------------------------------------------------------------------
; Zenpou Tenshin Z
[State -1]
type = ChangeState
value = 952
triggerall = command = "QCB_z"
triggerall = var(59) = 0
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,599]

;===========================================================================
;---------------------------------------------------------------------------
; Tatsu Maki Zankuu Kyaku A 
[State -1]
type = ChangeState
value = 3000
triggerall = command = "QCB_a"
triggerall = var(59) = 0
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,599]

;---------------------------------------------------------------------------
; Tatsu Maki Zankuu Kyaku B 
[State -1]
type = ChangeState
value = 3010
triggerall = command = "QCB_b"
triggerall = var(59) = 0
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,599]

;---------------------------------------------------------------------------
; Tatsu Maki Zankuu Kyaku C
[State -1]
type = ChangeState
value = 3020
triggerall = command = "QCB_c"
triggerall = var(59) = 0
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,599]

;---------------------------------------------------------------------------
; Tatsu Maki Zankuu Kyaku C
[State -1]
type = ChangeState
value = 3021
triggerall = command = "QCB_c"
triggerall = var(59) = 0
trigger1 = statetype = A
trigger1 = movecontact = 1
trigger1 = stateno = 550

;===========================================================================
;---------------------------------------------------------------------------
; Gou Hado Ken X (close)
[State -1]
type = ChangeState
value = 1010
triggerall = command = "QCF_x"
triggerall = var(59) = 0
triggerall = P2bodydist X < 55
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,599]

;---------------------------------------------------------------------------
; Gou Hado Ken Y (close)
[State -1]
type = ChangeState
value = 1011
triggerall = command = "QCF_y"
triggerall = P2bodydist X < 55
triggerall = var(59) = 0
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,599]

;---------------------------------------------------------------------------
; Gou Hado Ken Z (close)
[State -1]
type = ChangeState
value = 1012
triggerall = command = "QCF_z"
triggerall = P2bodydist X < 55
triggerall = var(59) = 0
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,599]

;---------------------------------------------------------------------------
; Gou Hado Ken X
[State -1]
type = ChangeState
value = 1000
triggerall = command = "QCF_x"
triggerall = var(59) = 0
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,599]

;---------------------------------------------------------------------------
; Gou Hado Ken Y
[State -1]
type = ChangeState
value = 1001
triggerall = command = "QCF_y"
triggerall = var(59) = 0
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,599]

;---------------------------------------------------------------------------
; Gou Hado Ken Z
[State -1]
type = ChangeState
value = 1002
triggerall = command = "QCF_z"
triggerall = var(59) = 0
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,599]

;---------------------------------------------------------------------------
;Punch Throw (Forward)
[State -1]
type = ChangeState
value = 4000
triggerall = statetype = S
triggerall = var(59) = 0
triggerall = ctrl = 1
triggerall = command = "holdfwd"
trigger1 = command = "z"
trigger1 = p2movetype != H && p2bodydist X < 36

;---------------------------------------------------------------------------
;Punch Throw (Backward)
[State -1]
type = ChangeState
value = 4005
triggerall = statetype = S
triggerall = var(59) = 0
triggerall = ctrl = 1
triggerall = command = "holdback"
trigger1 = command = "z" 
trigger1 = p2bodydist X < 36

;---------------------------------------------------------------------------
;Kick Throw (Forward)
[State -1]
type = ChangeState
value = 4010
triggerall = statetype = S
triggerall = var(59) = 0
triggerall = ctrl = 1
triggerall = command = "holdfwd"
trigger1 = command = "b"
trigger1 = p2bodydist X < 36

;---------------------------------------------------------------------------
;Kick Throw (Backward)
[State -1]
type = ChangeState
value = 4015
triggerall = statetype = S
triggerall = var(59) = 0
triggerall = ctrl = 1
triggerall = command = "holdback"
trigger1 = command = "b"
trigger1 = p2bodydist X < 36
       
;---------------------------------------------------------------------------
;Kick Throw (Forward)
[State -1]
type = ChangeState
value = 4020
triggerall = statetype = S
triggerall = var(59) = 0
triggerall = ctrl = 1
triggerall = command = "holdfwd"
trigger1 = command = "c"
trigger1 = p2bodydist X < 36

;---------------------------------------------------------------------------
;Kick Throw (Backward)
[State -1]
type = ChangeState
value = 4025
triggerall = statetype = S
triggerall = var(59) = 0
triggerall = ctrl = 1
triggerall = command = "holdback"
trigger1 = command = "c"
trigger1 = p2bodydist X < 36

;---------------------------------------------------------------------------
;Air Throw (Forward)
[State -1]
type = ChangeState
value = 4030
triggerall = statetype = A
triggerall = var(59) = 0
triggerall = ctrl = 1
triggerall = command = "holdfwd"
trigger1 = command = "ab"
trigger2 = command = "ac"
trigger3 = command = "bc"

;---------------------------------------------------------------------------
;Air Throw (Backward)
[State -1]
type = ChangeState
value = 4030
triggerall = statetype = A
triggerall = var(59) = 0
triggerall = ctrl = 1
triggerall = command = "holdback"
trigger1 = command = "ab"
trigger2 = command = "ac"
trigger3 = command = "bc"

;===========================================================================
;---------------------------------------------------------------------------
;Zugai Hassatsu
[State -1]
type = ChangeState
value = 500
triggerall = command = "fwd_y"
triggerall = var(59) = 0
triggerall = command != "holddown"
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,499]

;===========================================================================
;---------------------------------------------------------------------------
;Senpuu Kyaku
[State -1]
type = ChangeState
value = 550
triggerall = command = "fwd_b"
triggerall = var(59) = 0
triggerall = command != "holddown"
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,499]

;===========================================================================
;---------------------------------------------------------------------------
;Senpuu Kyaku
[State -1]
type = ChangeState
value = 560
triggerall = command = "fwd_c"
triggerall = var(59) = 0
triggerall = command != "holddown"
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = movecontact
trigger2 = stateno = [200,499]

;===========================================================================
;---------------------------------------------------------------------------
;RunFwd
[State -1]
type = ChangeState
value = 100
triggerall = var(59) = 0
trigger1 = command = "FF"
trigger1 = statetype = S
trigger1 = ctrl = 1

;---------------------------------------------------------------------------
;RunBack
[State -1]
type = ChangeState
value = 105
triggerall = var(59) = 0
trigger1 = command = "BB"
trigger1 = statetype = S
trigger1 = ctrl = 1

;===========================================================================
;---------------------------------------------------------------------------
;Stand X
[State -1]
type = ChangeState
value = 200
triggerall = var(59) = 0
triggerall = command = "x"
triggerall = command != "holddown"
triggerall = statetype = S
trigger1 = ctrl

;---------------------------------------------------------------------------
;Stand Y
[State -1]
type = ChangeState
value = 201
triggerall = var(59) = 0
triggerall = command = "y"
triggerall = command != "holddown"
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = (stateno = 200) && MoveContact
trigger3 = (stateno = 204) && MoveContact
trigger4 = (stateno = 400) && MoveContact
trigger5 = (stateno = 404) && MoveContact

;---------------------------------------------------------------------------
;Stand Z
[State -1]
type = ChangeState
value = 667
triggerall = var(59) = 0
triggerall = command = "z"
triggerall = command != "holddown"
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = (stateno = 200) && MoveContact
trigger3 = (stateno = 201) && MoveContact
trigger4 = (stateno = 204) && MoveContact
trigger5 = (stateno = 205) && MoveContact
trigger6 = (stateno = 400) && MoveContact
trigger7 = (stateno = 401) && MoveContact
trigger8 = (stateno = 404) && MoveContact
trigger9 = (stateno = 405) && MoveContact

;---------------------------------------------------------------------------
;Stand A
[State -1]
type = ChangeState
value = 204
triggerall = command = "a"
triggerall = var(59) = 0
triggerall = command != "holddown"
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = (stateno = 200) && MoveContact
trigger3 = (stateno = 400) && MoveContact

;---------------------------------------------------------------------------
;Stand B
[State -1]
type = ChangeState
value = 205
triggerall = var(59) = 0
triggerall = command = "b"
triggerall = command != "holddown"
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = (stateno = 200) && MoveContact
trigger3 = (stateno = 201) && MoveContact
trigger4 = (stateno = 204) && MoveContact
trigger5 = (stateno = 400) && MoveContact
trigger6 = (stateno = 401) && MoveContact
trigger7 = (stateno = 404) && MoveContact

;---------------------------------------------------------------------------
;Stand C
[State -1]
type = ChangeState
value = 206
triggerall = var(59) = 0
triggerall = command = "c"
triggerall = command != "holddown"
triggerall = statetype = S
trigger1 = ctrl = 1
trigger2 = (stateno = 200) && MoveContact
trigger3 = (stateno = 201) && MoveContact
trigger4 = (stateno = 204) && MoveContact
trigger5 = (stateno = 205) && MoveContact
trigger6 = (stateno = 400) && MoveContact
trigger7 = (stateno = 401) && MoveContact
trigger8 = (stateno = 404) && MoveContact
trigger9 = (stateno = 405) && MoveContact

;---------------------------------------------------------------------------
;Crouch X
[State -1]
type = ChangeState
value = 400
triggerall = var(59) = 0
triggerall = command = "x"
triggerall = command = "holddown"
triggerall = statetype = C
trigger1 = ctrl

;---------------------------------------------------------------------------
;Crouch Y
[State -1]
type = ChangeState
value = 401
triggerall = var(59) = 0
triggerall = command = "y"
triggerall = command = "holddown"
triggerall = statetype = C
trigger1 = ctrl = 1
trigger2 = (stateno = 200) && MoveContact
trigger3 = (stateno = 204) && MoveContact
trigger4 = (stateno = 400) && MoveContact
trigger5 = (stateno = 404) && MoveContact

;---------------------------------------------------------------------------
;Crouch Z
[State -1]
type = ChangeState
value = 402
triggerall = var(59) = 0
triggerall = command = "z"
triggerall = command = "holddown"
triggerall = statetype = C
trigger1 = ctrl = 1
trigger2 = (stateno = 200) && MoveContact
trigger3 = (stateno = 201) && MoveContact
trigger4 = (stateno = 204) && MoveContact
trigger5 = (stateno = 205) && MoveContact
trigger6 = (stateno = 400) && MoveContact
trigger7 = (stateno = 401) && MoveContact
trigger8 = (stateno = 404) && MoveContact
trigger9 = (stateno = 405) && MoveContact

;---------------------------------------------------------------------------
;Super Jump (Super salto)
[State -1]
Type = Changestate
value = 60
triggerall = var(59) = 0
triggerall = command = "SuperJump"
trigger1 = statetype != A
Trigger1 = Ctrl = 1
trigger2 = stateno = 100
trigger3 = stateno = 105
trigger4 = stateno = 402
trigger4 = movehit = 1

;---------------------------------------------------------------------------
;Aerial Rave Jump
[State -1]
type = ChangeState
value = 40
triggerall = var(59) = 0
triggerall = command = "holdup"
trigger1 = movecontact = 1
trigger1 = stateno = 402

;---------------------------------------------------------------------------
;Crouch A
[State -1]
type = ChangeState
value = 404
triggerall = var(59) = 0
triggerall = command = "a"
triggerall = command = "holddown"
triggerall = statetype = C
trigger1 = ctrl = 1
trigger2 = (stateno = 200) && MoveContact
trigger3 = (stateno = 400) && MoveContact
trigger4 = (stateno = 204) && MoveContact
trigger5 = (stateno = 404) && MoveContact

;---------------------------------------------------------------------------
;Crouch B
[State -1]
type = ChangeState
value = 405
triggerall = var(59) = 0
triggerall = command = "b"
triggerall = command = "holddown"
triggerall = statetype = C
trigger1 = ctrl = 1
trigger2 = (stateno = 200) && MoveContact
trigger3 = (stateno = 201) && MoveContact
trigger4 = (stateno = 204) && MoveContact
trigger5 = (stateno = 400) && MoveContact
trigger6 = (stateno = 401) && MoveContact
trigger7 = (stateno = 404) && MoveContact

;---------------------------------------------------------------------------
;Crouch C
[State -1]
type = ChangeState
value = 406
triggerall = var(59) = 0
triggerall = command = "c"
triggerall = command = "holddown"
triggerall = statetype = C
trigger1 = ctrl = 1
trigger2 = (stateno = 200) && MoveContact
trigger3 = (stateno = 201) && MoveContact
trigger4 = (stateno = 204) && MoveContact
trigger5 = (stateno = 205) && MoveContact
trigger6 = (stateno = 400) && MoveContact
trigger7 = (stateno = 401) && MoveContact
trigger8 = (stateno = 404) && MoveContact
trigger9 = (stateno = 405) && MoveContact

;---------------------------------------------------------------------------
;Jump X
[State -1]
type = ChangeState
value = 600
triggerall = var(59) = 0
triggerall = command = "x"
triggerall = statetype = A
trigger1 = ctrl = 1

;---------------------------------------------------------------------------
;Jump Y
[State -1]
type = ChangeState
value = 601
triggerall = var(59) = 0
triggerall = command = "y"
triggerall = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact
trigger3 = (stateno = 604) && MoveContact

;---------------------------------------------------------------------------
;Jump Z
[State -1]
type = ChangeState
value = 602
triggerall = var(59) = 0
triggerall = command = "z"
triggerall = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact
trigger3 = (stateno = 601) && MoveContact
trigger4 = (stateno = 604) && MoveContact
trigger5 = (stateno = 605) && MoveContact
trigger6 = (stateno = 704) && MoveContact
trigger7 = (stateno = 705) && MoveContact

;---------------------------------------------------------------------------
;Tenma Kuu Jin Kyaku
[State -1]
type = ChangeState
value = 800
triggerall = var(59) = 0
triggerall = command = "holddown"
triggerall = command = "b"
trigger1 = statetype = A
trigger1 = ctrl = 1
trigger1 = stateno = 50
trigger1 = time >= 14
trigger1 = vel x >= 0.5
trigger2 = statetype = A
trigger2 = ctrl = 1
trigger2 = stateno = 51
trigger2 = time <= 10
trigger2 = vel x >= 0.5

;---------------------------------------------------------------------------
;Jump C (spinning roundhouse)
[State -1]
type = ChangeState
value = 706
triggerall = var(59) = 0
triggerall = command = "holdup"
triggerall = command = "c"
triggerall = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact
trigger3 = (stateno = 601) && MoveContact
trigger4 = (stateno = 604) && MoveContact
trigger5 = (stateno = 605) && MoveContact
trigger6 = (stateno = 704) && MoveContact
trigger7 = (stateno = 705) && MoveContact

;---------------------------------------------------------------------------
;Jump Up A
[State -1]
type = ChangeState
value = 704
triggerall = vel X = 0
triggerall = command = "a"
triggerall = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact

;---------------------------------------------------------------------------
;Jump Up B
[State -1]
type = ChangeState
value = 705
triggerall = var(59) = 0
triggerall = vel X = 0
triggerall = command = "b"
triggerall = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact
trigger3 = (stateno = 601) && MoveContact
trigger4 = (stateno = 604) && MoveContact
trigger5 = (stateno = 605) && MoveContact
trigger6 = (stateno = 704) && MoveContact
trigger7 = (stateno = 705) && MoveContact

;---------------------------------------------------------------------------
;Jump Up C
[State -1]
type = ChangeState
value = 706
triggerall = vel X = 0
triggerall = command = "c"
triggerall = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact
trigger3 = (stateno = 601) && MoveContact
trigger4 = (stateno = 604) && MoveContact
trigger5 = (stateno = 605) && MoveContact
trigger6 = (stateno = 704) && MoveContact
trigger7 = (stateno = 705) && MoveContact

;---------------------------------------------------------------------------
;Jump A
[State -1]
type = ChangeState
value = 604
triggerall = var(59) = 0
triggerall = command = "a"
triggerall = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact

;---------------------------------------------------------------------------
;Jump B
[State -1]
type = ChangeState
value = 605
triggerall = command = "b"
triggerall = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact
trigger3 = (stateno = 601) && MoveContact
trigger4 = (stateno = 602) && MoveContact
trigger2 = (stateno = 604) && MoveContact
trigger3 = (stateno = 704) && MoveContact

;---------------------------------------------------------------------------
;Jump C
[State -1]
type = ChangeState
value = 606
triggerall = var(59) = 0
triggerall = command = "c"
triggerall = statetype = A
trigger1 = ctrl = 1
trigger2 = (stateno = 600) && MoveContact
trigger3 = (stateno = 601) && MoveContact
trigger4 = (stateno = 604) && MoveContact
trigger5 = (stateno = 605) && MoveContact
trigger6 = (stateno = 704) && MoveContact
trigger7 = (stateno = 705) && MoveContact

;---------------------------------------------------------------------------
;Asura F
[State -1]
type = ChangeState
value = 197
triggerall = var(59) = 0
triggerall = command = "s"
triggerall = command = "holdback"
trigger1 = statetype = S
trigger1 = ctrl = 1

;---------------------------------------------------------------------------
;Asura B
[State -1]
type = ChangeState
value = 196
triggerall = var(59) = 0
triggerall = command = "s"
triggerall = command = "holdfwd"
trigger1 = statetype = S
trigger1 = ctrl = 1
trigger2 = stateno = 100

;---------------------------------------------------------------------------
;Karga y Golpe C
[State -1]
type = ChangeState
value = 195
triggerall = var(59) = 0
triggerall = command = "s"
trigger1 = statetype = S
trigger1 = ctrl = 1

;---------------------------------------------------------------------------
;Tameiki Wari
[State -1]
type = ChangeState
value = 198
triggerall = var(59) = 0
triggerall = command = "Tameiki Wari"
triggerall = command = "s"
triggerall = power >= 1000
trigger1 = statetype = S
trigger1 = ctrl = 1

;---------------------------------------------------------------------------
; Zero/Alpha Counter X
[State -1]
type = ChangeState
value = 900
triggerall = var(59) = 0
triggerall = command = "QCD_x"
triggerall = power >= 500
trigger1 = stateno >= 150
trigger1 = stateno <= 153

;---------------------------------------------------------------------------
; Zero/Alpha Counter X
[State -1]
type = ChangeState
value = 900
triggerall = var(59) = 0
triggerall = command = "ff_x"
triggerall = power >= 500
trigger1 = stateno >= 150
trigger1 = stateno <= 153

;---------------------------------------------------------------------------
; Zero/Alpha Counter Y
[State -1]
type = ChangeState
value = 910
triggerall = var(59) = 0
triggerall = command = "QCD_y"
triggerall = power >= 500
trigger1 = stateno >= 150
trigger1 = stateno <= 153

;---------------------------------------------------------------------------
; Zero/Alpha Counter Y
[State -1]
type = ChangeState
value = 910
triggerall = var(59) = 0
triggerall = command = "ff_y"
triggerall = power >= 500
trigger1 = stateno >= 150
trigger1 = stateno <= 153

;---------------------------------------------------------------------------
; Zero/Alpha Counter Z
[State -1]
type = ChangeState
value = 920
triggerall = var(59) = 0
triggerall = command = "QCD_z"
triggerall = power >= 500
trigger1 = stateno >= 150
trigger1 = stateno <= 153

;---------------------------------------------------------------------------
; Zero/Alpha Counter Z
[State -1]
type = ChangeState
value = 920
triggerall = var(59) = 0
triggerall = command = "ff_z"
triggerall = power >= 500
trigger1 = stateno = [5000,5120]
triggerall = P2bodydist X <= 80
triggerall = P2bodydist y = [-50,30]

;---------------------------------------------------------------------------
; Zero/Alpha Counter Z
[State -1]
type = ChangeState
value = 920
triggerall = var(59) = 0
triggerall = command = "ff_z"
triggerall = power >= 500
trigger1 = stateno >= 150
trigger1 = stateno <= 153

;---------------------------------------------------------------------------
; Zero/Alpha Counter A
[State -1]
type = ChangeState
value = 945
triggerall = var(59) = 0
triggerall = command = "QCD_a"
triggerall = power >= 500
trigger1 = stateno >= 150
trigger1 = stateno <= 153

;---------------------------------------------------------------------------
; Zero/Alpha Counter A
[State -1]
type = ChangeState
value = 945
triggerall = var(59) = 0
triggerall = power >= 500
triggerall = command = "ff_c"
trigger1 = statetype = S
trigger1 = stateno = [5000,5070]
triggerall = P2bodydist X <= 80
triggerall = P2bodydist y = [-50,30]

;---------------------------------------------------------------------------
; Zero/Alpha Counter A
[State -1]
type = ChangeState
value = 945
triggerall = var(59) = 0
triggerall = command = "ff_a"
triggerall = power >= 500
trigger1 = stateno >= 150
trigger1 = stateno <= 153

;---------------------------------------------------------------------------
; Zero/Alpha Counter B
[State -1]
type = ChangeState
value = 945
triggerall = var(59) = 0
triggerall = command = "QCD_b"
triggerall = power >= 500
trigger1 = stateno >= 150
trigger1 = stateno <= 153

;---------------------------------------------------------------------------
; Zero/Alpha Counter B
[State -1]
type = ChangeState
value = 945
triggerall = var(59) = 0
triggerall = command = "ff_b"
triggerall = power >= 500
trigger1 = stateno >= 150
trigger1 = stateno <= 153

;---------------------------------------------------------------------------
; Zero/Alpha Counter C
[State -1]
type = ChangeState
value = 945
triggerall = var(59) = 0
triggerall = command = "QCD_c"
triggerall = power >= 500
trigger1 = stateno >= 150
trigger1 = stateno <= 153

;---------------------------------------------------------------------------
; Zero/Alpha Counter C
[State -1]
type = ChangeState
value = 945
triggerall = var(59) = 0
triggerall = command = "ff_c"
triggerall = power >= 500
trigger1 = stateno >= 150
trigger1 = stateno <= 153

;---------------------------------------------------------------------------
; Recovery Roll X
[State -1]
type = ChangeState
value = 930
triggerall = command = "QCD_x"
triggerall = var(59) = 0
triggerall = alive = 1
trigger1 = stateno = 5050
trigger2 = stateno = 5071

;---------------------------------------------------------------------------
; Recovery Roll Y
[State -1]
type = ChangeState
value = 932
triggerall = command = "QCD_y"
triggerall = var(59) = 0
triggerall = alive = 1
trigger1 = stateno = 5050
trigger2 = stateno = 5071

;---------------------------------------------------------------------------
; Recovery Roll Z
[State -1]
type = ChangeState
value = 934
triggerall = command = "QCD_z"
triggerall = var(59) = 0
triggerall = alive = 1
trigger1 = stateno = 5050
trigger2 = stateno = 5071

;---------------------------------------------------------------------------
; Recovery Roll A
[State -1]
type = ChangeState
value = 936
triggerall = command = "QCD_a"
triggerall = var(59) = 0
triggerall = alive = 1
trigger1 = stateno = 5050
trigger2 = stateno = 5071

;---------------------------------------------------------------------------
; Recovery Roll B
[State -1]
type = ChangeState
value = 938
triggerall = command = "QCD_b"
triggerall = var(59) = 0
triggerall = alive = 1
trigger1 = stateno = 5050
trigger2 = stateno = 5071

;---------------------------------------------------------------------------
; Recovery Roll C
[State -1]
type = ChangeState
value = 940
triggerall = command = "QCD_c"
triggerall = var(59) = 0
triggerall = alive = 1
trigger1 = stateno = 5050
trigger2 = stateno = 5071

;---------------------------------------------------------------------------
;Guard Push (Stand)
[State -1, Guard Push (Stand)]
type = ChangeState
value = 160
triggerall = stateno = 150
triggerall = var(59) = 0
triggerall = command = "xyz"
triggerall = command != "holddown"
triggerall = var(59) = 0
trigger1 = statetype = S
ignorehitpause = 1

;---------------------------------------------------------------------------
;Guard Push (Crouch)
[State -1, Guard Push (Crouch)]
type = ChangeState
value = 161
triggerall = stateno = 152
triggerall = var(59) = 0
triggerall = command = "xyz"
triggerall = var(59) = 0
trigger1 = statetype = C
ignorehitpause = 1

;---------------------------------------------------------------------------
;Guard Push (Air)
[State -1, Guard Push (Air)]
type = ChangeState
value = 162
triggerall = stateno = 154
triggerall = var(59) = 0
triggerall = command = "xyz"
triggerall = var(59) = 0
trigger1 = statetype = A
ignorehitpause = 1

;---------------------------------------------------------------------------
;POWER add All Time
[State -1, POWER ADD]
type = poweradd
trigger1 = life > 0
trigger1 = IsHelper = 0
trigger1 = stateno = [5000,5070]
trigger1 = stateno != 5050
trigger1 = random < 50
triggerall = HitShakeOver = 1
value = 20

---------------------------------------------------------------------------
;POWER add All Time
[State -1, POWER ADD]
type = poweradd
triggerall = life > 0
triggerall = IsHelper = 0
trigger1 = stateno = 5050
trigger1 = random < 50
trigger2 = stateno = 5120
trigger2 = random < 100
trigger2 = HitShakeOver = 1
trigger1 = HitShakeOver = 1
triggerall = time = 1
trigger3 = stateno = [5030,5035]
trigger3 = HitShakeOver = 1
value = 46

;---------------------------------------------------------------------------
[State -1,Power Add Fast]
type = changestate
value = 6072
triggerall = power < 3000
triggerall = var(59) = 0
triggerall = command = "hold_x"
triggerall = command = "hold_a"
trigger1 = statetype = S
trigger1 = ctrl = 1

;---------------------------------------------------------------------------
[State -1, Power Add Fast Kambio]
type = ChangeState
value = 0
triggerall = (roundstate != [0,1]) || (roundstate != [3,4]) 
triggerall = Var(59) = 1
triggerall = statetype = S
triggerall = ctrl = 1
triggerall = stateno = 6072
trigger1 = P2movetype = A
trigger2 = P2stateno != [5000,5120]
trigger3 = enemy, NumProj >= 1
trigger4 = P2bodydist X < 160

;---------------------------------------------------------------------------
; Zero/Alpha Counter A
[State -1]
type = ChangeState
value = 925
triggerall = var(59) = 0
triggerall = command = "PT"
triggerall = power >= 100
trigger1 = stateno >= 150
trigger1 = stateno <= 153
triggerall = statetype = S
triggerall = P2bodydist X <= 80
triggerall = P2bodydist y = [-50,30]
trigger2 = stateno = [5000,5070]

;---------------------------------------------------------------------------
; Zero/Alpha Counter A
[State -1]
type = ChangeState
value = 926
triggerall = var(59) = 0
triggerall = command = "PT"
triggerall = power >= 100
triggerall = statetype = A
triggerall = P2bodydist X <= 80
triggerall = P2bodydist y = [-50,30]
trigger2 = stateno = [5000,5070]
trigger1 = stateno >= 154
