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

;-| Default Values |-------------------------------------------------------
[Defaults]
; Default value for the "time" parameter of a Command. Minimum 1.
command.time = 15

; Default value for the "buffer.time" parameter of a Command. Minimum 1,
; maximum 30.
command.buffer.time = 3 ;1

;-| Hyper Motions |--------------------------------------------------------
[Command]
name = "qcbhcf_K"
command = ~D, DB, B, D, F, a
time = 30
[Command]
name = "qcbhcf_K"
command = ~D, DB, B, D, F, ~a
time = 30
[Command]
name = "qcbhcf_K"
command = ~D, DB, B, D, F, b
time = 30
[Command]
name = "qcbhcf_K"
command = ~D, DB, B, D, F, ~b
time = 30
[Command]
name = "qcbhcf_K"
command = ~D, DB, B, D, F, c
time = 30
[Command]
name = "qcbhcf_K"
command = ~D, DB, B, D, F, ~c
time = 30

[Command]
name = "qcfhcb_K"
command = ~D, F, D, B, a
time = 30
[Command]
name = "qcfhcb_K"
command = ~D, F, D, B, ~a
time = 30
[Command]
name = "qcfhcb_K"
command = ~D, F, D, B, b
time = 30
[Command]
name = "qcfhcb_K"
command = ~D, F, D, B, ~b
time = 30
[Command]
name = "qcfhcb_K"
command = ~D, F, D, B, c
time = 30
[Command]
name = "qcfhcb_K"
command = ~D, F, D, B, ~c
time = 30

[Command]
name = "qcfhcb_P"
command = ~D, DF, F, D, B, x
time = 30
[Command]
name = "qcfhcb_P"
command = ~D, DF, F, D, B, ~x
time = 30
[Command]
name = "qcfhcb_P"
command = ~D, DF, F, D, B, y
time = 30
[Command]
name = "qcfhcb_P"
command = ~D, DF, F, D, B, ~y
time = 30
[Command]
name = "qcfhcb_P"
command = ~D, DF, F, D, B, z
time = 30
[Command]
name = "qcfhcb_P"
command = ~D, DF, F, D, B, ~z
time = 30

[Command]
name = "2qcf2p"
command = ~D, DF, F, D, DF, x+y
time = 20
[Command]
name = "2qcf2p"
command = ~D, DF, F, D, DF, x+z
time = 20
[Command]
name = "2qcf2p"
command = ~D, DF, F, D, DF, y+z
time = 20

[Command]
name = "2qcf2k"
command = ~D, DF, F, D, DF, a+b
time = 20
[Command]
name = "2qcf2k"
command = ~D, DF, F, D, DF, a+c
time = 20
[Command]
name = "2qcf2k"
command = ~D, DF, F, D, DF, b+c
time = 20

[Command]
name = "qcbf3p"
command = ~D, $B, F, x+y+z
time = 20

[Command]
name = "qcbf2p"
command = ~D, $B, F, x+y
time = 20
[Command]
name = "qcbf2p"
command = ~D, $B, F, x+z
time = 20
[Command]
name = "qcbf2p"
command = ~D, $B, F, y+z
time = 20

[Command]
name = "EMO"
command = D, D, y+b;D, D, D, y+b
time = 20 ;30

[Command]
name = "puddle"
command = D, D, D ;D, D, x+a
time = 20


[Command]
name = "chaosburst"
command = D, D, x+y
time = 20

[Command]
name = "chaosburst"
command = D, D, y+z
time = 20

[Command]
name = "chaosburst"
command = D, D, x+z
time = 20

[Command]
name = "chaosburst"
command = D, D, a+b
time = 20

[Command]
name = "chaosburst"
command = D, D, b+c
time = 20

[Command]
name = "chaosburst"
command = D, D, a+c
time = 20


;-| Super Motions |--------------------------------------------------------

[Command]
name = "2qcfx"
command = ~D, DF, F, D, DF, x
time = 20
[Command]
name = "2qcfx"
command = ~D, DF, F, D, DF, ~x
time = 20
[Command]
name = "2qcfy"
command = ~D, DF, F, D, DF, y
time = 20
[Command]
name = "2qcfy"
command = ~D, DF, F, D, DF, ~y
time = 20
[Command]
name = "2qcfz"
command = ~D, DF, F, D, DF, z
time = 20
[Command]
name = "2qcfz"
command = ~D, DF, F, D, DF, ~z
time = 20

[Command]
name = "2qcfa"
command = ~D, DF, F, D, DF, a
time = 20
[Command]
name = "2qcfa"
command = ~D, DF, F, D, DF, ~a
time = 20
[Command]
name = "2qcfb"
command = ~D, DF, F, D, DF, b
time = 20
[Command]
name = "2qcfb"
command = ~D, DF, F, D, DF, ~b
time = 20
[Command]
name = "2qcfc"
command = ~D, DF, F, D, DF, c
time = 20
[Command]
name = "2qcfc"
command = ~D, DF, F, D, DF, ~c
time = 20

[Command]
name = "2qcbx"
command = ~D, DB, B, D, DB, x
time = 20
[Command]
name = "2qcbx"
command = ~D, DB, B, D, DB, ~x
time = 20
[Command]
name = "2qcby"
command = ~D, DB, B, D, DB, y
time = 20
[Command]
name = "2qcby"
command = ~D, DB, B, D, DB, ~y
time = 20
[Command]
name = "2qcbz"
command = ~D, DB, B, D, DB, z
time = 20
[Command]
name = "2qcbz"
command = ~D, DB, B, D, DB, ~z
time = 20

[Command]
name = "2qcba"
command = ~D, DB, B, D, DB, a
time = 20
[Command]
name = "2qcba"
command = ~D, DB, B, D, DB, ~a
time = 20
[Command]
name = "2qcbb"
command = ~D, DB, B, D, DB, b
time = 20
[Command]
name = "2qcbb"
command = ~D, DB, B, D, DB, ~b
time = 20
[Command]
name = "2qcbc"
command = ~D, DB, B, D, DB, c
time = 20
[Command]
name = "2qcbc"
command = ~D, DB, B, D, DB, ~c
time = 20

[Command]
name = "qcbfx"
command = ~D, DB, B, F, x;~D, $B, F, x
time = 20
[Command]
name = "qcbfx"
command = ~D, DB, B, F, ~x
time = 20
[Command]
name = "qcbfy"
command = ~D, DB, B, F, y
time = 20
[Command]
name = "qcbfy"
command = ~D, DB, B, F, ~y
time = 20
[Command]
name = "qcbfz"
command = ~D, DB, B, F, z
time = 20
[Command]
name = "qcbfz"
command = ~D, DB, B, F, ~z
time = 20

[Command]
name = "qcbfa"
command = ~D, DB, B, F, a
time = 20
[Command]
name = "qcbfa"
command = ~D, DB, B, F, ~a
time = 20
[Command]
name = "qcbfb"
command = ~D, DB, B, F, b
time = 20
[Command]
name = "qcbfb"
command = ~D, DB, B, F, ~b
time = 20
[Command]
name = "qcbfc"
command = ~D, DB, B, F, c
time = 20
[Command]
name = "qcbfc"
command = ~D, DB, B, F, ~c
time = 20

;-| EX Motions |------------------------------------------------------

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

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

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

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

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

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

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

;-| Special Motions |------------------------------------------------------

[Command]
name = "fbfx"
command = ~F, B, F, x
[Command]
name = "fbfx"
command = ~F, B, F, ~x
[Command]
name = "fbfy"
command = ~F, B, F, y
[Command]
name = "fbfy"
command = ~F, B, F, ~y
[Command]
name = "fbfz"
command = ~F, B, F, z
[Command]
name = "fbfz"
command = ~F, B, F, ~z

[Command]
name = "qcfx"
command = ~D, DF, F, x
[Command]
name = "qcfx"
command = ~D, DF, F, ~x
[Command]
name = "qcfy"
command = ~D, DF, F, y
[Command]
name = "qcfy"
command = ~D, DF, F, ~y
[Command]
name = "qcfz"
command = ~D, DF, F, z
[Command]
name = "qcfz"
command = ~D, DF, F, ~z

[Command]
name = "qcfa"
command = ~D, DF, F, a
[Command]
name = "qcfa"
command = ~D, DF, F, ~a
[Command]
name = "qcfb"
command = ~D, DF, F, b
[Command]
name = "qcfb"
command = ~D, DF, F, ~b
[Command]
name = "qcfc"
command = ~D, DF, F, c
[Command]
name = "qcfc"
command = ~D, DF, F, ~c

[Command]
name = "qcbx"
command = ~D, DB, B, x
[Command]
name = "qcbx"
command = ~D, DB, B, ~x
[Command]
name = "qcby"
command = ~D, DB, B, y
[Command]
name = "qcby"
command = ~D, DB, B, ~y
[Command]
name = "qcbz"
command = ~D, DB, B, z
[Command]
name = "qcbz"
command = ~D, DB, B, ~z

[Command]
name = "qcba"
command = ~D, DB, B, a
[Command]
name = "qcba"
command = ~D, DB, B, ~a
[Command]
name = "qcbb"
command = ~D, DB, B, b
[Command]
name = "qcbb"
command = ~D, DB, B, ~b
[Command]
name = "qcbc"
command = ~D, DB, B, c
[Command]
name = "qcbc"
command = ~D, DB, B, ~c

[Command]
name = "dpa"
command = ~F, D, DF, a
[Command]
name = "dpa"
command = ~F, D, DF, ~a
[Command]
name = "dpb"
command = ~F, D, DF, b
[Command]
name = "dpb"
command = ~F, D, DF, ~b
[Command]
name = "dpc"
command = ~F, D, DF, c
[Command]
name = "dpc"
command = ~F, D, DF, ~c

[Command]
name = "dpx"
command = ~F, D, DF, x
[Command]
name = "dpx"
command = ~F, D, DF, ~x
[Command]
name = "dpy"
command = ~F, D, DF, y
[Command]
name = "dpy"
command = ~F, D, DF, ~y
[Command]
name = "dpz"
command = ~F, D, DF, z
[Command]
name = "dpz"
command = ~F, D, DF, ~z




[Command]
name = "btoda"
command = ~B, DB, D, a
[Command]
name = "btoda"
command = ~B, DB, D, ~a
[Command]
name = "btodb"
command = ~B, DB, D, b
[Command]
name = "btodb"
command = ~B, DB, D, ~b
[Command]
name = "btodc"
command = ~B, DB, D, c
[Command]
name = "btodc"
command = ~B, DB, D, ~c

[Command]
name = "rdpx"
command = ~B, D, DB, x
[Command]
name = "rdpx"
command = ~B, D, DB, ~x
[Command]
name = "rdpy"
command = ~B, D, DB, y
[Command]
name = "rdpy"
command = ~B, D, DB, ~y
[Command]
name = "rdpz"
command = ~B, D, DB, z
[Command]
name = "rdpz"
command = ~B, D, DB, ~z

[Command]
name = "f2p"
command = $F, x+y
;time = 1
[Command]
name = "f2p"
command = $F, x+z
;time = 1
[Command]
name = "f2p"
command = $F, y+z
;time = 1

[Command]
name = "f2k"
command = $F, a+b
;time = 1
[Command]
name = "f2k"
command = $F, a+c
;time = 1
[Command]
name = "f2k"
command = $F, b+c
;time = 1

[Command]
name = "BBz"
command = B, B, z
time = 10


;-| Dir + Button |-----------------------------------------------------------
[Command]
name = "Fc"
command = F, c
time = 1

;-| Double Tap button |-----------------------------------------------------------
[Command]
name = "FFc"
command = F, F, c
time = 15

;-| 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

[Command]
name = "superjump"     ;Required (do not remove)
command = $D, U
time = 10

[Command]
name = "superjumpforward"     ;Required (do not remove)
command = $D, UF
time = 10

[Command]
name = "superjumpbackward"     ;Required (do not remove)
command = $D, UB
time = 10

[Command]
name = "tripleS"
command = s,s,s
time = 20

;-| 2/3 Button Combination |-----------------------------------------------
[Command]
name = "recovery";Required (do not remove)
command = x
time = 1
[Command]
name = "recovery";Required (do not remove)
command = y
time = 1
[Command]
name = "recovery";Required (do not remove)
command = z
time = 1
[Command]
name = "recovery";Required (do not remove)
command = a
time = 1
[Command]
name = "recovery";Required (do not remove)
command = b
time = 1
[Command]
name = "recovery";Required (do not remove)
command = c
time = 1

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

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

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

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

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

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

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

;-| Dir + Button |---------------------------------------------------------

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

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

[Command]
name = "down_y"
command = /$D,y
time = 1

;-| Single 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

[Command]
name = "mp_sp"
command = y+z
time = 10

[Command]
name = "mk_sk"
command = b+c
time = 10

[Command]
name = "lp_lk"
command = x+a
time = 10

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

;-| 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 = "holddown";Required (do not remove)
command = /$D
time = 1

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

;===================< DIR >===================

[Command]
name = "fwd"
command = F
time = 1
[Command]
name = "back"
command = B
time = 1
[Command]
name = "up"
command = U
time = 1
[Command]
name = "down"
command = D
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





[Statedef -1]

;===========================================================================
; HYPERS
;===========================================================================

[State -1, Mega Candy Beam - EMO Ender]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = !NumHelper(9996) ;MCB Limiter
triggerall = !NumHelper(1605) ;enemy is not candied
triggerall = var(32)>0 ;EMO mode
triggerall = command = "EMO"
triggerall = statetype != A  && !WinKo
;triggerall = power >= 2000 && stateno != 2900
trigger1 = Ctrl
trigger2 = stateno = 100 || stateno = 101
trigger3 = stateno = 1300 && movecontact  ;Slash Chop
trigger4 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movecontact
trigger5 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movecontact
trigger6 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movecontact
trigger7 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movecontact
value = 2900

;EMO Startup
[State -1, Kill You! EMO Startup]
type = ChangeState
triggerall = AILevel<=0
triggerall = !NumHelper(9996) ;MCB Limiter
;triggerall = roundstate = 2
triggerall = TeamMode != Simul
triggerall = enemyNear,TeamMode != Simul
triggerall = (enemy,Name != "Saibamen Z2")
triggerall = (var(32)=0 && power >= 3000) || (var(32)>0 && power >= 2000 && !NumHelper(9996))
;triggerall = var(32)=0 ;No EMO mode
triggerall = (command = "2qcba") || (command = "2qcbb") || (command = "2qcbc")
triggerall = statetype != A  && !WinKo
;triggerall = power >= 3000
triggerall = stateno != 4000
trigger1 = Ctrl
trigger2 = stateno = 100 || stateno = 101
trigger3 = stateno = 1300 && movecontact  ;Slash Chop
trigger4 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movecontact
trigger5 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movecontact
trigger6 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movecontact
trigger7 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movecontact
value = 4000


;===========================================================================
; SUPERS LV.2
;===========================================================================


; EMO Mode
[State -1, EMO Mode]
type = ChangeState
triggerall = TeamMode != Simul
triggerall = enemyNear,TeamMode != Simul
triggerall = (enemy,Name != "Saibamen Z2")
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = !NumHelper(9996) ;MCB Limiter
triggerall = var(32)=0 ;No EMO mode
triggerall = command = "EMO"
triggerall = statetype != A  && !WinKo
triggerall = power >= 2000 && stateno != 2700
trigger1 = Ctrl
trigger2 = stateno=900
value = 2700

;Air Vice Shot
[State -1, Air Vice Shot Lv.2]
type = ChangeState
triggerall = AILevel<=0
triggerall = !NumHelper(9996) ;MCB Limiter
;triggerall = roundstate = 2
triggerall = stateno != 2460
triggerall = (var(32)=0 && power >= 2000) || (var(32)>0 && power >= 1000 && !NumHelper(9996))
triggerall = (command = "qcbf2p")
triggerall = statetype = A  && !WinKo
triggerall = !NumHelper(2150) ;No Vice Shot										   
triggerall = !NumHelper(2450) ;No Vice Shot
trigger1 = Ctrl
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 620)
trigger2 = MoveContact
trigger3 = (StateNo = 630) || (StateNo = 640) || (StateNo = 650)
trigger3 = MoveContact
value = 2460


;Ground Vice Shot
[State -1, Ground Vice Shot Lv.2]
type = ChangeState
triggerall = AILevel<=0
triggerall = !NumHelper(9996) ;MCB Limiter
;triggerall = roundstate = 2
triggerall = stateno != 2400
triggerall = (var(32)=0 && power >= 2000) || (var(32)>0 && power >= 1000 && !NumHelper(9996))
triggerall = (command = "qcbf2p")
triggerall = statetype != A  && !WinKo
triggerall = !NumHelper(2150) ;No Vice Shot
triggerall = !NumHelper(2450) ;No Vice Shot
trigger1 = Ctrl
trigger2 = stateno = 100 || stateno = 101
trigger3 = stateno = 1300 && movecontact  ;Slash Chop
trigger4 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movecontact
trigger5 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movecontact
trigger6 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movecontact
trigger7 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movecontact
value = 2400

;Flesh Prison Lv2
[State -1, Flesh Prison Lv2]
type = ChangeState
triggerall = AILevel<=0
triggerall = !NumHelper(9996) ;MCB Limiter
;triggerall = roundstate = 2
;triggerall = var(32)=0 ;No rage mode
triggerall = (command = "2qcf2k")
triggerall = statetype = A  && !WinKo
triggerall = stateno != 2800
triggerall = (var(32)=0 && power >= 2000) || (var(32)>0 && power >= 1000 && !NumHelper(9996))
trigger1 = Ctrl
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 620)
trigger2 = MoveContact
trigger3 = (StateNo = 630) || (StateNo = 640) || (StateNo = 650)
trigger3 = MoveContact
value = 2800


;===========================================================================
; SUPERS LV.1
;===========================================================================
;Madman's Ball Lv1
[State -1, Madman's Ball Lv1]
type = ChangeState
triggerall = AILevel<=0
triggerall = !NumHelper(9996) ;MCB Limiter
;triggerall = roundstate = 2
;triggerall = var(32)=0 ;No rage mode
triggerall = !NumHelper(9999)   ;Limit timer
triggerall = (command = "2qcbx") || (command = "2qcby") || (command = "2qcbz")
triggerall = statetype = A  && !WinKo
triggerall = stateno != 2600
triggerall = (power >= 1000 || (var(32)>0 && !NumHelper(9996)))
trigger1 = Ctrl
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 620)
trigger2 = MoveContact
trigger3 = (StateNo = 630) || (StateNo = 640) || (StateNo = 650)
trigger3 = MoveContact
value = 2600

;Heavy Rain Lv1
[State -1, Heavy Rain Lv1]
type = ChangeState
triggerall = AILevel<=0
triggerall = !NumHelper(9996) ;MCB Limiter
;triggerall = roundstate = 2
triggerall = (command = "2qcbx") || (command = "2qcby") || (command = "2qcbz")
;triggerall = var(15):=(command = "2qcbx") + 2*(command = "2qcby") + 3*(command = "2qcbz")
triggerall = statetype != A  && !WinKo
triggerall = stateno != 2000
triggerall = (power >= 1000 || (var(32)>0 && !NumHelper(9996)))
trigger1 = Ctrl
trigger2 = stateno = 100 || stateno = 101
trigger3 = stateno = 1300 && movecontact  ;Slash Chop
trigger4 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movecontact
trigger5 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movecontact
trigger6 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movecontact
trigger7 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movecontact
value = 2000

;Ground Vice Shot
[State -1, Vice Shot Lv.1]
type = ChangeState
triggerall = AILevel<=0
triggerall = !NumHelper(9996) ;MCB Limiter
;triggerall = roundstate = 2
triggerall = stateno != 2100
triggerall = (power >= 1000 || (var(32)>0 && !NumHelper(9996)))
triggerall = stateno != [2100,2120]
triggerall = (command = "qcbfx") || (command = "qcbfy") || (command = "qcbfz")
triggerall = statetype != A  && !WinKo
triggerall = !NumHelper(2150) ;No Vice Shot
triggerall = !NumHelper(2450) ;No Vice Shot
trigger1 = Ctrl
trigger2 = stateno = 100 || stateno = 101
trigger3 = stateno = 1300 && movecontact  ;Slash Chop
trigger4 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movecontact
trigger5 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movecontact
trigger6 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movecontact
trigger7 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movecontact
value = 2100

;Air Vice Shot
[State -1, Air Vice Shot Lv.1]
type = ChangeState
triggerall = AILevel<=0
triggerall = !NumHelper(9996) ;MCB Limiter
;triggerall = roundstate = 2
triggerall = stateno != 2200
triggerall = (power >= 1000 || (var(32)>0 && !NumHelper(9996)))
;triggerall = (var(32)=0 && power >= 1000) || (var(32)>0 && var(33) >= 700) ;TEST
triggerall = stateno != [2200,2201]
triggerall = (command = "qcbfx") || (command = "qcbfy") || (command = "qcbfz")
triggerall = statetype = A  && !WinKo
triggerall = !NumHelper(2150) ;No Vice Shot
triggerall = !NumHelper(2450) ;No Vice Shot										   
trigger1 = Ctrl
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 620)
trigger2 = MoveContact
trigger3 = (StateNo = 630) || (StateNo = 640) || (StateNo = 650)
trigger3 = MoveContact
value = 2200

;Gackt!
[State -1, Gackt!]
type = ChangeState
triggerall = AILevel<=0
triggerall = !NumHelper(9996) ;MCB Limiter
;triggerall = roundstate = 2
triggerall = (command = "2qcfx") || (command = "2qcfy") || (command = "2qcfz")
triggerall = statetype != A  && !WinKo
triggerall = stateno != 2300
triggerall = (power >= 1000 || (var(32)>0 && !NumHelper(9996)))
trigger1 = Ctrl
trigger2 = stateno = 100 || stateno = 101
trigger3 = stateno = 1300 && movecontact  ;Slash Chop
trigger4 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movecontact
trigger5 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movecontact
trigger6 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movecontact
trigger7 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movecontact
value = 2300

;Pain Train Lv1
[State -1, Pain Train Lv1]
type = ChangeState
triggerall = AILevel<=0
triggerall = !NumHelper(9996) ;MCB Limiter
;triggerall = roundstate = 2
;triggerall = var(32)=0 ;No rage mode
triggerall = (command = "2qcfa") || (command = "2qcfb") || (command = "2qcfc")
triggerall = statetype != A  && !WinKo
triggerall = stateno != 2500
triggerall = (power >= 1000 || (var(32)>0 && !NumHelper(9996)))
trigger1 = Ctrl
trigger2 = stateno = 100 || stateno = 101
trigger3 = stateno = 1300 && movecontact  ;Slash Chop
trigger4 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 220)) && movecontact
trigger5 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movecontact
trigger6 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movecontact
trigger7 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movecontact
value = 2500


;===========================================================================
; AIR SPECIALS
;===========================================================================

;EX Air Maniac Ball
[State -1, EX Air Maniac Ball]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = power >= 500 && !NumHelper(9996) ; || (var(32)>0 && !NumHelper(9996))
triggerall = command = "qcb2p"
triggerall = statetype=A && !WinKo
triggerall = pos Y < -60
triggerall = !NumHelper(9997)   ;Limit timer
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = 630) || (StateNo = 610) || (StateNo = 620) || (StateNo = 640)
trigger2 = movecontact
value = 1470

;Air Maniac Ball
[State -1, Air Maniac Ball]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "qcbx" || command = "qcby" || command = "qcbz"
triggerall = statetype=A && !WinKo
triggerall = pos Y < -60
triggerall = !NumHelper(9997)   ;Limit timer
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = 630) || (StateNo = 610) || (StateNo = 620) || (StateNo = 640)
trigger2 = movecontact
value = 1420


;===========================================================================
; GROUND SPECIALS
;===========================================================================

;EX Maniac Ball
[State -1, EX Maniac Ball]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = power >= 500 && !NumHelper(9996) ; || (var(32)>0 && !NumHelper(9996))
triggerall = command = "qcb2p"
triggerall = statetype!=A && !WinKo
trigger1 = ctrl
trigger2 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movecontact
trigger3 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movecontact
trigger4 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movecontact
trigger5 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movecontact
trigger6 = stateno = 100 || stateno = 101
value = 1450

;EX Burp Fireball
[State -1, EX Burp Fireball]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = power >= 500 && !NumHelper(9996) ;|| (var(32)>0 && !NumHelper(9996))
triggerall = !NumHelper(1005)
triggerall = command = "qcf2p"
triggerall = statetype != A  && !WinKo
triggerall = (stateno!=[1000,1050])
trigger1 = ctrl
trigger2 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movecontact
trigger3 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 255)) && movecontact
trigger4 = (stateno = 250) && movecontact>=6
trigger5 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movecontact
trigger6 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movecontact
trigger7 = stateno = 100 || stateno = 101
value = 1050

;Candy Beam
[State -1, Candy Beam]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
;triggerall = var(32)=0 ;No rage mode
triggerall = power >= 500 && !NumHelper(9996) ;|| (var(32)>0 && !NumHelper(9996))
triggerall = (command = "btodex")
triggerall = statetype!=A && !WinKo
triggerall = !NumHelper(1605)
trigger1 = ctrl
trigger2 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movecontact
trigger3 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movecontact
trigger4 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movecontact
trigger5 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movecontact
trigger6 = stateno = 100 || stateno = 101
value = 1600

;EX Chaos Burst
[State -1, EX Chaos Burst]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
;triggerall = power >= 500 || var(32)>0 ;As EX
triggerall = (power >= 1000 && !NumHelper(9996)) ;|| (var(32)>0 && !NumHelper(9996))) ;As Lv1
triggerall = command = "chaosburst"
triggerall = stateno!=1750
triggerall = statetype != A  && StateType != L && !WinKo
trigger1 = movetype=H && stateno!=[120,155]
value = 1750

;Pop Kick
[State -1, Pop Kick]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = (command = "qcba") || (command = "qcbb") || (command = "qcbc")
;triggerall = var(15):=(command = "qcba") + 2*(command = "qcbb") + 3*(command = "qcbc")
triggerall = statetype != A  && !WinKo
triggerall = !NumHelper(9998)   ;Limit timer
trigger1 = ctrl
trigger2 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movecontact
trigger3 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movecontact
trigger4 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movecontact
trigger5 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movecontact
trigger6 = stateno = 100 || stateno = 101
value = 1200

;Head Throw
[State -1, Head Throw]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = (command = "rdpx") || (command = "rdpy") || (command = "rdpz")
;triggerall = var(15):=(command = "rdpx") + 2*(command = "rdpy") + 3*(command = "rdpz")
triggerall = statetype = S  && !WinKo
triggerall = !NumHelper(1150)   ;No head puddle
trigger1 = ctrl
trigger2 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movecontact
trigger3 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movecontact
trigger4 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movecontact
trigger5 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movecontact
trigger6 = stateno = 100 || stateno = 101
value = 1100

;Head Recall
[State -1, Head Recall]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = (command = "rdpx") || (command = "rdpy") || (command = "rdpz")
triggerall = statetype = S  && !WinKo
triggerall = stateno != 1100
triggerall = NumHelper(1150)   ;Head puddle onscreen
trigger1 = ctrl
trigger2 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movecontact
trigger3 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movecontact
trigger4 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movecontact
trigger5 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movecontact
trigger6 = stateno = 100 || stateno = 101
value = 1110

;Burp Fireball
[State -1, Burp Fireball]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = !NumHelper(1005)
triggerall = (command = "qcfx") || (command = "qcfy") || (command = "qcfz")
;triggerall = (command = "qcfx" && NumExplod(20)=0) || (command = "qcbx" && NumExplod(20)=1)
;triggerall = var(15):=(command = "qcfx") + 2*(command = "qcfy") + 3*(command = "qcfz")
triggerall = statetype != A  && !WinKo
triggerall = (stateno!=[1000,1050])
trigger1 = ctrl
trigger2 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movecontact
trigger3 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 255)) && movecontact
trigger4 = (stateno = 250) && movecontact>=6
trigger5 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movecontact
trigger6 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movecontact
trigger7 = stateno = 100 || stateno = 101
value = 1000

;Meltdown
[State -1, Meltdown]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
;triggerall = var(32)=0 ;No rage mode
triggerall = command = "puddle"
triggerall = statetype!=A && !WinKo
trigger1 = ctrl
trigger2 = ((stateno = 200) || (stateno = 205) || (stateno = 210 || (stateno = 211)) || (stateno = 220)) && movecontact
trigger3 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movecontact
trigger4 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movecontact
trigger5 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movecontact
trigger6 = stateno = 100 || stateno = 101
value = 300


;Maniac Ball
[State -1, Maniac Ball]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "qcbx" || command = "qcby" || command = "qcbz"
triggerall = statetype!=A && !WinKo
trigger1 = ctrl
trigger2 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movecontact
trigger3 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movecontact
trigger4 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movecontact
trigger5 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movecontact
trigger6 = stateno = 100 || stateno = 101
value = 1400

; Slashing Chop (aka Focus Attack)
[State -1, Slashing Chop]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = stateno !=[1300,1302]
triggerall = stateno != 106
;triggerall = command = "hold_z" && command = "hold_c"
triggerall = command = "z" && command = "c"
trigger1 = statetype = S
trigger1 = ctrl
value = 1300

;Zetto Counter
[State -1, Zetto counter]
type = ChangeState
;triggerall = var(32)=0 ;No rage mode
;trigger1 = AILevel<=0
trigger1 = stateno=150 || stateno=152
trigger1 = command="f2k" || command="f2p"
trigger1 = roundstate=2 && power>=1000 && statetype!=A
value = 750

;Air Zetto Counter
[State -1, Air Zetto counter]
type = ChangeState
;triggerall = var(32)=0 ;No rage mode
;trigger1 = AILevel<=0
trigger1 = stateno=154  ; && animelemtime(1)<6
trigger1 = command="f2k" || command="f2p"
trigger1 = roundstate=2 && power>=1000 && statetype=A
value = 760


;===========================================================================
; COMMAND & SYSTEM MOVES
;===========================================================================

; Dash attack
[State -1, Dash attack]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = statetype!=A
trigger1 = stateno = 100 || stateno = 101
trigger1 = command="z" && command!="holddown"
value = 225

;Power Charge
[State -1]
type = ChangeState
triggerall = AILevel<=0
triggerall = var(32)=0 ;No rage mode
;triggerall = roundstate = 2
triggerall = StateType != A
triggerall = Power < 3000
triggerall = stateno != 900
triggerall = Ctrl
triggerall = !NumHelper(1605) ;No Candy mode							 
;trigger1 = command = "b" && command = "y"
trigger1 = command = "hold_b" && command = "hold_y"
value = 900

;EMO Power Charge
[State -1]
type = ChangeState
triggerall = AILevel<=0
triggerall = !NumHelper(9996) ;MCB Limiter
triggerall = var(32)>0 ;SANITY mode
triggerall = var(33)<69 ;2100
;triggerall = roundstate = 2
triggerall = StateType != A
;triggerall = Power < 3000
triggerall = stateno != 910
triggerall = Ctrl
triggerall = !NumHelper(1605) ;No Candy mode							 
;trigger1 = command = "b" && command = "y"
trigger1 = command = "hold_b" && command = "hold_y"
trigger1 = command != "holddown"
value = 910

; BACK Throw/Reverse Throw
[State -1, BACK Throw]
type = ChangeState
triggerall = AILevel<=0
triggerall = roundstate=2 && ctrl && statetype=S && stateno!=100
trigger1 = command="xa" && command="holdback"
value = 810

; FWD Throw
[State -1, FWD Throw]
type = ChangeState
triggerall = AILevel<=0
triggerall = roundstate=2 && ctrl && statetype=S && stateno!=100
trigger1 = command="xa" && command="holdfwd"
trigger2 = command="xa" && command!="holdfwd" && command!="holdback"
value = 800

; Candy Grab
[State -1, Candy Throw]
type = ChangeState
triggerall = AILevel<=0
trigger1 = statetype != A
trigger1 = command="xa" && command="holddown"
trigger1 = roundstate=2 && ctrl && stateno!=100
value = 1620

;===========================================================================
; NORMALS
;===========================================================================

; Stand Light Punch
[State -1, Stand Light Punch]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "x"
triggerall = command != "holddown"
trigger1 = statetype != A
trigger1 = ctrl
trigger2 = stateno = 100 || stateno = 101
value = 200

; Stand Light Punch Combo
[State -1, Stand Light Punch Combo]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "x"
triggerall = command != "holddown"
trigger1 = stateno = 200
trigger1 = movecontact
value = 205

; Stand Medium Punch
[State -1, Stand Medium Punch]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "y" && command != "holdfwd"
triggerall = command != "holddown"
trigger1 = statetype != A
trigger1 = ctrl
trigger2 = StateType != A && movecontact
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 230) || (stateno = 240)
trigger3 = stateno = 100 || stateno = 101
trigger4 = StateType != A && movecontact
trigger4 = (stateno = 400) || (stateno = 430)
value = 210

; Stand Medium EXT Punch
[State -1, Stand Medium EXT Punch]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = NumHelper(9995)<2 ;Limit once Extended per combo
triggerall = command = "y" && command = "holdfwd"
triggerall = command != "holddown"
trigger1 = statetype != A
trigger1 = ctrl
trigger2 = StateType != A && movecontact
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 230) || (stateno = 240)
trigger3 = stateno = 100 || stateno = 101
trigger4 = StateType != A && movecontact
trigger4 = (stateno = 400) || (stateno = 430)
value = 211

; Stand Strong Punch
[State -1, Stand Strong Punch]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "z"
triggerall = command != "holddown"
trigger1 = statetype != A
trigger1 = ctrl
trigger2 = StateType != A && movecontact
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230) || (stateno = 240) || (stateno = 245)
trigger3 = stateno = 100 || stateno = 101
trigger4 = StateType != A && movecontact
trigger4 = (stateno = 400) || (stateno = 430) || (stateno = 410) || (stateno = 440)
value = 220

; Stand Light Kick
[State -1, Stand Light Kick]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "a"
triggerall = command != "holddown"
trigger1 = statetype != A
trigger1 = ctrl
trigger2 = stateno = 100 || stateno = 101
value = 230

; Standing Medium Kick
[State -1, Standing Medium Kick]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = NumHelper(9995)<2 ;Limit once Extended per combo
triggerall = command = "b" && command = "holdfwd"
triggerall = command != "holddown"
trigger1 = statetype != A
trigger1 = ctrl
trigger2 = StateType != A
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230)
trigger2 = movecontact
trigger3 = stateno = 100 || stateno = 101
trigger4 = StateType != A && movecontact
trigger4 = (stateno = 400) || (stateno = 430)
value = 240

; Standing Close Medium Kick
[State -1, Standing Close Medium Kick]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "b" && command != "holdfwd"
triggerall = command != "holddown"
trigger1 = statetype != A
trigger1 = ctrl
trigger2 = StateType != A
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230)
trigger2 = movecontact
trigger3 = stateno = 100 || stateno = 101
trigger4 = StateType != A && movecontact
trigger4 = (stateno = 400) || (stateno = 430)
value = 245

; Standing Strong Kick
[State -1, Standing Strong Kick]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "c" && command != "holdfwd"
triggerall = command != "holddown"
trigger1 = statetype != A
trigger1 = ctrl
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230) || (stateno = 240) || (stateno = 245)
trigger2 = movecontact
trigger3 = stateno = 100 || stateno = 101
trigger4 = StateType != A && movecontact
trigger4 = (stateno = 400) || (stateno = 430) || (stateno = 410) || (stateno = 440)
value = 250

; Standing Forward Strong Kick
[State -1, Standing Close Strong Kick]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "c" && command = "holdfwd"
triggerall = command != "holddown"
trigger1 = statetype != A
trigger1 = ctrl
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230) || (stateno = 240) || (stateno = 245)
trigger2 = movecontact
trigger3 = stateno = 100 || stateno = 101
trigger4 = StateType != A && movecontact
trigger4 = (stateno = 400) || (stateno = 430) || (stateno = 410) || (stateno = 440)
value = 255

; Crouching Light Punch
[State -1, Crouching Light Punch]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "x"
triggerall = command = "holddown"
trigger1 = statetype != A
trigger1 = ctrl
trigger2 = StateType != A & MoveContact
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 230)
trigger3 = stateno = 100 || stateno = 101
value = 400

; Crouching Medium Punch
[State -1, Crouching Medium Punch]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "y"
triggerall = command = "holddown"
trigger1 = statetype != A
trigger1 = ctrl
trigger2 = StateType != A & MoveContact
trigger2 = (StateNo = 400) || (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230) || (stateno = 245) || (stateno = 430)
trigger3 = stateno = 100 || stateno = 101
value = 410

; Crouching Strong Punch = Close Uppercut
[State -1, Crouching Strong Punch]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "z" && command = "holddown"
triggerall = statetype !=A
trigger1 = ctrl
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230) || (stateno = 240) || (stateno = 245)
trigger2 = movecontact
trigger3 = (stateno = 400) || (stateno = 430) || (stateno = 410) || (stateno = 440)
trigger3 = movecontact
trigger4 = stateno = 100 || stateno = 101
value = 420

; Crouching Light Kick
[State -1, Crouching Light Kick]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "a"
triggerall = command = "holddown"
trigger1 = statetype != A
trigger1 = ctrl
trigger2 = StateType != A & MoveContact
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 230)
trigger3 = stateno = 100 || stateno = 101
value = 430

; Crouching Medium Kick
[State -1, Crouching Medium Kick]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "b"
triggerall = command = "holddown"
trigger1 = statetype != A
trigger1 = ctrl
trigger2 = StateType != A && MoveContact
trigger2 = (StateNo = 400) || (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230) || (stateno = 430)
trigger3 = stateno = 100 || stateno = 101
value = 440

; Crouching Strong Kick
[State -1, Crouching Strong Kick]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "c"
triggerall = command = "holddown"
trigger1 = statetype != A
trigger1 = ctrl
trigger2 = StateType != A & MoveContact
trigger2 = (StateNo = 400) || (stateno = 410) || (stateno = 430) || (stateno = 440)
trigger3 = stateno = 100 || stateno = 101
trigger4 = StateType != A & MoveContact
trigger4 = (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230) || (stateno = 240) || (stateno = 245)
value = 450

;Jump Light Punch
[State -1, Jump Light Punch]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = NumExplod(90000200)||command = "x"
triggerall = stateno != 600
triggerall = statetype = A
trigger1 = ctrl
value = 600

;Jump Medium Punch
[State -1, Jump Medium Punch]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = NumExplod(90000210)||command = "y"
triggerall = statetype = A
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = 630)
trigger2 = MoveContact
value = 610

;Jump Strong Punch (two fists)
[State -1, Jump Strong Punch]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = (NumExplod(90000220)&& command != "holddown")||(command = "z" && command != "holddown")
triggerall = statetype = A
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 630) || (StateNo = 640)
trigger2 = MoveContact
value = 620

;Jump Strong Punch (Sleepy punch)
[State -1, Sleepy Punch]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = (NumExplod(90000220)&& command = "holddown")||(command = "z" && command = "holddown")
triggerall = statetype = A
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 630) || (StateNo = 640)
trigger2 = MoveContact
value = 620+35*(vel y>0) ;655   ;Only during downwards

;Jump Light Kick
[State -1, Jump Light Kick]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = NumExplod(90000230)||command = "a"
triggerall = statetype = A
trigger1 = ctrl
value = 630

;Jump Medium Kick
[State -1, Jump Medium Kick]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = NumExplod(90000240)||command = "b"
triggerall = statetype = A
triggerall = (stateno!=640)
trigger1 = ctrl
trigger2 = (StateNo = 600) || (StateNo = 630)
trigger2 = movecontact
value = 640

;Jump Strong Kick
[State -1, Jump Strong Kick]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = NumExplod(90000250)||command = "c"
triggerall = statetype = A
trigger1 = ctrl
trigger1 = stateno != 650  ;&& stateno != 660
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 630) || (StateNo = 640)
trigger2 = MoveContact
value = 650



;===========================================================================
; SYSTEM
;===========================================================================

; Taunt
[State -1, Taunt]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "s" && command != "holddown" && stateno!=195
trigger1 = statetype = S
trigger1 = ctrl
value = 195

; Crouching Taunt
[State -1, Crouching Taunt]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "s" && command = "holddown" && stateno!=495
trigger1 = statetype = C
trigger1 = ctrl
value = 495

; Air Taunt
[State -1, Air Taunt]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = var(4)=0 ;limiter
triggerall = command = "s" && stateno!=695
trigger1 = statetype = A
trigger1 = ctrl
value = 695

;Air Dash Forward
[State -1, Air Dash Fwd]
type = ChangeState
value = 110
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = var(10) = 0 ;limiter
trigger1 = pos Y < -20
triggerall = stateno != 105
trigger1 = (command = "FF") && (statetype = A) && (ctrl)

;Air Dash Back
[State -1, Air Dash Back]
type = ChangeState
value = 115
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = var(10) = 0 ;limiter
triggerall = vel x <= 0
trigger1 = pos Y < -20
triggerall = stateno != 105
trigger1 = (command = "BB") && (statetype = A) && (ctrl)

; Run Fwd
[State -1, Run Fwd]
type = ChangeState
triggerall = AILevel<=0
;triggerall = roundstate = 2
trigger1 = command = "FF"
trigger1 = statetype = S && ctrl
trigger1 = roundstate=2 && (stateno!=[100,106])
value = 100

; Run Back
[State -1, Run Back]
type = ChangeState
value = 105
triggerall = AILevel<=0
;triggerall = roundstate = 2
trigger1 = command = "BB"
trigger1 = statetype = S
trigger1 = ctrl

;chickenblock
[State -1, ChangeState]
type = ChangeState
triggerall = AILevel<=0
triggerall = InGuardDist
triggerall = StateType = A
trigger1 = command = "holdback" && command = "holdup"
trigger1 = ctrl
trigger2 = StateNo = 5210 && Time = 14
trigger2 = (command = "holdback" && command = "holdup") || (command = "holdback" && command = "holddown") || (command = "holdback" )
value = 120

; Super Jump
;This state executes only after performing the air launcher
[State -1, Jump Launcher]
type = ChangeState
value = 10230
triggerall = AILevel<=0
;triggerall = roundstate = 2
triggerall = command = "holdup"
trigger1 = (stateno = 420 || stateno = 421)  && animelemtime(5)>0 && MoveHit
trigger1 = statetype = S ;add

[State -1, Super Jump Straight Up]
type = ChangeState
value = 10231
triggerall = AILevel<=0
;triggerall = roundstate = 2
trigger1 = statetype = S
trigger1 = ctrl
trigger1 = command = "superjump"

[State -1, Super Jump Forward]
type = ChangeState
value = 10232
triggerall = AILevel<=0
;triggerall = roundstate = 2
trigger1 = statetype = S
trigger1 = ctrl
trigger1 = command = "superjumpforward"

[State -1, Super Jump Backward]
type = ChangeState
value = 10233
triggerall = AILevel<=0
;triggerall = roundstate = 2
trigger1 = statetype = S
trigger1 = ctrl
trigger1 = command = "superjumpbackward"

;____________________________________________________________________________
; AI
[State -1, AI Guard]
type= changestate
triggerall= AILevel>0 && numenemy
triggerall= var(32)=0  ;No EMO
triggerall= roundstate=2 && inguarddist
triggerall= statetype!=A || p2statetype=A
triggerall= ctrl && (stateno!=[120,155])&& !(enemynear,ctrl)
trigger1= !(enemynear,hitdefattr=SCA,AT) && (enemynear,time<120)
trigger2= random < 64*(AIlevel ** 2 / 64.0) && (enemynear,hitdefattr=SCA,NA)
trigger3= random < 128*(AIlevel ** 2 / 64.0) && (enemynear,hitdefattr=SCA,SA)
trigger4= random < 192*(AIlevel ** 2 / 64.0) && (enemynear,hitdefattr=SCA,HA)
value=120
; AI
[State -1, AI EMO Guard]
type= changestate
triggerall= AILevel>0 && numenemy
triggerall= var(32)>0 && var(33)>0  ;EMO
triggerall= roundstate=2 && inguarddist
triggerall= statetype!=A || p2statetype=A
triggerall= ctrl && (stateno!=[120,155])&& !(enemynear,ctrl)
trigger1= !(enemynear,hitdefattr=SCA,AT) && (enemynear,time<120)
trigger2= random < 32*(AIlevel ** 2 / 64.0) && (enemynear,hitdefattr=SCA,NA)
trigger3= random < 64*(AIlevel ** 2 / 64.0) && (enemynear,hitdefattr=SCA,SA)
trigger4= random < 86*(AIlevel ** 2 / 64.0) && (enemynear,hitdefattr=SCA,HA)
value=120

; AI Air Taunt
[State -1, AI Air Taunt]
type = ChangeState
triggerall = AILevel>0 && numenemy && roundstate=2 && StateType = A
triggerall =(p2bodydist x>=100) && (p2bodydist y>=40)&& P2statetype != A && P2statetype != L
triggerall = P2movetype=A
triggerall = var(4)=0 ;limiter
triggerall = stateno!=695
trigger1 = ctrl && random < 150*(AIlevel ** 2 / 64.0)
value = 695

;AI Dash Backward
[State -1, AI Dash Backward]
type=changestate
triggerall= AILevel>0 && numenemy
triggerall= roundstate=2 && statetype=S
triggerall= ctrl && (stateno!=105)
trigger1= (enemynear,movetype=A) && backedgedist>=80 && (p2bodydist x=[80,120]) && (enemynear,vel x)
trigger1= random<ifelse((enemynear,hitdefattr=SC,AT),100,50)
trigger2= (p2bodydist x=[0,80]) && backedgebodydist>=80
trigger2= enemynear,stateno=5120 && enemynear,animtime=-3 && random<300*((AIlevel**2)/64.0)
value=105

;AI Meltdown
[State -1, AI Meltdown]
type = ChangeState
triggerall= AILevel>0 && numenemy && roundstate = 2 && statetype != A
trigger1 = ctrl && random < 250*(AIlevel ** 2 / 64.0)
trigger1 = p2bodydist x>=120 && (P2movetype=A || enemynear,movetype=A)
trigger2 = ((stateno = 200) || (stateno = 205) || (stateno = 210 || (stateno = 211)) || (stateno = 220))
trigger2 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255))
trigger2 = ((stateno = 400) || (stateno = 410) || (stateno = 420))
trigger2 = ((stateno = 430) || (stateno = 440) || (stateno = 450))
trigger2 = Movehit && random < 50*(AIlevel ** 2 / 64.0)
trigger3 = stateno = 100 || stateno = 101
trigger3 = random < 50*(AIlevel ** 2 / 64.0)
value = 300


;AI Zetto Counter
[State -1, AI Zetto counter]
type=changestate
;triggerall = var(32)=0 ;No rage mode
trigger1= AILevel>0 && numenemy && roundstate=2 && statetype!=A && power>=1000
trigger1= stateno=150 || stateno=152
trigger1= random < 25*(AIlevel ** 2 / 64.0)
trigger1= (p2bodydist x=[0,50]) && (life<.5*lifemax)
value=750

;Air Zetto Counter
[State -1, AI Air Zetto counter]
type=changestate
;triggerall = var(32)=0 ;No rage mode
trigger1= AILevel>0 && numenemy && roundstate=2 && statetype=A && power>=1000
trigger1= stateno=154
trigger1= random < 25*(AIlevel ** 2 / 64.0)
trigger1= (p2bodydist x=[0,50]) && (life<.5*lifemax)
value=760

[State -1, AI Throw]
type = ChangeState
triggerall = AILevel>0
triggerall = roundstate=2 && statetype!=A && enemynear,statetype!=L && (enemynear,stateno!=[5120,5201])
triggerall = enemynear,movetype!=H && enemynear,statetype!=A && enemynear,Hitover && (p2bodydist x=[0,30])
triggerall = (!NumHelper(2010) || !NumHelper(2011)) ;don't attempt under Heavy Rain
triggerall = ctrl && stateno!=100
trigger1 = random < 200*(AIlevel ** 2 / 64.0)
trigger2 = enemynear,stateno=[120,155]
trigger2 = random < 500*(AIlevel ** 2 / 64.0)
value = Ifelse(random<=500,800,810)

; AI Candy Grab
[State -1, AI Candy Throw]
type = ChangeState
triggerall = NumHelper(1605) ;Candy mode
triggerall = Helper(1605),numtarget(1600) ;Candy mode
triggerall = AILevel>0
triggerall = roundstate=2 && statetype!=A
triggerall = p2bodydist x=[-20,40]
trigger1 = ctrl && stateno!=100
trigger1 = random < 400*(AIlevel ** 2 / 64.0)
value = 1620

; AI EMO Mode Activation
[State -1, AI EMO Mode Activation]
type = ChangeState
triggerall = TeamMode != Simul
triggerall = enemyNear,TeamMode != Simul
triggerall = (enemy,Name != "Saibamen Z2")
triggerall= AILevel>0 && numenemy && roundstate = 2 && (statetype != A) && power >= 2000 && stateno != 2700
triggerall = !NumHelper(9996) ;MCB Limiter
triggerall = var(32)=0 ;No EMO mode
triggerall= (enemynear,Movetype!=A) && (enemynear,Statetype=L) && (p2bodydist x>=120) && random < 900*(AIlevel ** 2 / 64.0)
trigger1 = Ctrl
trigger2 = stateno=900
value = 2700

;AI EMO Power Charge
[State -1, AI EMO Power Charge]
type = ChangeState
triggerall= AILevel>0 && numenemy && roundstate=2 && statetype!=A
triggerall= enemynear,Movetype!=A && !(enemynear,ctrl)
triggerall= !inguarddist && p2bodydist x>=100 && random<800*((AIlevel**2)/64.0)
triggerall = !NumHelper(9996) ;MCB Limiter
triggerall = !NumHelper(1605) ;No Candy mode
triggerall = var(32)>0 ;SANITY mode
triggerall = var(33)<69 ;2100
triggerall = stateno != [910,911]
triggerall= ctrl
trigger1=(enemynear,Movetype=H||enemynear,statetype=L)
trigger2=enemynear,vel x<=0
trigger3=enemynear,stateno=[120,155]
value = 910

;AI Power Charge
[State -1, AI Power Charge]
type=changestate
triggerall= AILevel>0 && numenemy && roundstate=2 && statetype!=A
triggerall = var(32)=0 ;No EMO mode
triggerall = !NumHelper(1605) ;No Candy mode
triggerall= power<const(data.power) && enemynear,Movetype!=A && !(enemynear,ctrl)
triggerall=  power < const(data.power) && power < powermax
triggerall= !inguarddist && random<900 && p2bodydist x>=120;*((powermax-power)/powermax) ;random < 300*(AIlevel ** 2 / 64.0)
triggerall = stateno != [900,901]
triggerall= ctrl
trigger1=(enemynear,Movetype=H||enemynear,statetype=L)
trigger2=enemynear,vel x<0
trigger3=enemynear,stateno=[120,155]
trigger4=enemynear,Movetype=I
value=900

__________________________________________________
; AI Stand Light Punch
[State -1, AI Stand Light Punch]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && StateType != A
triggerall =(p2bodydist x = [0, 50])&&P2statetype != C && P2statetype != L
trigger1 = ctrl && random < 550*(AIlevel ** 2 / 64.0)
trigger2 = (stateno = [100,101]) && random < 250*(AIlevel ** 2 / 64.0)
trigger3 = ctrl&&(enemynear,ctrl) && random < 600*(AIlevel ** 2 / 64.0)
value = 200


; AI Stand Light Punch Combo
[State -1, AI Stand Light Punch Combo]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && StateType != A  && P2statetype != C
triggerall = (p2bodydist x = [-5, 30]) && p2statetype != L
trigger1 = stateno = 200 && movehit
trigger1 = random < 400*(AIlevel ** 2 / 64.0)
value = 205

; AI Stand Medium Punch
[State -1, AI Stand Medium Punch]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && StateType != A  && P2statetype != C
triggerall = (p2bodydist x = [-15, 80]) && p2statetype != L
trigger1 = ctrl && random < 150*(AIlevel ** 2 / 64.0)
trigger2 = ((stateno = 200) || (stateno = 205) || (stateno = 230) || (stateno = 240))&& movehit
trigger2 = random < 600*(AIlevel ** 2 / 64.0)
trigger3 = (stateno = [100,101]) && random < 250*(AIlevel ** 2 / 64.0)
trigger4 = ((stateno = 400) || (stateno = 430)) && movehit
trigger4 = random < 400*(AIlevel ** 2 / 64.0)
value = 210

; AI Stand Medium EXT Punch
[State -1, AI Stand Medium EXT Punch]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && StateType != A  && P2statetype != C
triggerall = (p2bodydist x = [80, 130]) && p2statetype != L
triggerall = NumHelper(9995)<2 ;Limit once Extended per combo
trigger1 = ctrl && random < 150*(AIlevel ** 2 / 64.0)
trigger2 = ((stateno = 200) || (stateno = 205) || (stateno = 230) || (stateno = 240))&& movehit
trigger2 = random < 600*(AIlevel ** 2 / 64.0)
trigger3 = (stateno = [100,101]) && random < 250*(AIlevel ** 2 / 64.0)
trigger4 = ((stateno = 400) || (stateno = 430)) && movehit
trigger4 = random < 400*(AIlevel ** 2 / 64.0)
value = 211

; AI Stand Strong Punch
[State -1, AI Stand Strong Punch]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && StateType != A  && P2statetype != C
triggerall = (p2bodydist x = [10, 75]) && p2statetype != L
trigger1 = ctrl && random < 150*(AIlevel ** 2 / 64.0)
trigger2 = StateType != A && movehit
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230) || (stateno = 240) || (stateno = 245)
trigger2 = random < 600*(AIlevel ** 2 / 64.0)
trigger3 = (stateno = 100 || stateno = 101) && random < 250*(AIlevel ** 2 / 64.0)
trigger4 = (stateno = 400) || (stateno = 430) || (stateno = 410) || (stateno = 440)
trigger4 = movehit && random < 400*(AIlevel ** 2 / 64.0)
value = 220

; AI Stand Light Kick
[State -1, AI Stand Light Kick]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && StateType != A  && P2statetype != A
triggerall = (p2bodydist x = [10, 55]) && p2statetype != L
trigger1 = ctrl && random < 150*(AIlevel ** 2 / 64.0)
trigger2 = (stateno = 100 || stateno = 101) && random < 250*(AIlevel ** 2 / 64.0)
value = 230

; AI Standing Medium Kick
[State -1, AI Standing Medium Kick]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && StateType != A  ;&& P2statetype != C
triggerall = (p2bodydist x = [80, 140]) && p2statetype != L
triggerall = NumHelper(9995)<2 ;Limit once Extended per combo
trigger1 = ctrl && random < 150*(AIlevel ** 2 / 64.0)
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230)
trigger2 = movehit && random < 600*(AIlevel ** 2 / 64.0)
trigger3 = stateno = 100 || stateno = 101
trigger3 = movehit && random < 250*(AIlevel ** 2 / 64.0)
trigger4 = (stateno = 400) || (stateno = 430)
trigger4 = movehit && random < 450*(AIlevel ** 2 / 64.0)
value = 240

; AI Standing Close Medium Kick
[State -1, AI Standing Close Medium Kick]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && StateType != A  ;&& P2statetype != C
triggerall = (p2bodydist x = [-10, 50]) && p2statetype != L
trigger1 = ctrl && random < 150*(AIlevel ** 2 / 64.0)
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230)
trigger2 = movehit && random < 600*(AIlevel ** 2 / 64.0)
trigger3 = stateno = 100 || stateno = 101
trigger3 = movehit && random < 250*(AIlevel ** 2 / 64.0)
trigger4 = (stateno = 400) || (stateno = 430)
trigger4 = movehit && random < 450*(AIlevel ** 2 / 64.0)
value = 245

; AI Standing Strong Kick
[State -1, AI Standing Strong Kick]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && StateType != A  && P2statetype != A
triggerall = (p2bodydist x = [90, 150]) && p2statetype != L
trigger1 = ctrl && random < 150*(AIlevel ** 2 / 64.0)
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230) || (stateno = 240) || (stateno = 245)
trigger2 = movehit && random < 600*(AIlevel ** 2 / 64.0)
trigger3 = stateno = 100 || stateno = 101
trigger3 = movehit && random < 250*(AIlevel ** 2 / 64.0)
trigger4 = (stateno = 400) || (stateno = 430) || (stateno = 410) || (stateno = 440)
trigger4 = movehit && random < 450*(AIlevel ** 2 / 64.0)
value = 250

; AI Standing Forward Strong Kick
[State -1, AI Standing Close Strong Kick]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && StateType != A && P2statetype != S
triggerall = (p2bodydist x = [-15,70]) && p2statetype != L
trigger1 = ctrl && random < 150*(AIlevel ** 2 / 64.0)
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230) || (stateno = 240) || (stateno = 245)
trigger2 = movecontact && random < 600*(AIlevel ** 2 / 64.0)
trigger3 = stateno = 100 || stateno = 101
trigger3 = movecontact && random < 250*(AIlevel ** 2 / 64.0)
trigger4 = (stateno = 400) || (stateno = 430) || (stateno = 410) || (stateno = 440)
trigger4 = movecontact && random < 450*(AIlevel ** 2 / 64.0)
value = 255

; AI Crouching Light Punch
[State -1, AI Crouching Light Punch]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && StateType = C
triggerall = (p2bodydist x = [-5, 40]) &&(p2bodydist y = [-40,0]) && P2statetype != A && P2statetype != L
trigger1 = ctrl && random < 250*(AIlevel ** 2 / 64.0)
trigger2 = movehit
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 230)
trigger2 = random < 200*(AIlevel ** 2 / 64.0)
value = 400

; AI Crouching Medium Punch
[State -1, AI Crouching Medium Punch]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && StateType = C
triggerall = (p2bodydist x = [-5, 40]) &&(p2bodydist y = [-40,0]) && P2statetype != A && P2statetype != L
trigger1 = ctrl && random < 250*(AIlevel ** 2 / 64.0)
trigger2 = movehit
trigger2 = (StateNo = 400) || (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230) || (stateno = 245) || (stateno = 430)
value = 410

; AI Crouching Strong Punch = Close Uppercut
[State -1, AI Crouching Strong Punch]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1);Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && StateType = C
triggerall = (p2bodydist x = [-5, 70]) &&(p2bodydist y = [-90,0]) && P2statetype != L
trigger1 = ctrl && random < 250*(AIlevel ** 2 / 64.0)
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230) || (stateno = 240) || (stateno = 245)
trigger2 = movehit && random < 200*(AIlevel ** 2 / 64.0)
trigger3 = (stateno = 400) || (stateno = 430) || (stateno = 410) || (stateno = 440)
trigger3 = movehit && random < 400*(AIlevel ** 2 / 64.0)
value = 420

; AI Crouching Light Kick
[State -1, AI Crouching Light Kick]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1);Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && StateType = C
triggerall = (p2bodydist x = [-5, 40]) && P2statetype != A && P2statetype != L
trigger1 = ctrl && random < 250*(AIlevel ** 2 / 64.0)
trigger2 = (stateno = 200) || (stateno = 205) || (stateno = 230)
trigger2 = movehit && random < 400*(AIlevel ** 2 / 64.0)
value = 430

; AI Crouching Medium Kick
[State -1, AI Crouching Medium Kick]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && StateType = C
triggerall = (p2bodydist x = [60, 120]) && P2statetype != A && P2statetype != L
trigger1 = ctrl && random < 250*(AIlevel ** 2 / 64.0)
trigger2 = (StateNo = 400) || (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230) || (stateno = 430)
trigger2 = movehit && random < 400*(AIlevel ** 2 / 64.0)
value = 440

; AI Crouching Strong Kick
[State -1, AI Crouching Strong Kick]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && StateType = C
triggerall = (p2bodydist x = [40, 80]) && P2statetype != A && P2statetype != L
trigger1 = ctrl && random < 250*(AIlevel ** 2 / 64.0)
trigger2 = (StateNo = 400) || (stateno = 410) || (stateno = 430) || (stateno = 440)
trigger2 = movehit && random < 400*(AIlevel ** 2 / 64.0)
trigger3 = (stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 230) || (stateno = 240) || (stateno = 245)
trigger2 = movehit && random < 200*(AIlevel ** 2 / 64.0)
value = 450

;AI Jump Light Punch
[State -1, AI Jump Light Punch]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && statetype = A
triggerall = (p2bodydist x = [2,40]) && (p2bodydist y = [-60,60]) && p2statetype != L
trigger1 = ctrl
value = 600

;AI Jump Medium Punch
[State -1, AI Jump Medium Punch]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && statetype = A
triggerall = (p2bodydist x = [30,80]) && (p2bodydist y = [-60,60]) && p2statetype != L
trigger1 = ctrl && random < 250*(AIlevel ** 2 / 64.0)
trigger2 = (StateNo = 600) || (StateNo = 630)
trigger2 = Movehit && random < 450*(AIlevel ** 2 / 64.0)
value = 610

;AI Jump Strong Punch (two fists)
[State -1, AI Jump Strong Punch]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && statetype = A
triggerall = (p2bodydist x = [0,60]) && (p2bodydist y = [-60,60]) && p2statetype != L
trigger1 = ctrl && random < 250*(AIlevel ** 2 / 64.0)
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 630) || (StateNo = 640)
trigger2 = Movehit && random < 450*(AIlevel ** 2 / 64.0)
value = 620

;AI Jump Strong Punch (Sleepy punch)
[State -1, AI Sleepy Punch]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && statetype = A
triggerall = (p2bodydist x = [0,60]) && (p2bodydist y = [0,60]) && p2statetype != L
triggerall = vel y>0 ;Only during downwards
trigger1 = ctrl && random < 250*(AIlevel ** 2 / 64.0)
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 630) || (StateNo = 640)
trigger2 = Movehit && random < 450*(AIlevel ** 2 / 64.0)
value = 655

;AI Jump Light Kick
[State -1, AI Jump Light Kick]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && statetype = A
triggerall = (p2bodydist x = [5,50]) && (p2bodydist y = [-20,60]) && p2statetype != L
trigger1 = ctrl && random < 250*(AIlevel ** 2 / 64.0)
value = 630

;AI Jump Medium Kick
[State -1, AI Jump Medium Kick]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && statetype = A
triggerall = (p2bodydist x = [5,120]) && (p2bodydist y = [-20,60]) && p2statetype != L
trigger1 = ctrl && random < 250*(AIlevel ** 2 / 64.0)
trigger2 = (StateNo = 600) || (StateNo = 630)
trigger2 = Movehit && random < 450*(AIlevel ** 2 / 64.0)
value = 640

;AI Jump Strong Kick
[State -1, AI Jump Strong Kick]
type = ChangeState
triggerall = !NumHelper(1605) || (NumHelper(1605)=1 && NumHelper(9996)=1) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate=2 && statetype = A
triggerall = (p2bodydist x = [5,80]) && (p2bodydist y = [-20,80]) && p2statetype != L
trigger1 = ctrl && random < 250*(AIlevel ** 2 / 64.0)
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 630) || (StateNo = 640)
trigger2 = Movehit && random < 450*(AIlevel ** 2 / 64.0)
value = 650

;AI Candy Beam
[State -1, AI Candy Beam]
type = ChangeState
triggerall= AILevel>0 && numenemy && roundstate = 2 && statetype != A
triggerall = power >= 500 && !NumHelper(9996)
triggerall = !NumHelper(1605) ;Candy mode
triggerall= (enemy,stateno!=[120,155]) && (enemy,stateno!=[5100,5120]) && (enemynear,statetype!=L) && (enemynear,vel y>=-2)
triggerall= (p2bodydist x=[50,130]) && (p2bodydist y=[-110,5]) && (enemynear,vel x=[0,2))
trigger1 = ctrl && random < 200*(AIlevel ** 2 / 64.0)
trigger2 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movecontact && random < 100*(AIlevel ** 2 / 64.0)
trigger3 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movecontact && random < 100*(AIlevel ** 2 / 64.0)
trigger4 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movecontact && random < 100*(AIlevel ** 2 / 64.0)
trigger5 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movecontact && random < 100*(AIlevel ** 2 / 64.0)
trigger6 = (stateno = 100 || stateno = 101) && random < 100*(AIlevel ** 2 / 64.0)
value = 1600

;AI Maniac Ball
[State -1, AI Maniac Ball]
type = ChangeState
triggerall = !NumHelper(1605) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate = 2 && statetype != A && (p2bodydist x =[5,175]) && (p2bodydist y =[-70,5])
triggerall=(p2stateno != [120, 155]) && (enemynear,statetype != L)
trigger1 = ctrl && random < 150*(AIlevel ** 2 / 64.0)
trigger2 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger3 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger4 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movehit && random < 100*(AIlevel ** 2 / 64.0)
trigger5 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movehit && random < 100*(AIlevel ** 2 / 64.0)
trigger6 = (stateno = 100 || stateno = 101) && random < 150*(AIlevel ** 2 / 64.0)
trigger7 = ctrl && numtarget
trigger7 = target,movetype=H
trigger7 = random < 400*(AIlevel ** 2 / 64.0)
value = IfElse(((power>=500)&&random%10),1450,1400)

;AI Air (EX) Maniac Ball
[State -1, AI Air (EX) Maniac Ball]
type = ChangeState
triggerall = !NumHelper(1605) ;Candy mode
triggerall = AILevel>0 && numenemy && roundstate = 2 && statetype = A && vel x>=0
triggerall= (enemy,stateno!=[120,155]) && (p2bodydist x=[0,65]) && (p2bodydist y=[40,180])
triggerall = pos Y < -60
triggerall = !NumHelper(9997)   ;Limit timer
trigger1 = ctrl && random < 150*(AIlevel ** 2 / 64.0)
trigger2 = (StateNo = 600) || (StateNo = 630) || (StateNo = 610) || (StateNo = 620) || (StateNo = 640)
trigger2 = movehit && random < 350*(AIlevel ** 2 / 64.0)
trigger3 = enemynear,statetype=L && ctrl && random < 300*(AIlevel ** 2 / 64.0)
value = IfElse(((power>=500)&&random%10),1470,1420)

;AI Pop Kick
[State -1, AI Pop Kick]
type = ChangeState
triggerall= AILevel>0 && numenemy && roundstate = 2 && statetype != A
triggerall = !NumHelper(9998)   ;Limit timer
triggerall = p2bodydist x=[50,200]
trigger1 = (P2Statetype=L || P2Movetype=H) && (enemy,pos Y>-100 || p2bodydist y=[-100,0])
trigger1 = ctrl && (Random<400*((AIlevel**2)/64.0))
trigger2 = p2bodydist x=[120,200]
trigger2 = P2Movetype=A && P2Statetype!=C
trigger2 = ctrl && (Random<300*((AIlevel**2)/64.0))
trigger3 = (enemy,stateno!=[120,155])
trigger3 = ctrl && (Random<100*((AIlevel**2)/64.0))
trigger4 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger5 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger6 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger7 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger8 = (stateno = 100 || stateno = 101) && random < 150*(AIlevel ** 2 / 64.0)
value = 1200

;AI (EX) Burp Fireball
[State -1, AI (EX) Burp Fireball]
type = ChangeState
triggerall=  AILevel>0 && numenemy && roundstate = 2 && statetype != A
triggerall = !NumHelper(1005)
triggerall = (p2bodydist x>=90) && (p2bodydist y=[-90,0]) ;&& (enemy,stateno!=[120,155])
triggerall = (stateno!=[1000,1050])
trigger1 = (P2Statetype=L || P2Movetype=H) ;&& (enemy,pos Y>-90 || p2bodydist y=[-90,0])
trigger1 = ctrl && (Random<400*((AIlevel**2)/64.0))
trigger2 = P2Statetype=A && P2Movetype!=A
trigger2 = ctrl && (Random<400*((AIlevel**2)/64.0))
trigger3 = P2Statetype=C && (enemy,stateno=[120,155])
trigger3 = ctrl && (Random<200*((AIlevel**2)/64.0))
trigger4 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger5 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 255)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger6 = (stateno = 250) && movecontact>=6 && random < 150*(AIlevel ** 2 / 64.0)
trigger7 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger8 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger9 = (stateno = 100 || stateno = 101) && random < 150*(AIlevel ** 2 / 64.0)
value = IfElse(((power>=500)&&random%10),1050,1000)

;AI Head Throw
[State -1, AI Head Throw]
type = ChangeState
triggerall=  AILevel>0 && numenemy && roundstate = 2 && statetype = S
triggerall = !NumHelper(1150)   ;No head puddle
triggerall = stateno != [1100,1110]
trigger1 = ctrl && (Random<100*((AIlevel**2)/64.0))
trigger2 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger3 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger4 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger5 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger6 = (stateno = 100 || stateno = 101) && random < 150*(AIlevel ** 2 / 64.0)
value = 1100

;Head Recall (1 & 2)
[State -1, AI Head Recall 1]
type = ChangeState
triggerall=  AILevel>0 && numenemy && roundstate = 2 && statetype = S
triggerall = stateno != [1100,1110]
triggerall = NumHelper(1150)   ;Head puddle onscreen
triggerall = (Helper(1150),facing=-1) && (Helper(1150),p2bodydist x<10) ;Head behind enemy
triggerall = (Helper(1150),facing=-1) && (Helper(1150),RootDist X<-60) ;Head in front of Buu
trigger1 = ctrl && (Random<200*((AIlevel**2)/64.0))
trigger2 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movehit && random < 300*(AIlevel ** 2 / 64.0)
trigger3 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movehit && random < 300*(AIlevel ** 2 / 64.0)
trigger4 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movehit && random < 300*(AIlevel ** 2 / 64.0)
trigger5 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movehit && random < 300*(AIlevel ** 2 / 64.0)
trigger6 = (stateno = 100 || stateno = 101) && random < 300*(AIlevel ** 2 / 64.0)
value = 1110
[State -1, AI Head Recall 2]
type = ChangeState
triggerall=  AILevel>0 && numenemy && roundstate = 2 && statetype = S
triggerall = stateno != [1100,1110]
triggerall = NumHelper(1150)   ;Head puddle onscreen
triggerall = (Helper(1150),facing=1) && (Helper(1150),p2bodydist x<10) ;Head behind enemy
triggerall = (Helper(1150),facing=1) && (Helper(1150),RootDist X>60) ;Head in front of Buu
trigger1 = ctrl && (Random<200*((AIlevel**2)/64.0))
trigger2 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movehit && random < 300*(AIlevel ** 2 / 64.0)
trigger3 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movehit && random < 300*(AIlevel ** 2 / 64.0)
trigger4 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movehit && random < 300*(AIlevel ** 2 / 64.0)
trigger5 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movehit && random < 300*(AIlevel ** 2 / 64.0)
trigger6 = (stateno = 100 || stateno = 101) && random < 300*(AIlevel ** 2 / 64.0)
value = 1110

;AI Heavy Rain Lv1
[State -1, AI Heavy Rain Lv1]
type = ChangeState
triggerall = AILevel>0 && numenemy && roundstate = 2 && statetype !=A
triggerall = !NumHelper(9996) ;MCB Limiter
triggerall = enemynear,movetype!=A
triggerall = p2bodydist x=[120,220]
triggerall = stateno != [2000,2002]
triggerall = (power >= 1000 || (var(32)>0 && !NumHelper(9996)))
trigger1 = Ctrl && random < 200*(AIlevel ** 2 / 64.0)
trigger2 = (stateno = 100 || stateno = 101) && random < 50*(AIlevel ** 2 / 64.0)
trigger3 = stateno = 1300 && movehit && random < 75*(AIlevel ** 2 / 64.0)  ;Slash Chop
trigger4 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movehit && random < 75*(AIlevel ** 2 / 64.0)
trigger5 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movehit && random < 75*(AIlevel ** 2 / 64.0)
trigger6 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movehit && random < 75*(AIlevel ** 2 / 64.0)
trigger7 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movehit && random < 75*(AIlevel ** 2 / 64.0)
value = 2000

;AI Ground Vice Shot
[State -1, AI Vice Shot Lv.1]
type = ChangeState
triggerall = AILevel>0 && numenemy && roundstate = 2 && statetype !=A
triggerall = !NumHelper(9996) ;MCB Limiter
triggerall = p2bodydist x=[120,220]
triggerall = (power >= 1000 || (var(32)>0 && !NumHelper(9996)))
triggerall = stateno != [2100,2120]
triggerall = !NumHelper(2150) ;No Vice Shot
triggerall = !NumHelper(2450) ;No Vice Shot
trigger1 = Ctrl && random < 300*(AIlevel ** 2 / 64.0)
trigger2 = (stateno = 100 || stateno = 101) && random < 50*(AIlevel ** 2 / 64.0)
trigger3 = stateno = 1300 && movehit && random < 150*(AIlevel ** 2 / 64.0)  ;Slash Chop
trigger4 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger5 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger6 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger7 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
value = 2100

;AI Air Vice Shot
[State -1, AI Air Vice Shot Lv.1]
type = ChangeState
triggerall = AILevel>0 && numenemy && roundstate = 2 && statetype =A
triggerall = !NumHelper(9996) ;MCB Limiter
triggerall = (p2bodydist x=[80,180]) && p2bodydist y=[0,120]
triggerall = (power >= 1000 || (var(32)>0 && !NumHelper(9996)))
triggerall = stateno != [2200,2201]
triggerall = !NumHelper(2150) ;No Vice Shot
triggerall = !NumHelper(2450) ;No Vice Shot
trigger1 = Ctrl && random < 300*(AIlevel ** 2 / 64.0)
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 620)
trigger2 = movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger3 = (StateNo = 630) || (StateNo = 640) || (StateNo = 650)
trigger3 = movehit && random < 150*(AIlevel ** 2 / 64.0)
value = 2200

;AI Gackt!
[State -1, AI Gackt!]
type = ChangeState
triggerall= AILevel>0 && numenemy && roundstate = 2 && statetype != A
triggerall = !NumHelper(9996) ;MCB Limiter
triggerall= p2bodydist x>130
triggerall = stateno != [2300,2302]
triggerall = (power >= 1000 || (var(32)>0 && !NumHelper(9996)))
trigger1 = Ctrl && (Random<200*((AIlevel**2)/64.0))
trigger2 = (stateno = 100 || stateno = 101) && random < 50*(AIlevel ** 2 / 64.0)
trigger3 = stateno = 1300 && movehit && random < 150*(AIlevel ** 2 / 64.0)  ;Slash Chop
trigger4 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger5 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger6 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger7 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger8 = Ctrl && NumHelper(1005) ;Burp Fireball
trigger8 = helper(1005),p2bodydist x<50
trigger8 = random < 100*(AIlevel ** 2 / 64.0)
trigger9 = Ctrl && NumHelper(1150) ;Head Throw
trigger9 = helper(1150),movecontact
trigger9 = random < 100*(AIlevel ** 2 / 64.0)
value = 2300

;AI Pain Train Lv1
[State -1, AI Pain Train Lv1]
type = ChangeState
triggerall= AILevel>0 && numenemy && roundstate = 2 && statetype = S
triggerall = !NumHelper(9996) ;MCB Limiter
triggerall= p2bodydist x=[-10,100]
triggerall = FrontEdgeDist > 150
triggerall = stateno != [2500,2501]
triggerall = (power >= 1000 || (var(32)>0 && !NumHelper(9996)))
trigger1 = Ctrl && (Random<200*((AIlevel**2)/64.0))
trigger2 = (stateno = 100 || stateno = 101) && random < 50*(AIlevel ** 2 / 64.0)
trigger3 = stateno = 1300 && movehit && random < 150*(AIlevel ** 2 / 64.0)  ;Slash Chop
trigger4 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 220)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger5 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger6 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger7 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
value = 2500

;AI Madman's Ball Lv1
[State -1, AI Madman's Ball Lv1]
type = ChangeState
triggerall= AILevel>0 && numenemy && roundstate = 2 && statetype = A
triggerall = !NumHelper(9996) ;MCB Limiter
triggerall = enemynear,movetype!=A && enemynear,stateno!=[120,155]
triggerall = !NumHelper(9999)   ;Limit timer
triggerall = stateno != 2600
triggerall = (power >= 1000 || (var(32)>0 && !NumHelper(9996)))
triggerall = pos Y < -60
trigger1 = Ctrl && random < 300*(AIlevel ** 2 / 64.0)
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 620)
trigger2 = movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger3 = (StateNo = 630) || (StateNo = 640) || (StateNo = 650)
trigger3 = movehit && random < 150*(AIlevel ** 2 / 64.0)
value = 2600

;AI Air Vice Shot
[State -1, AI Air Vice Shot Lv.2]
type = ChangeState
triggerall = AILevel>0 && numenemy && roundstate = 2 && statetype =A
triggerall = !NumHelper(9996) ;MCB Limiter
triggerall = (p2bodydist x=[80,180]) && p2bodydist y=[0,120]
triggerall = stateno != 2460
triggerall = (var(32)=0 && power >= 2000) || (var(32)>0 && power >= 1000 && !NumHelper(9996))
triggerall = !NumHelper(2450) ;No Vice Shot
trigger1 = Ctrl && random < 300*(AIlevel ** 2 / 64.0)
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 620)
trigger2 = movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger3 = (StateNo = 630) || (StateNo = 640) || (StateNo = 650)
trigger3 = movehit && random < 150*(AIlevel ** 2 / 64.0)
value = 2460

;AI Ground Vice Shot
[State -1, AI Ground Vice Shot Lv.2]
type = ChangeState
triggerall = AILevel>0 && numenemy && roundstate = 2 && statetype !=A
triggerall = !NumHelper(9996) ;MCB Limiter
triggerall = p2bodydist x=[120,220]
triggerall = stateno != 2400
triggerall = (var(32)=0 && power >= 2000) || (var(32)>0 && power >= 1000 && !NumHelper(9996))
triggerall = !NumHelper(2450) ;No Vice Shot
trigger1 = Ctrl && random < 300*(AIlevel ** 2 / 64.0)
trigger2 = (stateno = 100 || stateno = 101) && random < 50*(AIlevel ** 2 / 64.0)
trigger3 = stateno = 1300 && movehit && random < 150*(AIlevel ** 2 / 64.0)  ;Slash Chop
trigger4 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger5 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger6 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger7 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
value = 2400

;AI Flesh Prison Lv2
[State -1, AI Flesh Prison Lv2]
type = ChangeState
triggerall = AILevel>0 && numenemy && roundstate = 2 && statetype !=A
triggerall = !NumHelper(9996) ;MCB Limiter
triggerall = p2bodydist x>80 && p2bodydist y=[-60,120]
triggerall = P2Statetype = A && enemynear,movetype!=A ;&& enemynear,stateno!=[120,155]
triggerall = stateno != 2800
triggerall = (var(32)=0 && power >= 2000) || (var(32)>0 && power >= 1000 && !NumHelper(9996))
triggerall = pos Y < -60
trigger1 = Ctrl && random < 300*(AIlevel ** 2 / 64.0)
trigger2 = (StateNo = 600) || (StateNo = 610) || (StateNo = 620)
trigger2 = movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger3 = (StateNo = 630) || (StateNo = 640) || (StateNo = 650)
trigger3 = movehit && random < 150*(AIlevel ** 2 / 64.0)
value = 2800

[State -1, AI Mega Candy Beam - EMO Ender]
type = ChangeState
triggerall = AILevel>0 && numenemy && roundstate = 2 && statetype !=A
triggerall = !NumHelper(9996) ;MCB Limiter
triggerall = !NumHelper(1605) ;enemy is not candied
triggerall = var(32)>0 ;EMO mode
triggerall = Life<200 ;Desperate move
triggerall = p2bodydist x>80 && p2bodydist y=[-60,120]
triggerall = enemynear,stateno!=[120,155]
trigger1 = Ctrl && random < 300*(AIlevel ** 2 / 64.0)
trigger2 = (stateno = 100 || stateno = 101) && random < 50*(AIlevel ** 2 / 64.0)
trigger3 = stateno = 1300 && movehit && random < 150*(AIlevel ** 2 / 64.0)  ;Slash Chop
trigger4 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger5 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger6 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
trigger7 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movehit && random < 150*(AIlevel ** 2 / 64.0)
value = 2900

;AI EMO Startup
[State -1, AI Kill You! EMO Startup]
type = ChangeState
triggerall = AILevel>0 && numenemy && roundstate = 2 && statetype !=A
triggerall = p2bodydist x<100
triggerall = TeamMode != Simul
triggerall = enemyNear,TeamMode != Simul
triggerall = (enemy,Name != "Saibamen Z2")
triggerall = (var(32)=0 && power >= 3000) || (var(32)>0 && power >= 2000 && !NumHelper(9996))
triggerall = stateno != 4000
trigger1 = Ctrl && random < 400*(AIlevel ** 2 / 64.0)
trigger2 = (stateno = 100 || stateno = 101) && random < 100*(AIlevel ** 2 / 64.0)
trigger3 = stateno = 1300 && movehit && random < 300*(AIlevel ** 2 / 64.0)  ;Slash Chop
trigger4 = ((stateno = 200) || (stateno = 205) || (stateno = 210) || (stateno = 211) || (stateno = 220)) && movehit && random < 300*(AIlevel ** 2 / 64.0)
trigger5 = ((stateno = 230) || (stateno = 240) || (stateno = 245) || (stateno = 250) || (stateno = 255)) && movehit && random < 300*(AIlevel ** 2 / 64.0)
trigger6 = ((stateno = 400) || (stateno = 410) || (stateno = 420)) && movehit && random < 300*(AIlevel ** 2 / 64.0)
trigger7 = ((stateno = 430) || (stateno = 440) || (stateno = 450)) && movehit && random < 300*(AIlevel ** 2 / 64.0)
value = 4000


;===========================================================================
; SYSTEM AI
;===========================================================================


