;===========================================================================
;Marvel vs. Capcom - Eternity of Heroes - Constants Template V.5
;by REDHOT, Acey & eSkRo
;===========================================================================
[Data]
life = 1000
attack = 130
defence = 100
fall.defence_up = 50
liedown.time = 50
airjuggle = 15
sparkno = 2
guard.sparkno = 40
KO.echo = 0
volume = 555
IntPersistIndex = 60
FloatPersistIndex = 40

[Size]
xscale = 1
yscale = 1
ground.back = 20
ground.front = 20
air.back = 18
air.front = 22
height = 60
attack.dist = 160
attack.width = 4,4   
proj.dist = 90
proj.attack.dist = 90 
proj.doscale = 0
head.pos = 1, -83
mid.pos = 1, -53
shadowoffset = 0
draw.offset = 0,0

[Velocity]
walk.fwd = 3.6
walk.back = -2.7
run.fwd = 6
run.back = -4,-5
jump.neu = 0,-9.0
jump.back = -3.7
jump.fwd = 3.2
runjump.fwd = 4.4
runjump.back = -4.4
airjump.neu = 0, -8.9
airjump.fwd = 2.5
airjump.back = -2.55

[Movement]
airjump.num = 0
airjump.height = 35
yaccel = .45
stand.friction = .80
crouch.friction = .80
air.friction = .80

;---------------------------------------------------------------------------
; RUN_FWD
[Statedef 100]
type    = S
physics = N
anim = 100
sprpriority = 1
velset = 7, 0

[State 100, 1] ;Prevent run from canceling into walk
type = AssertSpecial
trigger1 = 1
flag = NoWalk

[State 100, 2] ;Prevent from turning
type = AssertSpecial
trigger1 = 1
flag = NoAutoTurn

[State 100, 3]
type = PlaySnd
trigger1 = time = 3
value = 1100,1
channel = 0

[State 100, 4]
type = PlaySnd
trigger1 = time = 19
value = 8100,0

[State 100, 5]
type = PlaySnd
trigger1 = AnimElem = 7
value = 2, 4

[State 100, 6]
type = Explod
trigger1 = time < 15
trigger1 = (time % 4) = 1
ID = 41
anim = 2222
postype = p1
pos = -20, -40
bindtime = 1
removetime = -2
vel = -1, 0
ownpal = 1
random = 20, 60
sprpriority = 2

[State 100, 7]
type = Explod
trigger1 = time < 15
trigger1 = (time % 4) = 0
ID = 42
anim = 2222
postype = p1
pos = -20, -40
bindtime = 1
removetime = -2
vel = -.8, 0
ownpal = 1
random = 20, 60
sprpriority = 2

[State 100, 8]
type = VelAdd
triggerall = Vel X > 0
trigger1 = time > 15
x = -.3

[State 100, 9]
type = Explod
trigger1 = time = [16,35]
trigger1 = (time % 4) = 0
ID = 43
anim = 8500
postype = p1
pos = 10, 0
bindtime = 1
removetime = -2
vel = -.2, 0
ownpal = 1
sprpriority = 2 

[State 100, 10]
type = ChangeState
trigger1 = AnimTime = 0
value = 0

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


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


;---------------------------------------------------------------------------------------------
;Win Poses

[Statedef 180]
type = S

[State 180, 1]
type = VarRandom
trigger1 = Time = 0
v = 1
range = 0,400

[State 180, 2]
type = ChangeState
trigger1 = Var(1) = [0,100]
value = 181

[State 180, 3]
type = ChangeState
trigger1 = Var(1) = [101,200]
value = 182

[State 180, 4]
type = ChangeState
trigger1 = Var(1) = [201,300]
value = 183

[State 180, 5]
type = ChangeState
trigger1 = Var(1) = [301,400]
value = 184
;---------------------------------------------------------------------------------------------
;Win Pose 1

[Statedef 181]
type = S
movetype = I
physics = S
ctrl = 0
anim = 181
velset = 0,0

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

;---------------------------------------------------------------------------------------------
;Win Pose 2

[Statedef 182]
type = S
movetype = I
physics = S
ctrl = 0
anim = 182
velset = 0,0

[State 182, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1
;---------------------------------------------------------------------------------------------
;Win Pose 3

[Statedef 183]
type = S
movetype = I
physics = S
ctrl = 0
anim = 183
velset = 0,0

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

;---------------------------------------------------------------------------------------------
;Introductions

[Statedef 190]
type = S

[State 190, 1]
type = VarRandom
trigger1 = Time = 0
v = 1
range = 0,200

[State 190, 2]
type = ChangeState
trigger1 = Var(1) = [0,200]
value = 191

[State 190, 3]
type = ChangeState
trigger1 = Var(1) = [201,400]
value = 192

;---------------------------------------------------------------------------------------------
;Teleport In
[Statedef 191]
type = S
movetype = I
physics = N
ctrl = 0
anim = 191
velset = 0,0
spriority = 0

[State 0, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = Intro

[State 0, ScreenBound]
type = ScreenBound
trigger1 = 1
value = 1
movecamera = 0,0
;ignorehitpause =
;persistent =


[State 0, PosSet]
type = PosSet
trigger1 =time = 0
y = -500
;ignorehitpause =
;persistent =

[State 0, VelSet]
type = VelSet
trigger1 = time = 0
y = 10
;ignorehitpause =
;persistent =

[State 0, ChangeAnim]
type = ChangeAnim
trigger1 = pos y >= -2
value = 190
;elem = 1
;ignorehitpause =
persistent = 0

[State 0, PosSet]
type = PosSet
trigger1 = anim = 190
y = 0
;ignorehitpause =
;persistent =
[State 0, VelSet]
type = VelSet
trigger1 = anim = 190
x = 0
y = 0
;ignorehitpause =
;persistent =


[State 0, PlaySnd]
type = PlaySnd
trigger1 = animelemtime(7) = 15
value = S190,0
volume = 0
channel = -1
;lowpriority = -1
freqmul = 1.0
loop = 0
pan = 0
;abspan =
;ignorehitpause =
;persistent =

[State 0, Explod]
type = Explod
trigger1 = anim = 190 && animelem = 1
anim =  6010
ID = 6010
pos = 15,-28
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
removetime = -2
ontop = 1
ownpal = 1
removeongethit = 1

[State 0, Explod]
type = Explod
trigger1 = anim = 190 && animelem = 6
anim =  6009
ID = 6009
pos = 11,-48
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
removetime = -2
ontop = 1
ownpal = 1
removeongethit = 1

[State 0, Explod]
type = Explod
trigger1 = anim = 190 && animelem = 6
anim =  6010
ID = 6010
pos = 11,-48
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
removetime = -2
ontop = 1
ownpal = 1
removeongethit = 1




[State 0, EnvColor]
type = EnvColor
trigger1 = anim = 190 && animelem = 1
trigger2 = anim = 190 && animelem = 6
value = 255,255,255
time = 2
;under = 0
;ignorehitpause =
persistent = 1







[State 190, ChangeState]
type = ChangeState
trigger1 = AnimTime = 0
value = 193


;---------------------------------------------------------------------------------------------
;Intro2
[Statedef 192]
type = S
movetype = I
physics = N
ctrl = 0
anim = 191
velset = 0,0
spriority = 0

[State 0, VarSet]
type = VarRandom
trigger1 = time =0
v = 1
range = 6,8

[State 0, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = Intro

[State 190, ChangeState]
type = ChangeState
trigger1 = AnimTime = 0
value = 193

[State F]
type = destroyself
trigger1 = stateno = 193

;-----------------------------------------------
[Statedef 193]; Move around before match
type = S
physics =S
sprpriority = 0

[State 0]
type = varset
trigger1 = time = 1
var(50) = 0

[State 0]
type = posset
trigger1 = 1
y = 0

[State 0]
type = VelSet
trigger1 = Time = 0
y = 0

[State 20, 1]
type = VelSet
trigger1 = command = "holdfwd"
x = 2.4

[State 20, 2]
type = VelSet
trigger1 = command = "holdback"
x = -2.0

[State 2]
type = ChangeAnim
trigger1 = command = "holdfwd"
trigger1 = Anim != 20
value = 20

[State 2]
type = ChangeAnim
trigger1 = command = "holdback"
trigger1 = Anim != 21
value = 21

[State 2]
type = ChangeAnim
trigger1 = command != "holdback"
trigger1 = command != "holdfwd"
trigger1 = Anim != 0
value = 0

[State 20, 2]
type = VelSet
trigger1 = command != "holdback"
trigger1 = command != "holdfwd"
x = 0

[State var]
type = VarSet
trigger1 = roundstate != 2
var(9) = floor(pos x)

[State F]
type = posset
trigger1 = roundstate = 2
trigger1 = var(9) != 0
x = var(9)

[State F]
type = varset
trigger1 = roundstate = 2
var(9) = 0

[State F]
type = changestate
trigger1 = ctrl
value = ifelse((command = "holdfwd") || (command ="holdback"),20,0)

;---------------------------------------------------------------------------------------------
;Taunt

[Statedef 195]
type = A
movetype = I
physics = N
ctrl = 0
anim = 195
velset = 0,0
sprpriority = 0

[State 195, VarSet]
type = VarRandom
trigger1 = time =0
v = 28
range = 6,8

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


;---------------------------------------------------------------------------
;Basic Attacks
;---------------------------------------------------------------------------

;---------------------------------------------------------------------------
; Standing Light Punch

[Statedef 200]
type    = S
movetype= A
physics = S
juggle  = 4
ctrl = 0
anim = 200
poweradd = 15
sprpriority = 2

[State 200, VelMul, corrida]
type = VelMul
trigger1 = Time = 0
trigger1 = PrevStateNo = 100
x = .8

[State 200, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 8400,0

[State 200, HitDef]
type = HitDef
trigger1 = animelem = 3
trigger2 = animelem = 5
attr = S,NA
damage = 15,1
animtype = Light
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 5,10
sparkno = s7770
sparkxy = -10, -35
guard.sparkno = s6767
hitsound = 5,0
guardsound = 6,0
ground.type = High
ground.slidetime = 15
ground.hittime  = 15
ground.velocity = -1
air.type = Low
air.hittime = 15
air.velocity = -6,-5
envshake.time = 1
envshake.ampl = 1

[State 0, Explod]
type = Explod
trigger1 = animelem = 3
anim = 201
ID =201
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 0
ignorehitpause =0
;persistent =



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

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

[Statedef 210]
type    = S
movetype= A
physics = S
juggle  = 4
ctrl = 0
anim = 210
poweradd = 35
sprpriority = 2

[State 210, VelMul, corrida]
type = VelMul
trigger1 = Time = 0
trigger1 = PrevStateNo = 100
x = .8

[State 210, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 8400,1

[State 210, HitDef]
type = HitDef
trigger1 = AnimElem = 3
attr = S,NA
damage = 25,1
animtype = Medium
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 10,14
sparkno = s7771
sparkxy = -5,-35
guard.sparkno = s6767
hitsound = 5,1
guardsound = 6,0
ground.type = Low
ground.slidetime = 15
ground.hittime  = 15
ground.velocity = -6
air.type = Low
air.hittime = 15
air.velocity = -6,-5
envshake.time = 1
envshake.ampl = 1

[State 0, Explod]
type = Explod
trigger1 = animelem = 2
anim = 211
ID =211
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 0
ignorehitpause =0
;persistent =

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

;---------------------------------------------------------------------------
; Close Medium Punch

[Statedef 211]
type    = S
movetype= A
physics = S
juggle  = 4
ctrl = 0
anim = 211
poweradd = 35
sprpriority = 2

[State 211, VelMul, corrida]
type = VelMul
trigger1 = Time = 0
trigger1 = PrevStateNo = 100
x = .8

[State 211, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 8400,1

[State 211, HitDef]
type = HitDef
trigger1 = AnimElem = 2
attr = S,NA
damage = 25,1
animtype = Medium
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 13,14
sparkno = s7771
sparkxy = -10,-60
guard.sparkno = s6767
hitsound = 5,1
guardsound = 6,0
ground.type = High
ground.slidetime = 15
ground.hittime  = 15
ground.velocity = -6
air.type = Low
air.hittime = 15
air.velocity = -6,-5
envshake.time = 1
envshake.ampl = 1

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

;---------------------------------------------------------------------------
; Standing Heavy Punch
[Statedef 220]
type    = S
movetype= A
physics = S
juggle  = 4
ctrl = 0
anim = 220
poweradd = 55
sprpriority = 2

[State 220, VelMul, corrida]
type = VelMul
trigger1 = Time = 0
trigger1 = PrevStateNo = 100
x = .8

[State 220, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 250,0

[State 220, HitDef]
type = HitDef
trigger1 = AnimElem = 4
attr = S,NA
damage = 35,1
animtype = High
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 5,14
sparkno = s7772
sparkxy = -10, -60
guard.sparkno = s6767
hitsound = s8000,1
guardsound = 6,0
ground.type = High
ground.slidetime = 18
ground.hittime  = 18
ground.velocity = -10
air.type = Low
air.hittime = 18
air.velocity = -6,-7
envshake.time = 2
envshake.ampl = 2

[State 0, Explod]
type = Explod
trigger1 = animelem = 1
anim = 6000
ID =6000
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 0
ignorehitpause =0
;persistent =

[State 0, Explod]
type = null
trigger1 = animelem = 3
anim = 6001
ID =6001
pos = 10,-25
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = 1
vel = 1,0
accel = .5,0
random = 0,0
removetime = 100
supermove
pausemove
scale = .5,.5
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 0
ignorehitpause =0
;persistent =

[State 0, Helper]
type = Helper
trigger1 = animelem = 3
helpertype = normal ;player
name = "bustershot"
ID =  221
stateno = 221
pos = 10,-25
postype = p1    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 1
supermove
pausemove
size.xscale =.5
size.yscale =.5
;size.ground.back (int)
;size.ground.front (int)
;size.air.back (int)
;size.air.front (int)
;size.height (int)
;size.proj.doscale (int)
;size.head.pos (int,int)
;size.mid.pos (int,int)
;size.shadowoffset (int)
;ignorehitpause =
;persistent =


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

;---------------------------------------------------------------------------
;Buster Shot
[Statedef 221]
type    = S
movetype= A
physics = N
juggle  = 4
ctrl = 0
anim = 6001
poweradd = 55
sprpriority = 2
velset = 10,0


[State 221, HitDef]
type = HitDef
trigger1 = time
attr = S,NP
damage = 9,1
animtype = High
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 0,2
sparkno = s7772
sparkxy = 0, 0
guard.sparkno = s6767
hitsound = S8000,0
guardsound = 6,0
ground.type = Low
ground.slidetime = 18
ground.hittime  = 18
ground.velocity = -10
air.type = Low
air.hittime = 18
air.velocity = -6,-7
envshake.time = 2
envshake.ampl = 2

[State 0, DestroySelf]
type = DestroySelf
trigger1 = time>= 100
trigger2 = movecontact
ignorehitpause = 1
;persistent =


;---------------------------------------------------------------------------------------------
;Standing light kick

[Statedef 230]
type    = S
movetype= A
physics = S
juggle  = 4
ctrl = 0
anim = 230
poweradd = 15
sprpriority = 2

[State 230, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 8000,7

[State 230, VelMul, corrida]
type = VelMul
trigger1 = Time = 0
trigger1 = PrevStateNo = 100
x = .8

[State 0, Explod]
type = Explod
trigger1 =  animelem = 4
anim = 231
ID =  231
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 1
ignorehitpause = 1
;persistent =

[State 230, HitDef]
type = HitDef
trigger1 = time = 0
attr = S,NA
damage = 15,1
animtype = Light
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 1,14
sparkno = s7770
sparkxy = -10, -30
guard.sparkno = s6767
hitsound = s8000,8
guardsound = 6,0
ground.type = Low
ground.slidetime = 10
ground.hittime = 10
ground.velocity = -3,0
air.type = Low
air.hittime = 3
air.velocity = -5,0

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

;---------------------------------------------------------------------------------------------
;Standing medium kick

[Statedef 240]
type    = S
movetype= A
physics = S
juggle  = 4
ctrl = 0
anim = 240
poweradd = 35
sprpriority = 2


[State 240, VelMul, corrida]
type = VelMul
trigger1 = Time = 0
trigger1 = PrevStateNo = 100
x = .8



[State 240, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 8000,6

[State 0, Explod]
type = Explod
trigger1 =  animelem = 2
anim = 253
ID =  253
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 1
ignorehitpause = 1
;persistent =

[State 240, HitDef]
type = HitDef
trigger1 = AnimElem = 4
attr = S,NA
damage = 35,1
animtype = Medium
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 1,14
sparkno = s7771
sparkxy = -10,-35
guard.sparkno = s6767
hitsound = s8000,8
guardsound = 6,0
ground.type = Low
ground.slidetime = 12
ground.hittime = 12
ground.velocity = -5,0
air.type = Low
air.hittime = 5
air.velocity = -5,0

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

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


;---------------------------------------------------------------------------------------------
;Standing Saber Attack
[Statedef 250]
type    = S
movetype= A
physics = S
juggle  = 4
ctrl = 0
anim = 250
poweradd = 55
sprpriority = 2

[State 250, VelMul, corrida]
type = VelMul
trigger1 = Time = 0
trigger1 = PrevStateNo = 100
x = .8

[State 250, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 2
value = 8000,6

[State 250, HitDef]
type = HitDef
trigger1 = AnimElem = 3
attr = S,NA
damage = 55,1
animtype = High
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 1,14
sparkno = s7772
sparkxy = -10, -40
guard.sparkno = s6767
hitsound = s8000,8
guardsound = 6,0
ground.type = High
ground.slidetime = 13
ground.hittime = 13
ground.velocity = -8,0
air.type = Low
air.hittime = 5
air.velocity = -7,0
ground.cornerpush.veloff =0

[State 0, Explod]
type = Explod
trigger1 =  animelem = 2
anim = 251
ID =  251
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = 1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 1
ignorehitpause = 1
;persistent =


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

;---------------------------------------------------------------------------------------------
;2nd Saber Attack
[Statedef 251]
type    = S
movetype= A
physics = S
juggle  = 4
ctrl = 0
anim = 252
poweradd = 55
sprpriority = 2

[State 251, VelMul, corrida]
type = VelMul
trigger1 = Time = 0
trigger1 = PrevStateNo = 100
x = .8

[State 251, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 8000,7

[State 251, HitDef]
type = HitDef
trigger1 = time = 0
attr = S,NA
damage = 45,1
animtype = High
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 1,14
sparkno = s7772
sparkxy = -10, -45
guard.sparkno = s6767
hitsound = s8000,8
guardsound = 6,0
ground.type = High
ground.slidetime = 13
ground.hittime = 13
ground.velocity = -8,0
air.type = Low
air.hittime = 5
air.velocity = -7,0
ground.cornerpush.veloff =0

[State 0, Explod]
type = Explod
trigger1 =  animelem = 2
anim = 253
ID =  253
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 0
ignorehitpause = 1
;persistent =

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

;---------------------------------------------------------------------------------------------
;Crouching light punch

[Statedef 400]
type    = C
movetype= A
physics = C
juggle  = 4
ctrl = 0
anim = 400
poweradd = 15
sprpriority = 2

[State 400, VelMul, corrida]
type = VelMul
trigger1 = Time = 0
trigger1 = PrevStateNo = 100
x = .8

[State 200, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 8400,0

[State 400, HitDef]
type = HitDef
trigger1 = AnimElem = 2
attr = C,NA
damage = 15,1
animtype = Light
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 13,14
sparkno = s7770
sparkxy = -10, -53
guard.sparkno = s6767
hitsound = s8000,1
guardsound = 6,0
ground.type = Low
ground.slidetime = 10
ground.hittime = 10
ground.velocity = -3,0
air.type = Low
air.hittime = 3
air.velocity = -5,0

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

;---------------------------------------------------------------------------------------------
;Crouching medium punch

[Statedef 410]
type    = C
movetype= A
physics = C
juggle  = 4
ctrl = 0
anim = 410
poweradd = 35
sprpriority = 2

[State 410, VelMul, corrida]
type = VelMul
trigger1 = Time = 0
trigger1 = PrevStateNo = 100
x = .8

[State 410, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 8400,1

[State 410, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 4
value = 8200,0

[State 0, Explod]
type = Explod
trigger1 = animelem = 4
anim = 2224
ID = 2224
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = 1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = .5,.5
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 0
;ignorehitpause =
;persistent =

[State 0, Explod]
type = Explod
trigger1 = animelem = 4
anim = 2225
ID = 2224
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = 1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = .5,.5
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 0
;ignorehitpause =
;persistent =


[State 0, EnvShake]
type = EnvShake
trigger1 = animelem = 4
time = 15
freq = 50
ampl = -5
phase = 90
ignorehitpause =1
persistent =  0

[State 420, HitDef]
type = HitDef
trigger1 = AnimElem = 4
attr = C,NA
damage = 45,1
animtype = up
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 14,12
sparkno = s7772
sparkxy = -10, -30
guard.sparkno = s6767
hitsound = s8000,2
ground.type = High
ground.slidetime = 30
ground.hittime  = 40
ground.velocity = 0, -18
air.velocity = 0,-18
airguard.velocity = -6,0
yaccel = 0.39+(enemynear,const(movement.yaccel)/2)

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

;---------------------------------------------------------------------------------------------
;Crouching strong punch
[Statedef 420]
type    = C
movetype= A
physics = C
juggle  = 4
ctrl = 0
anim = 420
poweradd = 55
sprpriority = 2

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

[State 420, VelMul, corrida]
type = VelMul
trigger1 = Time = 0
trigger1 = PrevStateNo = 100
x = .8

[State 420, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 8400,2

[State 420, HitDef]
type = HitDef
trigger1 = AnimElem = 3
attr = C,NA
damage = 45,1
animtype = up
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 14,12
sparkno = s7772
sparkxy = -10, -30
guard.sparkno = s6767
hitsound = 5,4
ground.type = High
ground.slidetime = 30
ground.hittime  = 40
ground.velocity = 0, -18
air.velocity = 0,-18
airguard.velocity = -6,0
yaccel = 0.39+(enemynear,const(movement.yaccel)/2)

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

;---------------------------------------------------------------------------------------------
;Crouching light kick

[Statedef 430]
type    = C
movetype= A
physics = C
juggle  = 4
ctrl = 0
anim = 430
poweradd = 15
sprpriority = 2

[State 430, VelMul, corrida]
type = VelMul
trigger1 = Time = 0
trigger1 = PrevStateNo = 100
x = .8

[State 430, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 8400,0

[State 430, HitDef]
type = HitDef
trigger1 = AnimElem = 2
attr = C,NA
damage = 15,1
animtype = Light
hitflag = MA
guardflag = L
priority = 4, Hit
pausetime = 13,14
sparkno = s7770
sparkxy = -10, -15
guard.sparkno = s6767
hitsound = 5,3
guardsound = 6,0
ground.type = Low
ground.slidetime = 10
ground.hittime = 10
ground.velocity = -3,0
air.type = Low
air.hittime = 3
air.velocity = -5,0

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

;---------------------------------------------------------------------------------------------
;Crouching medium kick

[Statedef 440]
type    = C
movetype= A
physics = C
juggle  = 4
ctrl = 0
anim = 440
poweradd = 35
sprpriority = 2

[State 440, VelMul, corrida]
type = VelMul
trigger1 = Time = 0
trigger1 = PrevStateNo = 100
x = .8

[State 0, Explod]
type = Explod
trigger1 =  animelem = 2
anim = 441
ID =  441
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 1
ignorehitpause = 1
;persistent =

[State 440, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 8000,6

[State 440, HitDef]
type = HitDef
trigger1 = AnimElem = 2
attr = C,NA
damage = 35,1
animtype = Medium
hitflag = MA
guardflag = L
priority = 4, Hit
pausetime = 13,14
sparkno = s7771
sparkxy = -10,-30
guard.sparkno = s6767
hitsound = s8000,8
guardsound = 6,0
ground.type = Low
ground.slidetime = 12
ground.hittime = 12
ground.velocity = -5,0
air.type = Low
air.hittime = 5
air.velocity = -5,0

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

;---------------------------------------------------------------------------------------------
;Crouching Saber Attack
[Statedef 450]
type    = C
movetype= A
physics = C
juggle  = 4
ctrl = 0
anim = 450
poweradd = 55
sprpriority = 2

[State 0, Explod]
type = Explod
trigger1 =  animelem = 2
anim = 451
ID =  451
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 1
ignorehitpause = 1
;persistent =

[State 0, PlaySnd]
type = PlaySnd
trigger1 = animelem = 2
value = S8000,7
volume = 0
channel = -1
;lowpriority = -1
freqmul = 1.0
loop = 0
pan = 0
;abspan =
;ignorehitpause =
;persistent =


[State 450, HitDef]
type = HitDef
trigger1 = time = 0
attr = C,NA
damage = 45,1
animtype = low
hitflag = MA
guardflag = L
priority = 4, Hit
pausetime = 2,14
sparkno = s7772
sparkxy = -10, -30
guard.sparkno = s6767
hitsound = s8000,8
guardsound = 6,0
ground.type = low
ground.slidetime = 13
ground.hittime = 13
ground.velocity = -5,-2
air.type = Low
air.hittime = 5
air.velocity = -7,3

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

;---------------------------------------------------------------------------------------------
;Jumping light punch

[Statedef 600]
type    = A
movetype= A
physics = A
juggle  = 4
ctrl = 0
anim = 600
poweradd = 15
sprpriority = 2

[State 600, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 8400,0

[State 600, HitDef]
type = HitDef
trigger1 = AnimElem = 3
attr = A,NA
damage = 15,1
animtype = Light
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 13,14
sparkno = s7770
sparkxy = -10, -63
guard.sparkno = s6767
hitsound = 5,0
guardsound = 6,0
ground.type = High
ground.slidetime = 12
ground.hittime  = 25
ground.velocity = -6
air.fall = 0
air.velocity = -3.2, -10.5

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

;---------------------------------------------------------------------------------------------
;Jumping medium punch

[Statedef 610]
type    = A
movetype= A
physics = A
juggle  = 4
ctrl = 0
anim = 610
poweradd = 35
sprpriority = 2

[State 610, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 8400,1

[State 610, HitDef]
type = HitDef
trigger1 = AnimElem = 3
attr = A,NA
damage = 35,1
animtype = medium
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 13,14
sparkno = s7771
sparkxy = -10,-68
guard.sparkno = s6767
hitsound = 5,1
guardsound = 6,0
ground.type = High
ground.slidetime = 25
ground.hittime  = 20
ground.velocity = -8
air.fall = 0
air.velocity = -3.2, -7.5

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

;---------------------------------------------------------------------------------------------
;Jumping strong punch

[Statedef 620]
type    = A
movetype= A
physics = A
juggle  = 4
ctrl = 0
anim = 620
poweradd = 55
sprpriority = 2

[State 620, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 8400,2

[State 620, HitDef]
type = HitDef
trigger1 = AnimElem = 3
attr = A,NA
damage = 45,1
animtype = High
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 13,14
sparkno = s7772
sparkxy = -10, -53
guard.sparkno = s6767
hitsound = 5,4
guardsound = 6,0
ground.type = High
ground.slidetime = 18
ground.hittime  = 25
ground.velocity = -10
air.velocity = -12,10
air.hittime = 25
air.fall = 1

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

;---------------------------------------------------------------------------------------------
;Jumping light kick

[Statedef 630]
type    = A
movetype= A
physics = A
juggle  = 4
ctrl = 0
anim = 630
poweradd = 15
sprpriority = 2

[State 630, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 8400,0

[State 630, HitDef]
type = HitDef
triggerall = anim = 630
trigger1 = AnimElem = 3
attr = A,NA
damage = 15,1
animtype = Light
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 13,14
sparkno = s7770
sparkxy = -10, -63
guard.sparkno = s6767
hitsound = 5,3
guardsound = 6,0
ground.type = High
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -6
air.fall = 0
air.velocity = -3.2, -10.5
air.hittime = 25

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


;---------------------------------------------------------------------------------------------
;Jumping medium kick

[Statedef 640]
type    = A
movetype= A
physics = A
juggle  = 4
ctrl = 0
anim = 640
poweradd = 35
sprpriority = 2

[State 640, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 8400,1

[State 640, HitDef]
type = HitDef
trigger1 = AnimElem = 2
attr = A,NA
damage = 35,1
animtype = Medium
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 13,14
sparkno = s7771
sparkxy = -10,-68
guard.sparkno = s6767
hitsound = 5,1
guardsound = 6,0
ground.type = High
ground.slidetime = 15
ground.hittime  = 20
ground.velocity = -8
air.fall = 0
air.velocity = -3.2, -7.5
air.hittime = 25

[State 640, ChangeState]
type = ChangeState
trigger1 = AnimTime = 0
value = 50
ctrl = 1
;---------------------------------------------------------------------------------------------
;Jumping strong kick

[Statedef 650]
type    = A
movetype= A
physics = A
juggle  = 4
ctrl = 0
anim = 650
poweradd = 55
sprpriority = 2

[State 650, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 1
value = 8000,6

[State 650, HitDef]
type = HitDef
trigger1 = time= 0
attr = A,NA
damage = 45,1
animtype = High
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 0,14
sparkno = s7772
sparkxy = -10, -53
guard.sparkno = s6767
hitsound = s8000,8
guardsound = 6,0
ground.type = High
ground.slidetime = 18
ground.hittime  = 25
ground.velocity = -10
air.velocity = -12,10
air.fall = 1
air.hittime = 25

[State 0, Explod]
type = Explod
trigger1 =  animelem = 2
anim = 651
ID =  651
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 1
ignorehitpause = 1
;persistent =

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


;---------------------------------------------------------------------------------------------
;Throw 1
[Statedef 800]
type    = S
movetype= A
physics = S
juggle  = 0
velset = 0,0
ctrl = 0
anim = 800
sprpriority = 2

[State 800, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 2
value = 8400,2

[State 800, HitDef]
type = HitDef
trigger1 = Time = 0
attr = S, NT
hitflag = M-
priority = 1, Miss
sparkno = -1
sprpriority = 2
p1facing = ifelse(Command = "holdfwd",-1,1)
p2facing = -1
p1stateno = 810
p2stateno = 815
guard.dist = 0
fall.xvelocity = 0
fall.yvelocity = 0
fall = ifelse(PalNo > 6, 0, 1)
fall.recover = 0
fall.damage = 80


[State 800, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA

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

[Statedef 810]
type    = S
movetype= A
physics = N
anim = 810
sprpriority = 2

[State 810, TargetBind]
type = TargetBind
trigger1 = AnimElem = 1
pos = 45,0

[State 810, TargetBind]
type = TargetBind
trigger1 = AnimElem = 2
pos = 35,-90

[State 810, TargetBind]
type = TargetBind
trigger1 = AnimElem = 3
pos = 0,-84

[State 810, TargetBind]
type = TargetBind
trigger1 = AnimElem = 4
pos = -35,-84
time = 5

[State 810, TargetState]
type = TargetState
trigger1 = AnimElemtime(4) = 5
value = 816


[State 810, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = 8600,0

[State 810, PowerAdd]
type = PowerAdd
trigger1 = AnimElem = 5
value = 50

[State 810, TargetLifeAdd]
type = TargetLifeAdd
trigger1 = AnimElem = 5
value = -120

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

[Statedef 815]
type    = A
movetype= H
physics = N
velset = 0,0

[State 815, ScreenBound]
type = ScreenBound
trigger1 = 1
value = 0
movecamera = 0,0

[State 815, ChangeAnim2]
type = ChangeAnim2
trigger1 = Time = 0
value = 815

[Statedef 816]
type    = A
movetype= H
physics = N
velset = -15,-5
poweradd = 50

[State 816, ChangeAnim]
type = ChangeAnim
trigger1 = (Time = [0,10]) && (SelfAnimExist(5060));Not if hit off ground anim
value = 5060

[State 816, ChangeAnim2]
type = ChangeAnim2
trigger1 = (Time = 0) && (!SelfAnimExist(5060));Not if hit off ground anim
value = 816

[State 816, PosAdd]
type = PosAdd
trigger1 = Time = 0
Y = 40

[State 816, VelAdd]
type = VelAdd
trigger1 = Time >= 1
Y = 0.5

[State 816, SelfState]
type = SelfState
trigger1 = (Pos Y >= 0) && (Vel Y > 0)
value = 5100
ctrl = 0

;---------------------------------------------------------------------------------------------
;Throw 1
[Statedef 800]
type    = S
movetype= A
physics = S
juggle  = 0
velset = 0,0
ctrl = 0
anim = 800
sprpriority = 2

[State 800, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 2
value = 8400,2

[State 800, HitDef]
type = HitDef
trigger1 = Time = 0
attr = S, NT
hitflag = M-
priority = 1, Miss
sparkno = -1
sprpriority = 2
p1facing = ifelse (command = "holdfwd", 1, -1)
p2facing = 1
p1stateno = 801
p2stateno = 810
guard.dist = 0
fall.xvelocity = 0
fall.yvelocity = 0
fall = ifelse(PalNo > 6, 0, 1)
fall.recover = 0
fall.damage = 80

[State 800, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA

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

;---------------------------------------------------------------------------------------------
;Throw 2
[Statedef 820]
type    = S
movetype= A
physics = S
juggle  = 0
velset = 0,0
ctrl = 0
anim = 800
sprpriority = 2

[State 820, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 2
value = 8400,2

[State 820, HitDef]
type = HitDef
trigger1 = Time = 0
attr = S, NT
hitflag = M-
priority = 1, Miss
sparkno = -1
sprpriority = 2
p1facing = ifelse(Command = "holdfwd",-1,1)
p2facing = -1
p1stateno = 830
p2stateno = 835
guard.dist = 0
fall.xvelocity = 0
fall.yvelocity = 1
fall = 1
fall.recover = 0
fall.damage = 0

[State 820, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA

[State 820, ChangeState]
type = ChangeState
Trigger1 = AnimTime = 0
value = 0
ctrl = 1

[Statedef 830]
type    = S
movetype= A
physics = N
anim = 820

[State 830, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = 8600,0

[State 830, PlaySnd]
type = PlaySnd
trigger1 = Animelem = 5
value = 9999,7

[State 830, TargetBind]
type = TargetBind
trigger1 = animelem = 1
pos = 21,-10

[State 830, TargetBind]
type = TargetBind
trigger1 = animelem = 2
pos = 4,-10

[State 830, TargetBind]
type = TargetBind
trigger1 = animelem = 3
pos = -22,-29

[State 830, TargetBind]
type = TargetBind
trigger1 = AnimElem = 4
pos = -19,-16

[State 830, Bind 6]
type = TargetBind
trigger1 = animelem = 5
pos = -110,-10

[State 830, Shake]
type = EnvShake
trigger1 = AnimElem = 5
time = 15
ampl = -10

[State 830, TargetLifeAdd]
type = TargetLifeAdd
trigger1 = animelem = 5
value = -120

[State 830, TargetState]
type = TargetState
trigger1 = AnimElem = 6
value = 836

[State 830, Turn]
type = Turn
trigger1 = AnimElem = 7

[State 830, PowerAdd]
type = PowerAdd
trigger1 = animelem = 5
value = 50
persistent = 0

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

;-------------------------------------------------------------------------------------------------------------------------------------------
;P2
[Statedef 835]
type    = A
movetype= H
physics = N
velset = 0,0

[State 835, ChangeAnim2]
type = ChangeAnim2
Trigger1 = time = 0
value = 836

;---------------------------------------------------------------------------------------------
;P2
[Statedef 836]
type    = A
movetype= H
physics = N
velset = -15,-12

[State 836, VelAdd]
type = VelAdd
Trigger1 = 1
y = .4

[State 836, Turn]
type = Turn
trigger1 = Vel Y > 0
trigger1 = pos Y >= 0

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

;---------------------------------------------------------------------------
[Statedef 860]
type    = A
movetype= A
physics = A
juggle  = 1
ctrl = 0
anim = 860
sprpriority = 2

[State 860, PlaySnd]
type = PlaySnd
trigger1 = animelem = 2
value = 8400,2

[State 860, HitDef]
type = HitDef
trigger1 = AnimElem = 3
trigger1 = P2StateType = A
attr = S, NT
hitflag = A
priority = 2, Miss
sparkno = -1
sprpriority = 1
p2getp1state = 1
p1facing = ifelse(Command = "holdfwd",1,-1)
p2facing = -1
p1stateno = 861
p2stateno = 865
fall = 1

;---------------------------------------------------------------------------
[Statedef 861]
type    = A
movetype= A
physics = N
anim = 861

[State 861, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S8600,0

[State 861, TargetBind]
type = TargetBind
trigger1 = animelem = 1
pos = 78,0

[State 861, TargetBind]
type = TargetBind
trigger1 = animelem = 2
pos = 40, -22

[State 861, TargetBind]
type = TargetBind
trigger1 = animelem = 3
pos = 55,-25

[State 861, TargetBind]
type = TargetBind
trigger1 = animelem = 4
pos = 66,26

[State 861, vel]
type = VelSet
trigger1 = time = 0
x = 0
y = 0

[State 861, vel]
type = VelSet
trigger1 = animelemtime(4) = 3
x = 0
y = 7

[State 861, TargetLifeAdd]
type = TargetLifeAdd
trigger1 = animelem = 4
value = -120

[State 861, Targetstate]
type = TargetState
trigger1 = animelem = 4
value = 866

[State 861, PowerAdd]
type = PowerAdd
trigger1 = time = 0
value = 20

[State 861, ChangeState]
type = ChangeState
trigger1 = Vel Y > 0 && Pos Y >= 0
value = 52
ctrl = 1

;---------------------------------------------------------------------------
[Statedef 865]
type    = A
movetype= H
physics = N
velset = 0,0

[State 865, ChamgeAnim2]
type = ChangeAnim2
trigger1 = time = 0
value = 865

;---------------------------------------------------------------------------
[Statedef 866]
type    = A
movetype= H
physics = N
velset = 10,5

[State 866, Veladd]
type = VelAdd
trigger1 = 1
y = .5

[State 866, SelfState]
type = SelfState
trigger1 = vel Y > 0
trigger1 = pos Y >= 0
value = 5100

;---------------------------------------------------------------------------
[Statedef 870]
type    = A
movetype= A
physics = A
juggle  = 1
ctrl = 0
anim = 860
sprpriority = 2

[State 870, PlaySnd]
type = PlaySnd
trigger1 = animelem = 2
value = 8400,2

[State 870, HitDef]
type = HitDef
trigger1 = AnimElem = 3
trigger1 = P2StateType = A
attr = S, NT
hitflag = A
priority = 2, Miss
sparkno = -1
sprpriority = 1
p2getp1state = 1
p1facing = 1
p2facing = -1
snap = 25,-100
p1stateno = 871
p2stateno = 875
fall = 1

;---------------------------------------------------------------------------------------------
;Backbreaker

[Statedef 871]
type    = A
movetype= A
physics = N
anim = 871

[State 871, Width]
type = Width
trigger1 = Time >= 0
value = 25,10

[State 871, PosFreeze]
type = PosFreeze
trigger1 = Time = [0,5]
value = 1

[State 871, Jumping Forward]
type = VelSet
trigger1 = Vel X > 0
trigger1 = Time = [0,10]
x = 1.5
y = -5

[State 871, Jumping Forward 2]
type = VelSet
trigger1 = Vel X > 0
trigger1 = Time = 11
x = 1.5
y = .2

[State 871, Jumping Forward 3]
type = VelAdd
trigger1 = Vel X > 0
trigger1 = Time >= 12
x = .2
y = .6

[State 871, Jumping Up 1]
type = VelSet
trigger1 = Vel X = 0
trigger1 = Time = [0, 10]
x = 0
y = -5

[State 871, Jumping Up 2]
type = VelSet
trigger1 = Vel X = 0
trigger1 = Time = 11
x = 0
y = .2

[State 871, Jumping Up 3]
type = VelAdd
trigger1 = Vel X = 0
trigger1 = Time >= 12
x = 0
y = .6

[State 871, Jumping Back 1]
type = VelSet
trigger1 = Vel X < 0
trigger1 = Time = [0, 10]
x = -1.2
y = -5

[State 871, Jumping Back 2]
type = VelSet
trigger1 = Vel X < 0
trigger1 = Time = 11
x = -1.2
y = .2

[State 871, Jumping Back 3]
type = VelAdd
trigger1 = Vel X < 0
trigger1 = Time >= 12
x = -.2
y = .6

[State 871, PlaySnd 1]
type = PlaySnd
trigger1 = Time = 0
value = 8600,0

[State 871, PlaySnd 2]
type = PlaySnd
trigger1 = Time = 5
value = 9999,2

[State 871, Bind 1]
type = TargetBind
trigger1 = Time >= 0
pos = 45,-85

[State 871, ChangeState]
type = ChangeState
trigger1 = Pos Y >= 20
value = 872
ctrl = 0

[Statedef 872]
type    = S
movetype= A
physics = S
anim = 872
velset = 0,0
poweradd = 0

[State 872, TargetBind]
type = TargetBind
trigger1 = Time = 0
pos = 10,-34

[State 872, PosSet]
type = PosSet
trigger1 = Time = 0
Y = 0

[State 872, PlaySnd]
type = PlaySnd
trigger1 = Time = 1
value = 8200,0

[State 872, EnvShake]
type = EnvShake
trigger1 = Time = 0
ampl = -15
time = 15

[State 872, TargetLifeAdd]
type = TargetLifeAdd
trigger1 = Time = 0
value = -120

[State 872, TargetState]
type = TargetState
trigger1 = Time = 15
value = 876

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

;---------------------------------------------------------------------------------------------
;Backbreaker - p2

[Statedef 875]
type    = A
movetype= H
physics = N

[State 875,SprPriority]
type = SprPriority
trigger1 = P2StateNo = 872
value = 3

[State 875, ChangeAnim2]
type = ChangeAnim2
trigger1 = Time = 0
value = 875

[State 875, ChangeAnim2]
type = ChangeAnim2
trigger1 = Time > 0 && P2StateNo = 872
value = 876

[Statedef 876]
type    = A
movetype= H
physics = N
velset = 10,-8
poweradd = 40

[State 876, VelAdd]
type = VelAdd
Trigger1 = 1
y = .4

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

;---------------------------------------------------------------------------
;Falling

[Statedef 1201]
type    = A
movetype= I
physics = A
anim = 5210
sprpriority = 1

[State 1201, Ctrl]
type = CtrlSet
trigger1 = prevstateno = 4100
value = 0

[State 1201, Ctrl]
type = CtrlSet
triggerall = prevstateno != 4100
trigger1 = Var(12) = 0
value = 0

[State 1201, Ctrl]
type = CtrlSet
triggerall = prevstateno != 4100
trigger1 = Var(12) = 1
value = 1

[State 1201, Turn]
type = Turn
trigger1 = P2Dist X < -5

[State 1201, VelSet]
type = VelSet
trigger1 = FrontEdgeBodyDist <= 0
x = 0

[State 1201, ChangeState]
type = ChangeState
trigger1 = (Pos Y >= 0) && (Vel Y > 0)
value = 52

;---------------------------------------------------------------------------
;Super Moves
;---------------------------------------------------------------------------

;---------------------------------------------------------------------------------------------
;Hadoken
[Statedef 1000]
type    = S
movetype= A
juggle  = 1
physics = S
poweradd = 0
anim = 1000
ctrl = 0
sprpriority = 2

[State 0, PlaySnd]
type = PlaySnd
trigger1 = animelem = 4
value = S1000,1
volume = 0
channel = -1
;lowpriority = -1
freqmul = 1.0
loop = 0
pan = 0
;abspan =
;ignorehitpause =
;persistent =


[State 0, StateTypeSet]
type = StateTypeSet
trigger1 = var(16) = 1
physics = N         ;A,C,S,N

[State 0, VelSet]
type = VelSet
triggerall =var(16) = 1
trigger1 = animelem = 1
x = ifelse(vel x >=0,.15,-.15)
y = ifelse(vel y >=0,.15,-.15)

[State 0, Explod]
type = Explod
trigger1 = animelem = 4
anim = 2223
ID = 2223
pos = 0,10
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = 1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 1
;ignorehitpause =
;persistent =


[State 0, Helper]
type = Helper
trigger1 = animelemtime(5) = 2
helpertype = normal ;player
name = "Hadoken"
ID =6000
stateno = 6000
pos = 73,-41
postype = p1    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 1
supermove
pausemove
sprpriority = 999999999
size.xscale =.7
size.yscale =.7
;size.ground.back (int)
;size.ground.front (int)
;size.air.back (int)
;size.air.front (int)
;size.height (int)
;size.proj.doscale (int)
;size.head.pos (int,int)
;size.mid.pos (int,int)
;size.shadowoffset (int)
;ignorehitpause =
;persistent =



[State 1000, Fim]
type = ChangeState
trigger1 = AnimTime = 0
value = ifelse (var(16)=1,50,0)
ctrl = 1

;---------------------------------------------------------------------------------------------
;Beam Saber
[Statedef 1200]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
poweradd = 0
anim = 1200
ctrl = 0
sprpriority = 2

[State 0, Explod]
type = Explod
trigger1 =  animelem = 4
anim = 1201
ID =  1201
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 1
ignorehitpause = 1
;persistent =

[State 0, PlaySnd]
type = PlaySnd
trigger1 = animelem = 4
value = S8000,6
volume = 0
channel = -1
;lowpriority = -1
freqmul = 1.0
loop = 0
pan = 0
;abspan =
;ignorehitpause =
;persistent =


[State 0, Helper]
type = Helper
trigger1 = animelemtime(6) = 7
helpertype = normal ;player
name = "Beam Proj"
ID =1202
stateno = 1202
pos = 60,15
postype = p1    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 1
supermove
pausemove
sprpriority = 999999999
size.xscale =1
size.yscale =1


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

;---------------------------------------------------------------------------------------------
;BeamProjectile
[Statedef 1202]
type = A
movetype = A
physics = N
ctrl = 0
anim = 1202
sprpriority = 9999

[State 0, VelSet]
type = VelSet
trigger1 = time = 1
x = 10


[State 0, AfterImage]
type = AfterImage
trigger1 =  time = 0
time = 30
length = 10
;palcolor = 256
;palinvertall = 0
palbright = 30,130,030
palcontrast = 020,220,020
;palpostbright = 0,0,0
;paladd = 10,10,25
;palmul = .65,.65,.75
timegap = 1
framegap = 1
trans = add
;ignorehitpause =
;persistent =





[State 220, HitDef]
type = HitDef
trigger1 = time = 0
attr = S,SP
damage = 35,1
animtype = hard
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 0,14
sparkno = s8881
sparkxy = -10, -20
guard.sparkno = s6767
hitsound = s8000,8
guardsound = 6,0
ground.type = High
ground.slidetime = 18
ground.hittime  = 18
ground.velocity = -10
air.type = Low
air.hittime = 18
air.velocity = -6,-7
envshake.time = 2
envshake.ampl = 2



[State 0, DestroySelf]
type = DestroySelf
trigger1 = time = 100
;ignorehitpause =
;persistent =
;---------------------------------------------------------------------------------------------
;Charged Buster
[Statedef 1100]
type    = A
movetype= A
physics = S
ctrl = 0
anim = 3000
juggle  = 4


[State 0, Explod]
type = Explod
trigger1 = animelem = 3
anim =6007
ID = 6007
pos = 63,-50
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 0
;ignorehitpause =
;persistent =

[State 0, VarSet]
type = VarSet
trigger1 = animtime = 0
v = 5    ;fv = 10
value = 0
;ignorehitpause =
;persistent =

[State 0, PlaySnd]
type = PlaySnd
trigger1 =animelem = 3
value = S3000,0
volume = 0
channel = -1
;lowpriority = -1
freqmul = 1.0
loop = 0
pan = 0
;abspan =
;ignorehitpause =
;persistent =

[State 0, Helper]
type = Helper
triggerall =  var(5)>=200
trigger1 = animelem = 3
helpertype = normal ;player
name = "FullyChargedBlast"
ID =1101
stateno = 1101
pos = 76,-50
postype = p1    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 1
supermove
pausemove
sprpriority = 999999999
size.xscale =.9
size.yscale =.9

[State 0, Helper]
type = Helper
triggerall = var(5)<=199
trigger1 = animelem = 3
helpertype = normal ;player
name = "SemiChargedBlast"
ID =11011
stateno = 11011
pos = 76,-50
postype = p1    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 1
supermove
pausemove
sprpriority = 999999999
size.xscale =.9
size.yscale =.9






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



;---------------------------------------------------------------------------------------------
;Fully Charged Buster Helper
[Statedef 1101]
type = A
movetype = A
physics = N
ctrl = 0
anim = 6003
sprpriority = 9999

[State 0, StopSnd]
type = StopSnd
trigger1 = time = 1
channel = 3
;ignorehitpause =
;persistent =


[State 0, VelSet]
type = VelSet
trigger1 = time = 1
x = 10


[State 0, AfterImage]
type = AfterImage
trigger1 =  time = 0
time = 30
length = 5
;palcolor = 256
;palinvertall = 0
palbright = 30,030,130
palcontrast = 080,080,120
;palpostbright = 0,0,0
;paladd = 100,100,125
;palmul = .65,.65,.75
timegap = 1
framegap = 1
trans = add
;ignorehitpause =
;persistent =



[State 220, HitDef]
type = HitDef
trigger1 = time = 0
attr = S,SP
damage = 55,1
animtype = hard
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 0,14
sparkno = s8881
sparkxy = -10, -20
guard.sparkno = s6767
hitsound = s8000,4
guardsound = 6,0
ground.type = High
ground.slidetime = 18
ground.hittime  = 18
ground.velocity = -10
air.type = Low
air.hittime = 18
air.velocity = -6,-7
envshake.time = 2
envshake.ampl = 2



[State 0, DestroySelf]
type = DestroySelf
trigger1 = time = 100
trigger2 = movecontact
;ignorehitpause =
;persistent =


;-------------------------------------------------------------------
;Half Charged Buster Helper
[Statedef 11011]
type = A
movetype = A
physics = N
ctrl = 0
anim = 6008
sprpriority = 9999

[State 0, StopSnd]
type = StopSnd
trigger1 = time = 1
channel = 3
;ignorehitpause =
;persistent =

[State 0, VelSet]
type = VelSet
trigger1 = time = 1
x = 10


[State 0, AfterImage]
type = AfterImage
trigger1 =  time = 0
time = 30
length = 5
;palcolor = 256
;palinvertall = 0
palbright = 30,130,30
palcontrast = 080,120,80
;palpostbright = 0,0,0
;paladd = 100,100,125
;palmul = .65,.65,.75
timegap = 1
framegap = 1
trans = add
;ignorehitpause =
;persistent =



[State 220, HitDef]
type = HitDef
trigger1 = time = 0
attr = S,SP
damage = 35,1
animtype = hard
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 0,14
sparkno = s8881
sparkxy = -10, -20
guard.sparkno = s6767
hitsound = s8000,4
guardsound = 6,0
ground.type = High
ground.slidetime = 18
ground.hittime  = 18
ground.velocity = -10
air.type = Low
air.hittime = 18
air.velocity = -6,-7
envshake.time = 2
envshake.ampl = 2



[State 0, DestroySelf]
type = DestroySelf
trigger1 = time = 100
trigger2 = movecontact
;ignorehitpause =
;persistent =

;---------------------------------------------------------------------------------------------
;ChargeBuster (Air)
[Statedef 1102]
type    = A
movetype= A
physics = N
ctrl = 0
anim = 621
juggle  = 4


[State 0, VelSet]
type = VelSet
triggerall =var(16) = 1
trigger1 = animelem = 1
x = ifelse(vel x >=0,.15,-.15)
y = ifelse(vel y >=0,.15,-.15)

[State 0, Explod]
type = Explod
trigger1 = animelem = 3
anim =6007
ID = 6007
pos = 49,-66
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 0
;ignorehitpause =
;persistent =

[State 0, VarSet]
type = VarSet
trigger1 = animtime = 0
v = 5    ;fv = 10
value = 0
;ignorehitpause =
;persistent =

[State 0, PlaySnd]
type = PlaySnd
trigger1 =animelem = 3
value = S3000,0
volume = 0
channel = -1
;lowpriority = -1
freqmul = 1.0
loop = 0
pan = 0
;abspan =
;ignorehitpause =
;persistent =

[State 0, Helper]
type = Helper
triggerall =  var(5)>=200
trigger1 = animelem = 3
helpertype = normal ;player
name = "FullyChargedBlast"
ID =1101
stateno = 1101
pos = 57,-66
postype = p1    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 1
supermove
pausemove
sprpriority = 999999999
size.xscale =.9
size.yscale =.9

[State 0, Helper]
type = Helper
triggerall = var(5)<=199
trigger1 = animelem = 3
helpertype = normal ;player
name = "SemiChargedBlast"
ID =11011
stateno = 11011
pos = 57,-66
postype = p1    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 1
supermove
pausemove
sprpriority = 999999999
size.xscale =.9
size.yscale =.9






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


;-----------------------------------------------
;ChargeBuster (Crouch)
[Statedef 1103]
type    = C
movetype= A
physics = C
ctrl = 0
anim = 421
juggle  = 4




[State 0, Explod]
type = Explod
trigger1 = animelem = 2
anim =6007
ID = 6007
pos = 67,-34
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 0
;ignorehitpause =
;persistent =

[State 0, VarSet]
type = VarSet
trigger1 = animtime = 0
v = 5    ;fv = 10
value = 0
;ignorehitpause =
;persistent =

[State 0, PlaySnd]
type = PlaySnd
trigger1 =animelem = 3
value = S3000,0
volume = 0
channel = -1
;lowpriority = -1
freqmul = 1.0
loop = 0
pan = 0
;abspan =
;ignorehitpause =
;persistent =

[State 0, Helper]
type = Helper
triggerall = var(5)<=199
trigger1 = animelem = 3
helpertype = normal ;player
name = "SemiChargedBlast"
ID =1101
stateno = 11011
pos = 45,-34
postype = p1    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 1
supermove
pausemove
sprpriority = 999999999
size.xscale =.9
size.yscale =.9

[State 0, Helper]
type = Helper
triggerall =  var(5)>=200
trigger1 = animelem = 3
helpertype = normal ;player
name = "FullyChargedBlast"
ID =1101
stateno = 1101
pos = 45,-34
postype = p1    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 1
supermove
pausemove
sprpriority = 999999999
size.xscale =.9
size.yscale =.9




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

;---------------------------------------------------------------------------
;Hypers
;---------------------------------------------------------------------------

;---------------------------------------------------------------------------------------------
;Hyper1

[Statedef 3000]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
poweradd = 0
anim = 3200
ctrl = 0
sprpriority = 2

[State 3000, Hyper Portrait]
type = explod
trigger1 = time = 0
anim = 1080
postype = back
sprpriority = -3
supermovetime = -1
removetime = 60
pos = 0,0
bindtime = -1
removeongethit = 1
ownpal = 1

[State 3000, assertspecial]
type = assertspecial
trigger1 = time = [0,60]
flag = noBG
flag2 = noFG
ignorehitpause = 1

[State 3100, SuperPause]
type = SuperPause
trigger1 = AnimElemTime(1) = 0
Time = 60
pos = 9999,-9951
sound = 8889,0
poweradd = -1000
movetime = 30

[State 3000, Hyper Background]
type  = Explod
triggerall = Time = 42
trigger1 = p2life > 0
anim = 754
postype = left
ID = 750
sprpriority = -4
removetime = -1
pos = 0,0
scale = .5,.5
bindtime = -1
;facing=1
ignorehitpause=1
supermovetime=9999
pausemovetime=9999
supermove = 9999
pausemove = 9999
ownpal = 1


[State 3100, Hyper Explode]
type = Explod
trigger1 = time = 15
anim = 4532
postype = p1
pos = 40,-87
ownpal = 1
sprpriority = 5
supermovetime = 40


[State 3100, Sound]
type = PlaySnd
trigger1 = Time = 12
value = 8889,0

[State 3100, Ground Flash]
type = Explod
trigger1 = time = 15
anim = 6666
ID = 8400
postype = P1
pos = 50,10
sprpriority = 3
ownpal = 1
supermovetime = 0
scale = .5,.5

[State 3000, PlaySnd]
type = PlaySnd
trigger1 =  AnimElem = 4
trigger2 =  animelem = 7
value = 3000,0


[State 0, Explod]
type = Explod
trigger1 = animelem = 4
anim = 6003
ID = 6003
pos = 55,-52
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = 1
vel = 2,0
random = 0,0
removetime = -1
supermove
pausemove
scale = .7,.7
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 0
;ignorehitpause =
;persistent =

[State 0, Explod]
type = Explod
trigger1 = animelem = 7
anim = 6004
ID = 6004
pos = 70,-52
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = 1
vel = .5,0
accel = .2
random = 0,0
removetime = -1
supermove
pausemove
scale = .5,.5
sprpriority = 0
ontop = 0
shadow = 0,0,0
ownpal = 1
removeongethit = 0
;ignorehitpause =
;persistent =


[State 0, Helper]
type = Helper
trigger1 = time = 95
helpertype = normal ;player
name = "SuperBlast"
ID =3001
stateno = 3001
pos = 150,-55
postype = p1    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 1
supermove
pausemove
sprpriority = 999999999
size.xscale =.6
size.yscale =.6

[State 0, EnvColor]
type = EnvColor
trigger1 = time = 95
value = 255,255,255
time = 2
;under = 0
;ignorehitpause =
;persistent =



[State 0, RemoveExplod]
type = RemoveExplod
trigger1 = time = 95
id = 6003
;ignorehitpause =
;persistent =
[State 0, RemoveExplod]
type = RemoveExplod
trigger1 = time = 95
id = 6004
;ignorehitpause =
;persistent =



[State 3000, End]
type = ChangeState
trigger1 = animtime=0
trigger1 = BackEdgeBodyDist > -1
value = 0
ctrl = 1


;-----------------------------------------------------------------
 [Statedef 3001]
type = A
movetype = A
physics = N
ctrl = 0
anim = 6002
sprpriority = 9999

[State 0, VelSet]
type = VelSet
trigger1 = time
x = -1+(time*.17)

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

[State 3000, PlaySnd]
type = PlaySnd
trigger1 = time = 1
value = 3000,1

[State 0, AfterImage]
type = AfterImage
trigger1 =  time = 0
time = 30
length = 10
;palcolor = 256
;palinvertall = 0
palbright = 130,130,130
palcontrast = 020,020,020
;palpostbright = 0,0,0
paladd = 10,10,10
palmul = .65,.65,.65
timegap = 1
framegap = 1
trans = add
;ignorehitpause =
;persistent =





[State 220, HitDef]
type = HitDef
trigger1 = time = 0
attr = S,HP
damage = 70,1
animtype = hard
guardflag = MA
hitflag = MAFDHL
priority = 4, Hit
pausetime = 0,14
sparkno = s9992
sparkxy = -10, -20
guard.sparkno = s6767
hitsound = s8000,2
guardsound = 6,0
ground.type = High
ground.slidetime = 18
ground.hittime  = 18
ground.velocity = -10,-7
fall = 1
air.type = Low
air.hittime = 18
air.velocity = -6,-7
persistent = 1
ground.cornerpush.veloff =0

[State 0, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
;value2 = S,NA
time = 1
;ignorehitpause =
;persistent =

[State 0, DestroySelf]
type = DestroySelf
trigger1 = time = 100
trigger2 = movecontact
;ignorehitpause =
;persistent =


;---------------------------------------------------------------------------------------------
;Hyper2

[Statedef 3100]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
poweradd = 0
anim = 3100
ctrl = 0
sprpriority = 2

[State 3000, Hyper Portrait]
type = explod
trigger1 = time = 0
anim = 1080
postype = back
sprpriority = -3
supermovetime = -1
removetime = 60
pos = 0,0
bindtime = -1
removeongethit = 1
ownpal = 1

[State 3000, assertspecial]
type = assertspecial
trigger1 = time = [0,40]
flag = noBG
flag2 = noFG
ignorehitpause = 1

[State 3100, SuperPause]
type = SuperPause
trigger1 = AnimElemTime(1) = 0
Time = 60
pos = 9999,-9951
sound = 8889,0
poweradd = -1000
movetime = 40

[State 3000, Hyper Background]
type  = Explod
triggerall = Time = 42
trigger1 = p2life > 0
anim = 754
postype = left
ID = 751
sprpriority = -4
removetime = -1
pos = 0,0
scale = .5,.5
bindtime = -1
;facing=1
ignorehitpause=1
supermovetime=9999
pausemovetime=9999
supermove = 9999
pausemove = 9999
ownpal = 1


[State 3100, Hyper Explode]
type = Explod
trigger1 = time = 15
anim = 4532
postype = p1
pos = 40,-87
ownpal = 1
sprpriority = 5
supermovetime = 40


[State 3100, Sound]
type = PlaySnd
trigger1 = Time = 12
value = 8889,0

[State 3100, Ground Flash]
type = Explod
trigger1 = time = 15
anim = 6666
ID = 8400
postype = P1
pos = 50,10
sprpriority = 3
ownpal = 1
supermovetime = 0
scale = .5,.5

[State 0, Helper]
type = Helper
triggerall = anim = 3104
trigger1 = animelemtime(1) = 2
helpertype = normal ;player
name = "Beam Proj"
ID =3101
stateno = 3101
pos = 35,0
postype = p1    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 1
supermove
pausemove
sprpriority = 999999999
size.xscale =.6
size.yscale =.9

[State 0, VelSet]
type = VelSet
trigger1 = animelem = 4
x = 3
y = -11
;ignorehitpause =
persistent = 0

[State 0, VelSet]
type = VelSet
trigger1 = animelem = 5
x = 0
y = -6
;ignorehitpause =
persistent = 0


[State 0, PlaySnd]
type = PlaySnd
trigger1 = animelem = 4
value = S8000,6
volume = 0
channel = -1
;lowpriority = -1
freqmul = 1.0
loop = 0
pan = 0
;abspan =
;ignorehitpause =
persistent = 0

 [State 0, PlaySnd]
type = PlaySnd
trigger1 = animelem = 6
value = S8000,7
volume = 0
channel = -1
;lowpriority = -1
freqmul = 1.0
loop = 0
pan = 0
;abspan =
;ignorehitpause =
;persistent =


[State 0, PlaySnd]
type = PlaySnd
triggerall = anim = 3104
trigger1 = animelemtime(1) = 1
value = S8200,0
volume = 255
channel = -1
;lowpriority = -1
freqmul = 1.0
loop = 0
pan = 0
;abspan =
;ignorehitpause =
persistent = 0


[State 0, StateTypeSet]
type = StateTypeSet
trigger1 = var(16)=1
statetype = A       ;S,A,C,L
movetype = A        ;I,A,H
physics = A         ;A,C,S,N
;ignorehitpause =
;persistent =

[State 0, Explod]
type = Explod
trigger1 =  animelem = 4
anim = 3101
ID =3101
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove = 999
pausemove = 999
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 0
ignorehitpause =  0
;persistent =

[State 0, Explod]
type = Explod
trigger1 =  animelem = 6
anim = 3103
ID =3103
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove = 999
pausemove = 999
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 0
ignorehitpause = 0
;persistent =

[State 0, Explod]
type = Explod
trigger1 =  animelem = 15
anim = 3105
ID =3105
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove = 999
pausemove = 999
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 0
ignorehitpause = 0
;persistent =

[State 0, Explod]
type = Explod

trigger1 =  anim = 3104
anim = 3106
ID =3106
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove = 999
pausemove = 999
scale = 1,1
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 0
ignorehitpause = 0
persistent = 0

[State 0, EnvShake]
type = EnvShake
trigger1 = time = 121
time = 50
freq = 50
ampl = -5
phase = 90
ignorehitpause =1
persistent =  1


[State 0, VelSet]
type = VelSet
trigger1 = time = 121
y = 0
;ignorehitpause =
;persistent =

[State 0, PosSet]
type = PosSet
trigger1 = time = 121
y = 0
;ignorehitpause =
;persistent =

[State 0, StateTypeSet]
type = StateTypeSet
trigger1 = time = 121
statetype = S       ;S,A,C,L
movetype = A        ;I,A,H
physics = C         ;A,C,S,N
;ignorehitpause =
;persistent =

[State 0, ChangeAnim]
type = ChangeAnim
trigger1 = time = 120
value =3104
;elem = 1
ignorehitpause = 1
persistent = 0


[State 220, HitDef]
type = HitDef
trigger1 = animelem = 4
attr = S,HP
damage = 35,1
animtype = hard
guardflag = MA
hitflag = MAFDH
priority = 4, Hit
pausetime = 4,14
sparkno = s9990
sparkxy = -10, 0
guard.sparkno = s6767
hitsound = s8000,8
guardsound = 6,0
ground.type = High
ground.slidetime = 18
ground.hittime  = 18
ground.velocity = -2,-12
air.type = Low
air.hittime = 18
air.velocity = -2,-12
fall = 1
persistent = 1

[State 220, HitDef]
type = HitDef
trigger1 = animelem = 6
trigger2 = animelem = 8
trigger3 = animelem = 10
trigger4 = animelem = 12
attr = S,HP
damage = 35,1
animtype = hard
guardflag = MA
hitflag = MAFDH
priority = 4, Hit
pausetime = 4,8
sparkno = s9991
sparkxy = -10, 0
guard.sparkno = s6767
hitsound = s8000,8
guardsound = 6,0
ground.type = High
ground.slidetime = 18
ground.hittime  = 18
ground.velocity = -10
air.type = Low
air.hittime = 100
air.velocity = 0,10
fall = 1
persistent = 1

[State 3100, End]
type = ChangeState
trigger1 = animtime=0
trigger1 = BackEdgeBodyDist > -1
value = 10
ctrl = 1



;--------------------------------------------------
[Statedef 3101]
type = A
movetype = A
physics = N
ctrl = 0
anim = 3102
sprpriority = 9999

[State 0, VelSet]
type = VelSet
trigger1 = time = 1
x = 10

[State 0, PlaySnd]
type = PlaySnd
trigger1 = animelem = 1
value = S8000,6
volume = 0
channel = -1
;lowpriority = -1
freqmul = 1.0
loop = 0
pan = 0
;abspan =
;ignorehitpause =
persistent = 0


[State 0, AfterImage]
type = AfterImage
trigger1 =  time = 0
time = 30
length = 10
;palcolor = 256
;palinvertall = 0
palbright = 30,130,030
palcontrast = 020,220,020
;palpostbright = 0,0,0
;paladd = 10,10,25
;palmul = .65,.65,.75
timegap = 1
framegap = 1
trans = add
;ignorehitpause =
;persistent =





[State 220, HitDef]
type = HitDef
trigger1 = animelem = 1
trigger2 = animelem = 2
trigger3 = animelem = 3
trigger4 = animelem = 4
attr = S,HP
damage = 35,1
animtype = hard
guardflag = MA
hitflag = MAFDHL
priority = 4, Hit
pausetime = 4,14
sparkno = s9992
sparkxy = -10, -20
guard.sparkno = s6767
hitsound = s8000,8
guardsound = 6,0
ground.type = High
ground.slidetime = 18
ground.hittime  = 18
ground.velocity = -10
air.type = Low
air.hittime = 18
air.velocity = -6,-7
persistent = 1

[State 0, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
;value2 = S,NA
time = 1
;ignorehitpause =
;persistent =

[State 0, DestroySelf]
type = DestroySelf
trigger1 = time = 100
trigger2 = hitcount >=4
;ignorehitpause =
;persistent =
;---------------------------------------------------------------------------------------------
;Beginning of the super jump
[Statedef 7000]
type = S
physics = S
anim = 40
ctrl = 0
sprpriority = 1

[State 7000, VarSet]
type = VarSet
trigger1 = Time = 0
v = 11
value = 0

[State 7000, VarSet]
type = VarSet
trigger1 = command = "holdfwd"
v = 11
value = 1

[State 7000, VarSet]
type = VarSet
trigger1 = command = "holdback"
v = 11
value = -1

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

;---------------------------------------------------------------------------------------------
[Statedef 4210]
type    = A
movetype= H
physics = N
poweradd= 0
ctrl = 0
velset = 0,-16
sprpriority = 0

[State 4210, VelSet 2]
type = VelSet
trigger1 = (Pos Y >= 10) && (Vel Y > 0)
y = 0

[State 4210, VelSet]
type = VelSet
trigger1 = (Pos Y >= 10) && (Vel Y > 0)
y = 10

[State 4210, ChangeAnim2]
type = ChangeAnim2
trigger1 = Time = 0
value = 4210

[State 4210, SelfState]
type = SelfState
trigger1 = (Pos Y >= 0) && (Vel Y > 0)
value = 5100
ctrl = 0

[State 4210, ChangeState]
type = ChangeState
trigger1 = Time = 40
value = 4211
ctrl = 0

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

[Statedef 4211]
type    = A
movetype= H
physics = N
poweradd= 0
ctrl = 0
velset = 0,0
sprpriority = 3

[State 4211, ChangeAnim2]
type = ChangeAnim2
trigger1 = Time = 0
value = 4211

[State 4211, VelAdd]
type = VelAdd
trigger1 = Time > 49
y = 0.5

[State 4211, SelfState]
type = SelfState
trigger1 = (Pos Y >= 0) && (Vel Y > 0)
value = 5100
ctrl = 0

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

[Statedef 4212]
type    = A
movetype= H
physics = N
poweradd= 0
ctrl = 0
sprpriority = 0

[State 4212, ChangeAnim2]
type = ChangeAnim2
trigger1 = Time = 0
value = 4212

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

[Statedef 4213]
type    = L
movetype= H
physics = N
poweradd= 0
ctrl = 0
sprpriority = 0

[State 4213, SelfState]
type = SelfState
trigger1 = Time = 0
value = 5100
ctrl = 0


;---------------------------------------------------------------------------------------------
;Backbreaker

[Statedef 4551]
type    = A
movetype= A
physics = N
anim = 871
ctrl = 0

[State 4551, ScreenBound]
type = Null
trigger1 = 1
value = 0
movecamera = 0,0

[State 4551, Explod]
type = Explod
trigger1 = time = 0
anim = 8396
ID = 8396
postype = P2
pos  =  -5,-23
sprpriority = 3
ignorehitpause = 1
ownpal = 1

[State 4551, Width]
type = Width
trigger1 = Time >= 0
value = 25,10

[State 4551, PosFreeze]
type = PosFreeze
trigger1 = Time = [0,5]
value = 1

[State 4551, Jumping Up 1]
type = VelSet
trigger1 = Time = [0, 34]
x = 0
y = -24

[State 4551, Jumping Up 2]
type = VelSet
trigger1 = Time = 34
x = 0
y = 26

[State 4551, Jumping Up 2]
type = VelSet
trigger1 = Time >= 35
x = 0
y = 28

[State 4551, PlaySnd 1]
type = PlaySnd
trigger1 = Time = 0
value = 8600,0

[State 4551, PlaySnd 2]
type = PlaySnd
trigger1 = Time = 5
value = 9999,2

[State 4551, Bind 1]
type = TargetBind
trigger1 = Time >= 0
pos = 45,-85

[State 4551, ChangeState]
type = ChangeState
trigger1 = Pos Y >= 20
value = 4552
ctrl = 0

[Statedef 4552]
type    = S
movetype= A
physics = S
anim = 872
velset = 0,0
poweradd = 0
sprpriority = -1

[State 4551, ScreenBound]
type = Null
trigger1 = 1
value = 0
movecamera = 0,0

[State 4552, TargetBind]
type = TargetBind
trigger1 = Time = 0
pos = 10,-34

[State 4552, PosSet]
type = PosSet
trigger1 = Time = 0
Y = 0

[State 4552, PlaySnd]
type = PlaySnd
trigger1 = Time = 1
value = 8200,0

[State 4552, EnvShake]
type = EnvShake
trigger1 = Time = 0
ampl = -35
time = 15

[State 4552, TargetLifeAdd]
type = TargetLifeAdd
trigger1 = Time = 0
value = -70

[State 4552, TargetState]
type = TargetState
trigger1 = Time = 15
value = 4556

[State 4552, Explod]
type = Explod
trigger1 = time = 0
anim = 8394
ID = 8394
postype = P2
pos  =  0,0
sprpriority = 2
ignorehitpause = 1
ownpal = 1

[State 4552, ChangeState]
type = ChangeState
trigger1 = AnimTime = 0
value = 4553
ctrl = 0

[Statedef 4553]
type = A
movetype = A
physics = A
anim = 4006
velset = -9,-14


[State 4006, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoAutoTurn

[State 4006, Vel]
type = VelAdd
trigger1 = 1
y = .02

[State 4006,ChangeState]
type = ChangeState
trigger1 = Time > 0
trigger1 = Vel Y > 0 && Pos Y >= 0
value = 52

;---------------------------------------------------------------------------------------------
;Backbreaker - p2

[Statedef 4555]
type    = A
movetype= H
physics = N

[State 4555,SprPriority]
type = SprPriority
trigger1 = P2StateNo = 872
value = 3

[State 4555, ChangeAnim2]
type = ChangeAnim2
trigger1 = Time = 0
value = 875

[State 4555, ChangeAnim2]
type = ChangeAnim2
trigger1 = Time > 0 && P2StateNo = 872
value = 4556

[Statedef 4556]
type    = A
movetype= H
physics = N
velset = 10,-14
poweradd = 40
sprpriority = 2

[State 4556, VelAdd]
type = VelAdd
Trigger1 = 1
y = .4

[State 4556, SelfState]
type = SelfState
trigger1 = Vel Y > 0 && Pos Y >= 0
value = 5100
;===============================================
[Statedef 6000]
type = A
movetype = A
physics = N
ctrl = 0
anim = 6005
sprpriority = 9999

[State 0, VelSet]
type = VelSet
trigger1 = time = 1
x = ifelse(parent,var(25) = 4,3,ifelse(parent,var(25)=5,4.5,6))

[State 0, PalFXWiz]
type = null
trigger1 = time = 0
time = 100
add = 100,100,255
mul = 50,100,255
sinadd = 100,100,-80,10
invertall = 0
color = 0
;ignorehitpause = 0
;persistent = 1



[State 0, AfterImage]
type = afterimage
trigger1 =  time = 0
time = -1
length = 4
;palcolor = 256
;palinvertall = 0
palbright = 30,30,130
palcontrast = 020,020,220
;palpostbright = 0,0,0
;paladd = 10,10,25
;palmul = .65,.65,.75
timegap = 2
framegap = 2
trans = add
;ignorehitpause =
;persistent =

[State 220, HitDef]
type = HitDef
trigger1 = 1
attr = S,SA
damage = 35,1
animtype = hard
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 0,14
sparkno = s8882
sparkxy = -10, 0
guard.sparkno = s6767
hitsound = s8000,2
guardsound = 6,0
ground.type = High
ground.slidetime = 18
ground.hittime  = 18
ground.velocity = -10
air.type = Low
air.hittime = 18
air.velocity = -6,-7
envshake.time = 2
envshake.ampl = 2






[State 0, DestroySelf]
type = DestroySelf
trigger1 = time >= 80
trigger2 = movecontact
;ignorehitpause =
;persistent =




;---------------------------------------------------------------------------------------------
;Super Jump
[Statedef 7001]
type = A
physics = A
ctrl = 1
anim = 41
velset = 0,-16.3

[State 7001, VelAdd]
type = VelAdd
triggerall = Vel X >= -2
trigger1 = command = "holdback"
trigger1 = Anim != 43
x = -0.1

[State 7001, VelAdd]
type = VelAdd
triggerall = Vel X <= 2.5
trigger1 = command = "holdfwd"
trigger1 = Anim != 42
x = 0.25

[State 7001, VelSet]
type = VelSet
trigger1 = Anim = 42
trigger1 = Time = [0,5]
x = 4

[State 7001, VelSet]
type = VelSet
trigger1 = Anim = 43
trigger1 = Time = [0,5]
x = -3.5

[State 7001, ChangeAnim]
type = ChangeAnim
trigger1 = Var(11) = 0
trigger1 = Time = [0,4]
value = 41

[State 7001, ChangeAnim]
type = ChangeAnim
trigger1 = Var(11) = 1
trigger1 = Time = [0,4]
value = 42

[State 7001, ChangeAnim]
type = ChangeAnim
trigger1 = Var(11) = -1
trigger1 = Time = [0,4]
value = 43

[State 7001, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = 9999,5

[State 7001, Explod]
type = Explod
trigger1 = Time = 0
ID = 474
anim = 6669
postype = p1
pos = 12, 60
bindtime = 1
removetime = -2
ownpal = 1
sprpriority = 2
scale = .5 - (time * 0.15), .7 - (time * 0.15)

[State 7001, explod]
type = Explod
trigger1 = Time = 0
ID = 474
anim = 6699
postype = p1
pos = 5, 60
bindtime = 1
removetime = -2
ownpal = 1
sprpriority = 2
scale = 1.20 - (time * 0.15), 1.54 - (time * 0.15) 

[State 7001, explod]
type = Explod
trigger1 = Time = 0
ID = 474
anim = 9006
postype = p1
pos = 0, 20
bindtime = 1
removetime = -2
ownpal = 1
sprpriority = 2
scale = 2, 2
 
[State 7001, Variavelzinha muito útil]
type = VarSet
trigger1 = Time = 0
v = 12
value = 1

;---------------------------------------------------------------------------------------------
;Super Jump

[Statedef 7002]
type    = A
physics = A
ctrl = 1

[State 7005, Vel]
type = VelAdd
triggerall = Vel X >= -2
trigger1 = command = "holdback"
trigger1 = Anim != 43
x = -0.1

[State 7005, Vel]
type = VelAdd
triggerall = Vel X <= 2.5
trigger1 = command = "holdfwd"
trigger1 = Anim != 42
x = 0.25


;---------------------------------------------------------------------------------------------
[Statedef 8882]
type = S
physics = S
anim = 0
sprpriority = 1
ctrl = 0

[State 8882, ScreenBound]
type = ScreenBound
trigger1 = 1
value = 0

[State 8882, ChangeState]
type = Changestate
trigger1 = time = 30
value = 8883

[Statedef 8883]
type = S
physics = S
anim = 100
sprpriority = 1
ctrl = 0

[State 8883, PlaySnd]
type = PlaySnd
trigger1 = (AnimElem = 5) || (AnimElem = 9)
value = 8100,0

[State 8883, VelSet]
type = VelSet
trigger1 = 1
x = 8

[State 8883, ScreenBound]
type = ScreenBound
trigger1 = 1
value = 0

[State 8883, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoWalk

[State 8883, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoAutoTurn

[State 8883, ChangeState]
type = ChangeState
trigger1 = p2bodydist x <= 190
value = 101
ctrl = 0

;---------------------------------------------------------------------------------------------
[Statedef -3]

[State -3, VarAdd]
type = VarAdd
trigger1 = (HitPauseTime = 1) && (P2MoveType = H) && (MoveHit = 1) && (StateNo < 3000)
trigger2 = ProjHitTime(0) = 1
v = 21
value = 1
ignorehitpause = 1

[State -3, VarReset]
type = VarSet
trigger1 = P2MoveType != H
v = 21
value = 0

[State -3, AttackMulSet]
type = AttackMulSet
trigger1 = StateNo >= 3000
value = 1

[State -3, AttackMulSet]
type = AttackMulSet
triggerall = StateNo < 3000
trigger1 = Var(21) <= 1
value = 1

[State -3, AttackMulSet]
type = AttackMulSet
triggerall = StateNo < 3000
trigger1 = Var(21) = 2
value = 0.8

[State -3, AttackMulSet]
type = AttackMulSet
triggerall = StateNo < 3000
trigger1 = Var(21) = 3
value = 0.6

[State -3, AttackMulSet]
type = AttackMulSet
triggerall = StateNo < 3000
trigger1 = Var(21) = 4
value = 0.4

[State -3, AttackMulSet]
type = AttackMulSet
triggerall = StateNo < 3000
trigger1 = Var(21) >= 5
value = .2


[State 8510, Pó]
type = Explod
trigger1 = Stateno = 52 && time = 1
trigger2 = Stateno = 240 && animelem = 8
trigger3 = Stateno = 1102 && time = 1
trigger4 = Stateno = 1112 && time = 1
trigger5 = Stateno = 1122 && time = 1
trigger6 = Stateno = 106 && time = 1
trigger7 = Stateno = 352 && AnimElemTime(2) = 1
anim = 8510
ID = 8510
postype = P1
pos = 0,4
sprpriority = -1
ownpal = 1
scale = 1.4, 1.2

[State -3, Aterrisagem]
type = PlaySnd
trigger1 = StateNo = 52 && Time = 1 
value = 8100,0

[State -3, Explod]
type = RemoveExplod
trigger1 = StateNo != [3000,4999]
ID = 8900

[State -3, Explod]
type = RemoveExplod
trigger1 = Roundstate = 4
ID = 8901

[State -3, Explod]
type = RemoveExplod
trigger1 = Var(20) > 0
ID = 8900

[State -3, Explod]
type = RemoveExplod
trigger1 = StateNo != [3000,4999]
ID = 8998

[State -3, Explod]
type = RemoveExplod
trigger1 = Roundstate = 4
ID = 8998

[State -3, Explod]
type = RemoveExplod
trigger1 = Var(20) > 0
ID = 8998

[State -3, Explod]
type = RemoveExplod
trigger1 = StateNo != [3000,4999]
ID = 8997

[State -3, Explod]
type = RemoveExplod
trigger1 = Roundstate = 4
ID = 8997

[State -3, Explod]
type = RemoveExplod
trigger1 = Var(20) > 0
ID = 8997

[State -3, Explod]
type = RemoveExplod
trigger1 = StateNo != [3000,4999]
ID = 8999

[State -3, Explod]
type = RemoveExplod
trigger1 = Roundstate = 4
ID = 8999

[State -3, Explod]
type = RemoveExplod
trigger1 = Var(20) > 0
ID = 8999

[State -3, MSSM]
type = VarRandom
trigger1 = 1
v = 23
range = 0,8

[State -3, Super Jump]
type = VarSet
trigger1 = Stateno = 0
v = 12
value = 0

;[State -3, Afterimagetime]
type = Afterimagetime
trigger1 = stateno != [3000,4999] 
time = 0

[State -3, ctrl set]
type = ctrlset
trigger1 = roundstate = 4
value = 0

;---------------------------------------------------------------------------
;Guard Push (Stand)
[Statedef 6300]
type    = S
movetype= I
physics = N
poweradd= 0
velset = 10,0
ctrl = 0
anim = 1111
sprpriority = 2

[State 6300, a1]
type = VelMul
trigger1 = 1
x = 0.75

[State 6300, a2]
type = VelSet
trigger1 = Time = 10
x = 0

[State 6300, a3]
type = Width
trigger1 = 1
value = 10,0

[State 6300, a4]
type = NotHitBy
trigger1 = Time = 0
value = SCA
time = 25

[State 6300, a5]
type = Helper
trigger1 = Time = 0
helpertype = Normal
name = "GuardPush"
postype = P1
pos = -50,0
stateno = 6350
ownpal = 1
size.height = 200
size.ground.back = 30
size.ground.front = 30

[State 6300, a6]
type = Explod
trigger1 = Time = 0
anim = 3333
postype = p1
pos = 53,-50
ownpal = 1
vel = 2,0
ignorehitpause = 1
sprpriority = 7

[State 6300, a7]
type = PlaySnd
trigger1 = Time = 0
value = 54,3
volume = 255
channel = 1

[State 6300, a8]
type = PlaySnd
trigger1 = Time = 0
value = 1,0
channel = 0

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

[Statedef 6310];--------------crouch
type    = C
movetype= I
physics = N
poweradd= 0
velset = 10,0
ctrl = 0
anim = 121
sprpriority = 2

[State 6310, a1]
type = VelMul
trigger1 = 1
x = 0.75

[State 6310, a2]
type = VelSet
trigger1 = Time = 10
x = 0

[State 6310, a3]
type = Width
trigger1 = 1
value = 10,0

[State 6310, a4]
type = NotHitBy
trigger1 = Time = 0
value = SCA
time = 25

[State 6310, a5]
type = Helper
trigger1 = Time = 0
helpertype = Normal
name = "GuardPush"
postype = P1
pos = -50,0
stateno = 6350
ownpal = 1
size.height = 200
size.ground.back = 30
size.ground.front = 30

[State 6310, a6]
type = Explod
trigger1 = Time = 0
anim = 3333
postype = p1
pos = 33,-45
ownpal = 1
vel = 2,0
ignorehitpause = 1
sprpriority = 7

[State 6310, a7]
type = PlaySnd
trigger1 = Time = 0
value = 54,3
volume = 255
channel = 1

[State 6310, a8]
type = PlaySnd
trigger1 = Time = 0
value = 50,0
channel = 0

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


[Statedef 6320];------------air
type    = S
movetype= I
physics = N
poweradd= 0
velset = 10,0
ctrl = 0
anim = 122
sprpriority = 2

[State 6320, a1]
type = VelMul
trigger1 = 1
x = 0.75

[State 6320, a2]
type = VelSet
trigger1 = Time = 10
x = 0

[State 6320, a3]
type = Width
trigger1 = 1
value = 10,0

[State 6320, a4]
type = NotHitBy
trigger1 = Time = 0
value = SCA
time = 25

[State 6320, a5]
type = Helper
trigger1 = Time = 0
helpertype = Normal
name = "GuardPush"
postype = P1
pos = -50,0
stateno = 6350
ownpal = 1
size.height = 200
size.ground.back = 30
size.ground.front = 30

[State 6320, a6]
type = Explod
trigger1 = Time = 0
anim = 3333
postype = p1
pos = 33,-55
ownpal = 1
vel = 2,0
ignorehitpause = 1
sprpriority = 7

[State 6320, a7]
type = PlaySnd
trigger1 = Time = 0
value = 54,3
volume = 255
channel = 1

[State 6320, a8]
type = PlaySnd
trigger1 = Time = 0
value = 50,0
channel = 0

[State 6320, a9]
type = ChangeState
trigger1 = AnimTime = 0
value = 51
ctrl = 1

[Statedef 6350];guard push helper
type    = S
movetype= I
physics = N
poweradd= 0
ctrl = 0
anim = 1112
sprpriority = -4

[State 6350, a1]
type = PlayerPush
trigger1 = Time >= 0
value = 1

[State 6350, a2]
type = VelSet
trigger1 = Time = [0,10]
x = 30

[State 6350, a3]
type = VelSet
trigger1 = Time = [11,13]
x = 20

[State 6350, a4]
type = VelSet
trigger1 = Time >= 14
x = 10

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

[State 6350, a6]
type = DestroySelf
trigger1 = Time >= 18



;---------------------------------------------------------------------------
;--------------------------------- Roll ------------------------------------
;---------------------------------------------------------------------------

;---------------------------------------------------------------------------
; Near Roll

[Statedef 890]
type    = S
movetype= I
physics = S
juggle  = 0
poweradd= 20
velset = 4,0
ctrl = 0
anim = 810
sprpriority = -1

[State 890, 1]
type = VelSet
trigger1 = Time != 1
x = 4

[State 890, 2]
type = PlayerPush
trigger1 = Time >= 0
value = 0

[State 890, 4]
type = NotHitBy
trigger1 = 1
value = SCA

[State 890, 5]
type = VarRandom
trigger1 = Time = 0
v = 4
range = 0,1

[State 890, 6.1]
type = PlaySnd
trigger1 = AnimElem = 2 && Var(4) = 0
value = 810,0

[State 890, 6.2]
type = PlaySnd
trigger1 = AnimElem = 2 && Var(4) = 1
value = 810,1

[State 890, 7]
type = AfterImage
trigger1 = AnimElem = 2
time = 999
length = 20
PalBright = 0,0,0
PalContrast = 128,128,128
PalAdd = 0,0,0
PalMul = 1,1,1
FrameGap = 3
trans = add1
ignorehitpause = 1

[State 931, Dead]
type = ChangeState
trigger1 = alive = 0
value = 5150
ctrl = 0

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

;---------------------------------------------------------------------------
; Medium Roll

[Statedef 895]
type    = S
movetype= I
physics = S
juggle  = 0
poweradd= 20
velset = 4,0
ctrl = 0
anim = 810
sprpriority = -1

[State 895, 1]
type = VelSet
trigger1 = Time != 1
x = 5

[State 895, 2]
type = PlayerPush
trigger1 = Time >= 0
value = 0

[State 815, 4]
type = NotHitBy
trigger1 = 1
value = SCA

[State 895, 5]
type = VarRandom
trigger1 = Time = 0
v = 4
range = 0,1

[State 895, 6.1]
type = PlaySnd
trigger1 = AnimElem = 2 && Var(4) = 0
value = 810,0

[State 895, 6.2]
type = PlaySnd
trigger1 = AnimElem = 2 && Var(4) = 1
value = 810,1

[State 895, 7]
type = AfterImage
trigger1 = AnimElem = 2
time = 999
length = 20
PalBright = 0,0,0
PalContrast = 128,128,128
PalAdd = 0,0,0
PalMul = 1,1,1
FrameGap = 3
trans = add1
ignorehitpause = 1

[State 931, Dead]
type = ChangeState
trigger1 = alive = 0
value = 5150
ctrl = 0

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

;---------------------------------------------------------------------------
; Far Roll

[Statedef 898]
type    = S
movetype= I
physics = S
juggle  = 0
poweradd= 20
velset = 4,0
ctrl = 0
anim = 810
sprpriority = -1

[State 898, 1]
type = VelSet
trigger1 = Time != 1
x = 6

[State 898, 2]
type = PlayerPush
trigger1 = Time >= 0
value = 0

[State 898, 4]
type = NotHitBy
trigger1 = 1
value = SCA

[State 898, 5]
type = VarRandom
trigger1 = Time = 0
v = 4
range = 0,1

[State 898, 6.1]
type = PlaySnd
trigger1 = AnimElem = 2 && Var(4) = 0
value = 810,0

[State 898, 6.2]
type = PlaySnd
trigger1 = AnimElem = 2 && Var(4) = 1
value = 810,1

[State 898, 7]
type = AfterImage
trigger1 = AnimElem = 2
time = 999
length = 20
PalBright = 0,0,0
PalContrast = 128,128,128
PalAdd = 0,0,0
PalMul = 1,1,1
FrameGap = 3
trans = add1
ignorehitpause = 1

[State 931, Dead]
type = ChangeState
trigger1 = alive = 0
value = 5150
ctrl = 0

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

;---------------------------------------------------------------------------
;------------------------------ Recovery Roll ------------------------------
;---------------------------------------------------------------------------

;---------------------------------------------------------------------------
; Near Foward Recovery Roll

[Statedef 831]
type    = C
movetype= I
physics = N
juggle  = 0
poweradd= 0
velset = 0,0
ctrl = 0
anim = 831
sprpriority = -1

[State 831, 1]
type = PlayerPush
trigger1 = Time >= 0
value = 0

[State 831, 3]
type = PosSet
trigger1 = Time >= 0
y = 0

[State 831, 4]
type = MakeDust
trigger1 = Time >= 0
pos = -16,0
spacing = 6

[State 831, 5]
type = NotHitBy
trigger1 = Time >= 0
value = SCA
time = 1

[State 931, Dead]
type = ChangeState
trigger1 = alive = 0
value = 5150
ctrl = 0

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

;---------------------------------------------------------------------------
; Medium Foward Recovery Roll

[Statedef 832]
type    = C
movetype= I
physics = N
juggle  = 0
poweradd= 0
velset = 8,0
ctrl = 0
anim = 832
sprpriority = -1

[State 832, 1]
type = PlayerPush
trigger1 = Time >= 0
value = 0

[State 832, 2]
type = VelSet
trigger1 = AnimTime = 0
x = 0

[State 832, 3]
type = PosSet
trigger1 = Time >= 0
y = 0

[State 832, 4]
type = MakeDust
trigger1 = Time >= 0
pos = -16,0
spacing = 6

[State 832, 5]
type = NotHitBy
trigger1 = Time = 0
value = SCA
time = 10

[State 931, Dead]
type = ChangeState
trigger1 = alive = 0
value = 5150
ctrl = 0

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

;---------------------------------------------------------------------------
; Far Foward Recovery Roll

[Statedef 840]
type    = C
movetype= I
physics = N
juggle  = 0
poweradd= 0
velset = 8,0
ctrl = 0
anim = 840
sprpriority = -1

[State 840, 1]
type = PlayerPush
trigger1 = Time >= 0
value = 0

[State 840, 2]
type = VelSet
trigger1 = AnimTime = 0
x = 0

[State 840, 3]
type = PosSet
trigger1 = Time >= 0
y = 0

[State 840, 4]
type = MakeDust
trigger1 = Time >= 0
pos = -16,0
spacing = 6

[State 840, 5]
type = NotHitBy
trigger1 = Time = 0
value = SCA
time = 15

[State 931, Dead]
type = ChangeState
trigger1 = alive = 0
value = 5150
ctrl = 0

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

;---------------------------------------------------------------------------
; Near Backward Recovery Roll

[Statedef 850]
type    = C
movetype= I
physics = N
juggle  = 0
poweradd= 0
velset = 0,0
ctrl = 0
anim = 850
sprpriority = -1

[State 850, 1]
type = PlayerPush
trigger1 = Time >= 0
value = 0

[State 850, 3]
type = PosSet
trigger1 = Time >= 0
y = 0

[State 850, 4]
type = MakeDust
trigger1 = Time >= 0
pos = 16,0
spacing = 6

[State 850, 5]
type = NotHitBy
trigger1 = Time >= 0
value = SCA
time = 1

[State 931, Dead]
type = ChangeState
trigger1 = alive = 0
value = 5150
ctrl = 0

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

;---------------------------------------------------------------------------
; Medium Backward Recovery Roll

[Statedef 855]
type    = C
movetype= I
physics = N
juggle  = 0
poweradd= 0
velset = -8,0
ctrl = 0
anim = 855
sprpriority = -1

[State 855, 1]
type = PlayerPush
trigger1 = Time >= 0
value = 0

[State 855, 2]
type = VelSet
trigger1 = AnimTime = 0
x = 0

[State 855, 3]
type = PosSet
trigger1 = Time >= 0
y = 0

[State 855, 4]
type = MakeDust
trigger1 = Time >= 0
pos = 16,0
spacing = 6

[State 855, 5]
type = NotHitBy
trigger1 = Time = 0
value = SCA
time = 10

[State 931, Dead]
type = ChangeState
trigger1 = alive = 0
value = 5150
ctrl = 0

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

;---------------------------------------------------------------------------
; Far Backward Recovery Roll

[Statedef 860]
type    = C
movetype= I
physics = N
juggle  = 0
poweradd= 0
velset = -8,0
ctrl = 0
anim = 860
sprpriority = -1

[State 860, 1]
type = PlayerPush
trigger1 = Time >= 0
value = 0

[State 860, 2]
type = VelSet
trigger1 = AnimTime = 0
x = 0

[State 860, 3]
type = PosSet
trigger1 = Time >= 0
y = 0

[State 860, 4]
type = MakeDust
trigger1 = Time >= 0
pos = 16,0
spacing = 6

[State 860, 5]
type = NotHitBy
trigger1 = Time = 0
value = SCA
time = 15

[State 931, Dead]
type = ChangeState
trigger1 = alive = 0
value = 5150
ctrl = 0

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

;---------------------------------------------------------------------------
; Recovery Roll - Variable "Reset"

[State -2, 1]
type = VarSet
trigger1 = (StateNo != 5050) && (StateNo != 5071)
v = 30
value = 0

;-------------------------------------------------------------------------
; A.I. - Far Foward Recovery Roll

[State -2, 2]
type = ChangeState
triggerall = (RoundState = 2)&&(Var(59) = 2)
triggerall = (StateType != S)&&(StateType != L)
triggerall = (P2Life != 0)&&(Alive = 1)
triggerall = (Pos Y = [-10,0])
triggerall = (StateNo = 5050)||(StateNo = 5071)||(StateNo = 50700)
trigger1 = (P2Dist X)+(BackEdgeDist) <= 160
trigger2 = (Enemy, NumProj > 0)
value = 840

;-------------------------------------------------------------------------
; A.I. - Far Backward Recovery Roll

[State -2, 3]
type = ChangeState
triggerall = (RoundState = 2)&&(Var(59) = 2)
triggerall = (StateType != S)&&(StateType != L)
triggerall = (P2Life != 0)&&(Alive = 1)
triggerall = (Pos Y = [-10,0])
trigger1 = (StateNo = 5050)||(StateNo = 5071)||(StateNo = 50700)
trigger1 = (P2Dist X)+(BackEdgeDist) > 160
value = 55

;-------------------------------------------------------------------------
; A.I. - Lie Down Forward Recovery Roll

[State -2, 4]
type = ChangeState
triggerall = (RoundState = 2)&&(Var(59) = 2)
triggerall = (StateType != S)&&(StateType = L)
triggerall = (P2Life != 0)&&(Alive = 1)
triggerall = (StateNo = 5120)&&(StateNo = 51200)
trigger1 = Time = 1
trigger1 = (P2Dist X)+(BackEdgeDist) <= 160
trigger2 = (Enemy, NumProj > 0)
value = 832

;-------------------------------------------------------------------------
; A.I. - Lie Down Backward Recovery Roll

[State -2, 5]
type = ChangeState
triggerall = (RoundState = 2)&&(Var(59) = 2)
triggerall = (StateType != S)&&(StateType = L)
triggerall = (P2Life != 0)&&(Alive = 1)
trigger1 = (StateNo = 5120)&&(StateNo = 51200)
trigger1 = Time = 1
trigger1 = (P2Dist X)+(BackEdgeDist) > 160
value = 855
;---------------------------------------------------------------------------
; HITA_UP (initial going up)
[Statedef 5030]
type    = A
movetype= H
physics = N
ctrl = 0

[State 5030, 1]
type = VelAdd;Gravity
trigger1 = 1
y = GetHitVar(yaccel)

[State 5030, 2]
type = HitVelSet
trigger1 = Time = 0
x = 1
y = 1

[State 5030, snd]
type = PlaySnd
triggerall = vel x != 0
triggerall = numexplod(72) <= 0
trigger1 = backedgebodydist <= 5
trigger2 = frontedgebodydist <= 5
persistent = 0
;value = F7, 0 ;Hit ground
value = F7, (sysvar(1) > 5) + (sysvar(1) > 14)

[State 5030, GMA]
type = Explod
triggerall = vel x != 0
triggerall = backedgebodydist <= 5
trigger1 = numexplod(72) <= 0
persistent = 0
ignorehitpause = 1
id = 72
anim = 6777
pos = -20,-75
postype = p1
bindtime = 1

[State 5030, GMA]
type = Explod
triggerall = vel x != 0
triggerall = frontedgebodydist <= 5
trigger1 = numexplod(72) <= 0
persistent = 0
ignorehitpause = 1
id = 72
anim = 6777
pos = 20,-75
sprpriority = 2
facing = -1
bindtime = 1
ownpal = 1

[State 5030, 3]
type = ChangeState
triggerall = !HitFall
trigger1 = HitOver
trigger2 = Vel Y > 0    ;Hit ground
trigger2 = Pos Y >= 10  ;.
value = 5040 ;HITA_RECOV

[State 5030, 4]
type = ChangeState
triggerall = HitFall
trigger1 = HitOver
trigger2 = Vel Y > 0    ;Hit ground
trigger2 = Pos Y >= 10  ;.
value = 5050 ;HITA_FALL

[State 5030, 5]
type = ChangeState
trigger1 = AnimTime = 0
value = 5035 ;HITA_UP (transition)

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

; HITA_UP_T (transition)
[Statedef 5035]
type    = A
movetype= H
physics = N

[State 5035, 1]
type = ChangeAnim
trigger1 = Time = 0
trigger1 = SelfAnimExist(5035)
trigger1 = Anim != [5051,5059] ;Not if in hit up anim
trigger1 = Anim != 5090 ;Not if hit off ground anim
value = 5035

[State 5035, 2]
type = VelAdd
trigger1 = 1
y = GetHitVar(yaccel)

[State 5035, snd]
type = PlaySnd
triggerall = vel x != 0
triggerall = numexplod(72) <= 0
trigger1 = backedgebodydist <= 5
trigger2 = frontedgebodydist <= 5
persistent = 0
;value = F7, 0 ;Hit ground
value = F7, (sysvar(1) > 5) + (sysvar(1) > 14)

[State 5035, GMA]
type = Explod
triggerall = vel x != 0
triggerall = backedgebodydist <= 5
trigger1 = numexplod(72) <= 0
persistent = 0
ignorehitpause = 1
id = 72
anim = 6777
pos = -20,-75
postype = p1
bindtime = 1

[State 5035, GMA]
type = Explod
triggerall = vel x != 0
triggerall = frontedgebodydist <= 5
trigger1 = numexplod(72) <= 0
persistent = 0
ignorehitpause = 1
id = 72
anim = 6777
pos = 20,-75
sprpriority = 2
facing = -1
bindtime = 1
ownpal = 1

[State 5035, 3]
type = ChangeState
triggerall = !HitFall
trigger1 = HitOver  ;Hit is over
trigger2 = AnimTime = 0 ;Animation over
trigger3 = Vel Y > 0    ;Hit ground
trigger3 = Pos Y >= 10  ;.
trigger4 = Time = 0     ;No transition anim
trigger4 = Anim != 5035 ;.
value = 5040 ;HITA_RECOV

[State 5035, 4]
type = ChangeState
triggerall = HitFall
trigger1 = HitOver  ;Hit is over
trigger2 = AnimTime = 0 ;Anim is over
trigger3 = Vel Y > 0    ;Hit ground
trigger3 = Pos Y >= 10  ;.
trigger4 = Time = 0     ;No transition anim
trigger4 = Anim != 5035 ;.
value = 5050 ;HITA_FALL

;---------------------------------------------------------------------------
; HITA_FALL (knocked up, falling)
[Statedef 5050]
type    = A
movetype= H
physics = N

[State 5050, 1] ;Change anim when done with transition
type = ChangeAnim
trigger1 = AnimTime = 0
trigger1 = Anim = 5035
trigger2 = Time = 0     ;If no transition anim
trigger2 = Anim != 5035
trigger2 = (Anim != [5051, 5059]) && (Anim != [5061, 5069])
trigger2 = Anim != 5090 ;Not if hit off ground anim
value = 5050

[State 5050, 2] ;Coming down anim
type = ChangeAnim
trigger1 = anim = [5050,5059]
trigger1 = Vel Y >= ifelse(anim = 5050, 1, -2)
trigger1 = SelfAnimExist(anim+10)
value = anim+10
persistent = 0

[State 5050, 3] ;Gravity
type = VelAdd
trigger1 = 1
y = GetHitVar(yaccel)

[State 5050, snd]
type = PlaySnd
triggerall = vel x != 0
triggerall = numexplod(72) <= 0
trigger1 = backedgebodydist <= 5
trigger2 = frontedgebodydist <= 5
persistent = 0
;value = F7, 0 ;Hit ground
value = F7, (sysvar(1) > 5) + (sysvar(1) > 14)

[State 5050, GMA]
type = Explod
triggerall = vel x != 0
triggerall = backedgebodydist <= 5
trigger1 = numexplod(72) <= 0
persistent = 0
ignorehitpause = 1
id = 72
anim = 6777
pos = -20,-75
postype = p1
bindtime = 1

[State 5050, GMA]
type = Explod
triggerall = vel x != 0
triggerall = frontedgebodydist <= 5
trigger1 = numexplod(72) <= 0
persistent = 0
ignorehitpause = 1
id = 72
anim = 6777
pos = 20,-75
sprpriority = 2
facing = -1
bindtime = 1
ownpal = 1

[State 5050, 4] ;Recover near ground
type = ChangeState
triggerall = Vel Y > 0
triggerall = Pos Y >= -20
triggerall = alive
triggerall = CanRecover
trigger1 = Command = "recovery"
value = 5200 ;HITFALL_RECOVER

[State 5050, 5]; Recover in mid air
type = ChangeState
triggerall = Vel Y > -1
triggerall = alive
triggerall = CanRecover
trigger1 = Command = "recovery"
value = 5210 ;HITFALL_AIRRECOVER

[State 5050, 6]
type = ChangeState
trigger1 = Vel Y > 0
trigger1 = Pos Y >= ifelse((anim = [5051,5059]) || (anim = [5061,5069]), 0, 25)
value = 5100 ;HIT_BOUNCE

;---------------------------------------------------------------------------
; States that are always executed (use statedef -2)
;---------------------------------------------------------------------------
[Statedef -2]

[State 0, PlaySnd]
type = PlaySnd
trigger1 = var(5)=25
value = S3000,2
volume = 0
channel = 3
;lowpriority = -1
freqmul = 1.0
loop = 0
pan = 0
;abspan =
;ignorehitpause =
;persistent =

[State 0, StopSnd]
type = StopSnd
trigger1 = numhelper(11011)>=1
trigger2 = numhelper(1101)>=1
channel = 3
;ignorehitpause =
;persistent =


[State 0, Explod]
type = Explod
trigger1 = var(5)=25
anim =6006
ID = 6006
pos = 0,-35
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -1
supermove
pausemove
scale = .5,.5
sprpriority = 0
ontop = 1
shadow = 0,0,0
ownpal = 1
removeongethit = 0
;ignorehitpause =
;persistent =

[State 0, ModifyExplod]
type = ModifyExplod
trigger1 = var(16)=1
ID = 6006
pos = 0,-65
postype = p1  ;p2,front,back,left,right

[State 0, ModifyExplod]
type = ModifyExplod
trigger1 = var(16)=0
ID = 6006
pos = 0,-35
postype = p1  ;p2,front,back,left,right

[State 0, RemoveExplod]
type = RemoveExplod
trigger1 = numexplod(6006)>0=1 && var(5)= 0
trigger2 = numexplod(6006) >=2
trigger3 = var(6) = 1
id = 6006
;ignorehitpause =
;persistent =


[State 0, PalFXWiz]
type = PalFX
trigger1 = var(5)=25
time = -1
add = 240,100,50
mul = 250,224,120
sinadd = 110,55,250,20
invertall = 0
color = 200
ignorehitpause = 1
persistent = 0

[State 0, PalFXWiz]
type = PalFX
trigger1 = var(5)=200
time = -1
add = 240,100,50
mul = 250,224,220
sinadd = 255,55,150,8
invertall = 0
color = 200
ignorehitpause = 1
persistent = 0

[State 0, PalFXWiz]
type = PalFX
trigger1 = var(5)=0
trigger2 = command != "holdz"
time = 0
add = 150,150,150
mul = 100,100,100
sinadd = 100,100,100,10
invertall = 0
color = 200
ignorehitpause = 1
persistent = 0

[State 0, VarSet]
type = VarSet
trigger1 = command = "z"
v = 5    ;fv = 10
value = 0
;ignorehitpause =
persistent = 0

[State 0, VarAdd]
type = VarAdd
trigger1 = command = "holdz"
v = 5    ;fv =
value = 1
;ignorehitpause =
persistent = 1

[State 0, VarSet]
type = VarSet
trigger1 = var(5) >= 210
v = 5    ;fv = 10
value = 210
;ignorehitpause =
persistent = 0

[State 0, VarSet]
type = VarSet
trigger1 = command != "holdz"
v = 6    ;fv = 10
value = 1
;ignorehitpause =
;persistent =

[State 0, VarSet]
type = VarSet
trigger1 = command = "holdz"
v = 6    ;fv = 10
value = 0
;ignorehitpause =
;persistent =





[State -2, RemoveExplod]
type = RemoveExplod
trigger1 = Stateno != 3000
trigger2 = roundstate = 3
trigger3 = numexplod(9200) = 1
id = 750
;ignorehitpause =
;persistent =


[State -2, RemoveExplod]
type = RemoveExplod
trigger1 = Stateno != 3100
trigger2 = roundstate = 3
trigger3 = numexplod(9200) = 1
id = 751
;ignorehitpause =
;persistent =

[State -2, VarSet]
type = VarSet
trigger1 = Pos y <0
v = 16    ;fv = 10
value = 1
;ignorehitpause =
;persistent =

[State -2, VarSet]
type = VarSet
trigger1 = Pos y >=0
v = 16    ;fv = 10
value = 0
;ignorehitpause =
;persistent =

[State -2, VarSet]
type = VarSet
trigger1 = command != "holdup"
v = 20    ;fv = 10
value = 0
;ignorehitpause =
;persistent =

[State -2, VarSet]
type = VarSet
trigger1 = command = "holdup"
v = 20    ;fv = 10
value = 1
;ignorehitpause =
;persistent =

[State 0, VarSet]
type = VarSet
trigger1 = command = "a"
v = 25    ;fv = 10
value = 1
;ignorehitpause =
;persistent =

[State 0, VarSet]
type = VarSet
trigger1 = command = "b"
v = 25    ;fv = 10
value = 2
;ignorehitpause =
;persistent =

[State 0, VarSet]
type = VarSet
trigger1 = command = "c"
v = 25    ;fv = 10
value = 3
;ignorehitpause =
;persistent =

[State 0, VarSet]
type = VarSet
trigger1 = command = "x"
v = 25    ;fv = 10
value = 4
;ignorehitpause =
;persistent =

[State 0, VarSet]
type = VarSet
trigger1 = command = "y"
v = 25    ;fv = 10
value = 5
;ignorehitpause =
;persistent =

[State 0, VarSet]
type = VarSet
trigger1 = command = "z"
v = 25    ;fv = 10
value = 6
;ignorehitpause =
;persistent =


;For debugging purposes
[State -2, Debug Info]
type = DisplayToClipboard
trigger1 = 1
text = "Var(5): %d, Win or DOS? %d, AI On %d, Super Jump %d, Recovery Roll %d"
;text = "Intro No. %d, Win No. %d, Enemy Proj: %d, Enemy Helpers: %d"
;text = "Score %d"
;text = "P2 Distance X from P1 %f, P2 Distance Y from P1 %f"
params = var(5), var(17), var(59), var(0), var(5)
;params = var(1), var(2), var(7), var(6)
;params = var(11)
;params = P2BodyDist X, P2BodyDist Y

;---------------------------------------------------------------------------
;Is DOS or Win?
[State -2, Detect System]
type = Varadd
trigger1 = (var(17)%2 = 0) && (movecontact) > (movecontact = 1)
v = 17
value = 1

;screenpack mvsc2?
[State -2, Detect Screeenpack]
type = Varadd
trigger1 = var(17) < 10 && roundstate < 2 && numexplod(8522) != 0
v = 17
value = 10

;---------------------------------------------------------------------------
; - mvsc2 screen pack
[State -2, Is MvC2 Screeenpack]
type = Explod
trigger1 = var(17) < 10 && roundstate < 2 && numexplod(8522) = 0
id = 8522
anim = 9001
pos = 0,240
postype = p1
removetime = 1
bindtime = -1
sprpriority = -1
ownpal = 1

;---------------------------------------------------------------------------
; - Press Start (from the Mvc2 screen pack)
[State -2, Press Start Label]
type = Explod
triggerall = var(59) = 1 && roundstate >= 0
trigger1 = (gametime%60) = id && life != 0
id = 8620
anim = 9001
pos = ((enemy, id)<id)*172, 0
postype = Left
removetime = 30
bindtime = -1
sprpriority = -1
ownpal = 1
ontop = 1

; Super FX Section ==================================================


; Misc SCtrls Section ==================================================
[State -2, Lie Down Snd]
type = PlaySnd
trigger1 = Time = 1
trigger1 = anim = 5300
value = 3,21
channel = 0

; ----------------------------------------------------------------------
[State -2, NoHitBy]
Type = NotHitBy
trigger1 = (NumHelper(9985) = 1) && (NumHelper(9986) = 1)
trigger1 = Time = 0
value = SCA
Time = 30

[State -2, PalFX]
type = PalFX
trigger1 = (NumHelper(9985) = 1) && (NumHelper(9986) = 1)
time = 1
add = 0, 0, 256
mul = 256,256,256
persistent = 0

; ----------------------------------------------------------------------
[State -2, PosAdd]
type = PosAdd
trigger1 = Stateno = [5030, 5040]
trigger1 = (anim = 5040) && (AnimElem = 1, < 2)
y = -20
persistent = 0

; Reset Super Jump var
[State -2, Super Jump Reset]
type = VarSet
trigger1 = stateno = 52
trigger2 = stateno = 0
var(0) = 0

; Remove Explods Section ==============================================
; Remove Special BG if ------------------------------------------------
; State != 3100:
[State -2, RemoveExplod]
type = RemoveExplod
trigger1 = stateno != 3100
id = 9052

; Combo Messages and Score control =====================================
; 
[State -2, VS_Combo]
type = VarSet
trigger1 = var(8) >= 3
trigger2 = var(8)=-1 && (movehit || p2stateno = 6300 || p2stateno = [5000,5899])
var(9) = 1+(var(8)>4)+(var(8)>5)+(var(8)>7)+(var(8)>9)+(var(8)>29)+(var(8)>49)+(var(8)>69)-(var(8)=-1)
ignorehitpause = 1

[State -2, Danger]
type = VarSet
trigger1 = var(10) !=1 && roundstate=2 && life = [1,250]
var(9) = 9
ignorehitpause = 1

[State -2, First Attack]
type = PlaySnd
triggerall = var(8)=-1
triggerall = NumExplod(8701) = 0
trigger1 = var(8)=-1 && (movehit || p2stateno = 6300 || p2stateno = [5000,5899])
persistent = 0
value = 230,0
volume=255
ignorehitpause = 1

[State -2, Combo Sound]
type = PlaySnd
trigger1 = NumExplod(8701) = 0
trigger1 = var(8)=0 && var(9)!=0
persistent = 0;1
value = 230,var(9)
volume=255
ignorehitpause = 1

[State -2, Left]
type = explod
trigger1 = var(8)=0 && var(9)!=0
trigger2 = var(8)=-1 && (movehit || p2stateno = 6300 || p2stateno = [5000,5899])
triggerall = TeamSide = 1 && NumExplod(8701) = 0
anim = (8000 + var(9))
ID = 8701
postype = left
pos = 0,80
ontop = 1
bindtime = -1
removetime = 60
supermovetime = 60
pausemovetime = 60
scale = 0.5,0.5
persistent = 0
ignorehitpause = 1

[State -2, Right]
type = explod
trigger1 = var(8)=0 && var(9)!=0
trigger2 = var(8)=-1 && (movehit || p2stateno = 6300 || p2stateno = [5000,5899])
triggerall = TeamSide = 2 && NumExplod(8701) = 0
anim = (8100+ var(9))
ID = 8701
postype = right
pos = -1,80
ontop = 1
bindtime = -1
removetime = 60
supermovetime = 60
pausemovetime = 60
scale = 0.5,0.5
persistent = 0;1
ignorehitpause = 1

[State -2, VS_Combo]
type = VarAdd
trigger1 = enemynear, time = 0
trigger1 = enemynear, Hitshakeover = 0
trigger1 = p2stateno = 6300 || p2stateno = [5000,5899]
trigger2 = var(8)=-1 && (movehit || p2stateno = 6300 || p2stateno = [5000,5899])
var(8) = 1 + (var(8)=-1)
ignorehitpause = 1

[State -2, VS_Combo]
type = VarSet
trigger1 = var(8)!=-1 && (p2movetype!=H || enemynear, ctrl)
trigger2 = var(8)=-1 && stateno = [5000,5899]
var(8) = 0 - (roundstate<2)
ignorehitpause = 1

[State -2, VS_Combo]
type = VarSet
triggerall = numexplod(8701)!=0
trigger1 = var(8)=0
var(9) = 0
ignorehitpause = 1

[State -2, Score]
type = Varadd
trigger1 = enemynear, time=0
trigger1 = enemynear, Hitshakeover=0
trigger1 = moveguarded || p2stateno = 6300 || p2stateno = [5000,5899]
trigger2 = var(8)=-1 && (movehit || p2stateno = 6300 || p2stateno = [5000,5899])
trigger3 = roundstate=4 && time=0 && stateno = [180,189]
var(11) = ceil(stateno/50)*var(8) + (life)*(roundstate=4) + (moveguarded)
ignorehitpause = 1

[State -2, Normalize Score]
type = Varset
triggerall = numpartner=1
trigger1 = var(11)< partner, var(11)
var(11) = partner, var(11)

[State -2, Is Danger]
type = VarSet
trigger2 = var(10) = 0 && life <= 250
trigger1 = var(10) = 1 && roundstate!=2
var(10) = (roundstate>1)
ignorehitpause = 1

[State -2, Is First Attack p3]
type = VarSet
triggerall = numpartner=1
trigger1 = partner, movehit
trigger1 = partner, var(8) != -1
var(8) = 0
ignorehitpause = 1



; ---------------------------------------------------------
; Down message (Appears when partner dies)
; sound First attack
[State -2, Finish]
type = PlaySnd
triggerall = numexplod(8580) = 0
triggerall = roundstate = 2 && p2life = 0
trigger1 = (movehit) && (p2stateno = 8000 || p2stateno = [5000,5899])
trigger2 = (numproj > 0) && (p2stateno = 8000 || p2stateno = [5000,5899])
trigger3 = (numhelper(3001) >= 1) && (p2stateno = 8000 || p2stateno = [5000,5899])
persistent = 0
value = f8560, 0
volume = 255
ignorehitpause = 1

[State -2, Left]
type = explod
triggerall = teamside = 2 && numexplod(8580) = 0
triggerall = roundstate = 2 && p2life = 0
trigger1 = (movehit) && (p2stateno = 8000 || p2stateno = [5000,5899])
trigger2 = (numproj > 0) && (p2stateno = 8000 || p2stateno = [5000,5899])
trigger3 = (numhelper(3001) >= 1) && (p2stateno = 8000 || p2stateno = [5000,5899])
anim = f221
ID = 8580
postype = left
pos = 0,100
ontop = 1
bindtime = -1
removetime = 60
supermovetime = 60
pausemovetime = 60
scale = 0.5,0.5
persistent = 0
ignorehitpause = 1

[State -2, Right]
type = explod
triggerall = teamside = 1 && numexplod(8580) = 0
triggerall = roundstate = 2 && p2life = 0
trigger1 = (movehit) && (p2stateno = 8000 || p2stateno = [5000,5899])
trigger2 = (numproj > 0) && (p2stateno = 8000 || p2stateno = [5000,5899])
trigger3 = (numhelper(3001) >= 1) && (p2stateno = 8000 || p2stateno = [5000,5899])
anim = f222
ID = 8580
postype = right
pos = -9,100
ontop = 1
bindtime = -1
removetime = 60
supermovetime = 60
pausemovetime = 60
scale = 0.5,0.5
persistent = 0;1
ignorehitpause = 1

[state 19]
type = varadd
trigger1 = RoundState = 2
var(17) = 1

[State -3, 2]
type = PlaySnd
triggerall = Time = 1
triggerall = Life
triggerall = random % 10 > 5
trigger1 = stateno = 5000 || stateno = 5020
trigger1 = anim != 5000 && anim != 5010
trigger2 = stateno = 5010
trigger2 = anim != 5020
value = 11,1
channel = 0
ignorehitpause = 1
volume = 255

[State -3, 2]
type = PlaySnd
triggerall = Time = 1
triggerall = Life
triggerall = random % 10 > 5
trigger1 = stateno = 5000 || stateno = 5020
trigger1 = anim != 5000 && anim != 5010
trigger2 = stateno = 5010
trigger2 = anim != 5020
value = 11,2
channel = 0
ignorehitpause = 1
volume = 255
