[Data]
life=1000
attack=100
defence=100
power=6000
fall.defence_up=60
liedown.time=60
airjuggle=30
sparkno=2
guard.sparkno=40
volume=255
;echo = -1

[Size]
xscale=0.47
yscale=0.42
;z.width=3
ground.back=20        
ground.front=20       
air.back=12
air.front=11
height=0
;attack.width=0
attack.dist=160
proj.attack.dist=90
proj.doscale=0

[Movement]
airjump.num=0
airjump.height=1
yaccel=0.35
crouch.friction=0.8
stand.friction=0.8

[Velocity]
walk.fwd=2.4
walk.back=-2.2
run.fwd=8,0               
run.back=-4.5,-2.8
runjump.back=0,0
runjump.fwd=7,0
jump.neu=0,-8.0
jump.back=-2.3,0
jump.fwd=3.4,0
airjump.neu=0,-10
airjump.back=-5,-10
airjump.fwd=5,-10


;[-----------------------Force Feedback-----------------]
[State 5000, FFB Light]
type = ForceFeedback
trigger1 = anim = 5000 || anim = 5010
persistent = 0
time = 6
waveform = square

[State 5000, FFB Medium]
type = ForceFeedback
trigger1 = anim = 5001 || anim = 5011
persistent = 0
time = 8
waveform = sinesquare
ampl = 110,-1,-.3

[State 5000, FFB Hard]
type = ForceFeedback
trigger1 = anim = 5012 || anim = 5002 || anim = 5030
persistent = 0
time = 15
waveform = sinesquare
ampl = 140

;---------------------------------------------------------------------------

;super guard
;prova superguard
[Statedef 3675]
type    = S
physics = S

[State 3675, 1]
type = ChangeAnim
triggerall = var(1) = 0
trigger1 = Anim != 3675
value = 3675

[State 3675, 1]
type = ChangeAnim
triggerall = var(1) = 1
trigger1 = Anim != 3676
value = 3676

;-------------------------------------------
;reversal attack
[Statedef 1400]
type = S
physics = S
juggle = 5
velset = 0
ctrl = 0

[State 1400 , 1]
type = PlaySnd
trigger1 = animelem = 2
value = 40,0

[State 1400, 1]
type = ChangeAnim
triggerall = var(1) = 0
trigger1 = time = 0
value = 3675

[State 1400, 1]
type = ChangeAnim
triggerall = var(1) = 1
trigger1 = time = 0
value = 3676

[State 1400 , 4]
type = ReversalDef
trigger1 = time = 0
reversal.attr = SCA, NA, SA, HA
p1stateno = 1401
hitsound = S4,4
pausetime = 40,50
sparkxy = -100,20

[State 1400 , 7]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;-------------------------------------------------------
;new state of reversal attack
;reversal attack
[Statedef 1401]
type = S
movetype = A
physics = S
pos = 0,5
poweradd = 750
juggle = 5
velset = 0
ctrl = 0

[State 1400 , 1]
type = PlaySnd
trigger1 = time = 1
value = 1100,2

[State 1400 , 1]
type = PlaySnd
trigger1 = time = 1
value = 88888,0


[State 1401, 1]
type = ChangeAnim
triggerall = var(1) = 0
trigger1 = time = 0
value = 3675

[State 1401, 1]
type = ChangeAnim
triggerall = var(1) = 1
trigger1 = time = 0
value = 3676

[State 1400 , 1]
type = PlaySnd
trigger1 = time = 0
value = 5,1

[State 1401, light]
type = Explod
trigger1 = MoveContact
ID = 1401
anim = 1401
pos = 0,5
postype = p1
sprpriority = 4
supermove = 1
removetime = 70
ignorehitpause = 1
ownpal = 1
bindtime = -1
persistent = 0

[State 1401, polvere]
type = MakeDust
trigger1 = time = 0
pos = -15,3
pos2 = -22,-3
spacing = 2

[State 1401 , 2]
type = VelAdd
trigger1 = time = 0
x = -7;11

[State 1401 , 2]
type = VelMul
trigger1 = AnimElem = 1
x = 2.5

[State 1401 , 6]
type = ChangeState
triggerall = MoveContact
trigger1 = Life <= 300
;trigger1 = random > 250
value = 2160
ctrl = 0

[State 1401 , 7]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1
;-----------end reversal


; Grabbed and tossed by Close Throw (P2 State)
[Statedef 910]
type    = A
movetype= H
physics = N
ctrl = 0
velset = 0,0

[State 910, 1]
type = HitBy
Trigger1 = 1
value = SCA
time = 1

[State 910, 2]
type = HitFallSet
Trigger1 = Time = 0
value = 1

[State 910, 4]
type = ChangeAnim2
Trigger1 = Time = 0
value = 910

[State 910, 5]
type = PosAdd
Trigger1 = Time = 15
x = 30

[State 910, 6]
type = Turn
Trigger1 = Time = 20

[State 910, 7]
type = PosAdd
Trigger1 = Time = 20
x = -52
y = -5 

[State 910, 8]
type = PosAdd
Trigger1 = Time = 25
x = -39
y = 5

[State 910, 9]
type = LifeAdd
Trigger1 = Time = 28
value = -150

[State 910, 10]
type = PowerAdd
trigger1 = Time = 28
value = 70

[State 910, 11]
type = ChangeState
Trigger1 = Time = 30
value = 911

;---------------------------------------------------------------------------
; Flying Through the air!!! (P2 State)
[Statedef 911]
type    = A
movetype= H
physics = N

[State 911, Velocity Set]
type = VelSet
Trigger1 = Time = 0
x = -4
y = -9.5

[State 911, Velocity addition]
type = VelAdd
Trigger1 = 1
y = .35 

[State 911, Self State 1] 
type = SelfState
Trigger1 = ((Vel Y > 0) && (Pos Y > 25))
value = 5100

[State 911, Self State 2] 
type = SelfState
Triggerall = ((Vel Y > -1) && (Vel Y < 40) && (alive = 1) && (CanRecover = 1))
trigger1 = Command = "recovery"
value = 5210

[State 911, Change State]
type = ChangeState
triggerall = ((Vel Y > 0) && (Pos Y >= -20) && (alive = 1)  && (CanRecover = 1))
trigger1 = Command = "recovery"
value = 5200

;---------------------------------------------------------------------------


; Swing Throw P2 hit,caught,swing 
[Statedef 3124]
type    = L
movetype= H ;Get hit
physics = N
velset = 0,0

[State 3124, 1]
type = ChangeAnim2
Trigger1 = Time = 0
value = 3124

;---------------------------------------------------------------------------
; Swing throw flying through the air
[Statedef 3125]
type    = L
movetype= H ;Get hit
physics = N
velset = -5,-8

[State 3125, 2] ;Acceleration
type = VelAdd
Trigger1 = 1
y = .45

[State 3125, 3] ;Self's falling anim
type = ChangeAnim
Trigger1 = Time = 0
value = 5050

[State 3125, 3] ;Self's falling anim
type = ChangeAnim
Trigger1 = Time = 0
Trigger1 = AnimExist(5052)
value = 5052

[State 3125, 2] ;Coming down anim (normal fall type)
type = ChangeAnim
triggerall = anim != 5052 ;Not if in hit up anim
trigger1 = vel y >= 1
trigger1 = animexist(5060)
value = 5060
persistent = 0

[State 3125, 2] ;Coming down anim (hit up type)
type = ChangeAnim
triggerall = anim = 5052 ;Not if in hit up anim
trigger1 = vel y >= -2
trigger1 = animexist(5062)
value = 5062
persistent = 0

[State 3125, 4.1] ;Shake
type = EnvShake
trigger1 = vel y > 0
trigger1 = pos y >= 0
time = 18
ampl = 10

[State 3125, 4.2]
type = LifeAdd
trigger1 = vel y > 0
trigger1 = pos y >= 0
value = -40

[State 3125, 4.3] ;Hit ground
trigger1 = vel y > 0
trigger1 = pos y >= 0
type = SelfState
value = 5100

;---------------------------------------------------------------------------



;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------





;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------

;---------------------------------------------------------------------------
; Basic Attacks, Win Poses, etc...
;---------------------------------------------------------------------------
; Standing Light Punch 
[Statedef 200]
type    = S
movetype= A
physics = S
juggle  = 5
poweradd= 65
ctrl = 0
velset = 0,0
anim = 200
sprpriority = 2

[State 200, 1]
type = PlaySnd
trigger1 = Time = 2
value = 17503,2


[State 200, 2]
type = HitDef
trigger1 = Time = 0
attr = S, NA
animtype  = Medium
damage    = 60
guardflag = MA
pausetime = 12,12
sparkno = 1
sparkxy = -10,-60
hitsound   = S200,0
guardsound = S200,1
ground.type = high
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -6
air.hittime = 12
air.velocity = -2.2,-3.2

[State 200, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;------

[Statedef 201]
type    = S
movetype= A
physics = S
juggle  = 5
poweradd= 65
ctrl = 0
velset = 0,0
anim = 201
sprpriority = 2

[State 200, 1]
type = PlaySnd
trigger1 = Time = 2
value = 200,2

[State 200, 2]
type = HitDef
trigger1 = Time = 0
attr = S, NA
animtype  = Medium
damage    = 60
guardflag = MA
pausetime = 12,12
sparkno = 1
sparkxy = -10,-60
hitsound   = S200,0
guardsound = S200,1
ground.type = high
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -6
air.hittime = 12
air.velocity = -2.2,-3.2

[State 200, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1


;---------------------------------------------------------------------------
; Standing Medium Punch 

[Statedef 210]
type    = S
movetype= A
physics = S
juggle  = 5
poweradd= 65
ctrl = 0
velset = 0,0
anim = 9876
sprpriority = 3

[State 200, 1]
type = PlaySnd
trigger1 = Time = 2
value = 40,0

[State 210, 2]
type = HitDef
trigger1 = Time = 0
attr = S, NA
animtype  = Medium
damage    = 90
guardflag = MA
pausetime = 12,5
sparkno = 1
sparkxy = -10,-60
hitsound   = S220,0
guardsound = S200,1
ground.type = Low
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -6
air.hittime = 12
air.velocity = -2.2,-3.2

[State 210, 3]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1


;------

[Statedef 211]
type    = S
movetype= A
physics = S
juggle  = 5
poweradd= 65
ctrl = 0
velset = 0,0
anim = 211
sprpriority = 2

[State 200, 1]
type = PlaySnd
trigger1 = Time = 2
value = 40,0

[State 210, 2]
type = HitDef
trigger1 = Time = 0
attr = S, NA
animtype  = Medium
damage    = 90
guardflag = MA
pausetime = 12,5
sparkno = 1
sparkxy = -10,-60
hitsound   = S220,0
guardsound = S200,1
ground.type = Low
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -6
air.hittime = 12
air.velocity = -2.2,-3.2

[State 210, 3]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1



;---------------------------------------------------------------------------
; Standing Strong Punch
[Statedef 220]
type    = S
movetype= A
physics = S
juggle  = 5
poweradd= 65
ctrl = 0
velset = 0,0
anim = 220
sprpriority = 2

[State 220, 1]
type = PlaySnd
trigger1 = Time = 2
value = 1400, 1

[State 220, 2]
type = PlaySnd
trigger1 = Time = 2
value = 17503,2

[State 220, 2]
type = HitDef
trigger1 = Time = 0
attr = S, NA
animtype  = hard
damage    = 120
guardflag = MA
pausetime = 12,5
sparkno = 1
sparkxy = -10,-60
hitsound   = S240,0
guardsound = S200,1
ground.type = low
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -6
air.hittime = 12
air.velocity = -2.2,-3.2

[State 220, 3]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;------

[Statedef 221]
type    = S
movetype= A
physics = S
juggle  = 5
poweradd= 65
ctrl = 0
velset = 0,0
anim = 221
sprpriority = 2

[State 220, 1]
type = PlaySnd
trigger1 = Time = 2
value = 1400, 1

[State 220, 2]
type = HitDef
trigger1 = Time = 0
attr = S, NA
animtype  = Medium
damage    = 120
guardflag = MA
pausetime = 12,5
sparkno = 1
sparkxy = -10,-60
hitsound   = S240,0
guardsound = S200,1
ground.type = Low
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -6
air.hittime = 12
air.velocity = -2.2,-3.2

[State 220, 3]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1



;---------------------------------------------------------------------------

;---------------------------------------------------------------------------
; Standing Light Kick 
[Statedef 230]
type = S
movetype = A
physics = S
anim = 230
juggle = 1
velset = 0
ctrl = 0

[State 230 , 1]
type = PlaySnd
trigger1 = AnimElem = 2
value = 200,2

[State 9750, 1]
type = PlaySnd
trigger1 = Time = 1
value = 17503,0

[State 230 , 3]
type = HitDef
trigger1 = AnimElem = 3
priority = 4
attr = S, NA
damage = 70
getpower = 15
givepower = 7
animtype = Medium 
guardflag = MA
sparkxy = -10,-80
hitsound   = S200,0
guardsound = S200,1
pausetime = 12,12
ground.hittime = 13
ground.type = low
ground.slidetime = 9
ground.velocity = -5
air.velocity = -3,-3

[State 230 , 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

; Standing Light Kick 
[Statedef 231]
type = S
movetype = A
physics = S
anim = 231
juggle = 1
velset = 0
ctrl = 0

[State 231 , 1]
type = PlaySnd
trigger1 = AnimElem = 2
value = 200,2

[State 231 , 3]
type = HitDef
trigger1 = AnimElem = 3
priority = 4
attr = S, NA
damage = 70
getpower = 15
givepower = 7
animtype = Medium 
guardflag = MA
sparkxy = -10,-80
hitsound   = S200,0
guardsound = S200,1
pausetime = 12,12
ground.hittime = 13
ground.type = low
ground.slidetime = 9
ground.velocity = -5
air.velocity = -3,-3

[State 231 , 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1
;---------------------------------------------------------------------------
; Standing Medium Kick 
[Statedef 240]
type    = S
movetype= A
physics = S
juggle  = 5
poweradd= 65
ctrl = 0
velset = 0
anim = 240
sprpriority = 2

[State 240, 1]
type = PlaySnd
trigger1 = Animelem = 1
value = 40, 0

[State 240, 2]
type = PlaySnd
trigger1 = Time = 2
value = 17503,3

[State 240, 2]
type = HitDef
trigger1 = Time = 0
attr = S, NA
animtype  = light
damage    = 95
guardflag = MA
pausetime = 12,12
sparkno = 1
sparkxy = -10,-60
hitsound   = S220,0
guardsound = S200,1
ground.type = high
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -6
air.velocity = -2.2,-3.2

[State 240, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

; Standing Medium Kick 
[Statedef 241]
type    = S
movetype= A
physics = S
juggle  = 5
poweradd= 65
ctrl = 0
velset = 0
anim = 241
sprpriority = 2

[State 241, 1]
type = PlaySnd
trigger1 = Animelem = 1
value = 40, 0

[State 241, 2]
type = HitDef
trigger1 = Time = 0
attr = S, NA
animtype  = light
damage    = 95
guardflag = MA
pausetime = 12,12
sparkno = 1
sparkxy = -10,-60
hitsound   = S220,0
guardsound = S200,1
ground.type = high
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -6
air.velocity = -2.2,-3.2

[State 241, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
; Standing Strong Kick 
[Statedef 250]
type    = S
movetype= A
physics = S
juggle  = 5
poweradd= 65
ctrl = 0
velset = 0,0
anim = 250
sprpriority = 2

[State 250, 1]
type = PlaySnd
trigger1 = Time = 2
value = 1400, 1

[State 250, 2]
type = PlaySnd
trigger1 = Time = 2
value = 17503,3

[State 250, 2]
type = HitDef
trigger1 = Time = 0
attr = S, NA
animtype  = Medium
damage    = 120
guardflag = MA
pausetime = 12,12
sparkno = 1
sparkxy = -10,-60
hitsound   = S240,0
guardsound = S200,1
ground.type = high
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -6
air.velocity = -2.2,-3.2

[State 250, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

; Standing Strong Kick 
[Statedef 251]
type    = S
movetype= A
physics = S
juggle  = 5
poweradd= 65
ctrl = 0
velset = 0,0
anim = 251
sprpriority = 2

[State 251, 1]
type = PlaySnd
trigger1 = Time = 2
value = 1400, 1

[State 251, 2]
type = HitDef
trigger1 = Time = 0
attr = S, NA
animtype  = Medium
damage    = 120
guardflag = MA
pausetime = 12,12
sparkno = 1
sparkxy = -10,-60
hitsound   = S240,0
guardsound = S200,1
ground.type = high
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -6
air.velocity = -2.2,-3.2

[State 251, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
; Crouching Light Punch 
[Statedef 400]
type    = C
movetype= A
physics = C
juggle  = 6
poweradd= 50
ctrl = 0
anim = 400
sprpriority = 2

[State 400, 1]
type = PlaySnd
trigger1 = Time = 1
value = 200,2

[State 400, 2]
type = HitDef
trigger1 = AnimElem = 2
attr = C, NA
damage    = 60
animtype  = Medium
hitflag = MAF
guardflag = M
pausetime = 12,12
sparkno = 1
sparkxy = -10,-55
hitsound   = S200,0
guardsound = S200,1
ground.type = Low
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -4
air.velocity = -3,-4

[State 400, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

; Crouching Light Punch 
[Statedef 401]
type    = C
movetype= A
physics = C
juggle  = 6
poweradd= 50
ctrl = 0
anim = 401
sprpriority = 2

[State 400, 1]
type = PlaySnd
trigger1 = Time = 1
value = 200,2

[State 400, 2]
type = PlaySnd
trigger1 = Time = 2
value = 17503,1

[State 400, 2]
type = HitDef
trigger1 = AnimElem = 2
attr = C, NA
damage    = 60
animtype  = Medium
hitflag = MAF
guardflag = M
pausetime = 12,12
sparkno = 1
sparkxy = -10,-55
hitsound   = S200,0
guardsound = S200,1
ground.type = Low
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -4
air.velocity = -3,-4

[State 400, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1



;---------------------------------------------------------------------------
;Crouching Medium Punch
[Statedef 410]
type    = C
movetype= A
physics = C
juggle  = 6
poweradd= 50
ctrl = 0
anim = 410
sprpriority = 2

[State 410, 1]
type = PlaySnd
trigger1 = Time = 1
value = 40, 0

[State 410, 1]
type = PlaySnd
trigger1 = Time = 1
value = 17503,0

[State 410, 2]
type = HitDef
trigger1 = AnimElem = 2
attr = C, NA
damage    = 90
animtype  = Medium
hitflag = MAF
guardflag = M
pausetime = 12,12
sparkno = 1
sparkxy = -10,-55
hitsound   = S220,0
guardsound = S200,1
ground.type = Low
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -4
air.velocity = -3,-4

[State 410, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

;Crouching Medium Punch
[Statedef 411]
type    = C
movetype= A
physics = C
juggle  = 6
poweradd= 50
ctrl = 0
anim = 411
sprpriority = 2

[State 410, 1]
type = PlaySnd
trigger1 = Time = 1
value = 40, 0

[State 410, 2]
type = HitDef
trigger1 = AnimElem = 2
attr = C, NA
damage    = 90
animtype  = Medium
hitflag = MAF
guardflag = M
pausetime = 12,12
sparkno = 1
sparkxy = -10,-55
hitsound   = S220,0
guardsound = S200,1
ground.type = Low
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -4
air.velocity = -3,-4

[State 410, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

;---------------------------------------------------------------------------
;Crouching Strong Punch 
[Statedef 420]
type    = C
movetype= A
physics = S
juggle  = 15
poweradd= 60
velset = 0,0
anim = 420
ctrl = 0
sprpriority = 2

[State 550, pos]
type = Velset
trigger1 = time = 2
x = 4

[State 550, pos]
type = Velset
trigger1 = time = 4
x = 5

[State 550, pos]
type = Velset
trigger1 = animelem = 6
x = 14

[State 550, pos]
type = Velset
trigger1 = animelem = 7
x = 5

[State 550, pos]
type = Velset
trigger1 = animelem = 8
x = 2

[State 550, pos]
type = Velset
trigger1 = animelem = 9
x = 1

[State 420, Width]
type = Width
trigger1 = AnimElemTime(2) >= 0 && AnimElemTime(10) < 0
value = 5,0

[State 420, 1]
type = PlaySnd
trigger1 = AnimElem = 3
value = 1400, 1

[State 200, 1]
type = PlaySnd
trigger1 = Time = 2
value = 17503,3


[State 420, hit]
type = HitDef
trigger1 = AnimElem = 4
attr = S, SA
animtype  = Up
damage    = 90, 4
priority  = 5
guardflag = H
pausetime = 12,12
sparkxy = 0,-110
sparkno = s418
hitsound   = s1200,1
guardsound = 6,0
ground.type = high
ground.slidetime = 15
ground.hittime  = 18
ground.velocity = -1,-10.5
guard.velocity = -6
air.velocity = -1,-8.5
airguard.velocity = -4,-4.5
p2facing = 1
fall = 1
fall.recovertime = 50
yaccel = .4


[State 420, 5]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;Crouching Strong Punch 
[Statedef 421]
type    = C
movetype= A
physics = C
juggle  = 6
poweradd= 50
ctrl = 0
anim = 421
sprpriority = 2

[State 420, 1]
type = PlaySnd
trigger1 = Time = 1
value = 1400, 1

[State 420, 2]
type = HitDef
trigger1 = AnimElem = 2
attr = C, NA
damage    = 120
animtype  = Medium
hitflag = MAF
guardflag = M
pausetime = 12,12
sparkno = 1
sparkxy = -10,-55
hitsound   = S240,0
guardsound = S200,1
ground.type = Low
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -4
air.velocity = -3,-4

[State 420, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

;---------------------------------------------------------------------------
; Crouching Light Kick 
[Statedef 430]
type    = C
movetype= A
physics = C
juggle  = 5
poweradd= 22
ctrl = 0
anim = 430
sprpriority = 2

[State 430, 1]
type = PlaySnd
trigger1 = Time = 1
value = 200,2

[State 430, 2]
type = HitDef
trigger1 = Time = 0
attr = C, NA
damage    = 70
animtype  = Light
hitflag = MAFD
guardflag = L
pausetime = 12,12
sparkno = 0
sparkxy = -10,-8
hitsound   = S200,0
guardsound = S200,1
ground.type = Low
ground.slidetime = 6
ground.hittime  = 12
ground.velocity = -5
air.velocity = -2,-3
down.velocity = -5,0
down.hittime = 20

[State 430, 3]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

[Statedef 431]
type    = C
movetype= A
physics = C
juggle  = 5
poweradd= 22
ctrl = 0
anim = 431
sprpriority = 2

[State 431, 1]
type = PlaySnd
trigger1 = Time = 1
value = 200,2

[State 431, 2]
type = HitDef
trigger1 = Time = 0
attr = C, NA
damage    = 70
animtype  = Light
hitflag = MAFD
guardflag = L
pausetime = 12,12
sparkno = 0
sparkxy = -10,-8
hitsound   = S200,0
guardsound = S200,1
ground.type = Low
ground.slidetime = 6
ground.hittime  = 12
ground.velocity = -5
air.velocity = -2,-3
down.velocity = -5,0
down.hittime = 20

[State 431, 3]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

;---------------------------------------------------------------------------
; Crouching Medium Kick 
[Statedef 440]
type    = C
movetype= A
physics = C
juggle  = 5
poweradd= 22
ctrl = 0
anim = 440
sprpriority = 2

[State 440, 1]
type = PlaySnd
trigger1 = Time = 1
value = 40,0

[State 440, 2]
type = HitDef
trigger1 = Time = 0
attr = C, NA
damage    = 95
animtype  = Light
hitflag = MAFD
guardflag = L
pausetime = 12,12
sparkno = 0
sparkxy = -10,-8
hitsound   = S220,0
guardsound = S200,1
ground.type = Low
ground.slidetime = 6
ground.hittime  = 12
ground.velocity = -5
air.velocity = -2,-3
down.velocity = -5,0
down.hittime = 20

[State 440, 3]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

[Statedef 441]
type    = C
movetype= A
physics = C
juggle  = 5
poweradd= 22
ctrl = 0
anim = 441
sprpriority = 2

[State 441, 1]
type = PlaySnd
trigger1 = Time = 1
value = 40,0

[State 441, 2]
type = HitDef
trigger1 = Time = 0
attr = C, NA
damage    = 95
animtype  = Light
hitflag = MAFD
guardflag = L
pausetime = 12,12
sparkno = 0
sparkxy = -10,-8
hitsound   = S220,0
guardsound = S200,1
ground.type = Low
ground.slidetime = 6
ground.hittime  = 12
ground.velocity = -5
air.velocity = -2,-3
down.velocity = -5,0
down.hittime = 20

[State 441, 3]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

;---------------------------------------------------------------------------
; Crouching Strong Kick 
[Statedef 450]
type    = C
movetype= A
physics = C
poweradd= 60
ctrl = 0
anim = 450
sprpriority = 2
[State 550, pos]
type = Velset
trigger1 = time = 0
x = 3

[State 550, pos]
type = Velset
trigger1 = time = 2
x = 4

[State 550, pos]
type = Velset
trigger1 = time = 4
x = 5

[State 550, pos]
type = Velset
trigger1 = animelem = 3
x = 14

[State 550, pos]
type = Velset
trigger1 = animelem = 4
x = 5

[State 550, pos]
type = Velset
trigger1 = animelem = 5
x = 2

[State 550, pos]
type = Velset
trigger1 = animelem = 6
x = 1

[State 200, 1]
type = PlaySnd
trigger1 = animelem = 2
value = 1400, 1

[State 200, 1]
type = PlaySnd
trigger1 = Time = 2
value = 17503,3

[State 450, 3]
type = HitDef
triggerall = !MoveHit
trigger1 = animelem = 2
attr = C, NA
damage    = 120
animtype  = Light
hitflag = MA
guardflag = LA
pausetime = 0
sparkno = 2
sparkxy = -10,-55
hitsound   = S240,0
guardsound = S200,1
ground.type = Low
ground.slidetime = 6
ground.hittime  = 12
ground.velocity = -5
air.velocity = -2,-3
down.velocity = -5,0
down.hittime = 20
fall = 1

[State 450, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

[Statedef 451]
type    = C
movetype= A
physics = C
poweradd= 60
ctrl = 0
anim = 451
sprpriority = 2

[State 200, 1]
type = PlaySnd
trigger1 = animelem = 2
value = 1400, 1

[State 451, 3]
type = HitDef
triggerall = !MoveHit
trigger1 = animelem = 2
attr = C, NA
damage    = 120
animtype  = Light
hitflag = MA
guardflag = LA
pausetime = 0
sparkno = 2
sparkxy = -10,-55
hitsound   = S240,0
guardsound = S200,1
ground.type = Low
ground.slidetime = 6
ground.hittime  = 12
ground.velocity = -5
air.velocity = -2,-3
down.velocity = -5,0
down.hittime = 20
fall = 1

[State 451, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
; Jumping Medium Punch 
[Statedef 610]
type    = A
movetype= A
physics = A
juggle  = 4
poweradd= 65
ctrl = 0
sprpriority = 2


[State 610, 1]
type = changeanim
triggerall = var(1) = 0 
trigger1 = Time = 0
value = 610

[State 610, 1]
type = changeanim
triggerall = var(1) = 1 
trigger1 = Time = 0
value = 611

[State 610, 2]
type = PlaySnd
trigger1 = Time = 2
value = 40,0

[State 610, 1]
type = PlaySnd
trigger1 = Time = 1
value = 17503,4

[State 610, 3]
type = HitDef
trigger1 = Time = 0
attr = A, NA
damage = 90
guardflag = HA
priority = 4
pausetime = 12,12
sparkno = 1
sparkxy = -10,-55
hitsound   = S220,0
guardsound = S200,1
animtype = Med
ground.type = High
ground.slidetime = 17
ground.hittime  = 17
ground.velocity = -5
air.velocity = -3,-4

;---------------------------------------------------------------------------

; Jumping Light Punch

;---------------------------------------------------------------------------
; Jumping Medium Punch 
[Statedef 600]
type    = A
movetype= A
physics = A
juggle  = 4
poweradd= 65
ctrl = 0
sprpriority = 2


[State 600, 1]
type = changeanim
triggerall = var(1) = 0 
trigger1 = Time = 0
value = 600

[State 600, 1]
type = changeanim
triggerall = var(1) = 1 
trigger1 = Time = 0
value = 601

[State 600, 1]
type = PlaySnd
trigger1 = Time = 1
value = 40,0

[State 600, 2]
type = PlaySnd
trigger1 = Time = 2
value = 17503,0

[State 600, 3]
type = HitDef
trigger1 = Time = 0
attr = A, NA
damage = 90
guardflag = HA
priority = 4
pausetime = 12,12
sparkno = 1
sparkxy = -10,-55
hitsound   = S220,0
guardsound = S200,1
animtype = Med
ground.type = High
ground.slidetime = 17
ground.hittime  = 17
ground.velocity = -5
air.velocity = -3,-4

;---------------------------------------------------------------------------
; Jumping Strong Punch
[Statedef 620]
type    = A
movetype= A
physics = A
juggle  = 4
poweradd= 65
ctrl = 0
sprpriority = 2


[State 620, 1]
type = changeanim
triggerall = var(1) = 0 
trigger1 = Time = 0
value = 1970

[State 620, 1]
type = changeanim
triggerall = var(1) = 1 
trigger1 = Time = 0
value = 621

[State 620, 1]
type = PlaySnd
trigger1 = Time = 1
value = 17503,2

[State 620, 2]
type = PlaySnd
trigger1 = Time = 2
value = 40,0

[State 620, 3]
type = HitDef
trigger1 = AnimElem = 3
attr = S, NA
animtype  = Hard
damage    = 120
getpower  = 167
givepower = 30
priority = 6
pausetime = 10,12
sparkxy = -10,-74
sparkno = 3
guardflag = HA
yaccel = 0.4
hitsound   = S240,0
guardsound = S150,1
ground.type = High
ground.slidetime = 14
ground.hittime  = 14
ground.velocity = -5,-6
air.velocity = -5,-6
air.animtype = Back
fall = 1
fall.recover = 0


;---------------------------------------------------------------------------
; Jumping Light Kick 
[Statedef 630]
type    = A
movetype= A
physics = A
juggle  = 4
poweradd= 65
ctrl = 0
sprpriority = 2


[State 630, 1]
type = changeanim
triggerall = var(1) = 0 
trigger1 = Time = 0
value = 630

[State 630, 1]
type = changeanim
triggerall = var(1) = 1 
trigger1 = Time = 0
value = 631

[State 630, 2]
type = PlaySnd
trigger1 = Time = 2
value = 40,0

[State 200, 1]
type = PlaySnd
trigger1 = Time = 1
value = 17503,0

[State 630, 3]
type = HitDef
trigger1 = Time = 0
attr = A, NA
damage = 90
guardflag = HA
priority = 4
pausetime = 12,12
sparkno = 1
sparkxy = -10,-55
hitsound   = S220,0
guardsound = S200,1
animtype = Med
ground.type = High
ground.slidetime = 17
ground.hittime  = 17
ground.velocity = -5
air.velocity = -3,-4

;---------------------------------------------------------------------------
; Jumping Medium Kick 
[Statedef 640]
type    = A
movetype= A
physics = A
juggle  = 4
poweradd= 65
ctrl = 0
sprpriority = 2


[State 640, 1]
type = changeanim
triggerall = var(1) = 0 
trigger1 = Time = 0
value = 640

[State 640, 1]
type = changeanim
triggerall = var(1) = 1 
trigger1 = Time = 0
value = 641

[State 640, 2]
type = PlaySnd
trigger1 = Time = 2
value = 40,0

[State 640, 3]
type = HitDef
trigger1 = Time = 0
attr = A, NA
damage = 90
guardflag = HA
priority = 4
pausetime = 12,12
sparkno = 1
sparkxy = -10,-55
hitsound   = S220,0
guardsound = S200,1
animtype = Med
ground.type = High
ground.slidetime = 17
ground.hittime  = 17
ground.velocity = -5
air.velocity = -3,-4

;---------------------------------------------------------------------------
; Jumping Strong Kick
[Statedef 650]
type    = A
movetype= A
physics = A
juggle  = 4
poweradd= 65
ctrl = 0
sprpriority = 2


[State 650, 1]
type = changeanim
triggerall = var(1) = 0 
trigger1 = Time = 0
value = 650

[State 610, 1]
type = changeanim
triggerall = var(1) = 1 
trigger1 = Time = 0
value = 651

[State 650, 2]
type = PlaySnd
trigger1 = Time = 2
value = 40,0

[State 650, 3]
type = HitDef
trigger1 = Time = 0
attr = A, NA
damage = 90
guardflag = HA
priority = 4
pausetime = 12,12
sparkno = 1
sparkxy = -10,-55
hitsound   = S220,0
guardsound = S200,1
animtype = Med
ground.type = High
ground.slidetime = 17
ground.hittime  = 17
ground.velocity = -5
air.velocity = -3,-4

;C throw ATTEMPT
[Statedef 800]
type = S
movetype = A
physics = S
velset = 0,0
anim = 800
ctrl = 0

[State 800, 1]
type = HitDef
trigger1 = AnimElem = 1
attr = S, NT
priority = 2, miss
sparkno = -1
p2facing = 1
numhits = 0
p1stateno = 805
p2stateno = 810

[State 800, 2]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;C throw SUCCESS
[Statedef 805]
type = S
movetype = A
physics = S
velset = 0,0
ctrl = 0
anim = 805
sprpriority = 3




[State 311, Cancel Var]
type = varset
Trigger1 = Time = [0,7]
trigger1 = target, command = "x" || target, command = "y"
var(17) = 1

[State 301, Cancel]
type = changestate
Trigger1 = Time = [5,7]
trigger1 = var(17) = 1
value = 305

[State 301, Cancel]
type = targetstate
Trigger1 = Time = [5,7]
trigger1 = var(17) = 1
value = 306

[State 301, Cancel Var]
type = varset
Trigger1 = animtime = 0
var(17) = 0



[State 805, GrabSound]
type = PlaySnd
trigger1 = animelem = 2
value = 2,3
channel = 5

[State 701, 2]
type = explod
trigger1 = time = 0
anim = 890
pos = 0,-70
postype = p1
sprpriority = 3

[State 805, Invincibility]
type = NotHitBy
trigger1 = time >= 0
value = SCA

[State 805, Push]
type = PlayerPush
trigger1 = Time >= 0
value = 0

[State 805, Bind1]
type = TargetBind
trigger1 = animelem = 2, < 0
pos = 28,0

[State 805, Bind2]
type = TargetBind
trigger1 = animelem = 2, >= 0 && animelem = 3, < 0
pos = 32,-88

[State 805, Bind3]
type = TargetBind
trigger1 = animelem = 3, >= 0 && animelem = 4, < 0
pos = 42,-89

[State 805, Bind4]
type = TargetBind
trigger1 = animelem = 4, >= 0 && animelem = 6, < 0
pos = 48,-89

[State 805, Bind5]
type = TargetBind
trigger1 = animelem = 6, >= 0 && animelem = 8, < 0
pos = 40, -85

[State 805, Bind6]
type = TargetBind
trigger1 = animelem = 8, >= 0 && animelem = 10, < 0
pos = 35, -85

[State 805, Bind7]
type = TargetBind
trigger1 = animelem = 10, >= 0 && animelem = 11, < 0
pos = 51, -85

[State 805, Bind8]
type = TargetBind
trigger1 = animelem = 11, = 0
pos = 55, -33

[State 805, Combo]
type = HitAdd
trigger1 = animelem = 4
value = 1

[State 805, HitSound]
type = PlaySnd
trigger1 = AnimElem = 4
value = 1,2

[State 805, HitSound]
type = PlaySnd
trigger1 = time = 43
value = 2,1

[State 805, Hitspark]
type = Explod
trigger1 = AnimElem = 4
anim = F0
ontop = 1
postype = p1
pos = 54,-81
bindtime = 1

[State 805, Hitspark]
type = Explod
trigger1 = time = 43
anim = F2
ontop = 1
postype = p1
pos = 48,-89
bindtime = 1

[State 805, Move]
type = PosAdd
trigger1 = animelem = 12
trigger2 = animelem = 13
x = 8

[State 805, State]
type = ChangeState
trigger1 = animtime = 0
value = 0
ctrl = 1

;Hit by C throw
[Statedef 810]
type = A
movetype = H
physics = N
velset = 0
sprpriority = 0

[State 810, Invincibility]
type = NotHitBy
trigger1 = time >= 0
value = SCA

[State 810, ScreenBound]
type = ScreenBound
trigger1 = time < 47
movecamera = 0,0

[State 810, Anim]
type = ChangeAnim2
trigger1 = time = 0
value = 810

[State 860, Velocity]
type = VelSet
trigger1 = time = 47
x = -4.5
y = -5

[State 860, Gravity]
type = Gravity
trigger1 = time >= 47

[State 860, Anim]
type = ChangeAnim
trigger1 = time = 47
value = 5050

[State 860, Damage1]
type = LifeAdd
trigger1 = time = 47
value = -245

[State 860, State]
type = SelfState
trigger1 = Pos Y >= 0
trigger1 = Vel Y > 0
value = 5100

;D throw ATTEMPT
[Statedef 850]
type = S
movetype = A
physics = S
velset = 0,0
anim = 850
ctrl = 0

[State 850, 1]
type = HitDef
trigger1 = AnimElem = 1
attr = S, NT
priority = 2, miss
sparkno = -1
numhits = 0
snap = 28,0
p2facing = 1
p1stateno = 855
p2stateno = 860

[State 850, 2]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;D throw SUCCESS
[Statedef 855]
type = S
movetype = A
physics = S
velset = 0,0
ctrl = 0
anim = 855
sprpriority = 3


[State 311, Cancel Var]
type = varset
Trigger1 = Time = [0,7]
trigger1 = target, command = "x" || target, command = "y"
var(17) = 1

[State 301, Cancel]
type = changestate
Trigger1 = Time = [5,7]
trigger1 = var(17) = 1
value = 305

[State 301, Cancel]
type = targetstate
Trigger1 = Time = [5,7]
trigger1 = var(17) = 1
value = 306

[State 301, Cancel Var]
type = varset
Trigger1 = animtime = 0
var(17) = 0

[State 805, Width]
type = Width
trigger1 = time >= 0
edge = 0, 40

[State 805, GrabSound]
type = PlaySnd
trigger1 = animelem = 2
value = 2,3
channel = 5


[State 701, 2]
type = explod
trigger1 = time = 0
anim = 890
pos = 0,-70
postype = p1
sprpriority = 3

[State 805, Sound]
type = PlaySnd
trigger1 = animelem = 5
value = 4,1

[State 855, Invincibility]
type = NotHitBy
trigger1 = time >= 0
value = SCA

[State 855, Bind1]
type = TargetBind
trigger1 = animelem = 2, < 0
pos = 28,0

[State 855, Bind2]
type = TargetBind
trigger1 = animelem = 2, >= 0 && animelem = 3, < 0
pos = 14,-90

[State 855, Bind3]
type = TargetBind
trigger1 = animelem = 3, >= 0 && animelem = 4, < 0
pos = 12,-93

[State 855, Bind3]
type = TargetBind
trigger1 = animelem = 4, = 0
pos = -20,-90

[State 855, Move]
type = PosAdd
trigger1 = animelem = 7
trigger2 = animelem = 8
trigger3 = animelem = 9
trigger4 = animelem = 10
x = -8

[State 855, Turn]
type = Turn
trigger1 = animtime = -4

[State 855, State]
type = ChangeState
trigger1 = animtime = 0
value = 0
ctrl = 1

;Hit by D throw
[Statedef 860]
type = A
movetype = H
physics = N
velset = 0

[State 860, Invincibility]
type = NotHitBy
trigger1 = time >= 0
value = SCA

[State 860, ScreenBound]
type = ScreenBound
trigger1 = time < 19
movecamera = 0,0

[State 860, Anim]
type = ChangeAnim2
trigger1 = time = 0
value = 860

[State 860, Sprite2]
type = SprPriority
trigger1 = time >= 0 ;= [0,28]
value = 1

[State 860, Gravity]
type = VelAdd
trigger1 = time >= 19
y = .555556

[State 1420, Velocity]
type = VelSet
trigger1 = time = 19
x = 5
y = -7

[State 1420, Anim]
type = ChangeAnim
trigger1 = time = 19
value = 5050

[State 1420, Damage1]
type = LifeAdd
trigger1 = time = 19
value = -245

[State 1420, State]
type = SelfState
trigger1 = Pos Y >= 0
trigger1 = Vel Y > 0
value = 5100

;P1 Miss
[Statedef 305]
type    = S
movetype= I ;Get hit
physics = S
velset = -12,0
anim = 305
ctrl = 0

[State 810,]
type = PlaySnd
trigger1 = time = 0
value = F2,10

[State 810,]
type = posset
trigger1 = time = 0
y = 0

[State 305, Cancel]
type = targetstate
Trigger1 = time = 0
value = 306

[State 305, MD]
type = makedust
Trigger1 = 1
pos = 0,0
spacing = 3

[State 301, Cancel Var]
type = varset
Trigger1 = animtime = 0
var(17) = 0

[State 305, END]
type = changestate
Trigger1 = AnimTime = 0
value = 0
ctrl = 1

;P2 Counter
[Statedef 306]
type    = S
movetype= I ;Get hit
physics = S
velset = 0,0
ctrl = 0

[State 306, ANIM1]
type = posset
Trigger1 = time = 0
y = 0

[State 306, ANIM1]
type = changeanim
trigger1 = selfanimexist(306)
Trigger1 = time = 0
value = 306

[State 306, ANIM2]
type = changeanim
trigger1 = !selfanimexist(306)
trigger1 = selfanimexist(200)
Trigger1 = Time = 0
value = 200

[State 306, ANIM3]
type = changeanim
trigger1 = !selfanimexist(306)
trigger1 = !selfanimexist(200)
Trigger1 = Time = 0
value = 5000

[State 306, END]
type = selfstate
Trigger1 = AnimTime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------

[Statedef 170]
type = S
ctrl = 0
anim = 170
velset = 0,0

[State 170, 1]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1


;-------------------------------------------------------------------------
[Statedef 175]
type = S
ctrl = 0
anim = 175
velset = 0,0

[State 175, 1]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1

;---------------------------------------------------------------------------
;Win state decider
[Statedef 180]
type = S

[State 180]
type = VarRandom
trigger1 = Time = 0
v = 2
range = 0,99

[State 180]
type = ChangeState
triggerall = Var(7) = 0
trigger1 = Var(2) = [0,49]
value = 181

[State 180]
type = ChangeState
triggerall = Var(7) = 0
trigger1 = Var(2) = [50,99]
value = 182

[State 190, 4]
type = ChangeState
trigger1 = Var(7) = 1
value = 4042

[State 180, 9]
type = ChangeState
trigger1 = Var(7) = 2
value = 183

;---------------------------------------------------------------------------
;Win pose 1
[Statedef 181]
type = S
ctrl = 0
anim = 180
velset = 0,0

[State 181, Voce]
type = PlaySnd
trigger1 = AnimElem = 1
value = 5555,5555

[State 181, Assert]
type     = AssertSpecial
trigger1 = Time = [0,550]
flag     = roundnotover

[State 181, cosmo]
type = Explod
trigger1 = AnimElem = 1
pos = -2,0
anim = 182
sprpriority = -1
ownpal = 1
supermove = 1
removetime = -1
scale = 1.1,.98

[State 181]
type = PlaySnd
trigger1 = Animelem = 1
value = 5555,5555

[State 181]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1

;-------------------------------------------------------------------------
;Win pose 2
[Statedef 182]
type = S
ctrl = 0
anim = 181
velset = 0,0

[State 182, Voce]
type = PlaySnd
trigger1 = AnimElem = 1
value = 6666,6666

[State 182, Assert]
type     = AssertSpecial
trigger1 = Time = [0,550]
flag     = roundnotover

[State 182, cosmo]
type = Explod
trigger1 = AnimElem = 1
pos = -2,0
anim = 182
sprpriority = -1
ownpal = 1
supermove = 1
removetime = -1
scale = 1.1,.98

[State 182]
type = PlaySnd
trigger1 = Animelem = 9
value = 0, 0

[State 182]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1

;Win pose 3
[Statedef 183]
type = S
ctrl = 0
anim = 181
velset = 0,0

[State 192, Darken]
type = BGPalfx
trigger1 = Time = 10
ignorehitpause = 1
time = 700
mul = 100,100,100
sinadd = 34,56,67,80
add = 5,5,5
invertall = 0

[State 182, Voce]
type = PlaySnd
trigger1 = AnimElem = 1
value = 17,0

[State 182, Assert]
type     = AssertSpecial
trigger1 = Time = [0,525]
flag     = roundnotover

[State 182, cosmo]
type = Explod
trigger1 = AnimElem = 1
pos = -1,0
anim = 183
sprpriority = -1
ownpal = 1
supermove = 1
removetime = -1
scale = 1,.98

[State 182, polvere]
type = Explod
trigger1 = AnimElem = 4
pos = 0,0
anim = 461
sprpriority = -2
ownpal = 1
supermove = 1
removetime = -1

[State 182]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1

;===========================================================
;win Ultime Phoenix
[Statedef 4042]
type = S
ctrl = 0
anim = 81411
velset = 0,0

[State 182, Voce]
type = PlaySnd
trigger1 = AnimElem = 1
value = 4000,10

[State 182, Assert]
type     = AssertSpecial
trigger1 = Time = [0,525]
flag     = roundnotover

[State 182]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1

;---------------------------------------------------------------------------
;intro Cloth
[Statedef 191]
type = S
ctrl = 0
anim = 194
velset = 0,0

[State 191]
type = AssertSpecial
trigger1 = Time = [0,400]
flag = Intro

[state 191, cloth]
type = explod
trigger1 = animelem = 1
anim = 191
postype = p1
sprpriority = 1
pos = 70,-3

[state 195, sound]
type = playsnd
trigger1 = animelem = 2
value = 2000,0
channel=0

[state 191, cloth]
type = explod
trigger1 = animelem = 3
anim = 193
postype = p1
sprpriority = 1
pos = 0,0

[state 195, sound]
type = playsnd
trigger1 = animelem = 4
value = 3000,0


[State 191, 0]
type = PlaySnd
trigger1 = AnimElem = 6
value = 88888,1


[State 191,2]
type = AssertSpecial
trigger1 = time > 0
flag = intro

[State 192, 2]
type = ChangeState
trigger1 = AnimTime = -10
value = 0

;---------------------------------------------------------------------------
; Intro versus Seiya2
[Statedef 198]
type = S
ctrl = 0
anim = 4079
velset = 0,0

[State 198, 3]
type = AssertSpecial
trigger1 = 1
flag = Intro

[State 198, 4]
type = PlaySnd
trigger1 = AnimElem = 16
value = 191,1

[State 198, 4]
type = Explod
trigger1 = AnimElem = 43
anim = 3686
ID = 3686
pos = 0,0
postype = p1
sprpriority = -2
removetime = 75
ownpal = 1
bindtime = -1
persistent = 0

[State 198 , 5]
type = Explod
trigger1 = AnimElem = 44
id = 96
anim = 96
removetime = 70
sprpriority = 0
postype = p1
pos = 0,0
removeongethit = 1
bindtime = 1
ownpal = 1
supermove = 1

[State 198 , 6]
type = Explod
trigger1 = AnimElem = 44
id = 18506
anim = 18506
sprpriority = 0
postype = p1
pos = 0,0
bindtime = 1
removetime = 70
removeongethit = 1
ownpal = 1
supermove = 1

[State 198, 7]
type = ChangeState
trigger1 = AnimTime = 0
value = 0

; Intro versus Suzumiya Haruhi
[Statedef 255]
type = S
ctrl = 0
anim = 254
velset = 0,0

[State 255, 3]
type = AssertSpecial
trigger1 = 1
flag = Intro

[State 255, 4]
type = PlaySnd
trigger1 = AnimElem = 43
value = 2000,0

[State 191 , 6]
type = Explod
trigger1 = AnimElem = 5 = 6
anim = 3450
sprpriority = 1
postype = p1
pos = 0,0
removetime = 200
supermove = 1
ownpal = 1

[State 8000, light]
type = Explod
trigger1 = AnimElem = 7
anim = 7006
pos = 0,10
postype = p1
sprpriority = 2
ontop = 1
removetime = 50
ownpal = 1
supermove = 1


[State 255, 7]
type = ChangeState
trigger1 = AnimTime = 0
value = 0

;----------------------------------


;---------------------------------------------------------------------------

;-------------------------------------------------------
; Taunt controller
[Statedef 195]
type = S
ctrl = 0
velset = 0,0

[State 630, 1]
type = changestate
triggerall = var(1) = 0 
trigger1 = Time = 0
value = 196

[State 630, 1]
type = changestate
triggerall = var(1) = 1 
trigger1 = Time = 0
value = 197

;--------------------------------------------------------------------------

; Taunt 1
[Statedef 196]
type = S
ctrl = 0
anim=195
velset = 0,0
movetype = I
poweradd = 1000
physics = S
sprpriority = 2

[state 195, sound]
type = playsnd
trigger1 = animelem = 1
value = 910,0

[State 199 , 3]
type = ChangeState
trigger1 = command = "a"
trigger2 = command = "b"
trigger3 = command = "c"
trigger4 = command = "x"
trigger5 = command = "y"
trigger6 = command = "z"
trigger7 = command = "holdfwd"
trigger8 = command = "holdback"
trigger9 = command = "holdup"
trigger10 = command = "holddown"
value = 0
ctrl = 1

[State 196, 1]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

; Taunt 2
[Statedef 197]
type = S
ctrl = 0
anim=196
velset = 0,0
movetype = I
poweradd = 600
physics = S
sprpriority = 2

[state 195, sound]
type = playsnd
trigger1 = animelem = 1
value = 2020,0

[State 199 , 3]
type = ChangeState
trigger1 = command = "a"
trigger2 = command = "b"
trigger3 = command = "c"
trigger4 = command = "x"
trigger5 = command = "y"
trigger6 = command = "z"
trigger7 = command = "holdfwd"
trigger8 = command = "holdback"
trigger9 = command = "holdup"
trigger10 = command = "holddown"
value = 0
ctrl = 1

[State 197, 1]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1


;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
;---------------------------------------------------------------------------

;===========================================================================
[Statedef -2];  -2 State Section...
;===========================================================================
;---------------------------------------------------------------------------


[State -2,remove]
type = RemoveExplod
triggerall = NumExplod(2) = 1
trigger1 = stateno!= 0
ID = 2

[State -2,remove]
type = RemoveExplod
triggerall = NumExplod(2) = 1
trigger1 = anim =5
ID = 2
;Play "OWW!!" sound when hit
[State -2, 1]
type = PlaySnd
triggerall = ((Time = 1) && (var(8) < 500) && (random < 600))
trigger1 = (stateno = 5001) && (random < 500) 
value = 0, 1


[State -2, 1]
type = PlaySnd
triggerall = ((Time = 1) && (var(8) < 500) && (random < 600))
trigger1 = (stateno = 5040) && (random < 400) 
value = 0, 3

[State -2, 1]
type = PlaySnd
triggerall = ((Time = 1) && (var(8) < 500) && (random < 600))
trigger1 = (stateno = 5050)&& (random < 400) 
value = 0, 4


[State -2 , 1]
type = PlaySnd
triggerall = stateno = 20
trigger1 = AnimElem = 2
value = 0,0

[State -2 , 1]
type = PlaySnd
triggerall = stateno = 20
trigger1 = AnimElem = 5
value = 0,0

[State -2 , 1]
type = PlaySnd
triggerall = stateno = 21
trigger1 = AnimElem = 2
value = 0,0

[State -2 , 1]
type = PlaySnd
triggerall = stateno = 21
trigger1 = AnimElem = 5
value = 0,0

[State -2 , 1]
type = PlaySnd
triggerall = stateno = 100
trigger1 = AnimElem = 3
value = 0,0

[State -2 , 1]
type = PlaySnd
triggerall = stateno = 100
trigger1 = AnimElem = 6
value = 0,0



;===========================================================================
; Common1.cns Overide states...
;===========================================================================
;---------------------------------------------------------------------------
; Jump
[Statedef 50]
type    = A
physics = A

[State 180, 2]
type = PlaySnd
trigger1 = AnimElem = 1
value = 220, 2

[State 50, 1]
type = VarSet
trigger1 = Time = 0
sysvar(1) = 0

[State 50, VelSet]
type = VelSet
trigger1 = ((var(10) = 1) && (command = "holdfwd") && (command != "holdback"))
x = 3

[State 50, VelSet]
type = VelSet
trigger1 = ((var(10) = 1) && (command != "holdfwd") && (command = "holdback"))
x = -3

[State 50, 2]
type = ChangeAnim
triggerall = var(1) = 0
trigger1 = Time = 0
value = ifelse((vel x)=0, 41, ifelse((vel x)>0, 42, 43))

[State 50, 2]
type = ChangeAnim
triggerall = var(1) = 1
trigger1 = Time = 0
value = ifelse((vel x)=0, 61, ifelse((vel x)>0, 62, 63))

[State 50, 3]
type = ChangeAnim
trigger1 = (Vel y > -2 && SelfAnimExist(anim + 3))
persistent = 0
value = Anim + 3

;---------------------------------------------------------------------------
; Jump Land
[Statedef 52]
type    = S
physics = S
ctrl = 0

[State 52, 1]
type = changeanim
triggerall = var(1) = 0
trigger1 = time = 0
value = 47

[State 52, 1]
type = changeanim
triggerall = var(1) = 1
trigger1 = time = 0
value = 67

[State 52, VarSet]
type = VarSet
trigger1 = Time = 0
var(10) = 0

[State 52, 1]
type = VelSet
trigger1 = Time = 0
y = 0

[State 52, 2]
type = PosSet
trigger1 = Time = 0
y = 0

[State 180, 2]
type = PlaySnd
trigger1 = AnimElem = 1
value = 52, 0

[State 52, 3]
type = CtrlSet
trigger1 = Time = 3
value = 1

[State 52, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;-------------------------------------------------------
;counter
[Statedef 300]
type     = S
movetype = A
physics  = S
juggle   = ifelse(numprojID(2000)=1,8,15)
poweradd = 0
ctrl     = 0
velset   = 15,0
anim     = 8765
sprpriority = 3

[State 300,]
type = PowerAdd
trigger1 = prevstateno = [150,151]
trigger1 = time = 0
value = -1000

[State 300,]
type = NotHitBy
trigger1 = prevstateno = [150,151]
trigger1 = 1
value = SCA

[State 300, counter]
type = ChangeAnim
trigger1 = prevstateno = [150,151]
trigger1 = time = 0
value = 245

[state 300,]
type = Posset
trigger1 = time = 0
y = 0

[state 300,]
type = Posadd
triggerall = prevstateno = [150,151]
trigger1 = AnimElem = 1
x = 5

[state 300,]
type = Posadd
triggerall = prevstateno = [150,151]
trigger1 = AnimElem = 2
trigger2 = AnimElem = 3
x = 10

[state 300,]
type = Posadd
triggerall = prevstateno = [150,151]
trigger1 = AnimElem = 6
trigger2 = AnimElem = 7
trigger3 = AnimElem = 8
x = -10

[State 300,]
type = palfx
trigger1 = prevstateno = [150,151]
trigger1 = time = 0
time = 5
add = 230,230,230

[State 300,]
type = AfterImage
trigger1 = prevstateno = [150,151]
trigger1 = time = 0
time = 17
trans = add1
timegap = 2
framegap = 2
length = 5
palbright = 12,12,12
palcontrast = 220,220,220
palpostbright = 0,0,0
paladd = 0,0,0
palmul = 1,1,1

[State 300, counter]
type = HitDef
trigger1 = prevstateno = [150,151]
trigger1 = Time = 0
attr = S, NA
animtype  = Diagup
damage    = 10
pausetime = 14,16
sparkno = s4010
sparkxy = -20,-70
hitsound   = s1200,1
ground.type = High
ground.slidetime = 16
ground.hittime  = 18
ground.velocity = -5,-5
air.velocity = -5,-5
fall = 1
fall.recover = 0
kill = 0
ground.cornerpush.veloff = 0
air.cornerpush.veloff = 0

[State 300 , 1]
type = HitDef
trigger1 = prevstateno != [150,151]
trigger1 = time = 0
attr = S, NA
animtype  = Hard
damage    = 80
priority = 5
pausetime = 11,12
sparkno = 3
guard.sparkno = s4110
sparkxy = -20,-70
hitsound = s1200,1
hitflag = MAF
;guardflag = MA
guardsound = s2,1
ground.type = High
ground.slidetime = 14
ground.hittime  = 14
ground.velocity = -5,-5
air.velocity = -5,-5
air.animtype = Back
fall = 1
ground.cornerpush.veloff = 0
air.cornerpush.veloff = 0

[State 300, counter]
type = PlaySnd
trigger1 = AnimElem = 3
value = 1400, 1

[State 300, counter]
type = PlaySnd
trigger1 = prevstateno != [150,151]
trigger1 = AnimElem = 5
value = s10,12

[State 300, counter]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
;2counter
[Statedef 650]
type     = A
movetype = A
physics  = A
juggle   = ifelse(numprojID(2000)=1,8,15)
poweradd = 0
ctrl     = 0
anim     = 8765
sprpriority = 3

[State 240 , 1]
type = HitDef
trigger1 = time = 0
attr = A, NA
animtype  = Hard
damage    = 80
priority = 5
pausetime = 11,12
sparkno = s4010
guard.sparkno = s4110
sparkxy = -20,-60
hitsound = s1,4
hitflag = MAF
guardflag = MA
guardsound = s2,1
ground.type = High
ground.slidetime = 14
ground.hittime  = 14
ground.velocity = -5,-5
air.velocity = -5,-5
air.animtype = Back
fall = 1
ground.cornerpush.veloff = 0
air.cornerpush.veloff = 0

[State 200, 2counter]
type = PlaySnd
trigger1 = AnimElem = 5
value = s0,4

[State 300, 2counter]
type = PlaySnd
trigger1 = AnimElem = 5
value = s10,12

;---------------------------------------------------------------------------
;aircounter

[Statedef 669]
type    = A
movetype= A
physics = A
ctrl = 0
anim = 620
juggle  = 9 + var(13)

[State 669, aircounter]
type = PlaySnd
trigger1 = AnimElem = 3
value = 1400, 1

[State 669, aircounter]
type = PlaySnd
trigger1 = prevstateno != [150,151]
trigger1 = AnimElem = 5
value = s10,12

[State 650 , 1]
type = HitDef
trigger1 = AnimElem = 2
attr = S, NA
animtype  = Hard
damage    = 120
getpower  = 167
givepower = 30
priority = 6
pausetime = 10,12
sparkxy = -10,-74
sparkno = 3
;guardflag = HA
yaccel = 0.4
hitsound   = s1200,1
guardsound = S150,1
ground.type = High
ground.slidetime = 14
ground.hittime  = 14
ground.velocity = -5,-6
air.velocity = -5,-6
air.animtype = Back
fall = 1
fall.recover = 0

[State 650 , 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 50
ctrl = 1

;=======================================================
;Agarre Patada

[Statedef 8000]
type = S
movetype = A
physics = S
velset = 0,0
anim = 8010
ctrl = 0

[State 800, 1]
type = HitDef
trigger1 = AnimElem = 1
attr = S, NT
priority = 1, miss
sparkno = -1
p2facing = 1
numhits = 0
pausetime = 4,4
ground.slidetime = 9
ground.velocity = -8,0
air.velocity = -5,-6
p1stateno = 8005
p2stateno = 8010



[State 800, 2]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;C throw SUCCESS
[Statedef 8005]
type = S
movetype = A
physics = S
velset = 0,0
ctrl = 0
anim = 8005
sprpriority = 0



[State 311, Cancel Var]
type = varset
Trigger1 = Time = [0,7]
trigger1 = target, command = "x" || target, command = "y"
var(20) = 1

[State 301, Cancel]
type = changestate
Trigger1 = Time = [5,7]
trigger1 = var(20) = 1
value = 305

[State 301, Cancel]
type = targetstate
Trigger1 = Time = [5,7]
trigger1 = var(20) = 1
value = 306

[State 301, Cancel Var]
type = varset
Trigger1 = animtime = 0
var(20) = 0



[State 805, GrabSound]
type = PlaySnd
trigger1 = animelem = 2
value = 17503,3
channel = 5

[State 805, GrabSound]
type = PlaySnd
trigger1 = animelem = 12
value = 17503,2
channel = 5

[State 701, 2]
type = explod
trigger1 = time = 0
anim = 890
pos = 0,-70
postype = p1
sprpriority = 3

[State 805, Invincibility]
type = NotHitBy
trigger1 = time >= 0
value = SCA

[State 805, Push]
type = PlayerPush
trigger1 = Time >= 0
value = 0

[State 805, Bind1]
type = TargetBind
trigger1 = animelem = 2, < 0
pos = 28,0

[State 805, Bind2]
type = TargetBind
trigger1 = animelem = 2, >= 0 && animelem = 3, < 0
pos = 32,-88

[State 805, Bind3]
type = TargetBind
trigger1 = animelem = 3, >= 0 && animelem = 4, < 0
pos = 42,-89

[State 805, Bind4]
type = TargetBind
trigger1 = animelem = 4, >= 0 && animelem = 6, < 0
pos = 48,-89

[State 805, Bind5]
type = TargetBind
trigger1 = animelem = 6, >= 0 && animelem = 8, < 0
pos = 40, -85

[State 805, Bind6]
type = TargetBind
trigger1 = animelem = 8, >= 0 && animelem = 10, < 0
pos = 35, -85

[State 805, Bind7]
type = TargetBind
trigger1 = animelem = 10, >= 0 && animelem = 11, < 0
pos = 51, -85

[State 805, Bind8]
type = TargetBind
trigger1 = animelem = 11, = 0
pos = 400, -33

[State 805, Combo]
type = HitAdd
trigger1 = animelem = 12
value = 1


[State 805, HitSound]
type = PlaySnd
trigger1 = AnimElem = 4
value = 1,2

[State 805, HitSound]
type = PlaySnd
trigger1 = time = 43
value = 2,1

[State 805, Hitspark]
type = Explod
trigger1=AnimElem = 1
trigger2=AnimElem = 2
trigger3=AnimElem = 3
trigger4=AnimElem = 4
trigger5=AnimElem = 5
trigger6=AnimElem = 6
trigger7=AnimElem = 7
anim = 800500
Scale= 0.35,0.35
ontop = 1
postype = p1
pos = 95,-89
bindtime = 60

[State 805, Hitspark]
type = Explod
trigger1=AnimElem = 7
trigger2=AnimElem = 9
anim = 800500
Scale= 0.60,0.60
ontop = 1
postype = p1
pos = 95,-89
bindtime = 60


[State 805, Move]
type = PosAdd
trigger1 = animelem = 12
trigger2 = animelem = 13
x = 8

[State 805, State]
type = ChangeState
trigger1 = animtime = 0
value = 0
ctrl = 1

;Hit by C throw
[Statedef 8010]
type = A
movetype = H
physics = N
velset = 0
sprpriority = 0

[State 810, Invincibility]
type = NotHitBy
trigger1 = time >= 0
value = SCA

[State 810, ScreenBound]
type = ScreenBound
trigger1 = time < 47
movecamera = 0,0

[State 810, Anim]
type = ChangeAnim2
trigger1 = time = 0
value = 810

[State 860, Velocity]
type = VelSet
trigger1 = time = 47
x = -4.5
y = -5

[State 860, Gravity]
type = Gravity
trigger1 = time >= 47

[State 860, Anim]
type = ChangeAnim
trigger1 = time = 47
value = 5050

[State 860, Damage1]
type = LifeAdd
trigger1 = time = 47
value = -125

[State 860, State]
type = SelfState
trigger1 = Pos Y >= 0
trigger1 = Vel Y > 0
value = 5100