;------------------------------
;-----------Comandos-----------
;--------By Thunderbert--------
;------------------------------

;-| Remapeamento de botões |-----------------------------------------------
[Remap]
x = x
y = y
z = z
a = a
b = b
c = c
s = s

;-| Valores Padrões |------------------------------------------------------
[Defaults]
Command.Time = 30
Command.Buffer.Time = 1

;-| AI Commands | ---------------------------------------------------------
[command]
name = "AI_1"
command = D,D,D,D,D,D,D,D,D,D,D,D
time = 1

[command]
name = "AI_2"
command = U,U,U,U,U,U,U,U,U,U,U,U
time = 1

[command]
name = "AI_3"
command = F,F,F,F,F,F,F,F,F,F,F,F
time = 1

[command]
name = "AI_4"
command = B,B,B,B,B,B,B,B,B,B,B,B
time = 1

[command]
name = "AI_5"
command = a,a,a,a,a,a,a,a,a,a,a,a
time = 1

[command]
name = "AI_6"
command = b,b,b,b,b,b,b,b,b,b,b,b
time = 1

[command]
name = "AI_7"
command = c,c,c,c,c,c,c,c,c,c,c,c
time = 1

[command]
name = "AI_8"
command = x,x,x,x,x,x,x,x,x,x,x,x
time = 1

[command]
name = "AI_9"
command = y,y,y,y,y,y,y,y,y,y,y,y
time = 1

[command]
name = "AI_10"
command = z,z,z,z,z,z,z,z,z,z,z,z
time = 1

[command]
name = "AI_11"
command = s,s,s,s,s,s,s,s,s,s,s,s
time = 1

[command]
name = "AI_12"
command = D,F,D,F,D,F,D,F,D,F,D,F
time = 1

[command]
name = "AI_13"
command = D,B,D,B,D,B,D,B,D,B,D,B
time = 1

[command]
name = "AI_14"
command = D,U,D,U,D,U,D,U,D,U,D,U
time = 1

[command]
name = "AI_15"
command = U,F,U,F,U,F,U,F,U,F,U,F
time = 1

[command]
name = "AI_16"
command = U,B,U,B,U,B,U,B,U,B,U,B
time = 1

[command]
name = "AI_17"
command = U,D,U,D,U,D,U,D,U,D,U,D
time = 1

[command]
name = "AI_18"
command = F,D,F,D,F,D,F,D,F,D,F,D
time = 1

[command]
name = "AI_19"
command = F,U,F,U,F,U,F,U,F,U,F,U
time = 1

[command]
name = "AI_20"
command = F,B,F,B,F,B,F,B,F,B,F,B
time = 1

[command]
name = "AI_21"
command = B,D,B,D,B,D,B,D,B,D,B,D
time = 1

[command]
name = "AI_22"
command = B,U,B,U,B,U,B,U,B,U,B,U
time = 1

[command]
name = "AI_23"
command = B,F,B,F,B,F,B,F,B,F,B,F
time = 1

[command]
name = "AI_24"
command = DF,DF,DF,DF,DF,DF,DF,DF,DF,DF,DF,DF
time = 1

[command]
name = "AI_25"
command = DB,DB,DB,DB,DB,DB,DB,DB,DB,DB,DB,DB
time = 1

[command]
name = "AI_26"
command = UF,UF,UF,UF,UF,UF,UF,UF,UF,UF,UF,UF
time = 1

[command]
name = "AI_27"
command = UB,UB,UB,UB,UB,UB,UB,UB,UB,UB,UB,UB
time = 1

[command]
name = "AI_28"
command = D,F,U,B,D,F,U,B,D,F,U,B
time = 1

[command]
name = "AI_29"
command = F,U,B,D,F,U,B,D,F,U,B,D
time = 1

[command]
name = "AI_30"
command = U,B,D,F,U,B,D,F,U,B,D,F
time = 1

[command]
name = "AI_31"
command = B,D,F,U,B,D,F,U,B,D,F,U
time = 1

[command]
name = "AI_32"
command = a,b,c,x,y,z,a,b,c,x,y,z
time = 1

[command]
name = "AI_33"
command = b,c,x,y,z,a,b,c,x,y,z,a
time = 1

[command]
name = "AI_34"
command = c,x,y,z,a,b,c,x,y,z,a,b
time = 1

[command]
name = "AI_35"
command = x,y,z,a,b,c,x,y,z,a,b,c
time = 1

[command]
name = "AI_36"
command = y,z,a,b,c,x,y,z,a,b,c,x
time = 1

[command]
name = "AI_37"
command = z,a,b,c,x,y,z,a,b,c,x,y
time = 1

[command]
name = "AI_38"
command = a+b,a+b,a+b,a+b,a+b,a+b,a+b,a+b,a+b,a+b,a+b,a+b
time = 1

[command]
name = "AI_39"
command = a+c,a+c,a+c,a+c,a+c,a+c,a+c,a+c,a+c,a+c,a+c,a+c
time = 1

[command]
name = "AI_40"
command = a+x,a+x,a+x,a+x,a+x,a+x,a+x,a+x,a+x,a+x,a+x,a+x
time = 1

[command]
name = "AI_41"
command = a+y,a+y,a+y,a+y,a+y,a+y,a+y,a+y,a+y,a+y,a+y,a+y
time = 1

[command]
name = "AI_42"
command = a+z,a+z,a+z,a+z,a+z,a+z,a+z,a+z,a+z,a+z,a+z,a+z
time = 1

[command]
name = "AI_43"
command = a+s,a+s,a+s,a+s,a+s,a+s,a+s,a+s,a+s,a+s,a+s,a+s
time = 1

[command]
name = "AI_44"
command = b+c,b+c,b+c,b+c,b+c,b+c,b+c,b+c,b+c,b+c,b+c,b+c
time = 1

[command]
name = "AI_45"
command = b+x,b+x,b+x,b+x,b+x,b+x,b+x,b+x,b+x,b+x,b+x,b+x
time = 1

[command]
name = "AI_46"
command = b+y,b+y,b+y,b+y,b+y,b+y,b+y,b+y,b+y,b+y,b+y,b+y
time = 1

[command]
name = "AI_47"
command = b+z,b+z,b+z,b+z,b+z,b+z,b+z,b+z,b+z,b+z,b+z,b+z
time = 1

[command]
name = "AI_48"
command = b+s,b+s,b+s,b+s,b+s,b+s,b+s,b+s,b+s,b+s,b+s,b+s
time = 1

[command]
name = "AI_49"
command = c+x,c+x,c+x,c+x,c+x,c+x,c+x,c+x,c+x,c+x,c+x,c+x
time = 1

[command]
name = "AI_50"
command = c+y,c+y,c+y,c+y,c+y,c+y,c+y,c+y,c+y,c+y,c+y,c+y
time = 1

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

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

;-| Double Tap |-----------------------------------------------------------
[Command]
name = "FF"     ;Required (do not remove)
command = F, F
time = 10

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

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

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

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

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

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

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

;-| Dir + Button |---------------------------------------------------------
[Command]
name = "back_x"
command = /$B,x
time = 1

[Command]
name = "back_y"
command = /$B,y
time = 1

[Command]
name = "back_z"
command = /$B,z
time = 1

[Command]
name = "down_x"
command = /$D,x
time = 1

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

[Command]
name = "down_z"
command = /$D,z
time = 1

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

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

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

[Command]
name = "up_x"
command = /$U,x
time = 1

[Command]
name = "up_y"
command = /$U,y
time = 1

[Command]
name = "up_z"
command = /$U,z
time = 1

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

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

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

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

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

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

[Command]
name = "fwd_a"
command = /$F,a
time = 1

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

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

[Command]
name = "up_a"
command = /$U,a
time = 1

[Command]
name = "up_b"
command = /$U,b
time = 1

[Command]
name = "up_c"
command = /$U,c
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

;-| Single Dir |------------------------------------------------------------
[Command]
name = "fwd" ;Required (do not remove)
command = $F
time = 1

[Command]
name = "downfwd"
command = $DF
time = 1

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

[Command]
name = "downback"
command = $DB
time = 1

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

[Command]
name = "upback"
command = $UB
time = 1

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

[Command]
name = "upfwd"
command = $UF
time = 1

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

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

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

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

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

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

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

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

[Command]
name = "holddownfwd"
command = /$DF
time = 1

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

[Command]
name = "holddownback"
command = /$DB
time = 1

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

[Command]
name = "holdupback"
command = /$UB
time = 1

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

[Command]
name = "holdupfwd"
command = /$UF
time = 1

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


; Don't remove the following line. It's required by the CMD standard.
[Statedef -1]

;===========================================================================
;---------------------------------------------------------------------------
;------------------------------
;--------------AI--------------
;--------By Thunderbert--------
;------------------------------
[State -1, AI VarSet]
type = VarSet
trigger1 = command = "AI_1"
trigger2 = command = "AI_2"
trigger3 = command = "AI_3"
trigger4 = command = "AI_4"
trigger5 = command = "AI_5"
trigger6 = command = "AI_6"
trigger7 = command = "AI_7"
trigger8 = command = "AI_8"
trigger9 = command = "AI_9"
trigger10 = command = "AI_10"
trigger11 = command = "AI_11"
trigger12 = command = "AI_12"
trigger13 = command = "AI_13"
trigger14 = command = "AI_14"
trigger15 = command = "AI_15"
trigger16 = command = "AI_16"
trigger17 = command = "AI_17"
trigger18 = command = "AI_18"
trigger19 = command = "AI_19"
trigger20 = command = "AI_20"
trigger21 = command = "AI_21"
trigger22 = command = "AI_22"
trigger23 = command = "AI_23"
trigger24 = command = "AI_24"
trigger25 = command = "AI_25"
trigger26 = command = "AI_26"
trigger27 = command = "AI_27"
trigger28 = command = "AI_28"
trigger29 = command = "AI_29"
trigger30 = command = "AI_30"
trigger31 = command = "AI_31"
trigger32 = command = "AI_32"
trigger33 = command = "AI_33"
trigger34 = command = "AI_34"
trigger35 = command = "AI_35"
trigger36 = command = "AI_36"
trigger37 = command = "AI_37"
trigger38 = command = "AI_38"
trigger39 = command = "AI_39"
trigger40 = command = "AI_40"
trigger41 = command = "AI_41"
trigger42 = command = "AI_42"
trigger43 = command = "AI_43"
trigger44 = command = "AI_44"
trigger45 = command = "AI_45"
trigger46 = command = "AI_46"
trigger47 = command = "AI_47"
trigger48 = command = "AI_48"
trigger49 = command = "AI_49"
trigger50 = command = "AI_50"
v = 59
value = 1

[State -1, AI Guard]
type = ChangeState
trigger1 = Ctrl = 1
trigger1 = RoundState = 2
trigger1 = var(59) != 0
trigger1 = Random <= 699
trigger1 = P2BodyDist X <= 75
trigger1 = P2MoveType = A
Trigger1 = StateNo != [120,160]
value = 120

[State -1, AI Double Slap]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 99
Trigger1 = P2BodyDist X <= 5
Trigger1 = StateType = S
Value = 200

[State -1, AI Side Kick]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 199
Trigger1 = P2BodyDist X <= 5
Trigger1 = StateType = S
Value = 210

[State -1, AI Strong Down Kick]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 299
Trigger1 = P2BodyDist X <= 5
Trigger1 = StateType != A
Value = 220

[State -1, AI Headbut]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 399
Trigger1 = P2BodyDist X <= 5
Trigger1 = StateType != A
Value = 230

[State -1, AI Spin Kick]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 449
Trigger1 = P2BodyDist X <= 5
Trigger1 = StateType = S
Value = 250

[State -1, AI Down Kick]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 499
Trigger1 = P2BodyDist X <= 5
Trigger1 = StateType = S
Value = 260

[State -1, AI Up Kick]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 549
Trigger1 = P2BodyDist X <= 5
Trigger1 = StateType = S
Value = 270

[State -1, AI Air Kick]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 199
Trigger1 = P2BodyDist X <= 30
Trigger1 = StateType = A
Value = 300

[State -1, AI Air Side Kick]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 299
Trigger1 = P2BodyDist X <= 30
Trigger1 = StateType = A
Value = 310

[State -1, AI Back Air Side Kick]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 299
Trigger1 = P2BodyDist X <= -5
Trigger1 = StateType = A
Value = 320

[State -1, AI Air Up Slap]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 399
Trigger1 = P2BodyDist X <= 30
Trigger1 = StateType = A
Value = 330

[State -1, AI Air Spin Kick]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 499
Trigger1 = P2BodyDist X <= 30
Trigger1 = StateType = A
Value = 340

[State -1, AI Rollout]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 299
Trigger1 = P2BodyDist X = [50, 100]
Value = 400

[State -1, AI Pound]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 299
Trigger1 = P2BodyDist X <= 50
Value = 410

[State -1, AI Sing]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 399
Trigger1 = P2BodyDist X <= 20
Trigger1 = P2StateNo != 421
Value = 420

[State -1, AI Rest]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 699
Trigger1 = P2BodyDist X <= 5
Trigger1 = P2BodyDist Y >= -5
Value = 430

[State -1, AI Grab]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 899
Trigger1 = P2BodyDist X <= 5
Trigger1 = StateType = S
Value = 500

[State -1, AI Final Smash]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 299
Trigger1 = Pos X = [-50, 50]
Trigger1 = StateType = S
Trigger1 = Power >= 1000
Value = 600

[State -1, AI Song of Pain]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 299
Trigger1 = P2Dist X >= 100
Trigger1 = StateType = S
Trigger1 = Power >= 1000
Value = 700

[State -1, AI Song of Death]
Type = ChangeState
Trigger1 = Ctrl = 1
Trigger1 = RoundState = 2
Trigger1 = Var(59) != 0
Trigger1 = Random <= 499
Trigger1 = P2Dist X >= 100
Trigger1 = StateType = S
Trigger1 = Power >= 1000
Value = 800

;===========================================================================
;---------------------------------------------------------------------------
; Jump
[State -1, Jump]
Type = ChangeState
Value = IfElse(Var(4) = 1, (IfElse(Command = "a", 270, (IfElse(Command = "b", 420, (IfElse(Command = "y" && Power >= 1000, 700, 0)))))), 40)
Trigger1 = Command = "holdup"
Trigger1 = StateType = S
Trigger1 = Ctrl

;---------------------------------------------------------------------------
; Double Jump (Up)
[State -1, Double Jump (Up)]
Type = ChangeState
Value = 60
Trigger1 = Var(0) <= 4
Trigger1 = Command = "up"
Trigger1 = Command != "holdfwd"
Trigger1 = Command != "holdback"
Trigger1 = StateType = A
Trigger1 = Ctrl

;---------------------------------------------------------------------------
; Double Jump (Forward)
[State -1, Double Jump (Forward)]
Type = ChangeState
Value = 61
Trigger1 = Var(0) <= 4
Trigger1 = Command = "up"
Trigger1 = Command = "holdfwd"
Trigger1 = Command != "holdback"
Trigger1 = StateType = A
Trigger1 = Ctrl

;---------------------------------------------------------------------------
; Double Jump (Backward)
[State -1, Double Jump (Backward)]
Type = ChangeState
Value = 62
Trigger1 = Var(0) <= 4
Trigger1 = Command = "up"
Trigger1 = Command != "holdfwd"
Trigger1 = Command = "holdback"
Trigger1 = StateType = A
Trigger1 = Ctrl

;---------------------------------------------------------------------------
; Run Fwd
[State -1, Run Fwd]
type = ChangeState
value = 100
trigger1 = command = "FF"
trigger1 = statetype = S
trigger1 = ctrl

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

;---------------------------------------------------------------------------
; Guard
[State -1, Guard]
Type = ChangeState
Value = 120
Trigger1 = Command = "hold_c"
Trigger1 = Ctrl

;---------------------------------------------------------------------------
; Taunt
[State -1, Taunt]
type = ChangeState
value = 195
triggerall = command = "s"
TriggerAll = Command != "holdfwd"
TriggerAll = Command != "holdback"
TriggerAll = Command != "holddown"
trigger1 = statetype != A
trigger1 = ctrl

;---------------------------------------------------------------------------
; Taunt 2
[State -1, Taunt 2]
type = ChangeState
value = 196
triggerall = command = "s"
TriggerAll = Command = "holdfwd" || Command = "holdback"
TriggerAll = Command != "holddown"
trigger1 = statetype != A
trigger1 = ctrl

;---------------------------------------------------------------------------
; Taunt 3
[State -1, Taunt 3]
type = ChangeState
value = 197
triggerall = command = "s"
TriggerAll = Command = "holddown"
TriggerAll = Command != "holdfwd"
TriggerAll = Command != "holdback"
trigger1 = statetype != A
trigger1 = ctrl

;---------------------------------------------------------------------------
; Double Slap
[State -1, Double Slap]
type = ChangeState
value = 200
triggerall = command = "a"
TriggerAll = Command != "holdfwd"
triggerall = command != "holddown"
TriggerAll = Command != "holdup"
trigger1 = statetype = S
trigger1 = ctrl

;---------------------------------------------------------------------------
; Side Kick
[State -1, Side Kick]
type = ChangeState
value = 210
TriggerAll = Var(1) <= 5
TriggerAll = Command = "a"
triggerall = command = "holdfwd"
triggerall = command != "holddown"
TriggerAll = Command != "holdup"
trigger1 = statetype = S
trigger1 = ctrl

;---------------------------------------------------------------------------
; Strong Down Kick
[State -1, Strong Down Kick]
type = ChangeState
value = 220
TriggerAll = Var(2) <= 5
triggerall = command = "a"
triggerall = command = "holddown"
triggerall = command != "holdfwd"
TriggerAll = Command != "holdup"
trigger1 = statetype != A
trigger1 = ctrl

;---------------------------------------------------------------------------
; Headbut
[State -1, Headbut]
type = ChangeState
value = 230
TriggerAll = Var(3) <= 5
triggerall = command = "a"
TriggerAll = Command = "holdup"
triggerall = command != "holdfwd"
triggerall = command != "holddown"
trigger1 = statetype = S
trigger1 = ctrl
Trigger2 = StateNo = 40

;---------------------------------------------------------------------------
; Spin Kick
[State -1, Spin Kick]
type = ChangeState
value = 250
TriggerAll = Var(1) > 5
triggerall = command = "a"
TriggerAll = Command = "holdfwd"
TriggerAll = Command != "holdup"
triggerall = command != "holddown"
trigger1 = statetype = S
trigger1 = ctrl

;---------------------------------------------------------------------------
; Down Kick
[State -1, Down Kick]
type = ChangeState
value = 260
TriggerAll = Var(2) > 5
triggerall = command = "a"
triggerall = command = "holddown"
triggerall = command != "holdfwd"
TriggerAll = Command != "holdup"
trigger1 = statetype != A
trigger1 = ctrl

;---------------------------------------------------------------------------
; Up Kick
[State -1, Up Kick]
type = ChangeState
value = 270
TriggerAll = Var(3) > 5
triggerall = command = "a"
TriggerAll = Command = "holdup"
triggerall = command != "holdfwd"
triggerall = command != "holddown"
trigger1 = statetype = S
trigger1 = ctrl
Trigger2 = StateNo = 40

;---------------------------------------------------------------------------
; Air Kick
[State -1, Air Kick]
type = ChangeState
value = 300
triggerall = command = "a"
TriggerAll = Command != "holdfwd"
triggerall = command != "holddown"
TriggerAll = Command != "holdup"
TriggerAll = Command != "holdback"
trigger1 = statetype = A
trigger1 = ctrl

;---------------------------------------------------------------------------
; Air Side Kick
[State -1, Air Side Kick]
type = ChangeState
value = 310
triggerall = command = "a"
TriggerAll = Command = "holdfwd"
triggerall = command != "holddown"
TriggerAll = Command != "holdup"
TriggerAll = Command != "holdback"
trigger1 = statetype = A
trigger1 = ctrl

;---------------------------------------------------------------------------
; Air Back Side Kick
[State -1, Air Back Side Kick]
type = ChangeState
value = 320
triggerall = command = "a"
TriggerAll = Command = "holdback"
TriggerAll = Command != "holdfwd"
triggerall = command != "holddown"
TriggerAll = Command != "holdup"
trigger1 = statetype = A
trigger1 = ctrl

;---------------------------------------------------------------------------
; Air Up Slap
[State -1, Air Up Slap]
type = ChangeState
value = 330
triggerall = command = "a"
TriggerAll = Command = "holdup"
TriggerAll = Command != "holdback"
TriggerAll = Command != "holdfwd"
triggerall = command != "holddown"
trigger1 = statetype = A
trigger1 = ctrl

;---------------------------------------------------------------------------
; Air Spin Kick
[State -1, Air Spin Kick]
type = ChangeState
value = 340
triggerall = command = "a"
triggerall = command = "holddown"
TriggerAll = Command != "holdup"
TriggerAll = Command != "holdback"
TriggerAll = Command != "holdfwd"
trigger1 = statetype = A
trigger1 = ctrl

;---------------------------------------------------------------------------
; Rollout
[State -1, Rollout]
type = ChangeState
value = 400
triggerall = command = "b"
TriggerAll = Command != "holdfwd"
triggerall = command != "holddown"
TriggerAll = Command != "holdup"
trigger1 = statetype != C
trigger1 = ctrl

;---------------------------------------------------------------------------
; Pound
[State -1, Pound]
type = ChangeState
value = 410
triggerall = command = "b"
TriggerAll = Command = "holdfwd"
triggerall = command != "holddown"
TriggerAll = Command != "holdup"
trigger1 = statetype != C
trigger1 = ctrl

;---------------------------------------------------------------------------
; Sing
[State -1, Sing]
type = ChangeState
value = 420
triggerall = command = "b"
TriggerAll = Command = "holdup"
TriggerAll = Command != "holdfwd"
triggerall = command != "holddown"
trigger1 = statetype != C
trigger1 = ctrl
Trigger2 = StateNo = 40

;---------------------------------------------------------------------------
; Rest
[State -1, Rest]
type = ChangeState
value = 430
triggerall = command = "b"
triggerall = command = "holddown"
TriggerAll = Command != "holdup"
TriggerAll = Command != "holdfwd"
trigger1 = ctrl

;---------------------------------------------------------------------------
; Grab
[State -1, Grab]
type = ChangeState
value = 500
triggerall = command = "x"
trigger1 = statetype != A
trigger1 = ctrl

;---------------------------------------------------------------------------
; Final Smash
[State -1, Final Smash]
type = ChangeState
value = 600
TriggerAll = Power >= 1000
triggerall = command = "y"
triggerall = command != "holddown"
TriggerAll = Command != "holdup"
trigger1 = statetype = S
trigger1 = ctrl

;---------------------------------------------------------------------------
; Song of Pain
[State -1, Song of Pain]
type = ChangeState
value = 700
TriggerAll = Power >= 1000
triggerall = command = "y"
TriggerAll = Command = "holdup"
TriggerAll = Command != "holdfwd"
TriggerAll = Command != "holdback"
triggerall = command != "holddown"
trigger1 = statetype = S
trigger1 = ctrl
Trigger2 = StateNo = 40

;---------------------------------------------------------------------------
; Song of Death
[State -1, Song of Death]
type = ChangeState
value = 800
TriggerAll = Power >= 1000
triggerall = command = "y"
triggerall = command = "holddown"
TriggerAll = Command != "holdup"
TriggerAll = Command != "holdfwd"
TriggerAll = Command != "holdback"
trigger1 = statetype != A
trigger1 = ctrl

;---------------------------------------------------------------------------
; Pikachu
[State -1, Pikachu]
Type = Helper
Trigger1 = RoundState = 2
Trigger1 = Alive
Trigger1 = Command = "z"
Trigger1 = Command != "holdback"
Trigger1 = Command != "holdfwd"
Trigger1 = Command != "holddown"
Trigger1 = Command != "holdup"
Trigger1 = Power >= 200
Trigger1 = NumHelper(1000) = 0
Trigger1 = NumHelper(1100) = 0
Trigger1 = NumHelper(1200) = 0
Trigger1 = NumHelper(1300) = 0
Trigger1 = StateNo != [600,604]
Trigger1 = StateNo != [700,701]
Trigger1 = StateNo != [800,801]
HelperType = Normal
Name = "Pikachu"
ID = 1000
Stateno = 1000
Pos = -50,0
PosType = Back
Facing = 1
KeyCtrl = 0
OwnPal = 1

;---------------------------------------------------------------------------
; Squirtle (Back)
[State -1, Squirtle (Back)]
Type = Helper
Trigger1 = RoundState = 2
Trigger1 = Alive
Trigger1 = Command = "z"
Trigger1 = Command = "holdfwd"
Trigger1 = Command != "holdback"
Trigger1 = Command != "holddown"
Trigger1 = Command != "holdup"
Trigger1 = Power >= 200
Trigger1 = NumHelper(1000) = 0
Trigger1 = NumHelper(1100) = 0
Trigger1 = NumHelper(1200) = 0
Trigger1 = NumHelper(1300) = 0
Trigger1 = StateNo != [600,604]
Trigger1 = StateNo != [700,701]
Trigger1 = StateNo != [800,801]
HelperType = Normal
Name = "Wave"
ID = 1103
Stateno = 1103
Pos = -50,0
PosType = Back
Facing = 1
KeyCtrl = 0
OwnPal = 1

;---------------------------------------------------------------------------
; Squirtle (Front)
[State -1, Squirtle (Front)]
Type = Helper
Trigger1 = RoundState = 2
Trigger1 = Alive
Trigger1 = Command = "z"
Trigger1 = Command = "holdback"
Trigger1 = Command != "holdfwd"
Trigger1 = Command != "holddown"
Trigger1 = Command != "holdup"
Trigger1 = Power >= 200
Trigger1 = NumHelper(1000) = 0
Trigger1 = NumHelper(1100) = 0
Trigger1 = NumHelper(1200) = 0
Trigger1 = NumHelper(1300) = 0
Trigger1 = StateNo != [600,604]
Trigger1 = StateNo != [700,701]
Trigger1 = StateNo != [800,801]
HelperType = Normal
Name = "Wave"
ID = 1103
Stateno = 1103
Pos = 50,0
PosType = Front
Facing = -1
KeyCtrl = 0
OwnPal = 1

;---------------------------------------------------------------------------
; Ivysaur
[State -1, Ivysaur]
Type = Helper
Trigger1 = RoundState = 2
Trigger1 = Alive
Trigger1 = Command = "z"
Trigger1 = Command = "holddown"
Trigger1 = Command != "holdback"
Trigger1 = Command != "holdfwd"
Trigger1 = Command != "holdup"
Trigger1 = Power >= 300
Trigger1 = NumHelper(1000) = 0
Trigger1 = NumHelper(1100) = 0
Trigger1 = NumHelper(1200) = 0
Trigger1 = NumHelper(1300) = 0
Trigger1 = StateNo != [600,604]
Trigger1 = StateNo != [700,701]
Trigger1 = StateNo != [800,801]
HelperType = Normal
Name = "Ivysaur"
ID = 1200
Stateno = 1200
Pos = -50,0
PosType = Back
Facing = 1
KeyCtrl = 0
OwnPal = 1

;---------------------------------------------------------------------------
; Charizard
[State -1, Charizard]
Type = Helper
Trigger1 = RoundState = 2
Trigger1 = Alive
Trigger1 = Command = "z"
Trigger1 = Command = "holdup"
Trigger1 = Command != "holddown"
Trigger1 = Command != "holdback"
Trigger1 = Command != "holdfwd"
Trigger1 = Power >= 400
Trigger1 = NumHelper(1000) = 0
Trigger1 = NumHelper(1100) = 0
Trigger1 = NumHelper(1200) = 0
Trigger1 = NumHelper(1300) = 0
Trigger1 = StateNo != [600,604]
Trigger1 = StateNo != [700,701]
Trigger1 = StateNo != [800,801]
HelperType = Normal
Name = "Charizard"
ID = 1300
Stateno = 1300
Pos = -200,-100
PosType = Back
Facing = 1
KeyCtrl = 0
OwnPal = 1
