;==========================================================================
;                   Alfred 's Command file
;==========================================================================
;

[Remap]
x = x
y = y
z = z
a = a
b = b
c = c
s = s

[Defaults]
command.time = 15
command.buffer.time = 1

;------------------------------------------------------------------------------
;-| MAX2超必杀 |---------------------------------------------------------
[Command]
name = "踏浪者"
command = ~F,B,D,F,a+b
time = 30

[Command]
name = "踏浪者"
command = ~F,B,D,F,c
time = 30
;------------------------------------------------------------------------------
;-| MAX超必杀 |---------------------------------------------------------
[Command]
name = "MAX震荡失速"
command = ~D,F,a+b
time = 30

[Command]
name = "MAX震荡失速"
command = ~D,F,c
time = 30
;------------------------------------------------------------------------------
;-| 超必杀 |---------------------------------------------------------
[Command]
name = "震荡失速"
command = ~D,F,a
time = 30

[Command]
name = "震荡失速"
command = ~D,F,b
time = 30
;------------------------------------------------------------------------------
;-| 必杀技 |---------------------------------------------------------
[Command]
name = "求救求救·派生3"
command = ~b,b,b,b
time = 20

[Command]
name = "求救求救·派生2"
command = ~b,b,b
time = 20

[Command]
name = "求救求救·派生1"
command = ~b,b
time = 20

[Command]
name = "求救求救"
command = D,B,a
time = 20

[Command]
name = "求救求救"
command = ~D,B,b
time = 20

[Command]
name = "轻短距起落"
command = ~D,F,a
time = 20

[Command]
name = "重短距起落"
command = ~D,F,b
time = 20

[Command]
name = "增强之翼"
command = ~D,F,x
time = 16

[Command]
name = "散度"
command = ~D,F,y
time = 16

[Command]
name = "轻危急之翼"
command = ~D,B,x
time = 16

[Command]
name = "重危急之翼"
command = ~D,B,y
time = 16

[Command]
name = "jump"    
command = D, $U
time = 12

;------------------------------------------------------------------------------
;-| 普通操作 |---------------------------------------------------------
[Command]
name = "CD"
command = c
time = 10

[Command]
name = "CD"
command = b+y
time = 14

[Command]
name = "FF"
command = F, F
time = 10

[Command]
name = "BB"
command = B, B
time = 10

[Command]
name = "recovery"
command = x+a
time = 1

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

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

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

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

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

[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 = "start"
command = s
time = 1

[Command]
name = "holdfwd" 
command = /$F
time = 1

[Command]
name = "holdback" 
command = /$B
time = 1

[Command]
name = "holdup" 
command = /$U
time = 1

[Command]
name = "holddown"
command = /$D
time = 1

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

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

[Command]
name = "holdx"
command = /$x
time = 1

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

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

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

;------------------------------------------------------------------------------
;-| -1 |---------------------------------------------------------
[Statedef -1]
;---------------------------------------------------------------------------
;踏浪者
[State -1]
type = ChangeState
value = 3100
triggerall = Var(50) = 0
triggerall = power >= 3000
triggerall = command = "踏浪者"
trigger1 = ctrl && statetype != A
trigger2 = (stateno = 200 && MoveContact)
trigger3 = (stateno = 205 && MoveContact)
trigger4 = (stateno = 400 && MoveContact)
trigger5 = (stateno = 410 && MoveContact)
trigger6 = (stateno = 210 && MoveContact)
trigger7 = (stateno = 230 && MoveContact)
trigger8 = (stateno = 235 && MoveContact)
trigger9 = (stateno = 420 && MoveContact)
trigger10 = (stateno = 215 && MoveContact)
trigger11 = (stateno = 250 && MoveContact)

;---------------------------------------------------------------------------
;MAX震荡失速
[State -1]
type = ChangeState
value = 3050
triggerall = Var(50) = 0
triggerall = power >= 2000
triggerall = command = "MAX震荡失速"
trigger1 = ctrl && statetype = A
trigger2 = (stateno = 600 && MoveContact)
trigger3 = (stateno = 610 && MoveContact)
trigger4 = (stateno = 630 && MoveContact)
trigger5 = (stateno = 640 && MoveContact)

;---------------------------------------------------------------------------
;震荡失速
[State -1]
type = ChangeState
value = 3000
triggerall = Var(50) = 0
triggerall = power >= 1000
triggerall = command = "震荡失速"
trigger1 = ctrl && statetype = A
trigger2 = (stateno = 600 && MoveContact)
trigger3 = (stateno = 610 && MoveContact)
trigger4 = (stateno = 630 && MoveContact)
trigger5 = (stateno = 640 && MoveContact)

;---------------------------------------------------------------------------
;重短距起落
[State -1]
type = ChangeState
value = 1550
triggerall = Var(50) = 0
triggerall = command = "重短距起落"
trigger1 = ctrl && statetype != A
trigger2 = (stateno = 200 && MoveContact)
trigger3 = (stateno = 205 && MoveContact)
trigger4 = (stateno = 400 && MoveContact)
trigger5 = (stateno = 410 && MoveContact)
trigger6 = (stateno = 210 && MoveContact)
trigger7 = (stateno = 230 && MoveContact)
trigger8 = (stateno = 235 && MoveContact)
trigger9 = (stateno = 420 && MoveContact)
trigger10 = (stateno = 215 && MoveContact)
trigger11 = (stateno = 250 && MoveContact)

;---------------------------------------------------------------------------
;轻短距起落
[State -1]
type = ChangeState
value = 1500
triggerall = Var(50) = 0
triggerall = command = "轻短距起落"
trigger1 = ctrl && statetype != A
trigger2 = (stateno = 200 && MoveContact)
trigger3 = (stateno = 205 && MoveContact)
trigger4 = (stateno = 400 && MoveContact)
trigger5 = (stateno = 410 && MoveContact)
trigger6 = (stateno = 210 && MoveContact)
trigger7 = (stateno = 230 && MoveContact)
trigger8 = (stateno = 235 && MoveContact)
trigger9 = (stateno = 420 && MoveContact)
trigger10 = (stateno = 215 && MoveContact)
trigger11 = (stateno = 250 && MoveContact)

;---------------------------------------------------------------------------
;求救求救
[State -1]
type = ChangeState
value = 1400
triggerall = Var(50) = 0
triggerall = command = "求救求救"
trigger1 = ctrl && statetype = A
;trigger2 = (stateno = 200 && MoveContact)
;trigger3 = (stateno = 205 && MoveContact)
;trigger4 = (stateno = 400 && MoveContact)
;trigger5 = (stateno = 410 && MoveContact)
;trigger6 = (stateno = 210 && MoveContact)
;trigger7 = (stateno = 230 && MoveContact)
;trigger8 = (stateno = 235 && MoveContact)
;trigger9 = (stateno = 420 && MoveContact)
;trigger10 = (stateno = 215 && MoveContact)
;trigger11 = (stateno = 250 && MoveContact)

;---------------------------------------------------------------------------
;散度
[State -1]
type = ChangeState
value = 1100
triggerall = Var(50) = 0
triggerall = command = "散度"
trigger1 = ctrl && statetype != A
trigger2 = (stateno = 200 && MoveContact)
trigger3 = (stateno = 205 && MoveContact)
trigger4 = (stateno = 400 && MoveContact)
trigger5 = (stateno = 410 && MoveContact)
trigger6 = (stateno = 210 && MoveContact)
trigger7 = (stateno = 230 && MoveContact)
trigger8 = (stateno = 235 && MoveContact)
trigger9 = (stateno = 420 && MoveContact)
trigger10 = (stateno = 215 && MoveContact)
trigger11 = (stateno = 250 && MoveContact)

;---------------------------------------------------------------------------
;增强之翼
[State -1]
type = ChangeState
value = 1200
triggerall = Var(50) = 0
triggerall = command = "增强之翼"
trigger1 = ctrl && statetype != A
trigger2 = (stateno = 200 && MoveContact)
trigger3 = (stateno = 205 && MoveContact)
trigger4 = (stateno = 400 && MoveContact)
trigger5 = (stateno = 410 && MoveContact)
trigger6 = (stateno = 210 && MoveContact)
trigger7 = (stateno = 230 && MoveContact)
trigger8 = (stateno = 235 && MoveContact)
trigger9 = (stateno = 420 && MoveContact)
trigger10 = (stateno = 215 && MoveContact)
trigger11 = (stateno = 250 && MoveContact)

;---------------------------------------------------------------------------
;重危急之翼
[State -1]
type = ChangeState
value = 1050
triggerall = Var(50) = 0
triggerall = command = "重危急之翼"
trigger1 = ctrl && statetype != A
trigger2 = (stateno = 200 && MoveContact)
trigger3 = (stateno = 205 && MoveContact)
trigger4 = (stateno = 400 && MoveContact)
trigger5 = (stateno = 410 && MoveContact)
trigger6 = (stateno = 210 && MoveContact)
trigger7 = (stateno = 230 && MoveContact)
trigger8 = (stateno = 235 && MoveContact)
trigger9 = (stateno = 420 && MoveContact)
trigger10 = (stateno = 215 && MoveContact)
trigger11 = (stateno = 250 && MoveContact)

;---------------------------------------------------------------------------
;轻危急之翼
[State -1]
type = ChangeState
value = 1000
triggerall = Var(50) = 0
triggerall = command = "轻危急之翼"
trigger1 = ctrl && statetype != A
trigger2 = (stateno = 200 && MoveContact)
trigger3 = (stateno = 205 && MoveContact)
trigger4 = (stateno = 400 && MoveContact)
trigger5 = (stateno = 410 && MoveContact)
trigger6 = (stateno = 210 && MoveContact)
trigger7 = (stateno = 230 && MoveContact)
trigger8 = (stateno = 235 && MoveContact)
trigger9 = (stateno = 420 && MoveContact)
trigger10 = (stateno = 215 && MoveContact)
trigger11 = (stateno = 250 && MoveContact)

;------------------------------------------------------------------------------
;C投
[State -1, Throw]
type = ChangeState
value = 800
triggerall = command = "y"
triggerall = command = "holdfwd" || command = "holdback"
triggerall = statetype = S
triggerall = stateno != 100
trigger1 = p2bodydist X < 15
trigger1 = p2statetype != A && p2movetype != H
trigger1 = ctrl

;------------------------------------------------------------------------------
;D投技
[State -1, Throw]
type = ChangeState
value = 805
triggerall = command = "b"
triggerall = command = "holdfwd" || command = "holdback"
triggerall = statetype = S
triggerall = stateno != 100
trigger1 = p2bodydist X < 15
trigger1 = p2statetype != A && p2movetype != H
trigger1 = ctrl

;---------------------------------------------------------------------------
;回避后
[State -1, T S]
type = ChangeState
value = 710
triggerall = command = "recovery" && command = "holdback"
trigger1 = statetype = S
trigger1 = ctrl

;---------------------------------------------------------------------------
;回避
[State -1, T S]
type = ChangeState
value = 700
triggerall = command = "recovery"
trigger1 = statetype = S
trigger1 = ctrl
trigger2 = stateno = 100

;---------------------------------------------------------------------------
;受身
[State -1, UKEMI]
type = ChangeState
value = 5201
triggerall = command = "recovery"
triggerall = alive = 1
trigger1 = stateno = 5050
trigger1 = pos y > -30
trigger1 = vel y > 0 && vel y < 9

;------------------------------------------------------------------------------
;福克
[State -1]
type = ChangeState
value = 300
triggerall = !var(9)
triggerall = command = "b"
triggerall = command = "holddown"
triggerall = command != "holdback"
triggerall = command != "holdfwd"
triggerall = stateno !=105
triggerall = sysvar(3) = 0
triggerall = statetype =A
trigger1 = ctrl

;------------------------------------------------------------------------------
;跑步
[State -1, Dash]
type = ChangeState
value = 100
trigger1 = command = "FF"
trigger1 = statetype = S
trigger1 = ctrl

;疾退
[State -1, Back Step]
type = ChangeState
value = 105
trigger1 = command = "BB"
trigger1 = statetype = S
trigger1 = ctrl

;==============================================================================
;嬤嫍棧棫偪庛僷儞僠
[State -1, Stand Light Punch]
type = ChangeState
value = 205
triggerall = command = "x"
triggerall = command != "holddown"
triggerall = statetype = S
triggerall = p2bodydist X < 18
trigger1 = ctrl

;墦嫍棧棫偪庛僷儞僠
[State -1, Stand Light Punch]
type = ChangeState
value = 200
triggerall = command = "x"
triggerall = command != "holddown"
triggerall = statetype = S
trigger1 = ctrl

;嬤嫍棧棫偪嫮僷儞僠
[State -1, Stand Strong Punch]
type = ChangeState
value = 215
triggerall = command = "y"
triggerall = command != "holddown"
triggerall = statetype = S
triggerall = p2bodydist X < 24
trigger1 = ctrl

;墦嫍棧棫偪嫮僷儞僠
[State -1, Stand Strong Punch]
type = ChangeState
value = 210
triggerall = command = "y"
triggerall = command != "holddown"
triggerall = statetype = S
trigger1 = ctrl

;------------------------------------------------------------------------------
;嬤嫍棧棫偪庛僉僢僋
[State -1, Stand Light Kick]
type = ChangeState
value = 235
triggerall = command = "a"
triggerall = command != "holddown"
triggerall = statetype = S
triggerall = p2bodydist X < 14
trigger1 = ctrl

;墦嫍棧棫偪庛僉僢僋
[State -1, Stand Light Kick]
type = ChangeState
value = 230
triggerall = command = "a"
triggerall = command != "holddown"
triggerall = statetype = S
trigger1 = ctrl

;嬤嫍棧棫偪嫮僉僢僋
[State -1, Standing Strong Kick]
type = ChangeState
value = 245
triggerall = !var(59)
triggerall = command = "b"
triggerall = command != "holddown"
triggerall = statetype = S
triggerall = p2bodydist X < 20
trigger1 = ctrl

;墦嫍棧棫偪嫮僉僢僋
[State -1, Standing Strong Kick]
type = ChangeState
value = 240
triggerall = !var(59)
triggerall = command = "b"
triggerall = command != "holddown"
triggerall = statetype = S
trigger1 = ctrl

;------------------------------------------------------------------------------
;挧敪
[State -1, Taunt]
type = ChangeState
value = 195
triggerall = command = "start"
triggerall = var(20) = 0
trigger1 = statetype != A
trigger1 = ctrl

;------------------------------------------------------------------------------
;偟傖偑傒庛僷儞僠
[State -1, Crouching Light Punch]
type = ChangeState
value = 400
triggerall = command = "x"
triggerall = command = "holddown"
trigger1 = statetype = C
trigger1 = ctrl
trigger2 = stateno = 430 && time >= 4 && movecontact

;偟傖偑傒嫮僷儞僠
[State -1, Crouching Strong Punch]
type = ChangeState
value = 410
triggerall = command = "y"
triggerall = command = "holddown"
trigger1 = statetype = C
trigger1 = ctrl

;------------------------------------------------------------------------------
;偟傖偑傒庛僉僢僋
[State -1, Crouching Light Kick]
type = ChangeState
value = 430
triggerall = command = "a"
triggerall = command = "holddown"
trigger1 = statetype = C
trigger1 = ctrl

;偟傖偑傒嫮僉僢僋
[State -1, Crouching Strong Kick]
type = ChangeState
value = 440
triggerall = command = "b"
triggerall = command = "holddown"
trigger1 = statetype = C
trigger1 = ctrl

;------------------------------------------------------------------------------
;僕儍儞僾庛僷儞僠
[State -1, Jump Light Punch]
type = ChangeState
value = 600
triggerall = command = "x"
triggerall = stateno != 105
trigger1 = statetype = A
trigger1 = ctrl

;僕儍儞僾嫮僷儞僠
[State -1, Jump Strong Punch]
type = ChangeState
value = 610
triggerall = command = "y"
triggerall = stateno != 105
trigger1 = statetype = A
trigger1 = ctrl

;------------------------------------------------------------------------------
;悅捈僕儍儞僾庛僉僢僋
[State -1, Jump Light Kick]
type = ChangeState
value = 630
triggerall = command = "a"
triggerall = stateno != 105
triggerall = vel X = 0
trigger1 = statetype = A
trigger1 = ctrl

;幬傔僕儍儞僾庛僉僢僋
[State -1, Jump Light Kick]
type = ChangeState
value = 635
triggerall = command = "a"
triggerall = stateno != 105
triggerall = vel X != 0
trigger1 = statetype = A
trigger1 = ctrl

;悅捈僕儍儞僾嫮僉僢僋
[State -1, Jump Strong Kick]
type = ChangeState
value = 640
triggerall = command = "b"
triggerall = stateno != 105
trigger1 = statetype = A
trigger1 = ctrl

;CD simple (stand)
[State -1]
type = ChangeState
value = 250
triggerall = command = "CD" && statetype != A
trigger1 = ctrl

;CD simple (Jump)
[State -1]
type = ChangeState
value = 650
triggerall = command = "CD" && statetype = A
trigger1 = ctrl

; CD Counter
[State -1]
type = ChangeState
value = 255
trigger1 = command = "CD" && stateno = [150,151]
trigger1 = power >=1000
