;===========================================================================
;Marvel vs. Capcom Template
;by INFINITY
;===========================================================================
;---------------------------------------------------------------------------
;Artificial Intelligence
;---------------------------------------------------------------------------
;-|-AI-|--------------------------------------------------------------------
[Command]
name = "AI_1"
command = a, x, F, D, a, a, D
time = 1

[Command]
name = "AI_2"
command = a, a, a, a, a, a, b
time = 1

[Command]
name = "AI_3"
command = a, a, b, D, F, b, x
time = 1

[Command]
name = "AI_4"
command = y, a, F, b, B, y, a
time = 1

[Command]
name = "AI_5"
command = a, b, x, y, y, b, b
time = 1

[Command]
name = "AI_6"
command = b, y, y, F, b, B, B
time = 1

[Command]
name = "AI_7"
command = a, y, F, a, x, a, F, b
time = 1

[Command]
name = "AI_8"
command = a, a, b, y, x, B, x
time = 1

[Command]
name = "AI_9"
command = x, x, a, F, F, b, D
time = 1

[Command]
name = "AI_10"
command = x, x, a, F, y, a, a, F
time = 1

[Command]
name = "AI_11"
command = a, b, a, x, a, y, a
time = 1

[Command]
name = "AI_12"
command = b, y, a, F, y, a, x
time = 1

[Command]
name = "AI_13"
command = x, a, y, y, x, B, B
time = 1

[Command]
name = "AI_14"
command = a, F, F, x, B, F, x
time = 1

[Command]
name = "AI_15"
command = y, x, b, b, a, x, y
time = 1

;---------------------------------------------------------------------------
;Commands
;---------------------------------------------------------------------------
;Shinryuken
[Command]
name = "Shinryuken"
command = ~D, DF, F, a+b
[Command]
name = "Shinryuken"
command = ~D, DF, F, a+c
[Command]
name = "Shinryuken"
command = ~D, DF, F, b+c

;-------------------------------------------------------------------------
;Shoryureppa
[Command]
name = "Shoryureppa"
command = ~D, DF, F, x+y
[Command]
name = "Shoryureppa"
command = ~D, DF, F, x+z
[Command]
name = "Shoryureppa"
command = ~D, DF, F, y+z

;-------------------------------------------------------------------------
;Kuzuryuu Reppa
[Command]
name = "Kuzuryuu_Reppa"
command = ~D, DB, B, a+b
[Command]
name = "Kuzuryuu_Reppa"
command = ~D, DB, B, a+c
[Command]
name = "Kuzuryuu_Reppa"
command = ~D, DB, B, b+c

;-------------------------------------------------------------------------
;Kongou Kokuretsu Zan
[Command]
name = "Kongou_Kokuretsu_Zan"
command = ~D, D, x+y
[Command]
name = "Kongou_Kokuretsu_Zan"
command = ~D, D, x+z
[Command]
name = "Kongou_Kokuretsu_Zan"
command = ~D, D, y+z

;-------------------------------------------------------------------------
;Shinbuu Messatsu
[Command]
name = "Shinbuu_Messatsu"
command = ~D, DB, B, x+y
[Command]
name = "Shinbuu_Messatsu"
command = ~D, DB, B, x+z
[Command]
name = "Shinbuu_Messatsu"
command = ~D, DB, B, y+z

;-------------------------------------------------------------------------
;Shoryuken
[Command]
name = "Shoryuken"
command = ~F, D, DF, x
[Command]
name = "M.Shoryuken"
command = ~F, D, DF, y
[Command]
name = "H.Shoryuken"
command = ~F, D, DF, z

;---------------------------------------------------------------------------
;Hadouken
[Command]
name = "Hadouken"
command = ~D, DF, F, x
[Command]
name = "M.Hadouken"
command = ~D, DF, F, y
[Command]
name = "H.Hadouken"
command = ~D, DF, F, z

;---------------------------------------------------------------------------
;Air Hadouken
[Command]
name = "Air_Hadouken"
command = ~D, DF, F, x
[Command]
name = "Air_M.Hadouken"
command = ~D, DF, F, y
[Command]
name = "Air_H.Hadouken"
command = ~D, DF, F, z

;-------------------------------------------------------------------------
;Flip Kick
[Command]
name = "Flip_Kick"
command = ~B, D, B, a
[Command]
name = "M_Flip_Kick"
command = ~B, D, B, b
[Command]
name = "H_Flip_Kick"
command = ~B, D, B, c

;-------------------------------------------------------------------------
;Tatsumaki Zankuu Kyaku
[Command]
name = "Tatsumaki_Zankuu_Kyaku"
command = ~D, DB, B, a
[Command]
name = "M.Tatsumaki_Zankuu_Kyaku"
command = ~D, DB, B, b
[Command]
name = "H.Tatsumaki_Zankuu_Kyaku"
command = ~D, DB, B, c

;-------------------------------------------------------------------------
;Air Tatsumaki Zankuu Kyaku
[Command]
name = "Air_Tatsumaki_Zankuu_Kyaku"
command = ~D, DB, B, a
[Command]
name = "Air_M.Tatsumaki_Zankuu_Kyaku"
command = ~D, DB, B, b
[Command]
name = "Air_H.Tatsumaki_Zankuu_Kyaku"
command = ~D, DB, B, c

;-------------------------------------------------------------------------
;Kujinkyaku
[Command]
name = "Kujinkyaku"
command = ~D,DF,F, a
[Command]
name = "M_Kujinkyaku"
command = ~D,DF,F, b
[Command]
name = "H_Kujinkyaku"
command = ~D,DF,F, c

;-------------------------------------------------------------------------
;Mawashi Geri
[Command]
name = "Mawashi_Geri"
command = ~5$B, F, a
[Command]
name = "M_Mawashi_Geri"
command = ~5$B, F, b
[Command]
name = "H_Mawashi_Geri"
command = ~5$B, F, c

;--------------------------------------------------------------------------
;Rasetsu
[Command]
name = "rasetsu1"
command = ~F, D, DF, a
[Command]
name = "rasetsu1"
command = ~F, D, DF, ~a
[Command]
name = "rasetsu2"
command = ~F, D, DF, b
[Command]
name = "rasetsu2"
command = ~F, D, DF, ~b
[Command]
name = "rasetsu3"
command = ~F, D, DF, c
[Command]
name = "rasetsu3"
command = ~F, D, DF, ~c

;---------------------------------------------------------------------------------------------
;Super Jump
[Command]
name = "Super_Jump"
command = ~D, U

;---------------------------------------------------------------------------------------------
;Double_Tap
[Command]
name = "FF"     ;Required (do not remove)
command = F, F
time = 10
[Command]
name = "BB"     ;Required (do not remove)
command = B, B
time = 10

;---------------------------------------------------------------------------------------------
;2/3 button combination
[Command]
name = "recovery";Required (do not remove)
command = x+y
time = 1

[Command]
name = "guardpush"
command = x+y
time = 5

[Command]
name = "guardpush"
command = x+z
time = 5

[Command]
name = "guardpush"
command = y+z
time = 5

[Command]
name = "Headbutt"
command = /$F,x+y
time = 5

[Command]
name = "throw_p"
command = y+z
time = 5

[Command]
name = "throw_p"
command = x+z
time = 5

[Command]
name = "Knee_Press"
command = /$F,a+b
time = 5

[Command]
name = "throw_k"
command = b+c
time = 5

[Command]
name = "throw_k"
command = a+c
time = 5

;---------------------------------------------------------------------------------------------
;Dir + button
[Command]
name = "down_a"
command = /$D,a
time = 1

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

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

[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 = "back_b"        ;Alternative button command
command = /$B,b
time = 1

[Command]
name = "back_c"        ;Alternative button command
command = /$B,c
time = 1

[Command]
name = "Forward Wakeup Roll"
command = /$F
time = 10

[Command]
name = "Backward Wakeup Roll"
command = /$B
time = 10

;---------------------------------------------------------------------------------------------
;One 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 = "holdx"
command = /x
time = 1

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

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

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

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

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

[Command]
name = "pc1"
command = b+y

[Command]
name = "ki"
command = /b+y

;---------------------------------------------------------------------------------------------
;Hold dir
[Command]
name = "holdfwd";Required (do not remove)
command = /$F
time = 1

[Command]
name = "holdback";Required (do not remove)
command = /$B
time = 1

[Command]
name = "holdup" ;Required (do not remove)
command = /$U
time = 1

[Command]
name = "holddown";Required (do not remove)
command = /$D
time = 1

[Command]
name = "SJ"
command = $D, $U

;---------------------------------------------------------------------------
;Artificial Intelligence
;---------------------------------------------------------------------------
[Statedef -1]
;-|-AI-|--------------------------------------------------------------------
[State -1, AI]
type = VarSet
trigger1 = command = "AI_1"
trigger2 = command = "AI_2"
trigger3 = command = "AI_3"
trigger4 = command = "AI_4"
trigger5 = command = "AI_5"
trigger6 = command = "AI_6"
trigger7 = command = "AI_7"
trigger8 = command = "AI_8"
trigger9 = command = "AI_9"
trigger10 = command = "AI_10"
trigger11 = command = "AI_11"
trigger12 = command = "AI_12"
trigger13 = command = "AI_13"
trigger14 = command = "AI_14"
trigger15 = command = "AI_15"
v = 59
value = 1

;--|-AI Defense-|-----------------------------------------------------------
[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = S)
trigger1 = (p2bodydist X <= 250) && (random <= 799)
value = 130

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = C)
trigger1 = (p2bodydist X <= 250) && (random <= 799)
value = 131

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = A)
trigger1 = (p2bodydist X <= 250) && (random <= 799)
value = 132

;-|-AI Combo Attempt-|----------------------------------------------
[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = S)
trigger1 = p2bodydist x <=10
value = 200

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = S)
trigger1 = p2bodydist x <=10
value = 210

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = S)
trigger1 = p2bodydist x <=10
value = 220

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = S)
trigger1 = p2bodydist x <=10
value = 230

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = S)
trigger1 = p2bodydist x <=10
value = 240

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = S)
trigger1 = p2bodydist x <=10
value = 250

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = C)
trigger1 = p2bodydist x <=10
value = 400

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = C)
trigger1 = (p2bodydist X <= 10) && (random <= 750)
value = 410

[State -1]
type = ChangeState
triggerall = var(59)>=1  && random <=600
triggerall = statetype != A
trigger1 = stateno = 400 && movehit && p2statetype !=A
value = 420

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = C)
trigger1 = p2bodydist x <=10
value = 430

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = C)
trigger1 = p2bodydist x <=10
value = 440

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = C)
trigger1 = p2bodydist x <=10
value = 450

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = A)
trigger1 = p2bodydist x <=10
value = 600

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = A)
trigger1 = p2bodydist x <=30
value = 610

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = A)
trigger1 = p2bodydist x <=10
value = 620

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = A)
trigger1 = p2bodydist x <=10
value = 630

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = A)
trigger1 = p2bodydist x <=10
value = 640

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (p2movetype = A) && (statetype = A)
trigger1 = p2bodydist x <=10
value = 650

;-|-AI Super Attempt-|----------------------------------------------
[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (Statetype = S) && (random = [0,500])
trigger1 = stateno = 210 && movehit && p2statetype !=A
trigger2 = p2bodydist x >= 300
value = 1000

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (Statetype = S) && (random = [0,500])
trigger1 = stateno = 210 && movehit && p2statetype !=A
trigger2 = p2bodydist x >= 300
value = 1020

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (Statetype = S) && (random = [0,500])
trigger1 = p2bodydist x = [14,60]
trigger1 = p2bodydist y = [-82,-55]
value = 1120

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (Statetype = S) && (random = [0,500])
trigger1 = stateno = 210 && movehit && p2statetype = A && random <=600
trigger2 = stateno = 400 && movehit && p2statetype = A && random <=600
trigger3 = ctrl && (enemynear,movetype = A) && (p2bodydist x <=50) && (p2bodydist y <= -20) ;&& random <=200
value = 1240

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (Statetype = S) && (random = [0,500])
trigger1 = stateno = 210 && movehit && p2statetype = A && random <=600
trigger2 = stateno = 400 && movehit && p2statetype = A && random <=600
trigger3 = ctrl && (enemynear,movetype = A) && (p2bodydist x <=50) && (p2bodydist y <= -20) ;&& random <=200
value = 1270

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (Statetype = S) && (random = [0,500])
trigger1 = pos y <= -33
trigger2 = stateno = 640 && movehit
value = 1520

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (Statetype = S) && (random = [0,500])
trigger1 = pos y <= -33
trigger2 = stateno = 640 && movehit
value = 1540

[State -1]
type = ChangeState
triggerall = (roundstate = 2) && (var(59) != 0)
triggerall = (Ctrl) && (Statetype = S) && (random = [0,500])
trigger1 = p2bodydist x = 100
value = 1800

;-|-AI Attempt Hyper-|---------------------------------------------
[State -1]
type = ChangeState
value = 3000
triggerall = var(59)>=1
triggerall = statetype != A
triggerall = power >=1000
trigger1 = stateno = 210 && movehit && p2statetype = A && random <=400
trigger2 = stateno = 400 && movehit && p2statetype = A && random <=400

[State -1]
type = ChangeState
value = 3100
triggerall = var(59)>=1
triggerall = statetype != A
triggerall = power >=1000
trigger1 = stateno = 210 && movehit && p2statetype = A && random <=400
trigger2 = stateno = 400 && movehit && p2statetype = A && random <=400

[State -1]
type = ChangeState
value = 3200
triggerall = var(59)>=1  && random <=500
triggerall = statetype  = A
triggerall = power >=2000
trigger1 = (stateno = 210) && movehit

[State -1]
type = ChangeState
value = 3300
triggerall = var(59)>=1  && random <=500
triggerall = statetype  = A
triggerall = power >=2000
trigger1 = (stateno = 210) && movehit

[State -1]
type = ChangeState
value = 3400
triggerall = var(59)>0 && random <=400
triggerall = Statetype != A
triggerall = p2Statetype != A
triggerall = power >=3000
trigger1 = stateno=210 && movehit
trigger2 = stateno=400 && movehit
trigger3 = stateno=430 && movehit

;---------------------------------------------------------------------------
;Commands
;---------------------------------------------------------------------------
[State -1, Rasetsu]
type = ChangeState
value = 1800
triggerall = Command = "rasetsu1" || Command = "rasetsu2" || Command = "rasetsu3"
triggerall = statetype != A
trigger1 = ctrl
trigger2=(stateno=[200,499]) && movecontact
;-----------------------------
[State -1, Dash Forward]
type = ChangeState
value = 100
triggerall = StateType = S
triggerall = (Ctrl) && (StateNo != 100)
trigger1 = Command = "FF"
;-----------------------------
[State -1, Dash Back]
type = ChangeState
value = 105
triggerall = StateType = S
triggerall = (Ctrl) && (StateNo != 100)
trigger1 = Command = "BB"
;-----------------------------
[State -1, Shinryuken]
type = ChangeState
value = 3000
triggerall = command = "Shinryuken"
triggerall = power >= 1000
trigger1 = Statetype != A && ctrl
trigger2 = (StateType != A) && (HitdefAttr = SC, NA) && (MoveContact)
trigger3= (stateno = [200,250]) && movecontact
trigger4 = (stateno = [400,450]) && movecontact
;-----------------------------
[State -1, Shoryureppa]
type = ChangeState
value = 3100
triggerall = command = "Shoryureppa"
triggerall = power >=1000
trigger1 = Statetype != A && ctrl
trigger2 = (StateType != A) && (HitdefAttr = SC, NA) && (MoveContact)
trigger3= (stateno = [200,250]) && movecontact
trigger4 = (stateno = [400,450]) && movecontact
;-----------------------------
[State -1, Kuzuryuu Reppa]
type = ChangeState
value = 3200
triggerall = command = "Kuzuryuu_Reppa"
triggerall = power >= 2000
trigger1 = Statetype != A && ctrl
trigger2 = (StateType != A) && (HitdefAttr = SC, NA) && (MoveContact)
trigger3= (stateno = [200,250]) && movecontact
trigger4 = (stateno = [400,450]) && movecontact
;-----------------------------
[State -1, Kongou Kokuretsu Zan]
type = ChangeState
value = 3300
triggerall = command = "Kongou_Kokuretsu_Zan"
triggerall = power >= 2000
trigger1 = Statetype != A && ctrl
trigger2 = (StateType != A) && (HitdefAttr = SC, NA) && (MoveContact)
trigger3= (stateno = [200,250]) && movecontact
trigger4 = (stateno = [400,450]) && movecontact
;-----------------------------
[State -1, Shinbuu Messatsu]
type = ChangeState
value = 3400
triggerall = command = "Shinbuu_Messatsu"
triggerall = power >= 3000
trigger1 = Statetype != A && ctrl
trigger2 = (StateType != A) && (HitdefAttr = SC, NA) && (MoveContact)
trigger3= (stateno = [200,250]) && movecontact
trigger4 = (stateno = [400,450]) && movecontact
;-------------------------------------------------------------------------
[State -1, Shoryuken]
type = ChangeState
value = 1200
triggerall = command = "Shoryuken"
trigger1 = (statetype = s) && ctrl
trigger3= (stateno = [200,250]) && movecontact
trigger4 = (stateno = [400,450]) && movecontact
;-----------------------------
[State -1, Shoryuken]
type = ChangeState
value = 1240
triggerall = command = "M.Shoryuken"
trigger1 = (statetype = s) && ctrl
trigger3= (stateno = [200,250]) && movecontact
trigger4 = (stateno = [400,450]) && movecontact
;-----------------------------
[State -1, Shoryuken]
type = ChangeState
value = 1270
triggerall = command = "H.Shoryuken"
trigger1 = (statetype = s) && ctrl
trigger3= (stateno = [200,250]) && movecontact
trigger4 = (stateno = [400,450]) && movecontact
;-------------------------------------------------------------------------
[State -1, Hadouken]
type = ChangeState
value = 1000
triggerall = command = "Hadouken"
triggerall = numproj = 0
trigger1 = Statetype != A && ctrl
trigger2 = (StateType != A) && (HitdefAttr = SC, NA) && (MoveContact)
trigger3= (stateno = [200,250]) && movecontact
trigger4 = (stateno = [400,450]) && movecontact
;-----------------------------
[State -1, Hadouken]
type = ChangeState
value = 1010
triggerall = command = "M.Hadouken"
triggerall = numproj = 0
trigger1 = Statetype != A && ctrl
trigger2 = (StateType != A) && (HitdefAttr = SC, NA) && (MoveContact)
trigger3= (stateno = [200,250]) && movecontact
trigger4 = (stateno = [400,450]) && movecontact
;-----------------------------
[State -1, Hadouken]
type = ChangeState
value = 1020
triggerall = command = "H.Hadouken"
triggerall = numproj = 0
trigger1 = Statetype != A && ctrl
trigger2 = (StateType != A) && (HitdefAttr = SC, NA) && (MoveContact)
trigger3= (stateno = [200,250]) && movecontact
trigger4 = (stateno = [400,450]) && movecontact
;-------------------------------------------------------------------------
[State -1, Air Hadouken]
type = ChangeState
value = 1030
triggerall = command = "Air_Hadouken"
trigger1 =statetype = A
triggerall = numproj = 0
trigger1 = (statetype = A) && (ctrl)
trigger2= (stateno = [600,650]) && movecontact
;-----------------------------
[State -1, Air Hadouken]
type = ChangeState
value = 1040
triggerall = command = "Air_M.Hadouken"
trigger1 =statetype = A
triggerall = numproj = 0
trigger1 = (statetype = A) && (ctrl)
trigger2= (stateno = [600,650]) && movecontact
;-----------------------------
[State -1, Air Hadouken]
type = ChangeState
value = 1050
triggerall = command = "Air_H.Hadouken"
trigger1 = statetype = A
triggerall = numproj = 0
trigger1 = (statetype = A) && (ctrl)
trigger2= (stateno = [600,650]) && movecontact
;-----------------------------
[State -1, Flip Kick]
type = ChangeState
value = 1300
triggerall = command = "Flip_Kick"
trigger1 = statetype != A && ctrl
trigger2= (stateno = [200,250]) && movecontact
trigger3 = (stateno = [400,450]) && movecontact
[State -1, Flip Kick]
type = ChangeState
value = 1310
triggerall = command = "M_Flip_Kick"
trigger1 = statetype != A && ctrl
trigger2= (stateno = [200,250]) && movecontact
trigger3 = (stateno = [400,450]) && movecontact
[State -1, Flip Kick]
type = ChangeState
value = 1315
triggerall = command = "H_Flip_Kick"
trigger1 = statetype != A && ctrl
trigger2= (stateno = [200,250]) && movecontact
trigger3 = (stateno = [400,450]) && movecontact
;-------------------------------------------------------------------------
[State -1, Air Tatsumaki_Zankuu_Kyaku]
type = ChangeState
value = 1150
triggerall = command = "Air_Tatsumaki_Zankuu_Kyaku"
trigger1 = (statetype = A) && (ctrl)
trigger2= (stateno = [600,650]) && movecontact
;-----------------------------
[State -1, Air Tatsumaki_Zankuu_Kyaku]
type = ChangeState
value = 1160
triggerall = command = "Air_M.Tatsumaki_Zankuu_Kyaku"
trigger1 =(statetype = A) && (ctrl)
trigger2= (stateno = [600,650]) && movecontact
;-----------------------------
[State -1, Air Tatsumaki_Zankuu_Kyaku]
type = ChangeState
value = 1170
triggerall = command = "Air_H.Tatsumaki_Zankuu_Kyaku"
trigger1 =(statetype = A) && (ctrl)
trigger2= (stateno = [600,650]) && movecontact
;-------------------------------------------------------------------------
[State -1, Tatsumaki_Zankuu_Kyaku]
type = ChangeState
value = 1100
triggerall = command = "Tatsumaki_Zankuu_Kyaku"
trigger1 = (statetype != A) && ctrl
trigger2= (stateno = [200,250]) && movecontact
trigger3 = (stateno = [400,450]) && movecontact
;-----------------------------
[State -1, Tatsumaki_Zankuu_Kyaku]
type = ChangeState
value = 1110
triggerall = command = "M.Tatsumaki_Zankuu_Kyaku"
trigger1 = (statetype != A) && ctrl
trigger2= (stateno = [200,250]) && movecontact
trigger3 = (stateno = [400,450]) && movecontact
;-----------------------------
[State -1, Tatsumaki_Zankuu_Kyaku]
type = ChangeState
value = 1120
triggerall = command = "H.Tatsumaki_Zankuu_Kyaku"
trigger1 =(statetype != A) && ctrl
trigger2= (stateno = [200,250]) && movecontact
trigger3 = (stateno = [400,450]) && movecontact
;-----------------------------
[State -1, Kujinkyaku]
type = ChangeState
value = 1500
triggerall = command = "Kujinkyaku"
trigger1 = (statetype = A) && (ctrl)
trigger2= (stateno = [600,650]) && movecontact
[State -1, Kujinkyaku]
type = ChangeState
value = 1520
triggerall = command = "M_Kujinkyaku"
trigger1 = (statetype = A) && (ctrl)
trigger2= (stateno = [600,650]) && movecontact
[State -1, Kujinkyaku]
type = ChangeState
value = 1540
triggerall = command = "H_Kujinkyaku"
trigger1 = (statetype = A) && (ctrl)
trigger2= (stateno = [600,650]) && movecontact
;-----------------------------
[State -1, Mawashi Geri]
type = ChangeState
value = 252
triggerall = command = "Mawashi_Geri"
trigger1 = (StateType = S) && (Ctrl)
trigger2= (stateno = [200,251]) && movecontact
trigger3= (stateno = [400,450]) && movecontact
[State -1, Mawashi_Geri]
type = ChangeState
value = 253
triggerall = command = "M_Mawashi_Geri"
trigger1 = (StateType = S) && (Ctrl)
trigger2= (stateno = [200,251]) && movecontact
trigger3= (stateno = [400,450]) && movecontact
[State -1, Mawashi_Geri]
type = ChangeState
value = 254
triggerall = command = "H_Mawashi_Geri"
trigger1 = (StateType = S) && (Ctrl)
trigger2= (stateno = [200,251]) && movecontact
trigger3= (stateno = [400,450]) && movecontact
;---------------------------------------------------------------------------
;Headbutt
[State -1, Throw]
type = ChangeState
value = 830
triggerall = command = "Headbutt"
triggerall = statetype = S
triggerall = ctrl
trigger1 = command = "holdfwd"
trigger1 = p2bodydist X < 10
trigger1 = (p2statetype = S)
trigger1 = p2movetype != H
trigger2 = command = "holdback"
trigger2 = p2bodydist X < 10
trigger2 = (p2statetype = S)
trigger2 = p2movetype != H
;---------------------------------------------------------------------------
;Knee_Press
[State -1, Throw 2]
type = ChangeState
value = 800
triggerall = command = "Knee_Press"
triggerall = statetype = S
triggerall = ctrl
trigger1 = command = "holdfwd"
trigger1 = p2bodydist X < 10
trigger1 = (p2statetype = S)
trigger1 = p2movetype != H
trigger2 = command = "holdback"
trigger2 = p2bodydist X < 10
trigger2 = (p2statetype = S)
trigger2 = p2movetype != H
;-----------------------------
[State -1, s]
type = ChangeState
value = 199
triggerall = Command = "s"
triggerall = Command != "holddown"
triggerall = stateno != 100
trigger1 = (StateType = S) && (Ctrl)
;-----------------------------
[State -1, X]
type = ChangeState
value = 200
triggerall = Command = "x"
triggerall = Command != "holddown"
trigger1 = (StateType = S) && (Ctrl)
trigger2= stateno = 210 && movehit
trigger3= stateno = 210 && movehit
trigger4= stateno = 220 && movehit
trigger5= stateno = 221 && movehit
trigger6= stateno = 230 && movehit
trigger7= stateno = 231 && movehit
trigger8= stateno = 240 && movehit
trigger9= stateno = 241 && movehit
trigger10= stateno = 250 && movehit
trigger11= stateno = 400 && movehit
trigger12= stateno = 410 && movehit
trigger13= stateno = 420 && movehit
trigger14= stateno = 430 && movehit
trigger15= stateno = 440 && movehit
trigger16= stateno = 450 && movehit
;-----------------------------
[State -1, Y]
type = ChangeState
value = IfElse(P2BodyDist X > 28,210,211)
triggerall = Command = "y"
triggerall = Command != "holddown"
trigger1 = (StateType = S) && (Ctrl)
trigger2= stateno = 200 && movehit
trigger3= stateno = 220 && movehit
trigger4= stateno = 221 && movehit
trigger5= stateno = 230 && movehit
trigger6= stateno = 231 && movehit
trigger7= stateno = 240 && movehit
trigger8= stateno = 241 && movehit
trigger9= stateno = 250 && movehit
trigger10= stateno = 251 && movehit
trigger11= stateno = 400 && movehit
trigger12= stateno = 410 && movehit
trigger13= stateno = 420 && movehit
trigger14= stateno = 430 && movehit
trigger15= stateno = 440 && movehit
trigger16= stateno = 450 && movehit
;-----------------------------
[State -1, Z]
type = ChangeState
value = IfElse(P2BodyDist X > 0,220,221)
triggerall = Command = "z"
triggerall = Command != "holddown"
trigger1 = (StateType = S) && (Ctrl)
trigger2= stateno = 200 && movehit
trigger3= stateno = 210 && movehit
trigger4= stateno = 211 && movehit
trigger5= stateno = 230 && movehit
trigger6= stateno = 231 && movehit
trigger7= stateno = 240 && movehit
trigger8= stateno = 241 && movehit
trigger9= stateno = 250 && movehit
trigger10= stateno = 251 && movehit
trigger11= stateno = 400 && movehit
trigger12= stateno = 410 && movehit
trigger13= stateno = 420 && movehit
trigger14= stateno = 430 && movehit
trigger15= stateno = 440 && movehit
trigger16= stateno = 450 && movehit
;-----------------------------
[State -1, A]
type = ChangeState
value = IfElse(P2BodyDist X > 28,230,231)
triggerall = Command = "a"
triggerall = Command != "holddown"
trigger1 = (StateType = S) && (Ctrl)
trigger2= stateno = 200 && movehit
trigger3= stateno = 210 && movehit
trigger4= stateno = 211 && movehit
trigger5= stateno = 220 && movehit
trigger6= stateno = 221 && movehit
trigger7= stateno = 240 && movehit
trigger8= stateno = 241 && movehit
trigger9= stateno = 250 && movehit
trigger10= stateno = 251 && movehit
trigger11= stateno = 400 && movehit
trigger12= stateno = 410 && movehit
trigger13= stateno = 420 && movehit
trigger14= stateno = 430 && movehit
trigger15= stateno = 440 && movehit
trigger16= stateno = 450 && movehit
;-----------------------------
[State -1, B]
type = ChangeState
value = IfElse(P2BodyDist X > 28,240,241)
triggerall = Command = "b"
triggerall = Command != "holddown"
trigger1 = (StateType = S) && (Ctrl)
trigger2= stateno = 200 && movehit
trigger3= stateno = 210 && movehit
trigger4= stateno = 211 && movehit
trigger5= stateno = 220 && movehit
trigger6= stateno = 221 && movehit
trigger7= stateno = 230 && movehit
trigger8= stateno = 231 && movehit
trigger9= stateno = 250 && movehit
trigger10= stateno = 251 && movehit
trigger11= stateno = 400 && movehit
trigger12= stateno = 410 && movehit
trigger13= stateno = 420 && movehit
trigger14= stateno = 430 && movehit
trigger15= stateno = 440 && movehit
trigger16= stateno = 450 && movehit
;-----------------------------
[State -1, C]
type = ChangeState
value = IfElse(P2BodyDist X > 28,250,251)
triggerall = Command = "c"
triggerall = Command != "holddown"
trigger1 = (StateType = S) && (Ctrl)
trigger2= stateno = 200 && movehit
trigger3= stateno = 210 && movehit
trigger4= stateno = 211 && movehit
trigger5= stateno = 220 && movehit
trigger6= stateno = 221 && movehit
trigger7= stateno = 230 && movehit
trigger8= stateno = 231 && movehit
trigger9= stateno = 240 && movehit
trigger10= stateno = 241 && movehit
trigger11= stateno = 400 && movehit
trigger12= stateno = 410 && movehit
trigger13= stateno = 420 && movehit
trigger14= stateno = 430 && movehit
trigger15= stateno = 440 && movehit
trigger16= stateno = 450 && movehit
;-----------------------------
[State -1, X agachado]
type = ChangeState
value = 400
triggerall = Command = "x"
triggerall = Command = "holddown"
trigger1 = (StateType != A) && (Ctrl)
trigger2= stateno = 410 && movehit
trigger3= stateno = 420 && movehit
trigger4= stateno = 430 && movehit
trigger5= stateno = 440 && movehit
trigger6= stateno = 450 && movehit
trigger7=(stateno = [200,250]) && movehit
;-----------------------------
[State -1, Y agachado]
type = ChangeState
value = 410
triggerall = Command = "y"
triggerall = Command = "holddown"
trigger1 = (StateType != A) && (Ctrl)
trigger2= stateno = 400 && movehit
trigger3= stateno = 420 && movehit
trigger4= stateno = 430 && movehit
trigger5= stateno = 440 && movehit
trigger6= stateno = 450 && movehit
trigger7=(stateno = [200,250]) && movehit
;-----------------------------
[State -1, Z agachado]
type = ChangeState
value = 420
triggerall = Command = "z"
triggerall = Command = "holddown"
trigger1 = (StateType != A) && (Ctrl)
trigger2= stateno = 400 && movehit
trigger3= stateno = 410 && movehit
trigger4= stateno = 430 && movehit
trigger5= stateno = 440 && movehit
trigger6= stateno = 450 && movehit
trigger7=(stateno = [200,250]) && movehit
;-----------------------------
[State -1, A agachado]
type = ChangeState
value = 430
triggerall = Command = "a"
triggerall = Command = "holddown"
trigger1 = (StateType != A) && (Ctrl)
trigger2= stateno = 400 && movehit
trigger3= stateno = 410 && movehit
trigger4= stateno = 420 && movehit
trigger5= stateno = 440 && movehit
trigger6= stateno = 450 && movehit
trigger7=(stateno = [200,250]) && movehit
;-----------------------------
[State -1, B agachado]
type = ChangeState
value = 440
triggerall = Command = "b"
triggerall = Command = "holddown"
trigger1 = (StateType != A) && (Ctrl)
trigger2= stateno = 400 && movehit
trigger3= stateno = 410 && movehit
trigger4= stateno = 420 && movehit
trigger5= stateno = 430 && movehit
trigger6= stateno = 450 && movehit
trigger7=(stateno = [200,250]) && movehit
;-----------------------------
[State -1, C agachado]
type = ChangeState
value = 450
triggerall = Command = "c"
triggerall = Command = "holddown"
trigger1 = (StateType != A) && (Ctrl)
trigger2= stateno = 400 && movehit
trigger3= stateno = 410 && movehit
trigger4= stateno = 420 && movehit
trigger5= stateno = 430 && movehit
trigger6= stateno = 440 && movehit
trigger7=(stateno = [200,250]) && movehit
;-----------------------------
[State -1, X]
type = ChangeState
value = 600
triggerall = command = "x"
trigger1 = Statetype = A && ctrl
trigger2= stateno = 610 && movehit
trigger3= stateno = 620 && movehit
trigger4= stateno = 630 && movehit
trigger5= stateno = 640 && movehit
trigger6= stateno = 650 && movehit
;-----------------------------
[State -1, Y]
type = ChangeState
value = 610
triggerall = command = "y"
trigger1 = Statetype = A && ctrl
trigger2= stateno = 600 && movehit
trigger3= stateno = 620 && movehit
trigger4= stateno = 630 && movehit
trigger5= stateno = 640 && movehit
trigger6= stateno = 650 && movehit
;-----------------------------
[State -1, Z]
type = ChangeState
value = 620
triggerall = command = "z"
trigger1 = Statetype = A && ctrl
trigger2= stateno = 600 && movehit
trigger3= stateno = 610 && movehit
trigger4= stateno = 630 && movehit
trigger5= stateno = 640 && movehit
trigger6= stateno = 650 && movehit
;-----------------------------
[State -1, A]
type = ChangeState
value = 630
triggerall = command = "a"
trigger1 = Statetype = A && ctrl
trigger2= stateno = 600 && movehit
trigger3= stateno = 610 && movehit
trigger4= stateno = 620 && movehit
trigger5= stateno = 640 && movehit
trigger6= stateno = 650 && movehit
;-----------------------------
[State -1, B]
type = ChangeState
value = 640
triggerall = command = "b"
trigger1 = Statetype = A && ctrl
trigger2= stateno = 600 && movehit
trigger3= stateno = 610 && movehit
trigger4= stateno = 620 && movehit
trigger5= stateno = 630 && movehit
trigger6= stateno = 650 && movehit
;-----------------------------
[State -1, C]
type = ChangeState
value = 650
triggerall = command = "c"
trigger1 = Statetype = A && ctrl
trigger2= stateno = 600 && movehit
trigger3= stateno = 610 && movehit
trigger4= stateno = 630 && movehit
trigger5= stateno = 640 && movehit
;------------------------------------------------------------------------
[State -1, Super Jump]
type = ChangeState
value = 7000
triggerall = Command = "SJ"
trigger1 = StateType = S
trigger1 = ctrl
;-----------------------------
[State -1, Super Jump]
type = ChangeState
value = 7000
triggerall = Command = "holdup"
trigger1 = stateno = 420 && movehit
;-----------------------------
[State -1, Guard Push stand]
type = ChangeState
value = 6300
triggerall = command = "guardpush" && statetype = S
trigger1 = stateno = [150,153]
[State -1, Guard Push crouch]
type = ChangeState
value = 6310
triggerall = command = "guardpush" && statetype = C
trigger1 = stateno = [150,153]
[State -1, Guard Push crouch]
type = ChangeState
value = 6320
triggerall = command = "guardpush" && statetype = A
trigger1 = stateno = [150,153]
;---------------------------------------------------------------------------
;----------------------------- Recovery Roll -------------------------------
;---------------------------------------------------------------------------
;Forward Wakeup Roll
[State -1, Forward Wakeup Roll]
type = ChangeState
value = 900
triggerall = (stateno = 5110) && time >= 5
trigger1 =  Life
trigger1 = command = "Forward Wakeup Roll"

;---------------------------------------------------------------------------
;Backward Wakeup Roll
[State -1, Backward Wakeup Roll]
type = ChangeState
value = 920
triggerall = (stateno = 5110) && time >= 5
trigger1 = life
trigger1 =  command = "Backward Wakeup Roll"
