; Constants and state file.
; There are comments scattered through this file, so you may like to
; take a look if would like to learn more about the cns.

[Data]
life = 900			;Amount of life to start with
power = 3000		;Amount of maximum power
attack = 100		;attack power (more is stronger)
defence = 100		;defensive power (more is stronger)
fall.defence_up = 50	;Percentage to increase defense everytime player is knocked down
liedown.time = 60		;Time which player lies down for, before getting up
airjuggle = 15		;Number of points for juggling
sparkno = 2			;Default hit spark number for HitDefs
guard.sparkno = 40	;Default guard spark number
KO.echo = 0			;1 to enable echo on KO
volume = 0			;Volume offset (negative for softer)
IntPersistIndex = 45,47	;Variables with this index and above will not have their values
FloatPersistIndex = 40  ;reset to 0 between rounds or matches. There are 60 int variables,
  				;indexed from 0 to 59, and 40 float variables, indexed from 0 to 39.
  				;If omitted, then it defaults to 60 and 40 for integer and float
  				;variables repectively, meaning that none are persistent, i.e. all
  				;are reset. If you want your variables to persist between matches,
  				;you need to override state 5900 from common1.cns.


[Size]
xscale = 1			;Horizontal scaling factor.
yscale = 1			;Vertical scaling factor.
ground.back = 13		;Player width (back, ground)
ground.front = 16		;Player width (front, ground)
air.back = 12		;Player width (back, air)
air.front = 12		;Player width (front, air)
height = 60			;Height of player (for opponent to jump over)
attack.dist = 160		;Default attack distance
proj.attack.dist = 90	;Default attack distance for projectiles
proj.doscale = 0		;Set to 1 to scale projectiles too   
head.pos = -5, -90	;Approximate position of head
mid.pos = -5, -60		;Approximate position of midsection
shadowoffset = 0		;Number of pixels to vertically offset the shadow
draw.offset = 0,0		;Player drawing offset in pixels (x, y)

[Velocity]
walk.fwd  = 2.5		;Walk forward
walk.back = -2.8		;Walk backward
run.fwd  = 6.6, 0		;Run forward (x, y)
run.back = -4,-3	;Hop backward (x, y)
jump.neu = 0,-9		;Neutral jumping velocity (x, y)
jump.back = -2.55		;Jump back Speed (x, y)
jump.fwd = 3.0		;Jump forward Speed (x, y)
runjump.back = -2.55,-8.1;Running jump speeds (opt)
runjump.fwd = 4,-8.1	;.
airjump.neu = 0,-8.1	;.
airjump.back = -2.55	;Air jump speeds (opt)
airjump.fwd = 2.5		;.

[Movement]
airjump.num = 0		;Number of air jumps allowed (opt)
airjump.height = 35	;Minimum distance from ground before you can air jump (opt)
yaccel = .44		;Vertical acceleration
stand.friction = .85	;Friction coefficient when standing
crouch.friction = .82	;Friction coefficient when crouching

[Quotes]
Victory1 = "Stay out of my way."
Victory2 = "This was a waste of time."
Victory3 = "Every moment I waste here, Madoka is...! I need to hurry!"
Victory4 = "Everything's so different this time...Just where am I?"
Victory5 = "I've never seen you before. Is this due to restarting the timeline?"

;---------------------------------------------------------------------------
; Format:
; [Statedef STATENO]
; type = ?      S/C/A/L  stand/crouch/air/liedown
; movetype = ?  I/A/H    idle/attack/gethit
; physics = ?   S/C/A/N  stand/crouch/air/none
; juggle = ?             air juggle points move requires
;
; [State STATENO, ?]     ? - any number you choose
; type = ?
; ...

;---------------------------------------------------------------------------
; Lose by Time Over
; CNS difficulty: basic
[Statedef 170]
type = S
ctrl = 0
anim = 170
velset = 0,0

[State 170, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 3
value = S170,0+Random%3
channel = 0

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

;---------------------------------------------------------------------------
; Win state decider
; CNS difficulty: basic
[Statedef 180]
type = S

[State 180, 1]
type = ChangeState
trigger1 = Time = 0
value = 181

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

[State 181, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S180,0+random%3
channel = 0

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

;---------------------------------------------------------------------------
; Introduction
; CNS difficulty: basic
[Statedef 190]
type = S
ctrl = 0
anim = 190
velset = 0,0

[State 190, 2] ;Assert this until you want "round 1, fight" to begin
type = AssertSpecial
trigger1 = 1
flag = Intro

[State 190, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 25
value = S190,0+Random%3
Channel = 0

[State 190, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 25
value = S100,19

[State 190, Explod]
type = Explod
trigger1 = AnimElem = 25
anim = 191
pos = 0,0
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
sprpriority = 10

[State 190, Explod]
type = Explod
trigger1 = AnimElem = 27
anim = 192
pos = 0,0
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
sprpriority = 5

[State 190, Explod]
type = Explod
trigger1 = AnimElem = 33
anim = 193
pos = 0,0
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
sprpriority = 5

[State 190, 4] ;Change to stand state
type = ChangeState
trigger1 = AnimTime = 0
value = 0

;---------------------------------------------------------------------------
; Taunt
; CNS difficulty: easy
[Statedef 195]
type = S
ctrl = 0
anim = 195
velset = 0,0
movetype = I
physics = S
sprpriority = 2

[State 195, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 8
value = S195,0+Random%2
channel = 0

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

;---------------------------------------------------------------------------
; Standing Light Punch
; CNS difficulty: easy
[Statedef 200]
type    = S				;State-type: S-stand, C-crouch, A-air, L-liedown
movetype= A				;Move-type: A-attack, I-idle, H-gethit
physics = S				;Physics: S-stand, C-crouch, A-air
velset = 0,0			;Set velocity (x,y) (Def: no change)
ctrl = 0				;Set ctrl (Def: no change)
anim = 200				;Change animation (Def: no change)
sprpriority = 2			;Set layering priority to 2 (in front)
facep2 = 1

[State 200, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 2
value = S100,0

[State 200, PlaySnd]
type = PlaySnd
triggerall = MoveType != H && Random < 650
trigger1 = time = 1
value = S400,0+random%3
channel = 0

[State 200, Explod]
type = Explod
trigger1 = AnimElem = 2
anim = 201
ID = 201
pos = 0,0
postype = p1
sprpriority = 4
bindtime = -1
ownpal = 1
removeongethit = 1
ignorehitpause = 0
pausemovetime = 9999

[State 200, HitDef]
type = HitDef
trigger1 = AnimElem = 2
attr = S, NA
damage = IfElse(Var(10),17,14)
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 6,8
sparkno = -1+(0*(var(41) := 8050))
guard.sparkno = -1+(0*(var(42) := 9000))
sparkxy = 0,0+(0*(var(43) := 100 && var(44) := -15))
hitsound = S200,0
guardsound = S300,0
ground.type = High
ground.slidetime = 8
ground.hittime  = 8
ground.velocity = -4.8,0
guard.velocity = -4.8
air.velocity = -1.0,-4.4
getpower = 20
givepower = 15
yaccel = 0.35

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

;---------------------------------------------------------------------------
; Standing Medium Punch
; CNS difficulty: easy
[Statedef 210]
type    = S
movetype= A
physics = S
ctrl = 0
velset = 0,0
anim = 210
facep2 = 1

[State 210, VelAdd]
type = VelAdd
trigger1 = AnimElem = 4
x = 5

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

[State 210, PlaySnd]
type = PlaySnd
triggerall = MoveType != H && Random < 650
trigger1 = time = 1
value = S400,3+random%3
channel = 0

[State 210, HitDef]
type = HitDef
trigger1 = AnimElem = 4
attr = S, NA
damage = IfElse(Var(10),22,18)
animtype = Light
guardflag = MA
hitflag = MAF
priority = 3, Hit
pausetime = 6,8
sparkno = -1+(0*(var(41) := 8050))
guard.sparkno = -1+(0*(var(42) := 9000))
sparkxy = 0,0+(0*(var(43) := 100 && var(44) := -50))
hitsound = S200,0
guardsound = S300,0
ground.type = High
ground.slidetime = 8
ground.hittime  = 8
ground.velocity = -4.8,0
guard.velocity = -4.8
air.velocity = -1.0,-4.4
getpower = 30
givepower = 15
yaccel = 0.35

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

;---------------------------------------------------------------------------
; Standing Strong Punch
; CNS difficulty: easy
[Statedef 220]
type    = S
movetype= A
physics = S
ctrl = 0
velset = 0,0
anim = 220
facep2 = 1

[State 220, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 4
value = S100,2

[State 220, PlaySnd]
type = PlaySnd
triggerall = MoveType != H && Random < 650
trigger1 = time = 1
value = S400,6+random%3
channel = 0

[State 220, VelAdd]
type = VelAdd
trigger1 = AnimElem = 4
x = 6

[State 220, Explod]
type = Explod
trigger1 = AnimElem = 4
anim = 221
ID = 221
pos = -10,7
postype = p1
sprpriority = 4
bindtime = -1
ownpal = 1
removeongethit = 1
ignorehitpause = 0
pausemovetime = 9999

[State 220, HitDef]
type = HitDef
trigger1 = AnimElem = 4
attr = S, NA
damage = IfElse(Var(10),30,25)
animtype = Heavy
guardflag = MA
hitflag = MAF
priority = 5, Hit
pausetime = 8,13
sparkno = -1+(0*(var(41) := 8052))
guard.sparkno = -1+(0*(var(42) := 9000))
sparkxy = 0,0+(0*(var(43) := 100 && var(44) := -65))
hitsound = S200,2
guardsound = S300,0
ground.type = high
ground.slidetime = 18
ground.hittime = 18
ground.velocity = -6
airguard.ctrltime = 2
guard.velocity = -6
air.velocity = -1.5,-4.4
envshake.time = 9
envshake.ampl = 3
getpower = 50
givepower = 15
yaccel = 0.35

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

;---------------------------------------------------------------------------
; Crouching Light Punch
; CNS difficulty: easy
; Description: Simple crouching attack. The HitDef's guardflag parameter
;     is set to "L", meaning that the move can only be guarded low
;     (crouching), and not by standing or jumping opponents.
;     Like for all light attacks, it's a good idea to keep the slidetime
;     and hittime parameters at a smaller number, so the opponent isn't
;     stunned for too long. For all crouching attacks you have to
;     remember to set the attr parameter to indicate that it is crouching
;     attack. In this case, "C, NA" stands for "crouching, normal attack".
;     The HitDef's priority is set at 3, instead of the default of 4,
;     so this attack has a lower priority than most others, meaning the
;     player will get hit instead of trading hits with the opponent if
;     their attack collision boxes (Clsn1) intersect each other's Clsn2
;     boxes at the same time.
[Statedef 400]
type    = C
movetype= A
physics = C
ctrl = 0
anim = 400
facep2 = 1

[State 400, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 2
value = S100,0

[State 400, PlaySnd]
type = PlaySnd
triggerall = MoveType != H && Random < 650
trigger1 = time = 1
value = S400,0+random%3
channel = 0

[State 400, HitDef]
type = HitDef
trigger1 = AnimElem = 2
attr = S, NA
damage = IfElse(Var(10),15,13)
animtype = Light
guardflag = L
hitflag = MAF
priority = 3, Hit
pausetime = 6,7
sparkno = -1+(0*(var(41) := 8050))
guard.sparkno = -1+(0*(var(42) := 9000))
sparkxy = 0,0+(0*(var(43) := 100 && var(44) := -35))
hitsound = S200,0
guardsound = S300,0
ground.type = High
ground.slidetime = 8
ground.hittime = 8
ground.velocity = -5.2,0
guard.velocity = -5.2
air.velocity = -1.0,-4.4
getpower = 20
givepower = 15
yaccel = 0.35

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

;---------------------------------------------------------------------------
; Crouching Medium Punch
[Statedef 410]
type    = C
movetype= A
physics = C
ctrl = 0
anim = 410
facep2 = 1

[State 410, PlaySnd]
type = PlaySnd
triggerall = MoveType != H && Random < 650
trigger1 = time = 1
value = S400,3+random%3
channel = 0

[State 410, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 3
value = S100,4

[State 410, Explod]
type = Explod
trigger1 = AnimElem = 3
anim = 411
ID = 411
pos = 50,0
postype = p1
sprpriority = 0
bindtime = -1
ownpal = 1
scale = .8,.8
removeongethit = 1
ignorehitpause = 0
pausemovetime = 9999

[State 400, HitDef]
type = HitDef
triggerall = !MoveContact && !MoveReversed
trigger1 = AnimElemTime(3) >= 0
trigger1 = AnimElemTime(5) < 0
attr = S, NA
damage = IfElse(Var(10),22,18)
animtype = Light
guardflag = L
hitflag = MAF
priority = 3, Hit
pausetime = 6,8
sparkno = -1+(0*(var(41) := 8050))
guard.sparkno = -1+(0*(var(42) := 9000))
sparkxy = 0,0+(0*(var(43) := 100 && var(44) := -5))
hitsound = S200,0
guardsound = S300,0
ground.type = High
ground.slidetime = 8
ground.hittime = 8
ground.velocity = -5.2,0
guard.velocity = -5.2
air.velocity = -1.0,-4.4
getpower = 30
givepower = 15
yaccel = 0.35

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

;---------------------------------------------------------------------------
; Crouching Strong Punch
[Statedef 420]
type    = C
movetype= A
physics = C
ctrl = 0
anim = 420
facep2 = 1

[State 420, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 4
value = S100,8

[State 420, Explod]
type = Explod
trigger1 = AnimElem = 4
anim = 421
ID = 421
pos = 35,-90
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .3,.3
sprpriority = 5
removeongethit = 0
ownpal = 1
supermovetime = 9999
pausemovetime = 9999

[State 420, Helper]
type = Helper
trigger1 = AnimElem = 4
helpertype = normal
name= "Casing"
ID = 1002
StateNo = 1002
pos = 0,-75
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 420, Helper]
type = Helper
trigger1 = AnimElem = 4
name = "Bullet"
Stateno = 421
ID = 421
postype = p1
pos = 15,-70
ownpal = 1
ignorehitpause = 1

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

[StateDef 421]
Type = A
Movetype = A
Physics = N
Anim = 422
Ctrl = 0
Sprpriority = 5

[State 421, ParentVarAdd]
type = ParentVarAdd
trigger1 = IsHelper(421)
trigger1 = NumHelper(421)
trigger1 = Helper(421),MoveHit = 1
var(45) = 12-27*(!!Root,Var(46))

[State 421, ParentVarAdd]
type = ParentVarAdd
trigger1 = IsHelper(421)
trigger1 = NumHelper(421)
trigger1 = Helper(421),MoveGuarded = 1
var(45) = 6-21*(!!Root,Var(46))

[State 421, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow
ignorehitpause = 1

[State 421, Trans]
type = Trans
trigger1 = 1
trans = Add

[State 421, VelSet]
type = VelSet
trigger1 = 1
x = 20
y = -20

[State 421, HitDef]
type = HitDef
trigger1 = AnimElem = 1
attr = S,NP
animtype  = Hard
damage = ceil(IfElse(Root,Var(10),35,29)*(root,fvar(1)*root,fvar(2)))
hitflag = MAF
guardflag = MA
pausetime = 1,13
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,2
guardsound = S300,0
ground.type = high
ground.slidetime = 11
ground.hittime = 11
ground.velocity = -0.5,-4.4
guard.velocity = -6.4
air.velocity = -1.5,-4.4
fall = 1
fall.recover = 1
getpower = 45
givepower = 15
envshake.time = 9
envshake.ampl = 2
fall.recovertime = 20

[State 421, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8052
stateno = 8052
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 60)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 0

[State 421, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 60)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 0

[State 421, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 421, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 421, DestroySelf]
type = DestroySelf
trigger1 = MoveContact
trigger2 = FrontEdgeBodyDist <= -42
trigger3 = time >= 60

;---------------------------------------------------------------------------
; Jump Light Punch
; CNS difficulty: easy
[Statedef 600]
type    = A
movetype= A
physics = A
ctrl = 0
anim = 600

[State 600, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 2
value = S100,0

[State 600, PlaySnd]
type = PlaySnd
triggerall = MoveType != H && Random < 650
trigger1 = time = 1
value = S400,0+random%3
channel = 0

[State 600, Explod]
type = Explod
trigger1 = AnimElem = 2
anim = 601
ID = 601
pos = 0,0
postype = p1
sprpriority = 4
bindtime = -1
ownpal = 1
removeongethit = 1
ignorehitpause = 0
pausemovetime = 9999

[State 600, HitDef]
type = HitDef
trigger1 = AnimElem = 2
attr = A, NA
damage = IfElse(Var(10),13,11)
animtype = Light
guardflag = HA
hitflag = MAF
priority = 3, Hit
pausetime = 7,7
sparkno = -1+(0*(var(41) := 8050))
guard.sparkno = -1+(0*(var(42) := 9000))
sparkxy = 0,0+(0*(var(43) := 100 && var(44) := -35))
hitsound = S200,0
guardsound = S300,0
ground.type = High
airguard.ctrltime = 10
ground.slidetime = 10
ground.hittime = 10
ground.velocity = -5.2,0
air.velocity = -1.5,-6.1
getpower = 24
givepower = 15
yaccel = 0.4

[State 600, 5]
type = CtrlSet
trigger1 = Time = 12
value = 1

;---------------------------------------------------------------------------
; Jump Medium Punch
; CNS difficulty: easy
[Statedef 610]
type    = A
movetype= A
physics = A
ctrl = 0
anim = 610

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

[State 610, PlaySnd]
type = PlaySnd
triggerall = MoveType != H && Random < 650
trigger1 = time = 1
value = S400,3+random%3
channel = 0

[State 610, HitDef]
type = HitDef
trigger1 = AnimElem = 2
attr = A, NA
damage = IfElse(Var(10),22,18)
animtype = hard
guardflag = HA
hitflag = MAF
priority = 4, Hit
pausetime = 8,9
sparkno = -1+(0*(var(41) := 8051))
guard.sparkno = -1+(0*(var(42) := 9000))
sparkxy = 0,0+(0*(var(43) := 100 && var(44) := -40))
hitsound = S200,1
guardsound = S300,0
ground.type = low
ground.slidetime = 13
ground.hittime  = 13
airguard.ctrltime = 12
ground.velocity = -5.2
air.velocity = -1.5,-6.1
getpower = 35
givepower = 15
yaccel = 0.4
envshake.time = 9
envshake.ampl = 2

[State 610, 5]
type = CtrlSet
trigger1 = Time = 14
value = 1

;---------------------------------------------------------------------------
; Jump Strong Punch
; CNS difficulty: easy
[Statedef 620]
type    = A
movetype= A
physics = A
ctrl = 0
anim = 620

[State 620, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 5
value = S100,2

[State 620, PlaySnd]
type = PlaySnd
triggerall = MoveType != H && Random < 650
trigger1 = time = 1
value = S400,6+random%3
channel = 0

[State 620, HitDef]
type = HitDef
trigger1 = AnimElem = 5
attr = A, NA
damage = IfElse(Var(10),30,25)
guardFlag = HA
priority = 3, Hit
pauseTime = 10,15
guard.PauseTime = 8,8
hitSound = S200,2
guardSound = S300,0
sparkno = -1+(0*(var(41) := 8052))
guard.sparkno = -1+(0*(var(42) := 9000))
sparkxy = 0,0+(0*(var(43) := 100 && var(44) := -55))
animtype = Heavy
ground.type = High
ground.slideTime = 13
ground.hitTime = 13
ground.velocity = -5.6
guard.velocity = -6
air.velocity = -1.5,-6.1
airguard.velocity = -3,-1.9
down.velocity = -2.4,-2.5
ground.cornerPush.VelOff = -6
air.cornerPush.VelOff = -2.2
down.cornerPush.VelOff = -4.4
yaccel = .44
air.fall = 1
fall.recoverTime = 26
getpower = 50
givepower = 15
envshake.time = 9
envshake.ampl = 3

[StateDef 700]
type = S
movetype = I
physics = S
poweradd = 0
velset = 0,0
anim = 700
ctrl = 0
sprpriority = 2

[State 700, VarAdd]
type = VarAdd
triggerall = Var(46) = 0
trigger1 = Var(47) >= 1
trigger1 = Time = 0
trigger1 = Anim = 700
v = 47
Value = -2

[State 700, VarAdd]
type = VarAdd
triggerall = Var(46) = 1
trigger1 = Var(47) >= 1
trigger1 = Time = 0
trigger1 = Anim = 700
v = 47
Value = -1

[State 700, PlaySnd]
type = PlaySnd
trigger1 = AnimTime = 0
trigger1 = Anim = 700
value = S100,10

[State 700, PosAdd]
type = PosAdd
trigger1 = AnimTime = 0
trigger1 = Anim = 700
x = 300

[State 700, ChangeAnim]
type = ChangeAnim
trigger1 = AnimTime = 0
trigger1 = Anim = 700
value = 701

[State 700, Turn]
type = Turn
trigger1 = P2bodydist X < -30

[State 700, ChangeState]
type = ChangeState
trigger1 = AnimTime = 0
trigger1 = Anim = 701
value = 0
ctrl = 1

[StateDef 710]
type = S
movetype = I
physics = S
poweradd = 0
velset = 0,0
anim = 700
ctrl = 0
sprpriority = 2

[State 710, VarAdd]
type = VarAdd
triggerall = Var(46) = 0
trigger1 = Var(47) >= 1
trigger1 = Time = 0
trigger1 = Anim = 700
v = 47
Value = -2

[State 710, VarAdd]
type = VarAdd
triggerall = Var(46) = 1
trigger1 = Var(47) >= 1
trigger1 = Time = 0
trigger1 = Anim = 700
v = 47
Value = -1

[State 710, PlaySnd]
type = PlaySnd
trigger1 = AnimTime = 0
trigger1 = Anim = 700
value = S100,10

[State 710, PosAdd]
type = PosAdd
trigger1 = AnimTime = 0
trigger1 = Anim = 700
x = -100

[State 710, ChangeAnim]
type = ChangeAnim
trigger1 = AnimTime = 0
trigger1 = Anim = 700
value = 701

[State 710, ChangeState]
type = ChangeState
trigger1 = AnimTime = 0
trigger1 = Anim = 701
value = 0
ctrl = 1

[StateDef 720]
type = A
movetype = I
physics = S
poweradd = 0
velset = 0,0
anim = 700
ctrl = 0
sprpriority = 2

[State 720, VarAdd]
type = VarAdd
triggerall = Var(46) = 0
trigger1 = Var(47) >= 1
trigger1 = Time = 0
trigger1 = Anim = 700
v = 47
Value = -2

[State 720, VarAdd]
type = VarAdd
triggerall = Var(46) = 1
trigger1 = Var(47) >= 1
trigger1 = Time = 0
trigger1 = Anim = 700
v = 47
Value = -1

[State 720, PlaySnd]
type = PlaySnd
trigger1 = AnimTime = 0
trigger1 = Anim = 700
value = S100,10

[State 720, PosAdd]
type = PosAdd
trigger1 = AnimTime = 0
y = -120

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

[StateDef 730]
type = A
movetype = I
physics = N
poweradd = 0
velset = 0,0
anim = 730
ctrl = 0
sprpriority = 2

[State 730, VarAdd]
type = VarAdd
triggerall = Var(46) = 0
trigger1 = Var(47) >= 1
trigger1 = Time = 0
trigger1 = Anim = 730
v = 47
Value = -2

[State 730, VarAdd]
type = VarAdd
triggerall = Var(46) = 1
trigger1 = Var(47) >= 1
trigger1 = Time = 0
trigger1 = Anim = 730
v = 47
Value = -1

[State 730, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S100,10

[State 730, PosSet]
type = PosSet
trigger1 = Time = 0
y = 0

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

[StateDef 740]
type = A
movetype = I
physics = N
poweradd = 0
velset = 0,0
anim = 740
ctrl = 0
sprpriority = 2

[State 740, VarAdd]
type = VarAdd
triggerall = Var(46) = 0
trigger1 = Var(47) >= 1
trigger1 = Time = 0
trigger1 = Anim = 740
v = 47
Value = -2

[State 740, VarAdd]
type = VarAdd
triggerall = Var(46) = 1
trigger1 = Var(47) >= 1
trigger1 = Time = 0
trigger1 = Anim = 740
v = 47
Value = -1

[State 740, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S100,10

[State 740, Turn]
type = Turn
trigger1 = P2bodydist X < -30

[State 740, PosAdd]
type = PosAdd
trigger1 = Time = 0
x = 150

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

[StateDef 750]
type = A
movetype = I
physics = N
poweradd = 0
velset = 0,0
anim = 740
ctrl = 0
sprpriority = 2

[State 750, VarAdd]
type = VarAdd
triggerall = Var(46) = 0
trigger1 = Var(47) >= 1
trigger1 = Time = 0
trigger1 = Anim = 740
v = 47
Value = -2

[State 750, VarAdd]
type = VarAdd
triggerall = Var(46) = 1
trigger1 = Var(47) >= 1
trigger1 = Time = 0
trigger1 = Anim = 740
v = 47
Value = -1

[State 750, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S100,10

[State 750, PosAdd]
type = PosAdd
trigger1 = Time = 0
x = -150

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

[StateDef 760]
Type = S
Physics = S
MoveType = I
Anim = 760
VelSet = 0,0
Poweradd = 0
ctrl = 0
sprpriority = 2

[State 760, VarAdd]
type = VarAdd
triggerall = Var(47) < 10
trigger1 = Var(48) = 0
trigger1 = Var(49) <= 0
trigger1 = AnimElem = 5
v = 47
Value = 2

[State 760, VarAdd]
type = VarAdd
triggerall = Var(47) < 10
trigger1 = Var(48) >= 1
trigger1 = Var(48) <= 5
trigger1 = Var(49) <= 0
trigger1 = AnimElem = 5
v = 47
Value = 1

[State 760, VarSet]
type = VarSet
trigger1 = Var(47) > 10
trigger1 = AnimElem = 5
V = 47
Value = 10

[State 760, VarSet]
type = VarSet
trigger1 = AnimElem = 5
V = 48
Value = 10

[State 760, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 5
value = S100,12

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

;---------------------------------------------------------------------------
; Throw - Attempt
; CNS difficulty: medium-advanced
; Description: Throws are not difficult to make, although then can be
;     tedious at times. Throw attempt states have a HitDef of a
;     special format. The key parameters in a throw are p1stateno
;     and p2stateno. If the HitDef successfully connects, then
;     the attacker will change to the state number specified by
;     p1stateno, and the opponent will be change to the state
;     number assigned to p2stateno. The special thing about p2stateno
;     is that the opponent will be temporarily brought into the
;     attacker's state file. In this case, no matter who the
;     opponent is, he will be taken to state 820 of this file (kfm.cns)
;     and remain here until the end of the throw (look at his debug
;     information when he is being thrown; the text changes to yellow
;     to mean that he is in another player's state file).
[Statedef 800]
type    = S
movetype= A
physics = S
juggle  = 0
velset = 0,0
ctrl = 0
anim = 800

; Notes: The '-' symbol in the hitflag field means that it only affects
;   players who are not in a hit state. This prevents the player from combo-ing
;   into the throw. The priority should be set to a low number, such as
;   1 or 2, so that the throw does not take precedence over normal attacks.
;   The type of priority must always be set to "Miss" or "Dodge" for throws,
;   otherwise strange behavior can result.
[State 800, 1]
type = HitDef
Trigger1 = AnimElem = 1
attr = S, NT          ;Attributes: Standing, Normal Throw
hitflag = M-          ;Affect only ground people who are not being hit
priority = 1, Miss    ;Throw has low priority, must be miss or dodge type.
sparkno = -1          ;No spark
sprpriority = 1       ;Draw in front of p2
p1facing = 1 ;Turn if holding forwards
p2facing = 1          ;Force p2 to face player
p1stateno = 810       ;On success, player changes to state 810
p2stateno = 820       ;If hit, p2 changes to state 820 in player's cns
fall = 1              ;Force p2 into falling down

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

[StateDef 810]
type = A
movetype = A
physics = A
anim = 810
vel = 0,-2
sprpriority = -2

[State 810, VarAdd]
type = VarAdd
trigger1 = Var(46) = 0
trigger1 = MoveHit = 1
v = 45
value = 12

[State 810, VarAdd]
type = VarAdd
trigger1 = Var(46) = 0
trigger1 = MoveGuarded = 1
v = 45
value = 6

[State 810, VarAdd]
type = VarAdd
trigger1 = Var(46) = 1
trigger1 = MoveContact = 1
v = 45
value = -15

[State 810, PosAdd]
type = PosAdd
trigger1 = time = 0
x = 80
y = -60

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

[State 810, Turn]
type = Turn
trigger1 = time = 0

[State 810, SuperPause]
type = SuperPause
trigger1 = time = 3
time = 5
anim = -1
darken = 0
movetime = 0

[State 810, HitDef]
type = HitDef
trigger1 = AnimElem = 3
attr = A, NA
damage = 90
animtype = Medium
guardflag = MA
hitflag = MAF
priority = 7, Hit
pausetime = 15,15
sparkno = -1+(0*(var(41) := 8052))
guard.sparkno = -1+(0*(var(42) := 9000))
sparkxy = 0,0+(0*(var(43) := 100 && var(44) := -30))
hitsound = S200,2
guardsound = S300,0
ground.type = High
ground.slidetime = 15
ground.hittime = 15
ground.velocity = -4.8,0
guard.velocity = -4.8
air.velocity = -1.0,-4.4
fall = 1

[StateDef 820]
type  = S
movetype = H
physics = N
velset = 0,0
anim = 0
ctrl = 0

[State 820, ChangeState]
type = ChangeState
trigger1 = time = 20
value = 0
ctrl = 1

[StateDef 950]
Type = S
MoveType = I
Physics = N
VelSet = 0,0
Anim = 950
ctrl = 0

[State 950, VarAdd]
type = VarAdd
trigger1 = Var(46) = 1
trigger1 = Time = 0
v = 45
Value = -100

[State 950, PowerAdd]
type = PowerAdd
trigger1 = Var(46) = 0
trigger1 = time = 0
value = -1000

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

[State 950, Pause]
type = Pause
trigger1 = time = 0
time = 80
movetime = 80

[State 950, Helper]
type = Helper
trigger1 = Time = 0
Helpertype = normal
StateNo = 951
ID = 951
name = "Guard_Counter"
postype = p1
pos = ceil(0 * const(size.xscale)), ceil(-55 * const(size.yscale))
supermovetime = 9999
pausemovetime = 9999
ownpal = 1

[State 950, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S10000,3

[State 950, PosAdd]
type = PosAdd
trigger1 = AnimElem = 2
x = (P2Dist X)+150

[State 950, Turn]
type = Turn
trigger1 = AnimElem = 2

[State 950, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 2
value = S100,22

[State 950, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 2
value = S100,10

[State 950, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 3
value = S100,11

[State 950, PlaySnd]
type = PlaySnd
trigger1 = time = 40
value = S410,13
Channel = 0

[State 950, Explod]
type = Explod
trigger1 = AnimElem = 2
ID = 3000
anim = 3000
postype = back
pos = 150, 50
bindtime = -1
removetime = -2
sprpriority = 0
ownpal = 1
supermovetime = 9999
pausemovetime = 9999
scale = .5,.5

[State 950, Helper]
type = Helper
trigger1 = AnimElem = 2
name = "Pipebomb"
ID = 952
stateno = 952
pos = 0,IfElse(P2STateType != A,0,-50)
postype = p2
ownpal = 1
supermovetime = 9999
pausemovetime = 9999
ignorehitpause = 1

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

[StateDef 951]
Type = A
Physics = N
MoveType = I
Anim = 99999
ctrl = 0
velset = 0,0

[State 951, BGPalFX]
type = BGPalFX
trigger1 = 1
time = 1
color= 16*time
mul = 16*time, 16*time, 16*time

[State 951, Explod]
type = Explod
trigger1 = Time = 0
Anim = 952
ID = 952
sprpriority = 3
postype = p1
removetime = 16
pausemovetime = 9999
supermovetime = 9999
ownpal = 1

[State 951, ModifyExplod]
type = ModifyExplod
trigger1 = NumExplod(952)
ID = 952
scale = (.0625*time), (.0625*time)
trans = addalpha
alpha = 256-(16*time), 256

[State 951, Explod]
type = Explod
trigger1 = time = 0
anim = 953
ID = 953
sprpriority = -2
postype = p1
pos = 0,-ceil(pos y)
pausemovetime = 99999
supermovetime = 99999
ownpal = 1

[State 951, DestroySelf]
type = DestroySelf
trigger1= time >= 16

[StateDef 952]
Type = S
Movetype = I
Physics = N
Anim = 951
Ctrl = 0
Sprpriority = 5

[State 952, TargetBind]
type = TargetBind
trigger1 = time = 0
time = -1

[State 952, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 2
value = S100,31

[State 952, ChangeState]
type = ChangeState
trigger1 = Time >= 60
value = 953

[StateDef 953]
Type = A
Movetype = A
Physics = N
Anim = 1103
Velset = 0, 0
Ctrl = 0
Sprpriority = 4

[State 953, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow
ignorehitpause = 1

[State 953, Trans]
type = Trans
trigger1 = 1
trans = Add

[State 953, EnvShake]
type = EnvShake
Trigger1 = time = 0
time = 10
ampl = 20
freq = 127

[State 953, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S100,29

[State 953, HitDef]
type = HitDef
triggerall = !MoveContact && !MoveReversed
trigger1 = AnimElemTime(4) >= 0
trigger1 = AnimElemTime(11) < 0
attr = A,HA
damage = ceil(100*(root,fvar(1)*root,fvar(2))),
animtype = Heavy
guardflag =
hitflag = MAF
priority = 5, Hit
pausetime = 0,7
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,8
guardsound = S300,0
ground.type = high
ground.slidetime = 30
ground.hittime = 30
ground.velocity = -1.5,-12
guard.velocity = -3
air.velocity = -1.5,-12
yaccel = 0.4
fall = 1
fall.recover = 0
getpower = 0
palFX.time = 60
palFX.mul = 128, 128, 128
palFX.sinAdd = 96, 96, 96, 4

[State 953, Helper]
type = Helper
trigger1 = !NumHelper(8100)
trigger1 = MoveHit = 1 && NumTarget
trigger1 = var(43) := (Target, ID)
helperType = Normal
stateNo = 8100
ID = 8100
name = "Burning"
posType = P2
ownPal = 1
ignoreHitPause = 1

[State 953, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8053
stateno = 8053
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 4

[State 953, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 953, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 953, DestroySelf]
type = DestroySelf
trigger1 = AnimTime = 0

[StateDef 1000]
type = S
movetype = A
physics = N
anim = 1000
ctrl = 0
facep2 = 1
VelSet = 0,0
sprpriority = 1
PowerAdd = 110

[State 1000, VarAdd]
type = VarAdd
trigger1 = Var(48) >= 1
trigger1 = Anim = 1000
trigger1 = AnimElem = 8
v = 48
Value = -1

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

[State 1000, ChangeAnim]
type = ChangeAnim
trigger1 = Var(48) = 0
trigger1 = time = 0
value = 1003

[State 1000, PlaySnd]
type = PlaySnd
trigger1 = Anim = 1000
trigger1 = AnimElem = 8
value = S100,9

[State 1000, PlaySnd]
type = PlaySnd
trigger1 = Anim = 1003
trigger1 = AnimElem = 7
value = S100,11

[State 1000, Explod]
type = Explod
trigger1 = Anim = 1000
trigger1 = AnimElem = 8
anim = 421
ID = 421
pos = 65,-75
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .3,.3
sprpriority = 5
removeongethit = 0
ownpal = 1
supermovetime = 9999
pausemovetime = 9999

[State 1000, Helper]
type = Helper
trigger1 = Anim = 1000
trigger1 = AnimElem = 8
name = "Bullet"
Stateno = 1003
ID = 1003
postype = p1
pos = 50,-75
ownpal = 1
ignorehitpause = 1

[State 1000, VelSet]
type = VelSet
trigger1 = Anim = 1000
trigger1 = AnimElemTime(8) = 0
x = -8

[State 1000, VelSet]
type = VelSet
trigger1 = Anim = 1000
trigger1 = AnimElemTime(9) = 0
x = 0

[State 1000, Helper]
type = Helper
trigger1 = Anim = 1000
trigger1 = AnimElem = 8
helpertype = normal
name= "Casing"
ID = 1002
StateNo = 1002
pos = 25,-85
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 1000, HitDef]
type = HitDef
trigger1 = AnimElem = 5
attr = A,SA
damage = IfElse(Var(10),12,10)
animtype = Heavy
guardflag = MA
hitflag = MAF
priority = 5, Hit
pausetime = 0,7
guard.pausetime = 0,6
sparkno = -1+(0*(var(41) := 8050))
guard.sparkno = -1+(0*(var(42) := 9000))
sparkxy = 0,0+(0*(var(43) := 100 && var(44) := -65))
hitsound = S200,0
guardsound = S300,0
ground.type = high
ground.slidetime = 18
ground.hittime = 18
ground.velocity = -3
airguard.ctrltime = 2
guard.velocity = -3
air.velocity = -1.5,-2.4
envshake.time = 9
envshake.ampl = 3
getpower = 0
yaccel = 0.4

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

[StateDef 1001]
type = S
movetype = I
physics = N
anim = 1001
ctrl = 0
facep2 = 1
VelSet = 0,0
sprpriority = 1
PowerAdd = 50

[State 1001, VarAdd]
type = VarAdd
triggerall = Var(46) = 1
trigger1 = Anim = 1001
trigger1 = time = 0
v = 45
value = -15

[State 1001, VarAdd]
type = VarAdd
trigger1 = Anim = 1001
trigger1 = Time = 0
v = 0
value = 1

[State 1001, VarAdd]
type = VarAdd
trigger1 = Var(48) >= 1
trigger1 = Anim = 1001
trigger1 = AnimElem = 3
v = 48
Value = -1

[State 1001, ChangeAnim]
type = ChangeAnim
trigger1 = Var(48) = 0
trigger1 = time = 0
value = 1004

[State 1001, PlaySnd]
type = PlaySnd
trigger1 = Anim = 1001
trigger1 = AnimElem = 3
value = S100,9

[State 1001, PlaySnd]
type = PlaySnd
trigger1 = Anim = 1003
trigger1 = AnimElem = 2
value = S100,11

[State 1001, Helper]
type = Helper
trigger1 = Anim = 1001
trigger1 = AnimElem = 3
helpertype = normal
name= "Casing"
ID = 1002
StateNo = 1002
pos = 25,-85
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 1001, Explod]
type = Explod
trigger1 = Anim = 1001
trigger1 = AnimElem = 3
anim = 421
ID = 421
pos = 65,-70
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .3,.3
sprpriority = 5
removeongethit = 0
supermovetime = 9999
pausemovetime = 9999
ownpal = 1

[State 1001, VelSet]
type = VelSet
trigger1 = Anim = 1001
trigger1 = AnimElemTime(3) = 0
x = -8

[State 1001, VelSet]
type = VelSet
trigger1 = Anim = 1001
trigger1 = AnimElemTime(4) = 0
x = 0

[State 1001, Helper]
type = Helper
trigger1 = Anim = 1001
trigger1 = AnimElem = 3
name = "Bullet"
Stateno = 1004
ID = 1004
postype = p1
pos = 50,-75
ownpal = 1
ignorehitpause = 1

[State 1001, ChangeState]
type = ChangeState
trigger1 = AnimTime = 0
trigger2 = Anim = 1004
trigger2 = AnimTime = 0
value = 0
ctrl = 1

[StateDef 1002]
type = A
movetype = I
physics = N
Anim = 1005
ctrl = 0
sprpriority = 5

[State 1002, VarAdd]
type = VarAdd
trigger1 = Anim = 1006
var(0) = 1

[State 1002, ChangeAnim]
type = ChangeAnim
trigger1 = Pos y > 0
value = 1006

[State 1002, PlaySnd]
type = PlaySnd
trigger1 = !IsHelper(2000)
trigger1 = Pos y > 0
value = S100,15

[State 1002, VelSet]
type = VelSet
trigger1 = Time = 0
x= -4-(Random/Abs(333))
y= -3-(Random/Abs(-333))

[State 1002, VelAdd]
type = VelAdd
trigger1 = Anim = 1005
trigger2 = Anim = 1006
y = 0.5

[State 1002, VelSet]
type = VelSet
trigger1 = Anim = 1006
trigger1 = Pos y > 0
y = -5

[State 1002, VelMul]
type = VelMul
trigger1 = Anim = 1006
trigger1 = AnimElemTime(1) > 0
x = 0.95

[State 1002, Trans]
type = Trans
trigger1 = Anim = 1006
trans = AddAlpha
alpha = Ceil(256-12.8*(0.5*Var(0))),Ceil(128+6.4*(0.5*Var(0)))

[State 1002, DestroySelf]
type = DestroySelf
trigger1 = Anim = 1006
trigger1 = var(0) > 40

[StateDef 1003]
Type = A
Movetype = A
Physics = N
Anim = 1002
Ctrl = 0
Sprpriority = 5

[State 1003, ParentVarAdd]
type = ParentVarAdd
trigger1 = IsHelper(1003)
trigger1 = NumHelper(1003)
trigger1 = Helper(1003),MoveHit = 1
var(45) = 12-27*(!!Root,Var(46))

[State 1003, ParentVarAdd]
type = ParentVarAdd
trigger1 = IsHelper(1003)
trigger1 = NumHelper(1003)
trigger1 = Helper(1003),MoveGuarded = 1
var(45) = 6-21*(!!Root,Var(46))

[State 1003, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow
ignorehitpause = 1

[State 1003, Trans]
type = Trans
trigger1 = 1
trans = Add

[State 1003, VelSet]
type = VelSet
trigger1 = 1
x = 30

[State 1003, HitDef]
type = HitDef
trigger1 = AnimElem = 1
attr = S,SP
animtype  = Hard
damage = ceil(IfElse(Root,Var(10),48,40)*(root,fvar(1)*root,fvar(2))),4
hitflag = MAF
guardflag = MA
pausetime = 1,13
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,2
guardsound = S300,0
ground.type = high
ground.slidetime = 15
ground.hittime = 15
ground.velocity = -8
air.velocity = -8,-1
fall = 1
fall.recover = 1
envshake.time = 10
envshake.ampl = 3
fall.recovertime = 35

[State 1003, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8054
stateno = 8054
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 60)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 0

[State 1003, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 60)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 0

[State 1003, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 1003, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 1003, DestroySelf]
type = DestroySelf
trigger1 = MoveContact
trigger2 = FrontEdgeBodyDist <= -42

[StateDef 1004]
Type = A
Movetype = A
Physics = N
Anim = 1002
Ctrl = 0
Sprpriority = 5

[State 1004, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow
ignorehitpause = 1

[State 1004, Trans]
type = Trans
trigger1 = 1
trans = Add

[State 1004, VelSet]
type = VelSet
trigger1 = 1
x = 30

[State 1004, HitDef]
type = HitDef
trigger1 = AnimElem = 1
attr = S,SP
animtype  = Hard
damage = ceil(IfElse(Root,Var(10),19,16)*(root,fvar(1)*root,fvar(2))),4
hitflag = MAF
guardflag = MA
pausetime = 0,13
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,2
guardsound = S300,0
ground.type = high
ground.slidetime = 15
ground.hittime = 15
ground.velocity = -8
air.velocity = -8,-1
fall = 1
fall.recover = 1
envshake.time = 10
envshake.ampl = 3
fall.recovertime = 35

[State 1004, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8054
stateno = 8054
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 60)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 0

[State 1004, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 60)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 0

[State 1004, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 1004, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 1004, DestroySelf]
type = DestroySelf
trigger1 = MoveContact
trigger2 = FrontEdgeBodyDist <= -42

[StateDef 1010]
type = A
movetype = A
physics = N
anim = 1010
ctrl = 0
PowerAdd = 110

[State 1010, VarAdd]
type = VarAdd
trigger1 = Var(48) >= 1
trigger1 = Anim = 1010
trigger1 = AnimElem = 8
v = 48
Value = -1

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

[State 1010, ChangeAnim]
type = ChangeAnim
trigger1 = Var(48) = 0
trigger1 = time = 0
value = 1013

[State 1010, PlaySnd]
type = PlaySnd
trigger1 = Anim = 1010
trigger1 = AnimElem = 6
value = S100,9

[State 1010, PlaySnd]
type = PlaySnd
trigger1 = Anim = 1013
trigger1 = AnimElem = 6
value = S100,11

[State 1010, Explod]
type = Explod
trigger1 = Anim = 1010
trigger1 = AnimElem = 6
anim = 421
ID = 421
pos = 35,-15
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .3,.3
sprpriority = 5
removeongethit = 0
ownpal = 1
supermovetime = 9999
pausemovetime = 9999

[State 1010, Helper]
type = Helper
trigger1 = Anim = 1010
trigger1 = AnimElem = 6
helpertype = normal
name= "Casing"
ID = 1002
StateNo = 1002
pos = 25,-85
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 1010, Helper]
type = Helper
trigger1 = Anim = 1010
trigger1 = AnimElem = 6
name = "Bullet"
Stateno = 1012
ID = 1012
postype = p1
pos = 15,-35
ownpal = 1
ignorehitpause = 1

[State 1010, VelSet]
Type = VelSet
trigger1 = Time > 0
trigger1 = Time <= 13
X = 0
Y = 0

[State 1010, VelSet]
Type = VelSet
trigger1 = Anim = 1010
trigger1 = AnimElem = 6
X = -3
Y = -3

[State 1010, VelAdd]
type = VelAdd
trigger1 = AnimElemTime(7) > 0
Y = 0.5

[State 1010, HitDef]
type = HitDef
trigger1 = AnimElem = 4
attr = A,SA
damage = IfElse(Var(10),12,10)
animtype = Heavy
guardflag = MA
hitflag = MAF
priority = 5, Hit
pausetime = 0,7
guard.pausetime = 0,6
sparkno = -1+(0*(var(41) := 8050))
guard.sparkno = -1+(0*(var(42) := 9000))
sparkxy = 0,0+(0*(var(43) := 100 && var(44) := -45))
hitsound = S200,0
guardsound = S300,0
ground.type = high
ground.slidetime = 18
ground.hittime = 18
ground.velocity = -3
airguard.ctrltime = 2
guard.velocity = -3
air.velocity = -3,-1
envshake.time = 9
envshake.ampl = 3
getpower = 0
yaccel = 0.4

[State 1010, ChangeState]
type = ChangeState
trigger1 = vel Y > 0
trigger1 = pos Y >= 0
value = 1014

[StateDef 1011]
type = A
movetype = I
physics = N
anim = 1011
ctrl = 0
facep2 = 1
VelSet = 0,0
sprpriority = 1
PowerAdd = 30

[State 1011, VarAdd]
type = VarAdd
triggerall = Var(46) = 1
trigger1 = Anim = 1011
trigger1 = time = 0
v = 45
value = -15

[State 1011, VarAdd]
type = VarAdd
trigger1 = Var(48) >= 1
trigger1 = Anim = 1011
trigger1 = AnimElem = 3
v = 48
Value = -1

[State 1011, ChangeAnim]
type = ChangeAnim
trigger1 = Var(48) = 0
trigger1 = time = 0
value = 1014

[State 1011, VarAdd]
type = VarAdd
trigger1 = Anim = 1011
trigger1 = Time = 0
v = 0
value = 1

[State 1011, PlaySnd]
type = PlaySnd
trigger1 = Anim = 1011
trigger1 = AnimElem = 3
value = S100,9

[State 1011, PlaySnd]
type = PlaySnd
trigger1 = Anim = 1014
trigger1 = AnimElem = 3
value = S100,11

[State 1011, Explod]
type = Explod
trigger1 = Anim = 1011
trigger1 = AnimElem = 3
anim = 421
ID = 421
pos = 35,-15
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .3,.3
sprpriority = 5
removeongethit = 0
ownpal = 1
supermovetime = 9999
pausemovetime = 9999

[State 1011, Helper]
type = Helper
trigger1 = Anim = 1011
trigger1 = AnimElem = 3
name = "Bullet"
Stateno = 1013
ID = 1013
postype = p1
pos = 15,-35
ownpal = 1
ignorehitpause = 1

[State 1011, Helper]
type = Helper
trigger1 = Anim = 1011
trigger1 = AnimElem = 3
helpertype = normal
name= "Casing"
ID = 1002
StateNo = 1002
pos = 25,-85
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 1011, VelSet]
Type = VelSet
trigger1 = Time > 0
trigger1 = Time <= 6
X = 0
Y = 0

[State 1011, VelSet]
Type = VelSet
trigger1 = Anim = 1011
trigger1 = AnimElem = 3
X = -2
Y = -2

[State 1011, VelAdd]
type = VelAdd
trigger1 = AnimElemTime(5) > 0
Y = 0.5

[State 1011, ChangeState]
type = ChangeState
trigger1 = vel Y > 0
trigger1 = pos Y >= 0
value = 1014

[StateDef 1012]
Type = A
Movetype = A
Physics = N
Anim = 1012
Ctrl = 0
Sprpriority = 5

[State 1012, ParentVarAdd]
type = ParentVarAdd
trigger1 = IsHelper(1012)
trigger1 = NumHelper(1012)
trigger1 = Helper(1012),MoveHit = 1
trigger2 = IsHelper(1301)
trigger2 = NumHelper(1301)
trigger2 = Helper(1301),MoveHit = 1
var(45) = 12-27*(!!Root,Var(46))

[State 1012, ParentVarAdd]
type = ParentVarAdd
trigger1 = IsHelper(1012)
trigger1 = NumHelper(1012)
trigger1 = Helper(1012),MoveGuarded = 1
trigger2 = IsHelper(1301)
trigger2 = NumHelper(1301)
trigger2 = Helper(1301),MoveGuarded = 1
var(45) = 6-21*(!!Root,Var(46))

[State 1012, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow
ignorehitpause = 1

[State 1012, Trans]
type = Trans
trigger1 = 1
trans = Add

[State 1012, VelSet]
type = VelSet
trigger1 = 1
x = 20
y = 20

[State 1012, HitDef]
type = HitDef
trigger1 = !IsHelper(1301)
trigger1 = AnimElem = 1
attr = S,SP
animtype  = Hard
damage = ceil(IfElse(Root,Var(10),48,40)*(root,fvar(1)*root,fvar(2))),4
hitflag = MAF
guardflag = MA
pausetime = 1,13
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,2
guardsound = S300,0
ground.type = high
ground.slidetime = 15
ground.hittime = 15
ground.velocity = -8
air.velocity = -8,-1
fall = 1
fall.recover = 1
envshake.time = 10
envshake.ampl = 3
fall.recovertime = 35

[State 1012, HitDef]
type = HitDef
trigger1 = IsHelper(1301)
trigger1 = AnimElem = 1
attr = S,SP
animtype = Hard
damage = ceil(100*(root,fvar(1)*root,fvar(2))),20
hitflag = MAF
guardflag = MA
pausetime = 1,13
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,2
guardsound = S300,0
ground.type = high
ground.slidetime = 15
ground.hittime = 15
ground.velocity = -8,10
air.velocity = -8,10
guard.velocity = -3
fall = 1
fall.recover = 0
envshake.time = 10
envshake.ampl = 3

[State 1012, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8054
stateno = 8054
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 60)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 0

[State 1012, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 60)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 0

[State 1012, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 1012, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 1012, DestroySelf]
type = DestroySelf
trigger1 = MoveContact
trigger2 = FrontEdgeBodyDist <= -42
trigger3 = Pos Y >= 0

[StateDef 1013]
Type = A
Movetype = A
Physics = N
Anim = 1012
Ctrl = 0
Sprpriority = 5

[State 1013, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow
ignorehitpause = 1

[State 1013, Trans]
type = Trans
trigger1 = 1
trans = Add

[State 1013, VelSet]
type = VelSet
trigger1 = 1
x = 20
y = 20

[State 1013, HitDef]
type = HitDef
trigger1 = AnimElem = 1
attr = S,SP
animtype  = Hard
damage = ceil(IfElse(Root,Var(10),19,16)*(root,fvar(1)*root,fvar(2))),4
hitflag = MAF
guardflag = MA
pausetime = 1,13
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,2
guardsound = S300,0
ground.type = high
ground.slidetime = 15
ground.hittime = 15
ground.velocity = -8
air.velocity = -8,-1
fall = 1
fall.recover = 1
envshake.time = 10
envshake.ampl = 3
fall.recovertime = 35

[State 1013, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8054
stateno = 8054
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 60)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 0

[State 1013, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 60)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 0

[State 1013, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 1013, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 1013, DestroySelf]
type = DestroySelf
trigger1 = MoveContact
trigger2 = FrontEdgeBodyDist <= -42
trigger3 = Pos Y >= 0

[StateDef 1014]
type = S
movetype = I
physics = N
velset = 0,0
poweradd = 0
ctrl = 0
anim = 1015
sprpriority = 2

[State 1014, PosSet]
type = PosSet
trigger1 = Time = 0
y = 0

[State 1014, Explod]
type = Explod
trigger1 = Time = 0
anim = 8020
sprpriority = -3
postype = p1
scale= 0.5,0.5
pausemovetime = -1
supermovetime = -1
ownpal = 1

[State 1014, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 1
value = S40,0

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

[StateDef 1100]
Type = S
Movetype = I
Physics = N
Anim = 1100
Velset = 0, 0
Ctrl = 0
facep2 = 1
Poweradd = 100

[State 1100, VarAdd]
type = VarAdd
trigger1 = Var(46) = 1
trigger1 = Var(47) >= 1
trigger1 = Var(48) >= 3
trigger1 = AnimElem = 5
v = 47
Value = -1

[State 1100, VarAdd]
type = VarAdd
trigger1 = Var(48) >= 3
trigger1 = AnimElem = 8
v = 48
Value = -3

[State 1100, Explod]
type = Explod
trigger1 = time = 2
anim = 1104
ID = 1104
pos = 0,0
postype = p1
sprpriority = 4
bindtime = -1
ownpal = 1
removeongethit = 1
ignorehitpause = 0
pausemovetime = 9999

[State 1100, Helper]
type = Helper
trigger1 = Var(48) >= 3
trigger1 = AnimElem = 4
name = "Mortar"
Stateno = 1101
ID = 1101
postype = p1
pos = 50,0
ownpal = 1
ignorehitpause = 1
pausemovetime = 21

[State 1100, Helper]
type = Helper
trigger1 = Var(46) = 1
trigger1 = Var(47) >= 1
trigger1 = Var(48) >= 3
trigger1 = AnimElem = 4
name = "Mortar"
Stateno = 1101
ID = 1105
postype = p1
pos = -50,0
ownpal = 1
ignorehitpause = 1
pausemovetime = 21

[State 1100, Helper]
type = Helper
trigger1 = Var(48) <= 2
trigger1 = AnimElem = 4
name = "Mortar Dud"
Stateno = 1104
ID = 1104
postype = p1
pos = 50,0
ownpal = 1
ignorehitpause = 1
pausemovetime = 21

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

[StateDef 1101]
Type = A
Movetype = A
Physics = N
Anim = 1101
Ctrl = 0
Sprpriority = 5

[State 1101, ParentVarAdd]
type = ParentVarAdd
trigger1 = IsHelper(1101)
trigger1 = MoveHit = 1
trigger2 = IsHelper(1105)
trigger2 = MoveHit = 1
var(45) = 12-22*(!!Root,Var(46))

[State 1101, ParentVarAdd]
type = ParentVarAdd
trigger1 = IsHelper(1101)
trigger1 = MoveGuarded = 1
trigger2 = IsHelper(1105)
trigger2 = MoveGuarded = 1
var(45) = 6-16*(!!Root,Var(46))

[State 1101, ParentVarAdd]
type = ParentVarAdd
trigger1 = NumHelper(1102)
trigger1 = Helper(1102),MoveHit = 1
trigger2 = NumHelper(1106)
trigger2 = Helper(1106),MoveHit = 1
var(45) = 6-16*(!!Root,Var(46))

[State 1101, ParentVarAdd]
type = ParentVarAdd
trigger1 = NumHelper(1102)
trigger1 = Helper(1102),MoveGuarded = 1
trigger2 = NumHelper(1106)
trigger2 = Helper(1106),MoveGuarded = 1
var(45) = 3-13*(!!Root,Var(46))

[State 1101, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S100,20

[State 1101, PlaySnd]
type = PlaySnd
trigger1 = time = 20
value = S100,21

[State 1101, Explod]
type = Explod
trigger1 = time = 0
anim = 1105
ID = 1105
pos = -85,0
postype = p1
sprpriority = 4
bindtime = -1
ownpal = 1
removeongethit = 1
ignorehitpause = 0
pausemovetime = 9999

[State 1101, Explod]
type = Explod
trigger1 = time = 20
anim = 1106
ID = 1106
pos = -85,0
postype = p1
sprpriority = 4
bindtime = -1
ownpal = 1
removeongethit = 1
ignorehitpause = 0
pausemovetime = 9999

[State 1101, Explod]
type = Explod
trigger1 = time = 98
anim = 1107
ID = 1107
pos = -85,0
postype = p1
sprpriority = 4
bindtime = -1
ownpal = 1
removeongethit = 1
ignorehitpause = 0

[State 1101, HitDef]
type = HitDef
trigger1 = AnimElem = 1
attr = S,SA
damage = IfElse(Root,Var(10),12,10)
animtype = Heavy
guardflag = MA
hitflag = MAF
priority = 5, Hit
pausetime = 0,7
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,0
guardsound = S300,0
ground.type = high
ground.slidetime = 18
ground.hittime = 18
ground.velocity = -3
airguard.ctrltime = 2
guard.velocity = -3
air.velocity = -1.5,-2.4
envshake.time = 9
envshake.ampl = 3
getpower = 0
yaccel = 0.4

[State 1101, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8054
stateno = 8054
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 1

[State 1101, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 1

[State 1101, Helper]
type = Helper
trigger1 = IsHelper(1101)
trigger1 = time = 20
name = "Mortar Bomb"
Stateno = 1102
ID = 1102
postype = p1
pos = 18,-68
ownpal = 1
ignorehitpause = 1
pausemovetime = 5

[State 1101, Helper]
type = Helper
trigger1 = IsHelper(1105)
trigger1 = time = 20
name = "Mortar Bomb"
Stateno = 1102
ID = 1106
postype = p1
pos = 18,-68
ownpal = 1
ignorehitpause = 1
pausemovetime = 5

[State 1101, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 1101, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 1101, DestroySelf]
type = DestroySelf
trigger1 = time = 100

[StateDef 1102]
Type = A
Movetype = A
Physics = N
Anim = 1102
Ctrl = 0
Sprpriority = 5

[State 1102, VarSet]
type = VarSet
trigger1 = MoveContact
var(0) = 1+(MoveGuarded != 0)

[State 1102, HitOverride]
type = HitOverride
trigger1 = 1
attr = SCA,AA,AP,AT
time = -1
StateNo = 1103
ignorehitpause = 1

[State 1102, HitBy]
type = HitBy
trigger1 = 1
value = SCA,AP
time = -1

[State 1102, AngleAdd]
type = AngleAdd
trigger1 = time > 10
value = -4

[State 1102, AngleDraw]
type = AngleDraw
trigger1 = time > 10

[State 1102, VelSet]
type = VelSet
trigger1 = time = 0
x = 4
y = -10

[State 1102, VelAdd]
type = VelAdd
trigger1 = time = 10
x = -1

[State 1102, Gravity]
trigger1 = 1
type = Gravity

[State 1102, Explod]
type = Explod
trigger1 = (time%3) = 0
anim = 1207
ID = 1207
pos = 0,0
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .3,.3
sprpriority = 5
removeongethit = 0

[State 1102, HitDef]
type= HitDef
trigger1 = !Movecontact
attr = A,SP
hitflag	= MAF
guardflag = MA
damage = ceil(IfElse(Root,Var(10),12,10)*(root,fvar(1)*root,fvar(2))),2
animtype = Medium
air.animtype = Back
ground.type = High
priority = 6, Hit
pausetime = 0, 1
sparkno = -1
guard.sparkno = -1
sparkxy	= 0,0
hitsound = S200,0
guardsound = S300,0
ground.slidetime = 0
ground.hittime = 0
guard.hittime = 0
ground.velocity	= 0,-5
guard.velocity = 0
air.velocity = 0,-5
fall = 1
fall.recover = 1
fall.recovertime = 39
yaccel = 0.4

[State 1102, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8050
stateno = 8050
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 4

[State 1102, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 4

[State 1102, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 1102, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 1102, ChangeState]
type = ChangeState
trigger1 = time = 70
trigger2 = Var(0)
trigger3 = pos y > 0 && vel y > 0
value = 1103

[StateDef 1103]
Type = A
Movetype = A
Physics = N
Anim = 1103
Velset = 0, 0
Ctrl = 0
Sprpriority = 4

[State 1103, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow
ignorehitpause = 1

[State 1103, Trans]
type = Trans
trigger1 = 1
trans = Add

[State 1103, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S100,14

[State 1103, HitDef]
type = HitDef
triggerall = IsHelper(1102)
triggerall = !MoveContact && !MoveReversed
trigger1 = AnimElemTime(1) >= 0
trigger1 = AnimElemTime(12) < 0
attr = A,SA
damage = ceil(IfElse(Root,Var(10),66,55)*(root,fvar(1)*root,fvar(2))),10
animtype = Heavy
guardflag = MA
hitflag = MAF
priority = 5, Hit
pausetime = 0,7
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,2
guardsound = S300,0
ground.type = high
ground.slidetime = 20
ground.hittime = 20
ground.velocity = -1,-9
guard.velocity = -3
air.velocity = -1,-9
envshake.time = 10
envshake.ampl = 3
yaccel = 0.44
fall = 1
fall.recover = 1
fall.recovertime = 39
palFX.time = 45
palFX.mul = 128, 128, 128
palFX.sinAdd = 96, 96, 96, 4

[State 1103, HitDef]
type = HitDef
triggerall = IsHelper(1106)
triggerall = !MoveContact && !MoveReversed
trigger1 = AnimElemTime(1) >= 0
trigger1 = AnimElemTime(12) < 0
attr = A,SA
damage = ceil(IfElse(Root,Var(10),30,25)*(root,fvar(1)*root,fvar(2))),5
animtype = Heavy
guardflag = MA
hitflag = MAF
priority = 5, Hit
pausetime = 0,7
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,2
guardsound = S300,0
ground.type = high
ground.slidetime = 20
ground.hittime = 20
ground.velocity = -1,-9
guard.velocity = -3
air.velocity = -1,-9
envshake.time = 10
envshake.ampl = 3
yaccel = 0.44
fall = 1
fall.recover = 1
fall.recovertime = 39
palFX.time = 45
palFX.mul = 128, 128, 128
palFX.sinAdd = 96, 96, 96, 4

[State 1103, Helper]
type = Helper
trigger1 = !NumHelper(8100)
trigger1 = MoveHit = 1 && NumTarget
trigger1 = var(43) := (Target, ID)
helperType = Normal
stateNo = 8100
ID = 8100
name = "Burning"
posType = P2
ownPal = 1
ignoreHitPause = 1

[State 1103, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8054
stateno = 8054
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 60)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 4

[State 1103, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 60)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 4

[State 1103, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 1103, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 1103, DestroySelf]
type = DestroySelf
trigger1 = AnimTime = 0

[StateDef 1104]
Type = A
Movetype = A
Physics = N
Anim = 1108
Ctrl = 0
Sprpriority = 5

[State 1104, ParentVarAdd]
type = ParentVarAdd
trigger1 = IsHelper(1104)
trigger1 = NumHelper(1104)
trigger1 = Helper(1104),MoveHit = 1
var(45) = 12-27*(!!Root,Var(46))

[State 1104, ParentVarAdd]
type = ParentVarAdd
trigger1 = IsHelper(1104)
trigger1 = NumHelper(1104)
trigger1 = Helper(1104),MoveGuarded = 1
var(45) = 6-21*(!!Root,Var(46))

[State 1104, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S100,20

[State 1104, PlaySnd]
type = PlaySnd
trigger1 = time = 20
value = S100,11

[State 1104, Explod]
type = Explod
trigger1 = time = 0
anim = 1105
ID = 1105
pos = -85,0
postype = p1
sprpriority = 4
bindtime = -1
ownpal = 1
removeongethit = 1
ignorehitpause = 0
pausemovetime = 9999

[State 1104, Explod]
type = Explod
trigger1 = time = 58
anim = 1107
ID = 1107
pos = -85,0
postype = p1
sprpriority = 4
bindtime = -1
ownpal = 1
removeongethit = 1
ignorehitpause = 0

[State 1104, HitDef]
type = HitDef
trigger1 = AnimElem = 1
attr = S,SA
damage = IfElse(Root,Var(10),12,10)
animtype = Heavy
guardflag = MA
hitflag = MAF
priority = 5, Hit
pausetime = 0,7
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,0
guardsound = S300,0
ground.type = high
ground.slidetime = 18
ground.hittime = 18
ground.velocity = -3
airguard.ctrltime = 2
guard.velocity = -3
air.velocity = -1.5,-2.4
envshake.time = 9
envshake.ampl = 3
getpower = 0
yaccel = 0.4

[State 1104, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8054
stateno = 8054
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 4

[State 1104, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 4

[State 1104, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 1104, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 1104, DestroySelf]
type = DestroySelf
trigger1 = time = 60

[StateDef 1200]
Type = S
Movetype= A
Physics = S
Anim = 1200
Velset = 0, 0
Ctrl = 0
facep2 = 1
Poweradd = 110

[State 1200, VarAdd]
type = VarAdd
trigger1 = Var(48) >= 2
trigger1 = Anim = 1200
trigger1 = AnimElem = 6
v = 48
Value = -2

[State 1200, VarAdd]
type = VarAdd
trigger1 = Var(46) = 1
trigger1 = Var(47) >= 1
trigger1 = Anim = 1200
trigger1 = Time = 29
v = 47
Value = -1

[State 1200, ChangeAnim]
type = ChangeAnim
trigger1 = Var(48) < 2
trigger1 = time = 0
value = 1206

[State 1200, PlaySnd]
type = PlaySnd
trigger1 = Anim = 1200
trigger1 = Time = 26
value = S100,13

[State 1200, PlaySnd]
type = PlaySnd
trigger1 = Anim = 1206
trigger1 = AnimElem = 4
value = S100,11

[State 1200, Explod]
type = Explod
trigger1 = Anim = 1200
trigger1 = Time = 26
anim = 1203
ID = 1203
pos = -65,-85
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .5,.5
sprpriority = 5
pausemovetime = 9999
ownpal = 1

[State 1200, Helper]
type = Helper
trigger1 = Var(46) = 0
trigger1 = Anim = 1200
trigger1 = Time = 26
name = "RPG"
Stateno = 1201
ID = 1201
postype = p1
pos = 41,-81
ownpal = 1
ignorehitpause = 1

[State 1200, Helper]
type = Helper
trigger1 = Var(46) = 1
trigger1 = Var(47) = 0
trigger1 = Anim = 1200
trigger1 = Time = 26
name = "RPG"
Stateno = 1201
ID = 1201
postype = p1
pos = 41,-81
ownpal = 1
ignorehitpause = 1

[State 1200, Helper]
type = Helper
trigger1 = Var(46) = 1
trigger1 = Var(47) >= 1
trigger1 = Anim = 1200
trigger1 = Time = 26
name = "RPG"
Stateno = 1203
ID = 1203
postype = p1
pos = 41,-81
ownpal = 1
ignorehitpause = 1

[State 1200, ChangeAnim]
type = ChangeAnim
trigger1 = Anim = 1200
trigger1 = Time = 60
value = 1201

[State 1200, ChangeAnim]
type = ChangeState
trigger1 = AnimTime = 0
trigger1 = Anim = 1201
trigger2 = AnimTime = 0
trigger2 = Anim = 1206
value = 0
ctrl = 1

[StateDef 1201]
Type = A
Movetype = A
Physics = N
Anim = 1202
Ctrl = 0
Sprpriority = 5

[State 1201, ParentVarAdd]
type = ParentVarAdd
trigger1 = IsHelper(1201)
trigger1 = NumHelper(1201)
trigger1 = Helper(1201),MoveHit = 1
var(45) = 12-27*(!!Root,Var(46))

[State 1201, ParentVarAdd]
type = ParentVarAdd
trigger1 = IsHelper(1201)
trigger1 = NumHelper(1201)
trigger1 = Helper(1201),MoveGuarded = 1
var(45) = 6-21*(!!Root,Var(46))

[State 1201, VarSet]
type = VarSet
trigger1 = MoveContact
var(0) = 1+(MoveGuarded != 0)

[State 1201, HitOverride]
type = HitOverride
trigger1 = 1
attr = SCA,AA,AP,AT
time = -1
StateNo = 1202
ignorehitpause = 1

[State 1201, HitBy]
type = HitBy
trigger1 = 1
value = SCA,AP
time = -1

[State 1201, VelSet]
type = VelSet
trigger1 = Time > 0
x = 15

[State 1201, Explod]
type = Explod
trigger1 = (time%3) = 0
anim = 1207
ID = 1207
pos = 0,0
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .3,.3
sprpriority = 5
removeongethit = 0

[State 1201, HitDef]
type= HitDef
trigger1 = AnimElem = 1
attr = A,SP
hitflag	= MAF
guardflag = MA
damage = ceil(IfElse(Root,Var(10),30,25)*(root,fvar(1)*root,fvar(2))),2
animtype = Medium
air.animtype = Back
ground.type = High
priority = 6, Hit
pausetime = 0, 1
sparkno = -1
guard.sparkno = -1
sparkxy	= 0,0
hitsound = -1
guardsound = S300, 0
ground.slidetime = 0
ground.hittime = 0
guard.hittime = 0
ground.velocity	= 0,-5
guard.velocity = 0
air.velocity = 0,-5
fall = 1
fall.recover = 1
fall.recovertime = 39
yaccel = 0.4
getpower = 0

[State 1201, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 1201, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 1201, ChangeState]
type = ChangeState
trigger1 = Var(0)
value = 1202

[State 1201, DestroySelf]
type = DestroySelf
trigger1 = FrontEdgeBodyDist <= -42

[StateDef 1202]
Type = A
Movetype = A
Physics = N
Anim = 1204
Velset = 0, 0
Ctrl = 0
Sprpriority = 4

[State 1202, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow
ignorehitpause = 1

[State 1202, Trans]
type = Trans
trigger1 = 1
trans = Add

[State 1202, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S100,14

[State 1202, HitDef]
type = HitDef
triggerall = !MoveContact && !MoveReversed
trigger1 = AnimElemTime(1) >= 0
trigger1 = AnimElemTime(12) < 0
attr = A,SA
damage = ceil(IfElse(Root,Var(10),90,75)*(root,fvar(1)*root,fvar(2))),20
animtype = Heavy
guardflag = MA
hitflag = MAF
priority = 5, Hit
pausetime = 0,7
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,2
guardsound = S300,0
ground.type = high
ground.slidetime = 20
ground.hittime = 20
ground.velocity = -1,-5
guard.velocity = -3
air.velocity = -1,-5
envshake.time = 10
envshake.ampl = 3
yaccel = 0.4
fall = 1
fall.recover = 1
fall.recovertime = 39
palFX.time = 45
palFX.mul = 128, 128, 128
palFX.sinAdd = 96, 96, 96, 4

[State 1202, Helper]
type = Helper
trigger1 = !NumHelper(8100)
trigger1 = MoveHit = 1 && NumTarget
trigger1 = var(43) := (Target, ID)
helperType = Normal
stateNo = 8100
ID = 8100
name = "Burning"
posType = P2
ownPal = 1
ignoreHitPause = 1

[State 1202, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8054
stateno = 8054
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 4

[State 1202, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 4

[State 1202, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 1202, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 1202, DestroySelf]
type = DestroySelf
trigger1 = AnimTime = 0

[StateDef 1203]
Type = A
Movetype = A
Physics = N
Anim = 1205
Ctrl = 0
Sprpriority = 5

[State 1203, ParentVarAdd]
type = ParentVarAdd
trigger1 = IsHelper(1203)
trigger1 = NumHelper(1203)
trigger1 = Helper(1203),MoveHit = 1
var(45) = 12-27*(!!Root,Var(46))

[State 1203, ParentVarAdd]
type = ParentVarAdd
trigger1 = IsHelper(1203)
trigger1 = NumHelper(1203)
trigger1 = Helper(1203),MoveGuarded = 1
var(45) = 6-21*(!!Root,Var(46))

[State 1203, VarSet]
type = VarSet
trigger1 = MoveContact
var(0) = 1+(MoveGuarded != 0)

[State 1203, HitOverride]
type = HitOverride
trigger1 = 1
attr = SCA,AA,AP,AT
time = -1
StateNo = 1202
ignorehitpause = 1

[State 1203, HitBy]
type = HitBy
trigger1 = 1
value = SCA,AP
time = -1

[State 1203, AngleSet]
type = AngleSet
trigger1 = Vel x != 0
value = Atan(Vel y/Vel x)*(-180.0/pi)+((Vel x<0)*180) + 90

[State 1203, AngleSet]
type = AngleSet
trigger1 = Vel x = 0
value = IfElse(Vel y<0,90,-90)

[State 1203, AngleDraw]
type = AngleDraw
trigger1 = 1

[State 1203, Turn]
type = Turn
trigger1 = Time > 5
trigger1 = (P2Dist X < 10)

[State 1203, VelSet]
type = VelSet
trigger1 = (!Time)
x = 10

[State 1203, VelAdd]
type = VelAdd
trigger1 = Time > 5
trigger1 = (P2Dist X < 0) && (Vel X > -6)
x = -0.2

[State 1203, VelAdd]
type = VelAdd
trigger1 = Time > 5
trigger1 = (P2Dist X > 0) && (Vel X < 6)
x = 0.2

[State 1203, VelAdd]
type = VelAdd
trigger1 = Time > 5
trigger1 = (EnemyNear, Pos Y > Pos Y) && (Vel Y < 6)
y = 0.2

[State 1203, VelAdd]
type = VelAdd
trigger1 = Time > 5
trigger1 = (EnemyNear, Pos Y <= Pos Y) && (Vel Y > -6)
y = -0.2

[State 1203, Explod]
type = Explod
trigger1 = (time%3) = 0
anim = 1207
ID = 1207
pos = 0,0
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .3,.3
sprpriority = 5
removeongethit = 0

[State 1203, HitDef]
type= HitDef
trigger1 = AnimElem = 1
attr = A,SP
hitflag	= MAF
guardflag = MA
damage = ceil(IfElse(Root,Var(10),30,25)*(root,fvar(1)*root,fvar(2))),2
animtype = Medium
air.animtype = Back
ground.type = High
priority = 6, Hit
pausetime = 0, 1
sparkno = -1
guard.sparkno = -1
sparkxy	= 0,0
hitsound = -1
guardsound = S300, 0
ground.slidetime = 0
ground.hittime = 0
guard.hittime = 0
ground.velocity	= 0,-5
guard.velocity = 0
air.velocity = 0,-5
fall = 1
fall.recover = 1
fall.recovertime = 39
yaccel = 0.4
getpower = 0

[State 1203, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 1203, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 1203, ChangeState]
type = ChangeState
trigger1 = Var(0)
trigger2 = Time > 150
value = 1204

[StateDef 1204]
Type = A
Movetype = A
Physics = N
Anim = 1204
Velset = 0, 0
Ctrl = 0
Sprpriority = 4

[State 1204, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow
ignorehitpause = 1

[State 1204, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S100,14

[State 1204, HitDef]
type = HitDef
triggerall = !MoveContact && !MoveReversed
trigger1 = AnimElemTime(1) >= 0
trigger1 = AnimElemTime(12) < 0
attr = A,SA
damage = ceil(IfElse(Root,Var(10),98,82)*(root,fvar(1)*root,fvar(2))),24
animtype = Heavy
guardflag = MA
hitflag = MAF
priority = 5, Hit
pausetime = 0,7
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,2
guardsound = S300,0
ground.type = high
ground.slidetime = 20
ground.hittime = 20
ground.velocity = -1,-5
guard.velocity = -3
air.velocity = -1,-5
envshake.time = 10
envshake.ampl = 3
yaccel = 0.4
fall = 1
fall.recover = 1
fall.recovertime = 39
palFX.time = 45
palFX.mul = 128, 128, 128
palFX.sinAdd = 96, 96, 96, 4

[State 1204, Helper]
type = Helper
trigger1 = !NumHelper(8100)
trigger1 = MoveHit = 1 && NumTarget
trigger1 = var(43) := (Target, ID)
helperType = Normal
stateNo = 8100
ID = 8100
name = "Burning"
posType = P2
ownPal = 1
ignoreHitPause = 1

[State 1204, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8054
stateno = 8054
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 4

[State 1204, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 4

[State 1204, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 1204, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 1204, DestroySelf]
type = DestroySelf
trigger1 = AnimTime = 0

[StateDef 1300]
type = S
physics = S
velset = 0,0
poweradd = 100
ctrl = 0
anim = 1300
sprpriority = 2

[State 1300, ReversalDef]
type = ReversalDef
triggerall = Anim = 1300
trigger1 = AnimElem = 3
trigger2 = AnimElem = 4
trigger3 = AnimElem = 5
trigger4 = AnimElem = 6
reversal.attr = SCA, NA, SA
pausetime = 10,60
attr = S, SA
sparkno = -1
hitsound = S300,0
sprpriority = -1
p1stateno = IfElse(Var(48) >= 1,1301,1302)
getpower = 90

[State 1300, ChangeAnim]
type = Changeanim
trigger1 = Time = 28
value = 1301

[State 1300, ChangeState]
type = ChangeState
trigger1 = AnimTime = 0
trigger1 = Anim = 1301
value = 0
ctrl = 1

[StateDef 1301]
type = A
movetype = I
physics = N
anim = 1302
ctrl = 0

[State 1301, VarAdd]
type = VarAdd
trigger1 = Var(48) >= 1
trigger1 = AnimElem = 2
v = 48
Value = -1

[State 1301, PosAdd]
type = PosAdd
trigger1 = time = 0
x = (P2Dist X)+40
y = (P2Dist Y)-60

[State 1301, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S100,10

[State 1301, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 2
value = S100,9

[State 1301, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S400,9
Channel = 0

[State 1301, Explod]
type = Explod
trigger1 = AnimElem = 2
anim = 421
ID = 421
pos = 35,-15
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .3,.3
sprpriority = 5
removeongethit = 0
ownpal = 1
supermovetime = 9999
pausemovetime = 9999

[State 1301, Turn]
type = Turn
trigger1 = time = 0

[State 1301, VelSet]
Type = VelSet
trigger1 = AnimElem = 1
X = 0
Y = 0

[State 1301, VelSet]
Type = VelSet
trigger1 = AnimElem = 2
X = -4
Y = -4

[State 1301, VelAdd]
type = VelAdd
trigger1 = AnimElemTime(3) > 0
Y = 0.5

[State 1301, Helper]
type = Helper
trigger1 = AnimElem = 2
helpertype = normal
name= "Casing"
ID = 1002
StateNo = 1002
pos = 25,-85
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 1301, Helper]
type = Helper
trigger1 = AnimElem = 2
name = "Bullet"
Stateno = 1012
ID = 1301
postype = p1
pos = 15,-35
ownpal = 1
ignorehitpause = 1

[State 1301, ChangeState]
type = ChangeState
trigger1 = vel Y > 0
trigger1 = pos Y >= 0
value = 52

[StateDef 1302]
type = A
movetype = A
physics = A
anim = 810
vel = 0,-2
sprpriority = -2

[State 1302, PosAdd]
type = PosAdd
trigger1 = time = 0
x = (P2Dist X)+40
y = (P2Dist Y)-60

[State 1302, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S100,10

[State 1302, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S400,9
Channel = 0

[State 1302, Turn]
type = Turn
trigger1 = time = 0

[State 1302, HitDef]
type = HitDef
trigger1 = AnimElem = 3
attr = A, NA
damage = 80
animtype = Medium
guardflag = MA
hitflag = MAF
priority = 7, Hit
pausetime = 15,15
sparkno = -1+(0*(var(41) := 8052))
guard.sparkno = -1+(0*(var(42) := 9000))
sparkxy = 0,0+(0*(var(43) := 100 && var(44) := -30))
hitsound = S200,2
guardsound = S300,0
ground.type = High
ground.slidetime = 15
ground.hittime = 15
ground.velocity = -4.8,0
guard.velocity = -4.8
air.velocity = -1.0,-4.4
fall = 1

[StateDef 1400]
Type = S
Movetype = I
Physics = N
Anim = 1400
Velset = 0, 0
Ctrl = 0
facep2 = 1
Poweradd = 100

[State 1400, VarAdd]
type = VarAdd
trigger1 = Var(46) = 1
trigger1 = Var(47) >= 2
trigger1 = Time = 37
v = 47
Value = -2

[State 1400, VarAdd]
type = VarAdd
trigger1 = Var(48) >= 2
trigger1 = AnimElem = 9
v = 48
Value = -2

[State 1400, StateTypeSet]
type = StateTypeSet
trigger1 = AnimElem = 3
StateType = C
Movetype = I
Physics = N

[State 1400, StateTypeSet]
type = StateTypeSet
trigger1 = AnimElem = 11
StateType = S
Movetype = I
Physics = N

[State 1400, Helper]
type = Helper
trigger1 = Var(46) = 0
trigger1 = AnimElem = 9
trigger2 = Var(46) = 1
trigger2 = Var(47) < 2
trigger2 = AnimElem = 9
name = "Pipebomb"
ID = 1401
stateno = 1401
pos = 41,0
postype = p1
ownpal = 1
ignorehitpause = 1

[State 1400, Helper]
type = Helper
trigger1 = Var(46) = 1
trigger1 = Var(47) >= 2
trigger1 = AnimElem = 9
name = "Pipebomb"
ID = 1402
stateno = 1401
pos = 41,0
postype = p1
ownpal = 1
ignorehitpause = 1

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

[StateDef 1401]
Type = S
Movetype = I
Physics = N
Anim = 1401
Ctrl = 0
Sprpriority = 5

[State 1401, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 2
value = S100,31

[State 1401, ChangeState]
type = ChangeState
triggerall = IsHelper(1401)
trigger1 = Time >= 300
trigger2 = Time >= 30
trigger2 = P2Dist X = [-40,40]
trigger2 = P2Dist Y = [-40,0]
value = 1402

[State 1401, ChangeState]
type = ChangeState
triggerall = IsHelper(1402)
trigger1 = Time >= 300
trigger2 = Time >= 30
trigger2 = P2Dist X = [-60,60]
trigger2 = P2Dist Y = [-60,0]
value = 1402

[State 1401, DestroySelf]
type = DestroySelf
triggerall = IsHelper(1401)
trigger1 = Root,MoveType = H
trigger1 = Root,StateNo != [120,159]
trigger2 = Time > 0
trigger2 = NumHelper(1401) = 2
trigger3 = Time > 0
trigger3 = NumHelper(1402) = 1
trigger4 = Root,StateNo = 4001

[State 1401, DestroySelf]
type = DestroySelf
triggerall = IsHelper(1402)
trigger1 = Time > 0
trigger1 = NumHelper(1402) = 2
trigger2 = Time > 0
trigger2 = NumHelper(1401) = 1
trigger3 = Root,StateNo = 4001

[StateDef 1402]
Type = A
Movetype = A
Physics = N
Anim = 1103
Velset = 0, 0
Ctrl = 0
Sprpriority = 4

[State 1402, ParentVarAdd]
type = ParentVarAdd
trigger1 = IsHelper(1401)
trigger1 = NumHelper(1401)
trigger1 = Helper(1401),MoveHit = 1
trigger2 = IsHelper(1402)
trigger2 = NumHelper(1402)
trigger2 = Helper(1402),MoveHit = 1
var(45) = 12-27*(!!Root,Var(46))

[State 1402, ParentVarAdd]
type = ParentVarAdd
trigger1 = IsHelper(1401)
trigger1 = NumHelper(1401)
trigger1 = Helper(1401),MoveGuarded = 1
trigger2 = IsHelper(1402)
trigger2 = NumHelper(1402)
trigger2 = Helper(1402),MoveGuarded = 1
var(45) = 6-21*(!!Root,Var(46))

[State 1402, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow
ignorehitpause = 1

[State 1402, Trans]
type = Trans
trigger1 = 1
trans = Add

[State 1402, EnvShake]
type = EnvShake
Trigger1 = time = 0
time = 10
ampl = 20
freq = 127

[State 1402, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S100,29

[State 1402, HitDef]
type = HitDef
triggerall = !MoveContact && !MoveReversed
trigger1 = AnimElemTime(4) >= 0
trigger1 = AnimElemTime(10) < 0
attr = A,HA
damage = ceil(IfElse(Root,Var(10),90,75)*(root,fvar(1)*root,fvar(2))),10
animtype = Heavy
guardflag = MA
hitflag = MAF
priority = 5, Hit
pausetime = 0,7
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,8
guardsound = S300,0
ground.type = high
ground.slidetime = 30
ground.hittime = 30
ground.velocity = 0,-11
guard.velocity = -3
air.velocity = 0,-11
yaccel = 0.4
fall = 1
fall.recover = 0
getpower = 0
palFX.time = 60
palFX.mul = 128, 128, 128
palFX.sinAdd = 96, 96, 96, 4

[State 1402, Helper]
type = Helper
trigger1 = !NumHelper(8100)
trigger1 = MoveHit = 1 && NumTarget
trigger1 = var(43) := (Target, ID)
helperType = Normal
stateNo = 8100
ID = 8100
name = "Burning"
posType = P2
ownPal = 1
ignoreHitPause = 1

[State 1402, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8053
stateno = 8053
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 4

[State 1402, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 0

[State 1402, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 1402, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 1402, DestroySelf]
type = DestroySelf
trigger1 = AnimTime = 0

[StateDef 2000]
type = S
movetype = A
physics = S
anim = 2000
ctrl = 0
facep2 = 1
VelSet = 0,0
sprpriority = 2

[State 2000, VarAdd]
type = VarAdd
trigger1 = Var(46) = 0
trigger1 = Time = 0
v = 45
Value = 50

[State 2000, VarAdd]
type = VarAdd
trigger1 = Var(48) >= 3
trigger1 = Time = 8
v = 48
Value = -3

[State 2000, NotHitBy]
type = NotHitBy
trigger1 = time = 0
value = SCA
time = 18

[State 2000, PowerAdd]
type = PowerAdd
trigger1 = Time = 0
value = -1000

[State 2000, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S10000,4

[State 2000, Helper]
type = Helper
trigger1 = Time = 0
name = "EX"
ID = 6200
stateno = 6200
pos = 0,0
postype = p1
ownpal = 1
supermovetime = 999
pausemovetime = 999
ignorehitpause = 1

[State 2000, PalFX]
type = PalFX
trigger1 = GameTime % 3 = 0
time = 1
add = 0,76,224
color = 124
ignorehitpause = 1

[State 2000, PalFX]
type = PalFX
trigger1 = GameTime % 3 = 1
time = 1
add = 0,46,164
color = 256
ignorehitpause = 1

[State 2000, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 6
trigger2 = AnimElem = 7
value = S100,17
Channel = 1

[State 2000, PlaySnd]
type = PlaySnd
trigger1 = Anim = 2000
trigger1 = AnimElem = 1
value = S410,2
Channel = 0

[State 2000, Explod]
type = Explod
trigger1 = AnimElemTime(5) >= 0 && (time%6) = 0
anim = 2003
ID = 2003
pos = 37,-55
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .5,.5
sprpriority = 5
removeongethit = 1
pausemovetime = 9999
ownpal = 1

[State 2000, Helper]
type = Helper
trigger1 = AnimElemTime(5) >= 0 && (time%6) = 0
helpertype = normal
name = "Casing"
ID = 2000
StateNo = 1002
pos = 5,-55
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 2000, Helper]
type = Helper
trigger1 = AnimElemTime(5) >= 0 && (time%6) = 0
name = "Bullet"
Stateno = 2002
ID = 2002
postype = p1
pos = 30,-57
ownpal = 1
ignorehitpause = 1

[State 2000, ChangeState]
type = ChangeState
trigger1 = Time = 80
value = 2001

[StateDef 2001]
type = S
movetype = I
physics = N
anim = 2001
ctrl = 0
facep2 = 1
VelSet = 0,0
sprpriority = 2

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

[StateDef 2002]
Type = A
Movetype = A
Physics = N
Anim = 2002
Ctrl = 0
Sprpriority = 5

[State 2002, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow
ignorehitpause = 1

[State 2002, Trans]
type = Trans
trigger1 = 1
trans = Add

[State 2002, VelSet]
type = VelSet
trigger1 = 1
x = 40

[State 2002, HitDef]
type = HitDef
trigger1 = AnimElem = 1
attr = S,HP
animtype  = Hard
damage = ceil(IfElse(Root,Var(10),18,15)*(root,fvar(1)*root,fvar(2))),3
hitflag = MAF
guardflag = MA
pausetime = 1,12
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,6
guardsound = S300,0
ground.type = high
ground.slidetime = 32
ground.hittime = 32
ground.velocity = -5
air.velocity = -2.5,-3.5
fall = 1
fall.recover = 0
envshake.time = 10
envshake.ampl = 4
fall.recovertime = 35
getpower = 0

[State 2002, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8053
stateno = 8053
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(0)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 4

[State 2002, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(0)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 4

[State 2002, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 2002, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 2002, DestroySelf]
type = DestroySelf
trigger1 = MoveContact
trigger2 = FrontEdgeBodyDist <= -42

[StateDef 2010]
type = A
movetype = A
physics = N
anim = 2000
ctrl = 0
facep2 = 1
VelSet = 0,0
sprpriority = 2

[State 2010, VarAdd]
type = VarAdd
trigger1 = Var(46) = 0
trigger1 = Time = 0
v = 45
Value = 50

[State 2010, VarAdd]
type = VarAdd
trigger1 = Var(48) >= 3
trigger1 = Anim = 2000
trigger1 = Time = 8
v = 48
Value = -3

[State 2010, NotHitBy]
type = NotHitBy
trigger1 = Anim = 2000
trigger1 = time = 0
value = SCA
time = 18

[State 2010, PowerAdd]
type = PowerAdd
trigger1 = Anim = 2000
trigger1 = Time = 0
value = -1000

[State 2010, PlaySnd]
type = PlaySnd
trigger1 = Anim = 2000
trigger1 = Time = 0
value = S10000,4

[State 2010, Helper]
type = Helper
trigger1 = Anim = 2000
trigger1 = Time = 0
name = "EX"
ID = 6200
stateno = 6200
pos = 0,0
postype = p1
ownpal = 1
supermovetime = 999
pausemovetime = 999
ignorehitpause = 1

[State 2010, PalFX]
type = PalFX
trigger1 = Anim = 2000
trigger1 = GameTime % 3 = 0
time = 1
add = 0,76,224
color = 124
ignorehitpause = 1

[State 2010, PalFX]
type = PalFX
trigger1 = Anim = 2000
trigger1 = GameTime % 3 = 1
time = 1
add = 0,46,164
color = 256
ignorehitpause = 1

[State 2010, VelSet]
type = VelSet
triggerall = Anim = 2000
trigger1 = AnimElem = 6
trigger2 = AnimElem = 7
x = -0.5

[State 2010, VelSet]
type = VelSet
trigger1 = Anim != 2000
x = 0

[State 2010, PlaySnd]
type = PlaySnd
triggerall = Anim = 2000
trigger1 = AnimElem = 6
trigger2 = AnimElem = 7
value = S100,17
Channel = 1

[State 2010, PlaySnd]
type = PlaySnd
trigger1 = Anim = 2000
trigger1 = AnimElem = 1
value = S410,2
Channel = 0

[State 2010, Explod]
type = Explod
trigger1 = Anim = 2000
trigger1 = AnimElemTime(5) >= 0 && (time%6) = 0
anim = 2003
ID = 2003
pos = 37,-55
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .5,.5
sprpriority = 5
removeongethit = 1
pausemovetime = 9999
ownpal = 1

[State 2010, Helper]
type = Helper
trigger1 = Anim = 2000
trigger1 = AnimElemTime(5) >= 0 && (time%6) = 0
helpertype = normal
name= "Casing"
ID = 2000
StateNo = 1002
pos = 5,-55
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 2010, Helper]
type = Helper
trigger1 = Anim = 2000
trigger1 = AnimElemTime(5) >= 0 && (time%6) = 0
name = "Bullet"
Stateno = 2002
ID = 2002
postype = p1
pos = 30,-57
ownpal = 1
ignorehitpause = 1

[State 2010, ChangeAnim]
type = ChangeAnim
trigger1 = Time = 80
value = 2010

[State 2010, ChangeAnim]
type = ChangeAnim
trigger1 = Anim = 2010 && AnimTime = 0
value = 2011

[State 2010, StateTypeSet]
type = StateTypeSet
trigger1 = Anim = 2011
physics = A

[StateDef 2100]
type = S
physics = N
velset = 0,0
anim = 2100
ctrl = 0
facep2 = 1

[State 2101, VarAdd]
type = VarAdd
trigger1 = Var(46) = 0
trigger1 = time = 0
v = 45
value = -50

[State 2100, VarAdd]
type = VarAdd
trigger1 = Var(46) = 1
trigger1 = Var(47) = 1
trigger1 = AnimElem = 5
v = 47
Value = -1

[State 2100, VarAdd]
type = VarAdd
trigger1 = Var(46) = 1
trigger1 = Var(47) = 2
trigger1 = AnimElem = 5
v = 47
Value = -2

[State 2100, VarAdd]
type = VarAdd
trigger1 = Var(46) = 1
trigger1 = Var(47) = 3
trigger1 = AnimElem = 5
v = 47
Value = -3

[State 2100, VarAdd]
type = VarAdd
trigger1 = Var(46) = 1
trigger1 = Var(47) = 4
trigger1 = AnimElem = 5
v = 47
Value = -4

[State 2100, VarAdd]
type = VarAdd
trigger1 = Var(46) = 1
trigger1 = Var(47) >= 5
trigger1 = AnimElem = 5
v = 47
Value = -5

[State 2100, VarAdd]
type = VarAdd
trigger1 = Var(48) >= 5
trigger1 = AnimElem = 4
v = 48
Value = -10

[State 2100, PowerAdd]
type = PowerAdd
trigger1 = Time = 0
value = -1000

[State 2100, NotHitBy]
type = NotHitBy
trigger1 = time = 0
value = SCA
time = 23

[State 2100, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S10000,4

[State 2100, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 4
value = S100,11

[State 2100, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S410,3
Channel = 0

[State 2100, Helper]
type = Helper
trigger1 = Time = 0
name = "EX"
ID = 6200
stateno = 6200
pos = 0,0
postype = p1
ownpal = 1
supermovetime = 999
pausemovetime = 999
ignorehitpause = 1

[State 2100, PalFX]
type = PalFX
trigger1 = GameTime % 3 = 0
time = 1
add = 0,76,224
color = 124
ignorehitpause = 1

[State 2100, PalFX]
type = PalFX
trigger1 = GameTime % 3 = 1
time = 1
add = 0,46,164
color = 256
ignorehitpause = 1

[State 2100, Helper]
type = Helper
trigger1 = Var(46) = 0
trigger1 = AnimElem = 4
trigger2 = Var(46) = 1
trigger2 = Var(47) = 0
trigger2 = AnimElem = 4
Name = "Carpet Bombing"
StateNo = 2101
ID = 2101
Pos = 0,0
PosType = Back
OwnPal = 1

[State 2100, Helper]
type = Helper
trigger1 = Var(46) = 1
trigger1 = Var(47) = 1
trigger1 = AnimElem = 4
Name = "Carpet Bombing"
StateNo = 2101
ID = 2104
Pos = 0,0
PosType = Back
OwnPal = 1

[State 2100, Helper]
type = Helper
trigger1 = Var(46) = 1
trigger1 = Var(47) = 2
trigger1 = AnimElem = 4
Name = "Carpet Bombing"
StateNo = 2101
ID = 2105
Pos = 0,0
PosType = Back
OwnPal = 1

[State 2100, Helper]
type = Helper
trigger1 = Var(46) = 1
trigger1 = Var(47) = 3
trigger1 = AnimElem = 4
Name = "Carpet Bombing"
StateNo = 2101
ID = 2106
Pos = 0,0
PosType = Back
OwnPal = 1

[State 2100, Helper]
type = Helper
trigger1 = Var(46) = 1
trigger1 = Var(47) = 4
trigger1 = AnimElem = 4
Name = "Carpet Bombing"
StateNo = 2101
ID = 2107
Pos = 0,0
PosType = Back
OwnPal = 1

[State 2100, Helper]
type = Helper
trigger1 = Var(46) = 1
trigger1 = Var(47) >= 5
trigger1 = AnimElem = 4
Name = "Carpet Bombing"
StateNo = 2101
ID = 2108
Pos = 0,0
PosType = Back
OwnPal = 1

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

[StateDef 2101]
type = S
physics = N
poweradd = 0
anim = 99999
ctrl = 0
sprpriority = 2

[State 2101, Helper]
type = Helper
trigger1 = time%15 = 0
Name = "Bomb"
StateNo = 2102
ID = 2102
Pos = 50,-500
PosType = Front

[State 2101, DestroySelf]
type = DestroySelf
trigger1 = IsHelper(2101)
trigger1 = Time >= 180

[State 2101, DestroySelf]
type = DestroySelf
trigger1 = IsHelper(2104)
trigger1 = Time >= 200

[State 2101, DestroySelf]
type = DestroySelf
trigger1 = IsHelper(2105)
trigger1 = Time >= 220

[State 2101, DestroySelf]
type = DestroySelf
trigger1 = IsHelper(2106)
trigger1 = Time >= 240

[State 2101, DestroySelf]
type = DestroySelf
trigger1 = IsHelper(2107)
trigger1 = Time >= 260

[State 2101, DestroySelf]
type = DestroySelf
trigger1 = IsHelper(2108)
trigger1 = Time >= 280

[StateDef 2102]
type = A
movetype = A
physics = N
poweradd = 0
anim = 1205
ctrl = 0
sprpriority = 2

[State 2102, VarSet]
type = VarSet
trigger1 = MoveContact
var(0) = 1+(MoveGuarded != 0)

[State 2102, HitOverride]
type = HitOverride
trigger1 = 1
attr = SCA,AA,AP,AT
time = -1
StateNo = 1103
ignorehitpause = 1

[State 2102, HitBy]
type = HitBy
trigger1 = 1
value = SCA,AP
time = -1

[State 2102, VelAdd]
type = VelAdd
trigger1 = time = 20
x = -3

[State 2102, VelAdd]
type = VelAdd
trigger1 = time = 30
x = -random%20

[State 2102, AngleSet]
type = AngleSet
trigger1 = Vel x != 0
value = Atan(Vel y/Vel x)*(-180.0/pi)+((Vel x<0)*180) + 90

[State 2102, AngleSet]
type = AngleSet
trigger1 = Vel x = 0
value = IfElse(Vel y<0,90,-90)

[State 2102, AngleDraw]
type = AngleDraw
trigger1 = 1

[State 2102, VelAdd]
type = VelAdd
trigger1 = time > 15
x = 0
y = 0.1

[State 2102, Gravity]
trigger1 = 1
type = Gravity

[State 2102, Explod]
type = Explod
trigger1 = (time%3) = 0
anim = 1207
ID = 1207
pos = 0,0
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .3,.3
sprpriority = 5
removeongethit = 0

[State 2102, HitDef]
type= HitDef
trigger1 = !Movecontact
attr = A,SP
hitflag	= MAFD
guardflag = HA
damage = ceil(IfElse(Root,Var(10),6,5)*(root,fvar(1)*root,fvar(2))),1
animtype = Medium
air.animtype = Back
ground.type = High
priority = 6, Hit
pausetime = 0, 1
sparkno = -1
guard.sparkno = -1
sparkxy	= 0,0
hitsound = S200,0
guardsound = S300,0
ground.slidetime = 0
ground.hittime = 0
guard.hittime = 0
ground.velocity	= 0,-5
guard.velocity = 0
air.velocity = 0,-5
fall = 1
fall.recover = 1
fall.recovertime = 39
yaccel = 0.4

[State 2102, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8050
stateno = 8050
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 4

[State 2102, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 4

[State 2102, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 2102, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 2102, ChangeState]
type = ChangeState
trigger1 = Var(0)
trigger2 = pos y > 0 && vel y > 0
value = 2103

[StateDef 2103]
Type = A
Movetype = A
Physics = N
Anim = 1103
Velset = 0, 0
Ctrl = 0
Sprpriority = 4

[State 2103, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow
ignorehitpause = 1

[State 2103, Trans]
type = Trans
trigger1 = 1
trans = Add

[State 2103, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S100,14

[State 2103, HitDef]
type = HitDef
triggerall = !MoveContact && !MoveReversed
trigger1 = AnimElemTime(1) >= 0
trigger1 = AnimElemTime(12) < 0
attr = A,SA
damage = ceil(IfElse(Root,Var(10),36,30)*(root,fvar(1)*root,fvar(2))),3
animtype = Heavy
guardflag = HA
hitflag = MAFD
priority = 5, Hit
pausetime = 0,10
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,8
guardsound = S300,0
ground.type = high
ground.slidetime = 20
ground.hittime = 20
ground.velocity = -2,-4
guard.velocity = -3
air.velocity = -2,-4
envshake.time = 10
envshake.ampl = 4
yaccel = 0.4
fall = 1
fall.recover = 1
fall.recovertime = 39
palFX.time = 45
palFX.mul = 128, 128, 128
palFX.sinAdd = 96, 96, 96, 4

[State 2103, Helper]
type = Helper
trigger1 = !NumHelper(8100)
trigger1 = MoveHit = 1 && NumTarget
trigger1 = var(43) := (Target, ID)
helperType = Normal
stateNo = 8100
ID = 8100
name = "Burning"
posType = P2
ownPal = 1
ignoreHitPause = 1

[State 2103, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8054
stateno = 8054
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 60)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 4

[State 2103, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 60)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 4

[State 2103, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 2103, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 2103, DestroySelf]
type = DestroySelf
trigger1 = AnimTime = 0

[StateDef 2200]
type = S
movetype = I
physics  = N
anim = 2200
velset = 0,0
ctrl = 0
facep2 = 1
sprpriority = 1

[State 2200, VarAdd]
type = VarAdd
triggerall = Var(46) = 1
triggerall = Anim = 2201
trigger1 = AnimElem = 14
v = 47
Value = -1

[State 2200, VarAdd]
type = VarAdd
triggerall = Var(46) = 1
triggerall = Anim = 2202
trigger1 = AnimElem = 14
trigger2 = AnimElem = 18
v = 47
Value = -1

[State 2200, VarAdd]
type = VarAdd
triggerall = Var(46) = 1
triggerall = Anim = 2203
trigger1 = AnimElem = 14
trigger2 = AnimElem = 18
trigger3 = AnimElem = 22
v = 47
Value = -1

[State 2200, VarAdd]
type = VarAdd
trigger1 = Var(48) >= 4
trigger1 = AnimElem = 6
v = 48
Value = -4

[State 2200, ChangeAnim]
type = ChangeAnim
trigger1 = Var(46) = 1
trigger1 = Var(47) = 1
trigger1 = time = 0
value = 2201

[State 2200, ChangeAnim]
type = ChangeAnim
trigger1 = Var(46) = 1
trigger1 = Var(47) = 2
trigger1 = time = 0
value = 2202

[State 2200, ChangeAnim]
type = ChangeAnim
trigger1 = Var(46) = 1
trigger1 = Var(47) >= 3
trigger1 = time = 0
value = 2203

[State 2200, PowerAdd]
type = PowerAdd
trigger1 = Time = 0
value = -1000

[State 2200, NotHitBy]
type = NotHitBy
trigger1 = time = 0
value = SCA
time = 26

[State 2200, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S10000,4

[State 2200, PlaySnd]
type = PlaySnd
trigger1 = Anim != 2203
trigger1 = AnimElem = 1
value = S410,0
Channel = 0

[State 2200, PlaySnd]
type = PlaySnd
trigger1 = Anim = 2203
trigger1 = AnimElem = 1
value = S410,1
Channel = 0

[State 2200, PlaySnd]
type = PlaySnd
triggerall = Anim = 2200
trigger1 = AnimElem = 6
trigger2 = AnimElem = 10
value = S100,13

[State 2200, PlaySnd]
type = PlaySnd
triggerall = Anim = 2201
trigger1 = AnimElem = 6
trigger2 = AnimElem = 10
trigger3 = AnimElem = 14
value = S100,13

[State 2200, PlaySnd]
type = PlaySnd
triggerall = Anim = 2202
trigger1 = AnimElem = 6
trigger2 = AnimElem = 10
trigger3 = AnimElem = 14
trigger4 = AnimElem = 18
value = S100,13

[State 2200, PlaySnd]
type = PlaySnd
triggerall = Anim = 2203
trigger1 = AnimElem = 6
trigger2 = AnimElem = 10
trigger3 = AnimElem = 14
trigger4 = AnimElem = 18
trigger5 = AnimElem = 22
value = S100,13

[State 2200, Explod]
type = Explod
triggerall = Anim = 2200
trigger1 = AnimElem = 6
trigger2 = AnimElem = 10
anim = 1203
ID = 1203
pos = -65,-85
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .5,.5
sprpriority = 5
pausemovetime = 9999
ownpal = 1

[State 2200, Explod]
type = Explod
triggerall = Anim = 2201
trigger1 = AnimElem = 6
trigger2 = AnimElem = 10
trigger3 = AnimElem = 14
anim = 1203
ID = 1203
pos = -65,-85
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .5,.5
sprpriority = 5
pausemovetime = 9999
ownpal = 1

[State 2200, Explod]
type = Explod
triggerall = Anim = 2202
trigger1 = AnimElem = 6
trigger2 = AnimElem = 10
trigger3 = AnimElem = 14
trigger4 = AnimElem = 18
anim = 1203
ID = 1203
pos = -65,-85
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .5,.5
sprpriority = 5
pausemovetime = 9999
ownpal = 1

[State 2200, Explod]
type = Explod
triggerall = Anim = 2203
trigger1 = AnimElem = 6
trigger2 = AnimElem = 10
trigger3 = AnimElem = 14
trigger4 = AnimElem = 18
trigger5 = AnimElem = 22
anim = 1203
ID = 1203
pos = -65,-85
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .5,.5
sprpriority = 5
pausemovetime = 9999
ownpal = 1

[State 2200, VelSet]
type = VelSet
triggerall = Anim = 2200
trigger1 = AnimElemTime(6) = 0
trigger2 = AnimElemTime(10) = 0
x = -8

[State 2200, VelSet]
type = VelSet
triggerall = Anim = 2201
trigger1 = AnimElemTime(6) = 0
trigger2 = AnimElemTime(10) = 0
trigger3 = AnimElemTime(14) = 0
x = -8

[State 2200, VelSet]
type = VelSet
triggerall = Anim = 2202
trigger1 = AnimElemTime(6) = 0
trigger2 = AnimElemTime(10) = 0
trigger3 = AnimElemTime(14) = 0
trigger4 = AnimElemTime(18) = 0
x = -8

[State 2200, VelSet]
type = VelSet
triggerall = Anim = 2203
trigger1 = AnimElemTime(6) = 0
trigger2 = AnimElemTime(10) = 0
trigger3 = AnimElemTime(14) = 0
trigger4 = AnimElemTime(18) = 0
trigger5 = AnimElemTime(22) = 0
x = -8

[State 2200, VelSet]
type = VelSet
triggerall = Anim = 2200
trigger1 = AnimElemTime(7) = 0
trigger2 = AnimElemTime(11) = 0
x = 0

[State 2200, VelSet]
type = VelSet
triggerall = Anim = 2201
trigger1 = AnimElemTime(7) = 0
trigger2 = AnimElemTime(11) = 0
trigger3 = AnimElemTime(15) = 0
x = 0

[State 2200, VelSet]
type = VelSet
triggerall = Anim = 2202
trigger1 = AnimElemTime(7) = 0
trigger2 = AnimElemTime(11) = 0
trigger3 = AnimElemTime(15) = 0
trigger4 = AnimElemTime(19) = 0
x = 0

[State 2200, VelSet]
type = VelSet
triggerall = Anim = 2203
trigger1 = AnimElemTime(7) = 0
trigger2 = AnimElemTime(11) = 0
trigger3 = AnimElemTime(15) = 0
trigger4 = AnimElemTime(19) = 0
trigger5 = AnimElemTime(23) = 0
x = 0

[State 2200, Helper]
type = Helper
trigger1 = Time = 0
name = "EX"
ID = 6200
stateno = 6200
pos = 0,0
postype = p1
ownpal = 1
supermovetime = 999
pausemovetime = 999
ignorehitpause = 1

[State 2200, PalFX]
type = PalFX
trigger1 = GameTime % 3 = 0
time = 1
add = 0,76,224
color = 124
ignorehitpause = 1

[State 2200, PalFX]
type = PalFX
trigger1 = GameTime % 3 = 1
time = 1
add = 0,46,164
color = 256
ignorehitpause = 1

[State 2200, Helper]
type = Helper
trigger1 = AnimElem = 6
trigger2 = AnimElem = 10
name = "Dread Chase"
Stateno = 2201
ID = 2201
postype = p1
pos = 41,-81
ownpal = 1
ignorehitpause = 1
pausemovetime = 5

[State 2200, Helper]
type = Helper
triggerall = Anim = 2201
trigger1 = AnimElem = 14
name = "Dread Chase"
Stateno = 2203
ID = 2203
postype = p1
pos = 41,-81
ownpal = 1
ignorehitpause = 1
pausemovetime = 5

[State 2200, Helper]
type = Helper
triggerall = Anim = 2202
trigger1 = AnimElem = 14
trigger2 = AnimElem = 18
name = "Dread Chase"
Stateno = 2203
ID = 2203
postype = p1
pos = 41,-81
ownpal = 1
ignorehitpause = 1
pausemovetime = 5

[State 2200, Helper]
type = Helper
triggerall = Anim = 2203
trigger1 = AnimElem = 14
trigger2 = AnimElem = 18
trigger3 = AnimElem = 22
name = "Dread Chase"
Stateno = 2203
ID = 2203
postype = p1
pos = 41,-81
ownpal = 1
ignorehitpause = 1
pausemovetime = 5

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

[StateDef 2201]
Type = A
Movetype = A
Physics = N
Anim = 1205
Ctrl = 0
Sprpriority = 5

[State 2201, VarSet]
type = VarSet
trigger1 = MoveContact
var(0) = 1+(MoveGuarded != 0)

[State 2201, HitOverride]
type = HitOverride
trigger1 = 1
attr = SCA,AA,AP,AT
time = -1
StateNo = 2202
ignorehitpause = 1

[State 2201, HitBy]
type = HitBy
trigger1 = 1
value = SCA,AP
time = -1

[State 2201, AngleSet]
type = AngleSet
trigger1 = Vel x != 0
value = Atan(Vel y/Vel x)*(-180.0/pi)+((Vel x<0)*180) + 90

[State 2201, AngleSet]
type = AngleSet
trigger1 = Vel x = 0
value = IfElse(Vel y<0,90,-90)

[State 2201, AngleDraw]
type = AngleDraw
trigger1 = 1

[State 2201, Turn]
type = Turn
trigger1 = Time > 5
trigger1 = (P2Dist X < 10)

[State 2201, VelSet]
type = VelSet
trigger1 = (!Time)
x = 10

[State 2201, VelAdd]
type = VelAdd
trigger1 = Time > 5
trigger1 = (P2Dist X < 0) && (Vel X > -6)
x = -0.2

[State 2201, VelAdd]
type = VelAdd
trigger1 = Time > 5
trigger1 = (P2Dist X > 0) && (Vel X < 6)
x = 0.2

[State 2201, VelAdd]
type = VelAdd
trigger1 = Time > 5
trigger1 = (EnemyNear, Pos Y > Pos Y) && (Vel Y < 6)
y = 0.2

[State 2201, VelAdd]
type = VelAdd
trigger1 = Time > 5
trigger1 = (EnemyNear, Pos Y <= Pos Y) && (Vel Y > -6)
y = -0.2

[State 2201, Explod]
type = Explod
trigger1 = (time%3) = 0
anim = 1207
ID = 1207
pos = 0,0
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .3,.3
sprpriority = 5
removeongethit = 0

[State 2201, HitDef]
type= HitDef
trigger1 = !Movecontact
attr = A,HP
hitflag	= MAF
guardflag = MA
damage = ceil(IfElse(Root,Var(10),24,20)*(root,fvar(1)*root,fvar(2))),2
animtype = Medium
air.animtype = Back
ground.type = High
priority = 6, Hit
pausetime = 0, 1
sparkno = -1
guard.sparkno = -1
sparkxy	= 0,0
hitsound = -1
guardsound = S300, 0
ground.slidetime = 0
ground.hittime = 0
guard.hittime = 0
ground.velocity	= 0,-5
guard.velocity = 0
air.velocity = 0,-5
fall = 1
fall.recover = 1
fall.recovertime = 39
yaccel = 0.4
getpower = 0

[State 2201, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 2201, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 2201, ChangeState]
type = ChangeState
trigger1 = Var(0)
trigger2 = Time > 150
value = 2202

[StateDef 2202]
Type = A
Movetype = A
Physics = N
Anim = 1204
Velset = 0, 0
Ctrl = 0
Sprpriority = 4

[State 2202, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow
ignorehitpause = 1

[State 2202, Trans]
type = Trans
trigger1 = 1
trans = Add

[State 2202, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S100,14

[State 2202, HitDef]
type = HitDef
triggerall = !MoveContact && !MoveReversed
trigger1 = AnimElemTime(1) >= 0
trigger1 = AnimElemTime(12) < 0
attr = A,HA
damage = ceil(IfElse(Root,Var(10),66,55)*(root,fvar(1)*root,fvar(2))),15
animtype = Heavy
guardflag = MA
hitflag = MAF
priority = 5, Hit
pausetime = 0,15
guard.pausetime = 0,8
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,8
guardsound = S300,0
ground.type = high
ground.slidetime = 20
ground.hittime = 20
ground.velocity = -1,-5
guard.velocity = -3
air.velocity = -1,-5
envshake.time = 10
envshake.ampl = 3
getpower = 0
yaccel = 0.4
fall = 1
fall.recover = 1
fall.recovertime = 39
palFX.time = 45
palFX.mul = 128, 128, 128
palFX.sinAdd = 96, 96, 96, 4

[State 2202, Helper]
type = Helper
trigger1 = !NumHelper(8100)
trigger1 = MoveHit = 1 && NumTarget
trigger1 = var(43) := (Target, ID)
helperType = Normal
stateNo = 8100
ID = 8100
name = "Burning"
posType = P2
ownPal = 1
ignoreHitPause = 1

[State 2202, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8053
stateno = 8053
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 4

[State 2202, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 4

[State 2202, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 2202, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 2202, DestroySelf]
type = DestroySelf
trigger1 = AnimTime = 0

[StateDef 2203]
Type = A
Movetype = A
Physics = N
Anim = 1205
Ctrl = 0
Sprpriority = 5

[State 2203, VarSet]
type = VarSet
trigger1 = MoveContact
var(0) = 1+(MoveGuarded != 0)

[State 2203, HitOverride]
type = HitOverride
trigger1 = 1
attr = SCA,AA,AP,AT
time = -1
StateNo = 2204
ignorehitpause = 1

[State 2203, HitBy]
type = HitBy
trigger1 = 1
value = SCA,AP
time = -1

[State 2203, AngleSet]
type = AngleSet
trigger1 = Vel x != 0
value = Atan(Vel y/Vel x)*(-180.0/pi)+((Vel x<0)*180) + 90

[State 2203, AngleSet]
type = AngleSet
trigger1 = Vel x = 0
value = IfElse(Vel y<0,90,-90)

[State 2203, AngleDraw]
type = AngleDraw
trigger1 = 1

[State 2203, Turn]
type = Turn
trigger1 = Time > 5
trigger1 = (P2Dist X < 10)

[State 2203, VelSet]
type = VelSet
trigger1 = (!Time)
x = 10

[State 2203, VelAdd]
type = VelAdd
trigger1 = Time > 5
trigger1 = (P2Dist X < 0) && (Vel X > -6)
x = -0.2

[State 2203, VelAdd]
type = VelAdd
trigger1 = Time > 5
trigger1 = (P2Dist X > 0) && (Vel X < 6)
x = 0.2

[State 2203, VelAdd]
type = VelAdd
trigger1 = Time > 5
trigger1 = (EnemyNear, Pos Y > Pos Y) && (Vel Y < 6)
y = 0.2

[State 2203, VelAdd]
type = VelAdd
trigger1 = Time > 5
trigger1 = (EnemyNear, Pos Y <= Pos Y) && (Vel Y > -6)
y = -0.2

[State 2203, Explod]
type = Explod
trigger1 = (time%3) = 0
anim = 1207
ID = 1207
pos = 0,0
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .3,.3
sprpriority = 5
removeongethit = 0

[State 2203, HitDef]
type= HitDef
trigger1 = !Movecontact
attr = A,HP
hitflag	= MAF
guardflag = MA
damage = ceil(IfElse(Root,Var(10),12,10)*(root,fvar(1)*root,fvar(2))),2
animtype = Medium
air.animtype = Back
ground.type = High
priority = 6, Hit
pausetime = 0, 1
sparkno = -1
guard.sparkno = -1
sparkxy	= 0,0
hitsound = -1
guardsound = S300, 0
ground.slidetime = 0
ground.hittime = 0
guard.hittime = 0
ground.velocity	= 0,-5
guard.velocity = 0
air.velocity = 0,-5
fall = 1
fall.recover = 1
fall.recovertime = 39
yaccel = 0.4
getpower = 0

[State 2203, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 2203, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 2203, ChangeState]
type = ChangeState
trigger1 = Var(0)
trigger2 = Time > 150
value = 2204

[StateDef 2204]
Type = A
Movetype = A
Physics = N
Anim = 1204
Velset = 0, 0
Ctrl = 0
Sprpriority = 4

[State 2204, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow
ignorehitpause = 1

[State 2204, Trans]
type = Trans
trigger1 = 1
trans = Add

[State 2204, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S100,14

[State 2204, HitDef]
type = HitDef
triggerall = !MoveContact && !MoveReversed
trigger1 = AnimElemTime(1) >= 0
trigger1 = AnimElemTime(12) < 0
attr = A,HA
damage = ceil(IfElse(Root,Var(10),24,20)*(root,fvar(1)*root,fvar(2))),5
animtype = Heavy
guardflag = MA
hitflag = MAF
priority = 5, Hit
pausetime = 0,15
guard.pausetime = 0,8
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,8
guardsound = S300,0
ground.type = high
ground.slidetime = 20
ground.hittime = 20
ground.velocity = -1,-5
guard.velocity = -3
air.velocity = -1,-5
envshake.time = 10
envshake.ampl = 3
getpower = 0
yaccel = 0.4
fall = 1
fall.recover = 1
fall.recovertime = 39
palFX.time = 45
palFX.mul = 128, 128, 128
palFX.sinAdd = 96, 96, 96, 4

[State 2204, Helper]
type = Helper
trigger1 = !NumHelper(8100)
trigger1 = MoveHit = 1 && NumTarget
trigger1 = var(43) := (Target, ID)
helperType = Normal
stateNo = 8100
ID = 8100
name = "Burning"
posType = P2
ownPal = 1
ignoreHitPause = 1

[State 2204, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8053
stateno = 8053
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 4

[State 2204, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 4

[State 2204, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 2204, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 2204, DestroySelf]
type = DestroySelf
trigger1 = AnimTime = 0

[StateDef 2300]
type = S
physics = S
velset = 0,0
poweradd = 30
ctrl = 0
anim = 1300
sprpriority = 2

[State 2300, VarAdd]
type = VarAdd
trigger1 = Var(46) = 0
trigger1 = Time = 0
v = 45
Value = 50

[State 2300, NotHitBy]
type = NotHitBy
trigger1 = time = 0
value = SCA
time = 13

[State 2300, Helper]
type = Helper
trigger1 = Time = 0
name = "EX"
ID = 6200
stateno = 6200
pos = 0,0
postype = p1
ownpal = 1
supermovetime = 999
pausemovetime = 999
ignorehitpause = 1

[State 2300, PalFX]
type = PalFX
trigger1 = GameTime % 3 = 0
time = 1
add = 0,76,224
color = 124
ignorehitpause = 1

[State 2300, PalFX]
type = PalFX
trigger1 = GameTime % 3 = 1
time = 1
add = 0,46,164
color = 256
ignorehitpause = 1

[State 2300, PowerAdd]
type = PowerAdd
trigger1 = Time = 0
value = -1000

[State 2300, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S10000,4

[State 2300, ReversalDef]
type = ReversalDef
triggerall = Anim = 1300
trigger1 = AnimElem = 3
trigger2 = AnimElem = 4
trigger3 = AnimElem = 5
trigger4 = AnimElem = 6
reversal.attr = SCA, NA, SA, HA
pausetime = 0,0
attr = S, HA
sparkno = -1
hitsound = -1
sprpriority = -1
p1stateno = 2301
getpower = 0

[State 2300, ChangeAnim]
type = Changeanim
trigger1 = Time = 38
value = 1301

[State 2300, ChangeState]
type = ChangeState
trigger1 = AnimTime = 0
trigger1 = Anim = 1301
value = 0
ctrl = 1

[StateDef 2301]
type = S
movetype = I
physics = N
anim = 2300
ctrl = 0

[State 2301, VarAdd]
type = VarAdd
triggerall = Var(47) < 10
trigger1 = Var(49) <= 0
trigger1 = Time = 0
v = 47
Value = 1

[State 2301, AssertSpecial]
type = AssertSpecial
trigger1 = time > 0
trigger1 = time <= 119
flag = TimerFreeze
ignorehitpause = 1

[State 2301, Pause]
type = Pause
trigger1 = time = 0
time = 120
movetime = 120

[State 2301, PosAdd]
type = PosAdd
trigger1 = time = 0
x = (P2Dist X)+150

[State 2301, Turn]
type = Turn
trigger1 = time = 0

[State 2301, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S100,22

[State 2301, PlaySnd]
type = PlaySnd
trigger1 = time = 60
value = S410,10+Random%2
Channel = 0

[State 2301, Explod]
type = Explod
trigger1 = Time = 0
ID = 3000
anim = 3000
postype = back
pos = 150, 50
bindtime = -1
removetime = -2
sprpriority = 0
ownpal = 1
supermovetime = 9999
pausemovetime = 9999
scale = .5,.5

[State 2301, Helper]
type = Helper
trigger1 = Time = 0
name = "C4"
ID = 2302
stateno = 2302
pos = 0,0
postype = p2
ownpal = 1
supermovetime = 9999
pausemovetime = 9999
ignorehitpause = 1

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

[StateDef 2302]
Type = A
Movetype = I
Physics = N
Anim = IfElse(Facing = 1,2301,2302)
Ctrl = 0
Sprpriority = 5

[State 2302, PosSet]
type = PosSet
trigger1 = time = 0
y = 0

[State 2302, TargetBind]
type = TargetBind
trigger1 = time = 0
time = -1

[State 2302, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 1
trigger2 = AnimElem = 2
trigger3 = AnimElem = 3
trigger4 = AnimElem = 4
value = S100,31

[State 2302, ChangeState]
type = ChangeState
trigger1 = AnimTime = 0
value = 2303

[StateDef 2303]
Type = A
Movetype = A
Physics = N
Anim = 2303
Velset = 0, 0
Ctrl = 0
Sprpriority = 4

[State 2303, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow
ignorehitpause = 1

[State 2303, Trans]
type = Trans
trigger1 = 1
trans = Add

[State 2303, PosSet]
type = PosSet
trigger1 = time = 0
y = 0

[State 2303, EnvShake]
type = EnvShake
Trigger1 = time = 0
time = 20
ampl = 20
freq = 127

[State 2303, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S100,29

[State 2303, HitDef]
type = HitDef
triggerall = !MoveContact && !MoveReversed
trigger1 = AnimElemTime(4) >= 0
trigger1 = AnimElemTime(11) < 0
attr = A,HA
damage = ceil(150*(root,fvar(1)*root,fvar(2))),
animtype = Heavy
guardflag =
hitflag = MAF
priority = 5, Hit
pausetime = 0,7
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,8
guardsound = S300,0
ground.type = high
ground.slidetime = 30
ground.hittime = 30
ground.velocity = 0,-12
guard.velocity = -3
air.velocity = 0,-12
yaccel = 0.4
fall = 1
fall.recover = 0
getpower = 0
palFX.time = 60
palFX.mul = 128, 128, 128
palFX.sinAdd = 96, 96, 96, 4

[State 2303, Helper]
type = Helper
trigger1 = !NumHelper(8100)
trigger1 = MoveHit = 1 && NumTarget
trigger1 = var(43) := (Target, ID)
helperType = Normal
stateNo = 8100
ID = 8100
name = "Burning"
posType = P2
ownPal = 1
ignoreHitPause = 1

[State 2303, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8053
stateno = 8053
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 4

[State 2303, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 2303, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 2303, DestroySelf]
type = DestroySelf
trigger1 = AnimTime = 0

[StateDef 2400]
Type = S
Movetype = I
Physics = N
Anim = 2400
Velset = 0, 0
Ctrl = 0
facep2 = 1
Poweradd = 50

[State 2400, VarAdd]
type = VarAdd
trigger1 = Var(46) = 1
trigger1 = Var(47) >= 3
trigger1 = Time = 28
v = 47
Value = -3

[State 2400, VarAdd]
type = VarAdd
trigger1 = Var(48) >= 2
trigger1 = AnimElem = 9
v = 48
Value = -2

[State 2400, NotHitBy]
type = NotHitBy
trigger1 = time = 0
value = SCA
time = 30

[State 2400, PowerAdd]
type = PowerAdd
trigger1 = Time = 0
value = -1000

[State 2400, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S10000,4

[State 2400, Helper]
type = Helper
trigger1 = Time = 0
name = "EX"
ID = 6200
stateno = 6200
pos = 0,0
postype = p1
ownpal = 1
supermovetime = 999
pausemovetime = 999
ignorehitpause = 1

[State 2400, PalFX]
type = PalFX
trigger1 = GameTime % 3 = 0
time = 1
add = 0,76,224
color = 124
ignorehitpause = 1

[State 2400, PalFX]
type = PalFX
trigger1 = GameTime % 3 = 1
time = 1
add = 0,46,164
color = 256
ignorehitpause = 1

[State 2400, StateTypeSet]
type = StateTypeSet
trigger1 = AnimElem = 3
StateType = C
Movetype = I
Physics = N

[State 2400, StateTypeSet]
type = StateTypeSet
trigger1 = AnimElem = 11
StateType = S
Movetype = I
Physics = N

[State 2400, Helper]
type = Helper
trigger1 = Var(46) = 0
trigger1 = AnimElem = 9
trigger2 = Var(46) = 1
trigger2 = Var(47) < 3
trigger2 = AnimElem = 9
name = "Pipebomb"
ID = 2401
stateno = 2401
pos = 41,0
postype = p1
ownpal = 1
ignorehitpause = 1

[State 2400, Helper]
type = Helper
trigger1 = Var(46) = 1
trigger1 = Var(47) >= 3
trigger1 = AnimElem = 9
name = "Pipebomb"
ID = 2402
stateno = 2401
pos = 41,0
postype = p1
ownpal = 1
ignorehitpause = 1

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

[StateDef 2401]
Type = S
Movetype = I
Physics = N
Anim = 1401
Ctrl = 0
Sprpriority = 5

[State 2401, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 2
value = S100,31

[State 2401, ChangeState]
type = ChangeState
triggerall = IsHelper(2401)
trigger1 = Time >= 300
trigger2 = Time >= 30
trigger2 = P2Dist X = [-40,40]
trigger2 = P2Dist Y = [-40,0]
value = 2402

[State 2401, ChangeState]
type = ChangeState
triggerall = IsHelper(2402)
trigger1 = Time >= 480
trigger2 = Time >= 30
trigger2 = P2Dist X = [-60,60]
trigger2 = P2Dist Y = [-60,0]
value = 2402

[State 2401, DestroySelf]
type = DestroySelf
trigger1 = Root,StateNo = 4001

[StateDef 2402]
Type = A
Movetype = A
Physics = N
Anim = 1103
Velset = 0, 0
Ctrl = 0
Sprpriority = 4

[State 2402, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow
ignorehitpause = 1

[State 2402, Trans]
type = Trans
trigger1 = 1
trans = Add

[State 2402, EnvShake]
type = EnvShake
Trigger1 = time = 0
time = 10
ampl = 20
freq = 127

[State 2402, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S100,29

[State 2402, HitDef]
type = HitDef
triggerall = !MoveContact && !MoveReversed
trigger1 = AnimElemTime(4) >= 0
trigger1 = AnimElemTime(10) < 0
attr = A,HA
damage = ceil(IfElse(Root,Var(10),144,120)*(root,fvar(1)*root,fvar(2))),12
animtype = Heavy
guardflag = MA
hitflag = MAF
priority = 5, Hit
pausetime = 0,7
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,8
guardsound = S300,0
ground.type = high
ground.slidetime = 30
ground.hittime = 30
ground.velocity = 0,-11
guard.velocity = -3
air.velocity = 0,-11
yaccel = 0.4
fall = 1
fall.recover = 0
getpower = 0
palFX.time = 60
palFX.mul = 128, 128, 128
palFX.sinAdd = 96, 96, 96, 4

[State 2402, Helper]
type = Helper
trigger1 = !NumHelper(8100)
trigger1 = MoveHit = 1 && NumTarget
trigger1 = var(43) := (Target, ID)
helperType = Normal
stateNo = 8100
ID = 8100
name = "Burning"
posType = P2
ownPal = 1
ignoreHitPause = 1

[State 2402, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8053
stateno = 8053
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 4

[State 2402, Helper]
type = Helper
trigger1 = MoveGuarded  = 1
helpertype = normal
stateno = 9000
ID = 9000
name = "Guard_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
ownpal = 1
pausemovetime = 9999
supermovetime = 9999
ignorehitpause = 1
persistent = 0

[State 2402, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 2402, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 2402, DestroySelf]
type = DestroySelf
trigger1 = AnimTime = 0

[StateDef 3000]
type = S
movetype = I
physics = N
anim = 760
ctrl = 0
facep2 = 1
VelSet = 0,0
sprpriority = 2

[State 3000, VarSet]
type = VarAdd
trigger1 = Var(47) >= 10
trigger1 = AnimElem = 4
v = 47
Value = -10

[State 3000, VarSet]
type = VarSet
trigger1 = AnimElem = 4
V = 48
Value = 10

[State 3000, VarSet]
type = VarSet
trigger1 = Var(46) = 0
trigger1 = AnimElem = 4
var(49) = 360
ignorehitpause = 1

[State 3000, VarSet]
type = VarSet
trigger1 = Var(46) = 1
trigger1 = AnimElem = 4
var(49) = 420
ignorehitpause = 1

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

[State 3000, Pause]
type = Pause
trigger1 = Var(46) = 0
trigger1 = RoundState = 2
trigger1 = AnimElem = 4
time = 389
movetime = 389

[State 3000, Pause]
type = Pause
trigger1 = Var(46) = 1
trigger1 = RoundState = 2
trigger1 = AnimElem = 4
time = 449
movetime = 449

[State 3000, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 1
value = S410,12
Channel = 0

[State 3000, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S10000,6

[State 3000, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 4
value = S100,22

[State 3000, Helper]
type = Helper
trigger1 = time = 0
helpertype = normal
stateno = 3010
ID = 3010
name = "Effect"
postype = p1
pos = -5,-60
SuperMovetime = 9999
PauseMovetime = 9999
size.xscale = 0.335
size.yscale = 0.335
ownpal = 1

[State 3000, Helper]
type = Helper
trigger1 = Time = 0
stateno = 3011
ID = 3011
name = "Portrait"
SuperMovetime = 9999
PauseMovetime = 9999
ownpal = 1

[State 3000, Helper]
type = Helper
trigger1 = Time = 0
stateno = 3012
ID = 3012
Name = "Trigger"
postype = Left
pos = 320,-140
facing = 1
sprpriority = 1
ownpal = 1
ignorehitpause = 1
persistent = 0
Pausemovetime = 9999
SuperMovetime = 9999

[State 3000, Helper]
type = Helper
trigger1 = Time = 0
stateno = 3013
ID = 3013
Name = "Trigger"
postype = Left
pos = 320,-100
facing = 1
sprpriority = 1
ownpal = 1
ignorehitpause = 1
persistent = 0
Pausemovetime = 9999
SuperMovetime = 9999

[State 3000, Helper]
type = Helper
trigger1 = Var(46) = 0
trigger1 = AnimElem = 4
name = "Time Stop"
ID = 3001
stateno = 3001
pos = 0,0
postype = p1
ownpal = 1
supermovetime = 9999
pausemovetime = 9999
ignorehitpause = 1

[State 3000, Helper]
type = Helper
trigger1 = Var(46) = 1
trigger1 = AnimElem = 4
name = "Time Stop"
ID = 3003
stateno = 3001
pos = 0,0
postype = p1
ownpal = 1
supermovetime = 9999
pausemovetime = 9999
ignorehitpause = 1

[State 3000, helper]
type = Helper
trigger1 = AnimElem = 4
stateno = 3002
ID = 3002
Name = "TS Meter"
postype = P1
facing = 1
sprpriority = 5
ownpal = 1
ignorehitpause = 1
persistent = 0
Helpertype = Normal
pausemovetime=-2**31-1
supermovetime=-2**31-1

[State 3000, Explod]
type = Explod
trigger1 = AnimElem = 4
ID = 3000
anim = 3000
postype = back
pos = 150, 50
bindtime = 1
removetime = -2
sprpriority = 0
ownpal = 1
supermovetime = 9999
pausemovetime = 9999
scale = .5,.5

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

[StateDef 3001]
type = S
movetype = I
physics = N
anim = 99999
ctrl = 0

[State 3001, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = TimerFreeze

[State 3001, DestroySelf]
type = DestroySelf
trigger1 = IsHelper(3001)
trigger1 = Time >= 389
trigger2 = IsHelper(3003)
trigger2 = Time >= 449

[StateDef 3002]
type = A
movetype = I
physics = N
anim = 99999
ctrl = 0
velset = 0,0
sprpriority = -99

[State 3002, nothitby]
type = nothitby
trigger1 = 1
value = SCA
time = 999

[State 3002, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow

[State 3002, BindToParent]
type = BindToParent
trigger1 = 1
pos = 0,0

[State 3002, Explod]
type = explod
trigger1 = Numexplod(6027)=0
ID = 6027
anim = IfElse(Teamside = 1,6027,6028)
pos = Ifelse(Teamside = 1,-10,10),15
postype = P1
scale = 0.5,0.5
ownpal = 1
bindtime = -1
removetime = -1
ontop = 1
facing = 1
pausemovetime=-1
supermovetime=-1

[State 3001, Explod]
type = explod
trigger1 = NumExplod(6029) = 0
id = 6029
anim = 6029
pos = Ifelse(Teamside = 1,-12,12),6
postype = P1
scale = 0.5,0.5
ownpal = 1
bindtime = -1
removetime = -1
ontop = 1
facing = ifelse(teamside=1,1,-1)
pausemovetime=-1
supermovetime=-1

[State 3002, ModifyExplod]
type = modifyexplod
trigger1 = 1
id = 6029
Scale = .5*Root,Var(49)/420,0.50

[State 3002, RemoveExplod]
type = RemoveExplod
trigger1 = Root,Var(49) <= 0
id = 6027

[State 3002, RemoveExplod]
type = RemoveExplod
trigger1 = Root,Var(49) <= 0
id = 6029

[State 3002, DestroySelf]
type = DestroySelf
trigger1 = Root,Var(49) <= 0

[StateDef 3010]
Type = A
Physics = N
MoveType = I
Anim = 3010
Ctrl = 0
velset = 0,0
sprpriority = 5

[State 3010, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[State 3010, AngleSet]
type = AngleSet
trigger1 = Time = 0
value = 6*(random%60)

[State 3010, AngleAdd]
type = AngleAdd
trigger1 = 1
value = -6

[State 3010, AngleDraw]
type = AngleDraw
trigger1 = time < 8
scale = (0.0625*time),(0.0625*time)

[State 3010, AngleDraw]
type = AngleDraw
trigger1 = time >= 8
scale = 0.5,0.5

[State 3010, Trans]
type = Trans
trigger1 = time < 16
trans = AddAlpha
alpha = 256, 256

[State 3010, Trans]
type = Trans
trigger1 = time >= 16
trans = AddAlpha
alpha = ceil(256 - 25.6*(time-16)), 256

[State 3010, Explod]
type = explod
trigger1 = Time = 0
anim = 3011
ID = 3011
sprpriority = 5
postype = p1
facing = IfElse(random<500,-1,1)
vfacing = IfElse(random<500,-1,1)
removetime = 16
supermovetime = -1

[State 3010, ModifyExplod]
type = ModifyExplod
trigger1 = NumExplod(3011)
ID = 3011
scale = 2-(.125*time), 2-(.125*time)
trans = AddAlpha
alpha = IfElse(time<4, 64*time, 256), 256

[State 3010, Explod]
type = Explod
trigger1 = time = 16
anim = 3012
ID = 3012
sprpriority = 5
postype = p1
removetime = 32
supermovetime = -1

[State 3010, ModifyExplod]
type = ModifyExplod
trigger1 = NumExplod(3012)
ID = 3012
scale = (.1*(time-16)), (.1*(time-16))
trans = AddAlpha
alpha = ceil(256 - 25.6*(time-16)), 256

[State 3010, RemoveExplod]
type = RemoveExplod
trigger1 = time >= 26

[State 3010, DestroySelf]
type = DestroySelf
trigger1 = time >= 26

[StateDef 3011]
Type = S
Physics = N
MoveType = I
Anim = 99999
Ctrl = 0
velset = 0,0
sprpriority = 5

[State 3011, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[State 3011, BGPalFX]
type = BGPalFX
trigger1 = time > 0
trigger1 = time <= 51
time = 1
color= 5*time
mul = 5*time, 5*time, 5*time

[State 3011, Explod]
type = Explod
trigger1 = time = 0
anim = 3013
id = 3013
pos = ceil(gamewidth/2.0),ceil(gameheight/2.0-40)
postype = left
sprpriority = -8
bindtime = -1
ownpal = 1
Scale = .5,.5
ignorehitpause = 1
supermovetime = 9999
pausemovetime = 9999

[State 3011, Explod]
type = Explod
trigger1 = time = 0
anim = 3014
ID = 3014
pos = ceil(gamewidth/2.0),ceil(gameheight/2.0-40)
postype = left
sprpriority = -7
bindtime = -1
ownpal = 1
Scale = .5,.5
ignorehitpause = 1
supermovetime = 9999
pausemovetime = 9999

[State 3011, ModifyExplod]
type = ModifyExplod
trigger1 = time >= 65
ID = 3013
Scale = 0.5,0.5-((time-65)*0.1)

[State 3011, ModifyExplod]
type = ModifyExplod
trigger1 = time >= 65
ID = 3014
Scale = 0.5,0.5-((time-65)*0.1)

[State 3011, RemoveExplod]
type = RemoveExplod
trigger1 = Time >= 70
ID = 3013

[State 3011 RemoveExplod]
type = RemoveExplod
trigger1 = Time >= 70
ID = 3014

[State 3011, DestroySelf]
type = DestroySelf
trigger1 = Time >= 70

[StateDef 3012]
type = A
movetype = I
physics = N
anim = 99999
ctrl = 0
velset = 0,0
sprpriority = 1

[State 3012, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow

[State 3012, Explod]
type = Explod
Trigger1 = TeamSide = 1
Trigger1 = Time = 0
Anim = 3015
id = 3015
Pos = 0,ceil((1.33*gameheight/gamewidth)*54)
PosType = left
ownpal = 1
bindtime = -1
pausemovetime = 9999
supermove = 9999
ignorehitpause = 1
sprpriority = -5
scale = 0.5,0.5

[State 3012, Explod]
type = Explod
Trigger1 = TeamSide = 2
Trigger1 = Time = 0
Anim = 3015
id = 3015
Pos = 0,ceil((1.33*gameheight/gamewidth)*54)
PosType = left
ownpal = 1
bindtime = -1
pausemovetime = 9999
supermove = 9999
ignorehitpause = 1
sprpriority = -5
scale = 0.5,0.5

[State 3012, RemoveExplod]
type = RemoveExplod
ID = 3015
trigger1 = Time >= 73

[State 3012, DestroySelf]
type = DestroySelf
trigger1 = Time >= 73

[StateDef 3013]
type = A
movetype = I
physics = N
anim = 99999
ctrl = 0
velset = 0,0
sprpriority = 1

[State 3013, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow

[State 3013, Explod]
type = Explod
Trigger1 = TeamSide = 1
Trigger1 = Time = 0
Anim = 3016
id = 3016
Pos = 225,ceil((1.33*gameheight/gamewidth)*114)
PosType = left
ownpal = 1
bindtime = -1
pausemovetime = 9999
supermove = 9999
ignorehitpause = 1
sprpriority = -5
scale = 0.5,0.5

[State 3013, Explod]
type = Explod
Trigger1 = TeamSide = 2
Trigger1 = Time = 0
Anim = 3016
id = 3016
Pos = 225,ceil((1.33*gameheight/gamewidth)*114)
PosType = left
ownpal = 1
bindtime = -1
pausemovetime = 9999
supermove = 9999
ignorehitpause = 1
sprpriority = -5
scale = 0.5,0.5

[State 3013, RemoveExplod]
type = RemoveExplod
ID = 3016
trigger1 = Time >= 73

[State 3013, DestroySelf]
type = DestroySelf
trigger1 = Time >=73

[StateDef 4000]
type = S
movetype = A
physics = N
ctrl = 0
Velset = 0,0
anim = 4000
facep2 = 1

[State 4000, VarAdd]
type = VarAdd
trigger1 = Var(46) = 1
trigger1 = Var(47) = 1
trigger1 = Time = 75
v = 47
Value = -1

[State 4000, VarAdd]
type = VarAdd
trigger1 = Var(46) = 1
trigger1 = Var(47) = 2
trigger1 = Time = 75
v = 47
Value = -2

[State 4000, VarAdd]
type = VarAdd
trigger1 = Var(46) = 1
trigger1 = Var(47) >= 3
trigger1 = Time = 75
v = 47
Value = -3

[State 4000, VarSet]
type = VarSet
trigger1 = Var(49) > 0
trigger1 = AnimElem = 3
v = 49
value = 0

[State 4000, AssertSpecial]
type = AssertSpecial
trigger1 = time >= 8
flag = NoBG
flag2 = NoFG
pausemovetime = 9999
supermovetime = 9999

[State 4000, NotHitBy]
type = NotHitBy
trigger1 = Time = 0
value = SCA
time = 67

[State 4000, PowerAdd]
type = PowerAdd
trigger1 = Time = 0
value = -3000

[State 4000, Pause]
type = Pause
trigger1 = AnimElem = 3
time = 50
movetime = 50

[state ]
type=helper
stateno=20200
id=20200
postype=left
ownpal=1
pausemovetime=2147483647
supermovetime=2147483647
trigger1=AnimElem = 3

[State 4000, Helper]
type = Helper
trigger1 = AnimElem = 3
name = "EX2"
ID = 6210
stateno = 6210
pos = -5,-65
postype = p1
ownpal = 1
supermovetime = 99999
pausemovetime = 99999
ignorehitpause = 1

[State 4000, Explod]
type = Explod
trigger1 = AnimElem = 4
anim = 4004
ID = 4004
postype = p1
pos = 0,-65
vel = 8,8
bindtime = 1
sprpriority = 2
supermovetime = 9999
pausemovetime = 9999

[State 4000, Helper]
type = Helper
trigger1 = Time = 67
StateNo = 4014
ID = 4014
name = "Flash"
pos = 60,10
postype = p1
helpertype = normal
keyctrl = 0
ownpal = 1

[State 4000, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 3
value = S10000,5

[State 4000, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 3
value = S410,5
channel = 0

[State 4000, PlaySnd]
type = PlaySnd
trigger1 = Time = 67
value = S100,30

[State 4000, HitDef]
type = HitDef
trigger1 = AnimElem = 7
attr = S,HA
animtype = Heavy
damage = 0,0
guardflag = MA
pausetime = 0,0
sparkno = -1+(0*(var(41) := 8053))
guard.sparkno = -1+(0*(var(42) := 9000))
sparkxy = 0,0+(0*(var(43) := 100 && var(44) := -30))
hitsound = -1
guardsound = S300,0
ground.type = High
ground.slidetime = 12
ground.hittime  = 12
ground.velocity = -3
air.velocity = -4,-4
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
p1stateno = 4001
p2stateno = 4009
kill = 0
getpower = 0
envshake.time = 10
envshake.ampl = 4

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

[StateDef 4001]
type = S
movetype = I
physics = N
ctrl = 0
Velset = 0,0
anim = 4001

[State 4001, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoBG
flag2 = NoFG
pausemovetime = 9999
supermovetime = 9999

[State 4001, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 7
value = S410,4

[State 4001, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 20
value = S100,10

[State 4001, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 7
value = S100,11

[State 4001, ChangeState]
type = ChangeState
trigger1 = time = 110
value = 4002

[StateDef 4002]
type = A
movetype = I
physics = N
ctrl = 0
anim = 11

[State 4002, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoBG
flag2 = NoFG
pausemovetime = 9999
supermovetime = 9999

[State 4002, PosSet]
type = PosSet
trigger1 = time = 0
x = IfElse(Facing = 1,-200,200)

[State 4002, PosSet]
type = PosSet
trigger1 = time = 21
x = IfElse(Facing = 1,-170,170)

[State 4002, PosSet]
type = PosSet
trigger1 = time = 24
x = IfElse(Facing = 1,-100,100)

[State 4002, PosSet]
type = PosSet
trigger1 = time = 0
y = -130

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

[State 4002, EnvShake]
type = EnvShake
trigger1 = time = [0,180]
trigger1 = time%10 = 0
time = 10
ampl = 4
freq = 127

[State 4002, Helper]
type = Helper
trigger1 = time = 0
StateNo = 4013
ID = 4013
name = "Speed Line"
pos = 0,0
postype = back
helpertype = normal
pausemovetime = 99999
supermovetime = 99999
keyctrl = 0
ownpal = 1

[State 4002, Helper]
type = Helper
trigger1 = Time = 0
ID = 4005
pos = 95,-80
postype = Back
stateno = 4005
helpertype = normal
name = "Truck"
keyctrl = 0
ownpal = 1
supermovetime = 1
persistent = 0

[State 4002, ChangeState]
type = ChangeState
trigger1 = time = 180
value = 4003

[StateDef 4003]
type = A
movetype = I
physics = N
ctrl = 0
Velset = 0,0
anim = 4002

[State 4003, VarAdd]
type = VarAdd
trigger1 = Var(46) = 1
trigger1 = Var(47) = 1
trigger1 = Time = 210
v = 47
Value = -1

[State 4003, VarAdd]
type = VarAdd
trigger1 = Var(46) = 1
trigger1 = Var(47) = 2
trigger1 = Time = 210
v = 47
Value = -2

[State 4003, VarAdd]
type = VarAdd
trigger1 = Var(46) = 1
trigger1 = Var(47) >= 3
trigger1 = Time = 210
v = 47
Value = -3

[State 4003, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoBG
flag2 = NoFG
pausemovetime = 9999
supermovetime = 9999

[State 4003, EnvShake]
type = EnvShake
trigger1 = time = [0,70]
trigger1 = time%10 = 0
time = 10
ampl = 4
freq = 127

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

[State 4003, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S40,2

[State 4003, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S410,7
channel = 0

[State 4003, VelSet]
type = VelSet
trigger1 = time = 0
x = -5
y = -8

[State 4003, AssertSpecial]
type = AssertSpecial
trigger1 = Time > 40
flag = Invisible

[State 4003, Helper]
type = Helper
trigger1 = Var(46) = 0
trigger1 = Time = 80
trigger2 = Var(46) = 1
trigger2 = Var(47) = 0
trigger2 = Time = 80
ID = 4006
pos = -300,-600
postype = Back
stateno = 4006
helpertype = normal
name = "Truck2"
keyctrl = 0
ownpal = 1
supermovetime = 1
persistent = 0

[State 4003, Helper]
type = Helper
trigger1 = Var(46) = 1
trigger1 = Var(47) = 1
trigger1 = Time = 80
ID = 4007
pos = -300,-600
postype = Back
stateno = 4006
helpertype = normal
name = "Truck2"
keyctrl = 0
ownpal = 1
supermovetime = 1
persistent = 0

[State 4003, Helper]
type = Helper
trigger1 = Var(46) = 1
trigger1 = Var(47) = 2
trigger1 = Time = 80
ID = 4008
pos = -300,-600
postype = Back
stateno = 4006
helpertype = normal
name = "Truck2"
keyctrl = 0
ownpal = 1
supermovetime = 1
persistent = 0

[State 4003, Helper]
type = Helper
trigger1 = Var(46) = 1
trigger1 = Var(47) >= 3
trigger1 = Time = 80
ID = 4009
pos = -300,-600
postype = Back
stateno = 4006
helpertype = normal
name = "Truck2"
keyctrl = 0
ownpal = 1
supermovetime = 1
persistent = 0

[State 4003, TargetState]
type = TargetState
trigger1 = Time = 122
value = 4010

[State 4003, ChangeState]
type = ChangeState
trigger1 = time = 300
value = 4004

[StateDef 4004]
type = A
physics = N
Ctrl = 0
Anim = 4003
VelSet = 0,0

[State 4004, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S100,10

[State 4004, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S410,9
channel = 0

[State 4004, PosSet]
type = PosSet
trigger1 = time = 0
x = 0
y = -250

[State 4004, VelAdd]
type = VelAdd
trigger1 = Time > 0
y = 0.55

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

[State 4004, ChangeState]
type = ChangeState
trigger1 = vel Y > 0
trigger1 = Pos Y >= 0
value = 52

[StateDef 4005]
type = S
movetype = I
physics = N
ctrl = 0
Velset = 0,0
anim = 4006

[State 4005, AngleDraw]
type = AngleDraw
trigger1 = 1
scale = 1.25,1.25

[State 4005, AngleAdd]
type = AngleAdd
trigger1 = time > 186
trigger1 = time <= 190
value = 5

[State 4005, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S100,27

[State 4005, Helper]
type = Helper
trigger1 = Time = 180
ID = 4011
pos = 0,75
postype = p1
stateno = 4011
helpertype = normal
name = "Ramp"
keyctrl = 0
ownpal = 1
supermovetime = 1
persistent = 0

[State 4005, VelSet]
type = VelSet
trigger1 = Time = 210
x = 20
y = -5

[State 4005, DestroySelf]
type = DestroySelf
trigger1 = Time >= 240

[StateDef 4006]
type = A
movetype = I
physics = N
ctrl = 0
anim = 4007

[State 4006, AngleDraw]
type = AngleDraw
trigger1 = 1
scale = 1.25,1.25

[State 4006, VelSet]
type = VelSet
trigger1 = Anim = 4007
trigger1 = Time > 0
x = 10

[State 4006, Gravity]
type = Gravity
trigger1 = Anim = 4007

[State 4006, ChangeAnim]
type = ChangeAnim
trigger1 = Anim = 4007
trigger1 = time = 41
value = 4008

[State 4006, VelSet]
type = VelSet
trigger1 = Anim = 4008
x = 0
y = 0

[State 4006, EnvShake]
type = EnvShake
trigger1 = Anim = 4008
trigger1 = AnimElem = 1
time = 10
ampl = 20
freq = 127

[State 4006, PlaySnd]
type = PlaySnd
trigger1 = Anim = 4008
trigger1 = AnimElem = 1
value = S100,26

[State 4006, PlaySnd]
type = PlaySnd
trigger1 = Anim = 4008
trigger1 = AnimElem = 1
value = S100,28

[State 4006, Helper]
Type = Helper
trigger1 = Anim = 4008
trigger1 = AnimElem = 1
Stateno = 4012
ID = 4012
Name = "Rock"
Pos = 110,190
PosType = P1
Ownpal = 1
Keyctrl = 0
Size.Xscale = 1
Size.Yscale = 1
IgnoreHitPause = 1

[State 4006, Helper]
Type = Helper
trigger1 = Anim = 4008
trigger1 = AnimElem = 1
Stateno = 4012
ID = 4012
Name = "Rock"
Pos = 110,190
PosType = P1
Ownpal = 1
Keyctrl = 0
Size.Xscale = 0.9
Size.Yscale = 0.9
IgnoreHitPause = 1

[State 4006, Helper]
Type = Helper
trigger1 = Anim = 4008
trigger1 = AnimElem = 1
Stateno = 4012
ID = 4012
Name = "Rock"
Pos = 110,190
PosType = P1
Ownpal = 1
Keyctrl = 0
Size.Xscale = 0.8
Size.Yscale = 0.8
IgnoreHitPause = 1

[State 4006, Helper]
Type = Helper
trigger1 = Anim = 4008
trigger1 = AnimElem = 1
Stateno = 4012
ID = 4012
Name = "Rock"
Pos = 110,190
PosType = P1
Ownpal = 1
Keyctrl = 0
Size.Xscale = 0.7
Size.Yscale = 0.7
IgnoreHitPause = 1

[State 4006, Helper]
Type = Helper
trigger1 = Anim = 4008
trigger1 = AnimElem = 1
Stateno = 4012
ID = 4012
Name = "Rock"
Pos = 110,190
PosType = P1
Ownpal = 1
Keyctrl = 0
Size.Xscale = 0.6
Size.Yscale = 0.6
IgnoreHitPause = 1

[State 4006, Helper]
Type = Helper
trigger1 = Anim = 4008
trigger1 = AnimElem = 1
Stateno = 4012
ID = 4012
Name = "Rock"
Pos = 110,190
PosType = P1
Ownpal = 1
Keyctrl = 0
Size.Xscale = 0.5
Size.Yscale = 0.5
IgnoreHitPause = 1

[State 4006, Helper]
Type = Helper
trigger1 = Anim = 4008
trigger1 = AnimElem = 1
Stateno = 4012
ID = 4012
Name = "Rock"
Pos = 110,190
PosType = P1
Ownpal = 1
Keyctrl = 0
Size.Xscale = 0.4
Size.Yscale = 0.4
IgnoreHitPause = 1

[State 4006, Helper]
Type = Helper
trigger1 = Anim = 4008
trigger1 = AnimElem = 1
Stateno = 4012
ID = 4012
Name = "Rock"
Pos = 110,190
PosType = P1
Ownpal = 1
Keyctrl = 0
Size.Xscale = 0.3
Size.Yscale = 0.3
IgnoreHitPause = 1

[State 4006, ChangeState]
type = ChangeState
trigger1 = Anim = 4008
trigger1 = Time >= 120
value = 4007

[StateDef 4007]
Type = S
Movetype = A
Physics = N
Anim = 4017
Velset = 0, 0
Ctrl = 0
Sprpriority = 4

[State 4007, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow
ignorehitpause = 1

[State 4007, Trans]
type = Trans
trigger1 = 1
trans = Add

[State 4007, AngleDraw]
type = AngleDraw
trigger1 = 1
scale = 1.5,1.5
ignorehitpause = 1

[State 4007, PosSet]
type = PosSet
trigger1 = time = 0
x = 0
y = 0

[State 4007, EnvShake]
type = EnvShake
Trigger1 = time = 0
time = 30
ampl = 20
freq = 127

[State 4007, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S100,32

[State 4007, AllPalFX]
Type = AllPalFx
Trigger1 = time = 0
Time = 10
Add = 250,250,250

[State 4007, HitDef]
type = HitDef
triggerall = IsHelper(4006)
triggerall = !MoveContact && !MoveReversed
trigger1 = AnimElemTime(4) >= 0
trigger1 = AnimElemTime(11) < 0
attr = S,HA
damage = ceil(IfElse(Root,Var(10),408,340)*(root,fvar(1)*root,fvar(2))),
animtype = Heavy
guardflag =
hitflag = MAF
priority = 5, Hit
pausetime = 0,7
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,8
guardsound = S300,0
ground.type = high
ground.slidetime = 30
ground.hittime = 30
ground.velocity = -1.5,-32
guard.velocity = -3
air.velocity = -1.5,-32
yaccel = 0.4
fall = 1
fall.recover = 0
getpower = 0
palFX.time = 180
palFX.mul = 128, 128, 128
palFX.sinAdd = 96, 96, 96, 4

[State 4007, HitDef]
type = HitDef
triggerall = IsHelper(4007)
triggerall = !MoveContact && !MoveReversed
trigger1 = AnimElemTime(4) >= 0
trigger1 = AnimElemTime(11) < 0
attr = S,HA
damage = ceil(IfElse(Root,Var(10),449,374)*(root,fvar(1)*root,fvar(2))),
animtype = Heavy
guardflag =
hitflag = MAF
priority = 5, Hit
pausetime = 0,7
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,8
guardsound = S300,0
ground.type = high
ground.slidetime = 30
ground.hittime = 30
ground.velocity = -1.5,-32
guard.velocity = -3
air.velocity = -1.5,-32
yaccel = 0.4
fall = 1
fall.recover = 0
getpower = 0
palFX.time = 180
palFX.mul = 128, 128, 128
palFX.sinAdd = 96, 96, 96, 4

[State 4007, HitDef]
type = HitDef
triggerall = IsHelper(4008)
triggerall = !MoveContact && !MoveReversed
trigger1 = AnimElemTime(4) >= 0
trigger1 = AnimElemTime(11) < 0
attr = S,HA
damage = ceil(IfElse(Root,Var(10),490,408)*(root,fvar(1)*root,fvar(2))),
animtype = Heavy
guardflag =
hitflag = MAF
priority = 5, Hit
pausetime = 0,7
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,8
guardsound = S300,0
ground.type = high
ground.slidetime = 30
ground.hittime = 30
ground.velocity = -1.5,-32
guard.velocity = -3
air.velocity = -1.5,-32
yaccel = 0.4
fall = 1
fall.recover = 0
getpower = 0
palFX.time = 180
palFX.mul = 128, 128, 128
palFX.sinAdd = 96, 96, 96, 4

[State 4007, HitDef]
type = HitDef
triggerall = IsHelper(4009)
triggerall = !MoveContact && !MoveReversed
trigger1 = AnimElemTime(4) >= 0
trigger1 = AnimElemTime(11) < 0
attr = S,HA
damage = ceil(IfElse(Root,Var(10),530,442)*(root,fvar(1)*root,fvar(2))),
animtype = Heavy
guardflag =
hitflag = MAF
priority = 5, Hit
pausetime = 0,7
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = S200,8
guardsound = S300,0
ground.type = high
ground.slidetime = 30
ground.hittime = 30
ground.velocity = -1.5,-32
guard.velocity = -3
air.velocity = -1.5,-32
yaccel = 0.4
fall = 1
fall.recover = 0
getpower = 0
palFX.time = 180
palFX.mul = 128, 128, 128
palFX.sinAdd = 96, 96, 96, 4

[State 4007, Helper]
type = Helper
trigger1 = !NumHelper(8100)
trigger1 = MoveHit = 1 && NumTarget
trigger1 = var(43) := (Target, ID)
helperType = Normal
stateNo = 8100
ID = 8100
name = "Burning"
posType = P2
ownPal = 1
ignoreHitPause = 1

[State 4007, Helper]
type = Helper
trigger1 = movehit = 1
helpertype = normal
ID = 8053
stateno = 8053
name = "Hit_Spark"
postype = p1
Pos = Ceil(EnemyNear,Pos X - Pos X) * Facing,Ceil(EnemyNear,Pos Y - Pos Y - 50)
pausemovetime = 9999
supermovetime = 9999
ownpal = 1
ignorehitpause = 1
persistent = 4

[State 4007, VarSet]
type = VarSet
trigger1 = NumEnemy
trigger1 = MoveContact != 1
var(10) = (EnemyNear,MoveType = A)

[State 4007, Helper]
type = Helper
trigger1 = MoveContact = 1 && NumTarget && Var(10)
trigger1 = !(Target,HitShakeOver)
helpertype = Normal
stateno = 8700
ID = 8700
name = "Counter"
postype = P1
pos = 0,0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
persistent = 0

[State 4007, DestroySelf]
type = DestroySelf
trigger1 = AnimTime = 0

[StateDef 4009]
type = U
movetype = H
physics = N
ctrl = 0
velset = 0,0

[State 4009, PosSet]
type = PosSet
trigger1 = time = 0
y = 0

[State 4009, PosSet]
type = PosSet
trigger1 = time = 369
x = 0

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

[State 4009, ChangeAnim]
type = ChangeAnim
trigger1 = time = 0
value = 5300

[State 4009, AssertSpecial]
type = AssertSpecial
trigger1 = time > 109
trigger1 = time <= 369
flag = invisible

[StateDef 4010]
type = U
movetype = H
Physics = N
ctrl = 0
velset = 0,0

[State 4010, ChangeAnim]
type = ChangeAnim
triggerall = SelfAnimExist(5061)
trigger1 = Time = 0
value = 5061

[State 4010, ChangeAnim]
type = ChangeAnim
triggerall =! SelfAnimExist(5061)
triggerall = SelfAnimExist(5030)
trigger1 = Time = 0
value = 5030

[State 4010, ChangeAnim]
type = ChangeAnim
triggerall =! SelfAnimExist(5061)
triggerall = SelfAnimExist(5035)
trigger1 =! SelfAnimExist(5030)
trigger1 = Time = 0
trigger2 = Anim = 5030
trigger2 = AnimTime = 0
Value = 5035

[State 4010, ChangeAnim]
type = ChangeAnim
triggerall =! SelfAnimExist(5061)
triggerall = SelfAnimExist(5050)
trigger1 =! SelfAnimExist(5030)
trigger1 =! SelfAnimExist(5035)
trigger1 = Time = 0
trigger2 =! SelfAnimExist(5035)
trigger2 = Anim = 5030
trigger2 = AnimTime = 0
trigger3 =! SelfAnimExist(5030)
trigger3 = Anim = 5035
trigger3 = AnimTime = 0
value = 5050

[State 4010, VelSet]
type = VelSet
trigger1 = Time = 0
x = 0
y = -9

[State 4010, StateTypeSet]
type = StateTypeSet
trigger1 = StateType != A
trigger1 = Time = 0
StateType = A

[State 4010, VelAdd]
type = VelAdd
trigger1 = Time >= 1
y = .2

[State 4010, HitFallSet]
type = HitFallSet
trigger1 = Time = 25
value = 1
IgnoreHitPause = 1
Persistent = 0

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

[StateDef 4011]
type = A
movetype = I
physics = N
ctrl = 0
anim = 4018
sprpriority = 5

[State 4011, DestroySelf]
type = DestroySelf
trigger1 = Time >= 19

[StateDef 4012]
Type = A
Physics = N
Anim = 4019
SprPriority = 8

[State 4012, VarRandom]
Type = VarRandom
Trigger1 = Time = 0
V = 40
Range = -4,4

[State 4012, VarRandom]
Type = VarRandom
Trigger1 = Time = 0
V = 50
Range = -8,-4

[State 4012, VarRandom]
Type = VarRandom
Trigger1 = Time = 0
V = 51
Range = 1,3

[State 4012, VarRandom]
Type = VarRandom
Trigger1 = Time = 0
V = 52
Range = -10,10

[State 4012, PosAdd]
Type = PosAdd
Trigger1 = Time = 1
X = Var(52)

[State 4012, VelSet]
Type = VelSet
Trigger1 = Time = 1
X = Var(40)
Y = Var(50)

[State 4012, VelAdd]
Type = VelAdd
Trigger1 = 1
Y = Var(51)/10.0

[State 4012, AngleAdd]
Type = AngleAdd
Trigger1 = Vel X >= 0
Value = -5

[State 4012, AngleAdd]
Type = AngleAdd
Trigger1 = Vel X < 0
Value = 5

[State 4012, AngleDraw]
Type = Angledraw
Trigger1 = 1
Scale = 2.5,2.5

[State 4012, Trans]
Type = Trans
Trigger1 = Time >= 44
Trigger2 = Var(40) > 0
Trans = Add

[State 4012, VarAdd]
Type = VarAdd
Trigger1 = Time >= 44
Trigger1 = Var(40) < 256
V = 40
Value = 16

[State 4012, VarSet]
Type = VarSet
Trigger1 = Var(40) >= 256
V = 40
Value = 256

[State 4012, PalFX]
Type = PalFx
Trigger1 = 1
Time = 1
Add = 0,0,0
Mul = 256-Var(40),256-Var(40),256-Var(40)

[State 4012, AssertSpecial]
Type = AssertSpecial
Trigger1 = 1
Flag = Noshadow
IgnoreHitPause = 1

[State 4012, DestroySelf]
Type = Destroyself
Trigger1 = Pos Y >= 50
Trigger2 = Time >= 60
Trigger3 = Var(40) >= 256

[StateDef 4013]
type = A
ctrl = 0
anim = 4009
velset = 0,0
movetype = I
physics = N
sprpriority = -100

[State 4013, VarSet]
type = VarSet
trigger1 = time = 0
v = 1
value = 0

[State 4013, VarAdd]
type = VarAdd
trigger1 = time < 8
v = 1
value = 8

[State 4013, VarAdd]
type = VarAdd
trigger1 = time >= 8
trigger1 = time < 80
v = 1
value = -3

[State 4013, Trans]
type = Trans
trigger1 = 1
trans = addalpha
alpha = var(1),256 - var(1)

[State 4013, AngleDraw]
type = AngleDraw
trigger1 = 1
scale = 99999,99999

[State 4013, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[State 4013, PosSet]
type = PosSet
trigger1 = 1
x = 0
y = 0

[State 4013, Explod]
type = Explod
trigger1 = time = 8
anim = 4009
ID = 4009
postype = back
pos = 0, 0
scale = 99999,99999
bindtime = -1
removetime = -1
sprpriority = -9999
supermovetime = 9999
pausemovetime = 9999

[State 4013, Explod]
type = Explod
trigger1 = time = 8
anim = 4010
ID = 4010
postype = back
pos = 0, 0
bindtime = -1
removetime = -1
sprpriority = -999
supermovetime = 9999
pausemovetime = 9999

[State 4013, Explod]
type = Explod
trigger1 = time = 8
anim = 4010
ID = 4010
postype = back
pos = 320, 0
bindtime = -1
removetime = -1
sprpriority = -999
supermovetime = 9999
pausemovetime = 9999

[State 4013, Explod]
type = Explod
trigger1 = time = 8
anim = 4011
ID = 4011
postype = back
pos = 0, 0
bindtime = -1
removetime = -1
sprpriority = -999
supermovetime = 9999
pausemovetime = 9999

[State 4013, Explod]
type = Explod
trigger1 = time = 8
anim = 4011
ID = 4011
postype = back
pos = 320, 0
bindtime = -1
removetime = -1
sprpriority = -999
supermovetime = 9999
pausemovetime = 9999

[State 4013, Explod]
type = Explod
trigger1 = time = 8
anim = 4011
ID = 4011
postype = back
pos = 0, 0
bindtime = -1
removetime = -1
sprpriority = -999
supermovetime = 9999
pausemovetime = 9999

[State 4013, Explod]
type = Explod
trigger1 = time = 8
anim = 4011
ID = 4011
postype = back
pos = 320, 0
bindtime = -1
removetime = -1
sprpriority = -999
supermovetime = 9999
pausemovetime = 9999

[State 4013, Explod]
type = Explod
trigger1 = time = 8
anim = 4012
ID = 4012
postype = back
pos = 0, 0
bindtime = -1
removetime = -1
sprpriority = -999
supermovetime = 9999
pausemovetime = 9999

[State 4013, Explod]
type = Explod
trigger1 = time = 8
anim = 4012
ID = 4012
postype = back
pos = 320, 0
bindtime = -1
removetime = -1
sprpriority = -999
supermovetime = 9999
pausemovetime = 9999

[State 4013, Explod]
type = Explod
trigger1 = time = 8
anim = 4013
ID = 4013
postype = back
pos = 0, 0
bindtime = -1
removetime = -1
sprpriority = -999
supermovetime = 9999
pausemovetime = 9999

[State 4013, Explod]
type = Explod
trigger1 = time = 8
anim = 4013
ID = 4013
postype = back
pos = 320, 0
bindtime = -1
removetime = -1
sprpriority = -999
supermovetime = 9999
pausemovetime = 9999

[State 4013, Explod]
type = Explod
trigger1 = time = 8
anim = 4014
ID = 4014
postype = back
pos = 0, 0
bindtime = -1
removetime = -1
sprpriority = -999
supermovetime = 9999
pausemovetime = 9999

[State 4013, Explod]
type = Explod
trigger1 = time = 8
anim = 4014
ID = 4014
postype = back
pos = 320, 0
bindtime = -1
removetime = -1
sprpriority = -999
supermovetime = 9999
pausemovetime = 9999

[State 4013, Explod]
type = Explod
trigger1 = time = 8
anim = 4015
ID = 4015
postype = back
pos = 0, 0
bindtime = -1
removetime = -1
sprpriority = -999
supermovetime = 9999
pausemovetime = 9999

[State 4013, Explod]
type = Explod
trigger1 = time = 8
anim = 4015
ID = 4015
postype = back
pos = 320, 0
bindtime = -1
removetime = -1
sprpriority = -999
supermovetime = 9999
pausemovetime = 9999

[State 4013, Explod]
type = Explod
trigger1 = time = 8
anim = 4016
ID = 4016
postype = back
pos = 0, 0
bindtime = -1
removetime = -1
sprpriority = -999
supermovetime = 9999
pausemovetime = 9999

[State 4013, Explod]
type = Explod
trigger1 = time = 8
anim = 4016
ID = 4016
postype = back
pos = 320, 0
bindtime = -1
removetime = -1
sprpriority = -999
supermovetime = 9999
pausemovetime = 9999

[State 4013, RemoveExplod]
type = RemoveExplod
trigger1 = Time >= 260
ID = 4009

[State 4013, RemoveExplod]
type = RemoveExplod
trigger1 = Time >= 260
ID = 4010

[State 4013, RemoveExplod]
type = RemoveExplod
trigger1 = Time >= 260
ID = 4011

[State 4013, RemoveExplod]
type = RemoveExplod
trigger1 = Time >= 260
ID = 4012

[State 4013, RemoveExplod]
type = RemoveExplod
trigger1 = Time >= 260
ID = 4013

[State 4013, RemoveExplod]
type = RemoveExplod
trigger1 = Time >= 260
ID = 4014

[State 4013, RemoveExplod]
type = RemoveExplod
trigger1 = Time >= 260
ID = 4015

[State 4013, RemoveExplod]
type = RemoveExplod
trigger1 = Time >= 260
ID = 4016

[State 4013, DestroySelf]
type = DestroySelf
trigger1 = time >= 260

[StateDef 4014]
type = A
ctrl = 0
anim = 4005
velset = 3,-3
movetype = I
physics = N
sprpriority = 30

[State 4014, VarSet]
type = VarSet
trigger1 = time = 0
var(1) = 0

[State 4014, VarAdd]
type = VaRadd
trigger1 = 1
var(1) = 1

[State 4014, VarSet]
type = VarSet
trigger1 = time = 0
var(2) = 0

[State 4014, VarAdd]
type = VarAdd
trigger1 = time >= 22
var(2) = 8

[State 4014, Trans]
type = Trans
trigger1 = 1
trans = addalpha
alpha = 256 - var(2),256

[State 4014, AngleDraw]
type = AngleDraw
trigger1 = 1
scale = 0+var(1)*0.2,0+var(1)*0.2

[State DestroySelf]
type = DestroySelf
trigger1 = Var(2) >= 256

[StateDef 6000]
Type = S
Physics = S
MoveType = A
Anim = 6000
VelSet = 0,0
ctrl = 0
sprpriority = 2

[State 6000, VarSet]
type = VarSet
trigger1 = Time = 0
V = 46
Value = 1

[State 6000, VarAdd]
type = VarAdd
trigger1 = Time = 0
var(45) = -50
ignorehitpause = 1

[State 6000, PowerAdd]
type = PowerAdd
trigger1 = Var(46) = 1
trigger1 = Time = 0
trigger1 = Var(47) < 10
value = 200

[State 6000, VarSet]
type = VarAdd
triggerall = Var(47) < 10
trigger1 = Var(46) = 1
trigger1 = Var(49) <= 0
trigger1 = Time = 0
v = 47
Value = 1

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

[State 6000, HitDef]
type = HitDef
trigger1 = AnimElemTime(1) = 1
attr = S, NA
damage = 10
animtype = Heavy
guardflag = MA
hitflag = MAF
priority = 5, Hit
pausetime = 0,30
guard.pausetime = 0,16
sparkno = -1+(0*(var(41) := 8052))
guard.sparkno = -1+(0*(var(42) := 9000))
sparkxy = 0,0+(0*(var(43) := 100 && var(44) := -65))
hitsound = S200,2
guardsound = S300,0
ground.type = high
ground.slidetime = 18
ground.hittime = 18
ground.velocity = -3
airguard.ctrltime = 2
guard.velocity = -3
air.velocity = -1.5,-4.4
envshake.time = 9
envshake.ampl = 3
getpower = 0
givepower = 15
yaccel = 0.4

[State 6000, PosFreeze]
type = PosFreeze
trigger1 = 1
value = 1

[State 6000, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S10000,3

[State 6000, PlaySnd]
type = PlaySnd
trigger1 = AnimElem = 1
value = S6000,0+Random%3
Channel = 0

[State 6000, Helper]
type = Helper
trigger1 = Time = 0
Helpertype = normal
StateNo = 6001
ID = 6001
name = "Burst"
postype = p1
pos = ceil(0 * const(size.xscale)), ceil(-53 * const(size.yscale))
pausemovetime=-2**31-1
supermovetime=-2**31-1
ownpal = 1

[State 6000, Helper]
type = Helper
trigger1 = Time = 0
helpertype = normal
stateno = 6002
ID = 6002
name = "MAX"
postype = p1
pos = ceil(-6 * const(size.xscale)), ceil(-64 * const(size.yscale))
size.xscale = 1
size.yscale = 1
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1

[State 6000, helper]
type = Helper
trigger1 = Time = 0
stateno = 6003
ID = 6003
Name = "Cooldown"
postype = left
facing = 1
sprpriority = 5
ownpal = 1
ignorehitpause = 1
persistent = 0
Helpertype = Normal
pausemovetime=-2**31-1
supermovetime=-2**31-1

[State 6000, ChangeState]
type = ChangeState
trigger1 = Time = 15
value = 0
ctrl = 1

[StateDef 6001]
Type = A
Physics = N
MoveType = I
Anim = 99999
ctrl = 0
velset = 0,0

[State 6001, BGPalFX]
type = BGPalFX
trigger1 = 1
time = 1
color= 16*time
mul = 16*time, 16*time, 16*time

[State 6001, Explod]
type = Explod
trigger1 = Time = 0
Anim = 6020
ID = 6020
sprpriority = 3
postype = p1
removetime = 16
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1

[State 6001, ModifyExplod]
type = ModifyExplod
trigger1 = NumExplod(6020)
ID = 6020
scale = (.0625*time), (.0625*time)
trans = addalpha
alpha = 256-(16*time), 256

[State 6001, Explod]
type = Explod
trigger1 = time = 0
anim = 6021
ID = 6021
sprpriority = -2
postype = p1
pos = 0,-ceil(pos y)
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1

[State 6001, DestroySelf]
type = DestroySelf
trigger1= time >= 16

[StateDef 6002]
anim = 0
ctrl = 0
sprpriority = -6

[State 6002, Bindtoroot]
type = BindToRoot
trigger1 = 1

[State 6002, Turn]
type = turn
trigger1 = facing != Root,facing

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

[State 6002, VarSet]
type = VarSet
trigger1 = Root, HitPauseTime = 0
var(0) = Root, AnimElemNo(0)

[State 6002, Anim]
type = ChangeAnim
triggerall = SelfAnimExist(Root, Anim)
triggerall = AnimExist(Root, Anim)
trigger1 = Root, Anim < 6003
value = Root, Anim
elem = Var(0)

[State 6002, Anim]
type = ChangeAnim
triggerall = SelfAnimExist(Root,Anim)
triggerall = AnimExist(Root,Anim)
triggerall = Root,HitPauseTime > 0
trigger1 = Root,AnimElemNo(0) > AnimElemNo(0)
value = Root,Anim
elem = Root,AnimElemNo(0)

[State 6002, AssertSpecial]
type = AssertSpecial
trigger1 = Time <= 0
trigger2 = !SelfAnimExist(Root,Anim)
trigger3 = !AnimExist(Root,Anim)
trigger4 = Root,StateNo >= 160
trigger4 = Root,StateNo < 5000
trigger4 = Root,MoveType = H
trigger5 = Root,StateNo >= 6000
trigger5 = Root,MoveType = H
trigger6 = Root,Anim >= 160
trigger6 = Root,Anim < 5000
trigger6 = Root,MoveType = H
trigger7 = Root,Anim >= 6000
trigger7 = Root,MoveType = H
trigger8 = Root,Stateno = [190,194]
trigger9 = Root,Stateno = 5150
trigger10 = Root,Stateno = 3000
flag = Invisible

[State 6002, AngleDraw]
type = angledraw
trigger1 = 1
scale = 1+var(1)*.002,1+var(1)*.0015

[State 6002, Trans]
type = trans
trigger1 = 1
trans = addalpha
alpha = 256, 256

[State 6002, PalFx]
type = PalFX
trigger1 = 1
time = 1
add = 255,-220,-220
invertall = 0
color = 256

[State 6002, VarAdd]
type = varadd
trigger1 = 1
var(2) = 1

[State 6002, VarAdd]
type = varadd
trigger1 = var(2) <= 30
var(1) = 1

[State 6002, VarAdd]
type = varadd
trigger1 = var(2) > 30
var(1) = -1

[State 6002, VarAdd]
type = varset
trigger1 = var(2) >= 60
var(2) = 0

[State 6002, DestroySelf]
type = DestroySelf
trigger1 = Root,Var(46) = 0

[StateDef 6003]
type = A
movetype = I
physics = N
anim = 99999
ctrl = 0
velset = 0,0
sprpriority = -99

[State 6003, Null]
type = Null
trigger1 = Root,NumPartner!=0
trigger1 = (Partner,ID) < (Root,ID)
trigger1 = Partner,Authorname = "Kohaku"
trigger1 = var(0):=1

[State 6003, nothitby]
type = nothitby
trigger1 = 1
value = SCA
time = 999

[State 6003, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow

[State 6003, Explod]
type = explod
trigger1 = Time = 0
id = 6022
anim = 6022
pos = Ifelse(Teamside = 1,108,208),ifelse(1.0*gamewidth/gameheight<1.34,227,167)-(20*(var(0)))
postype = left
scale = 0.5,0.5
ownpal = 1
bindtime = -1
removetime = -1
ontop = 1
facing = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1

[State 6003, RemoveExplod]
type = RemoveExplod
trigger1 = Time >= 180
id = 6022

[State 6003, DestroySelf]
type = DestroySelf
trigger1 = Time >= 180

[StateDef 6005]
Type = S
Physics = S
MoveType = I
Anim = 6001
VelSet = 0,0
ctrl = 0
sprpriority = 2

[State 6005, VarSet]
type = VarSet
trigger1 = Time = 0
V = 46
Value = 0

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

[StateDef 6010]
movetype = I
physics = N
anim = 99999
ctrl = 0

[State -2, VarSet]
type = ParentVarSet
trigger1 = root,Var(45) > 300
v = 45
Value = 300

[State -2, VarSet]
type = ParentVarSet
trigger1 = root,Var(45) < 0
v = 45
Value = 0

[State 6010, Null]
type = Null
trigger1 = Root,NumPartner!=0
trigger1 = (Partner,ID) < (Root,ID)
trigger1 = Partner,Authorname = "Kohaku"
trigger1 = var(0):=1

[state ]
type=removeexplod
trigger1=var(1)-root,var(45)/100
trigger1=0*(var(1):=root,var(45)/100)*(var(5):=1)
trigger2=var(2)-(root,var(45)/10)%10
trigger2=0*(var(2):=(root,var(45)/10)%10)*(var(5):=1)
trigger3=var(3)-root,var(45)%10
trigger3=0*(var(3):=root,var(45)%10)*(var(5):=1)
trigger4=var(6)-(root,var(48)/10)%10
trigger4=0*(var(6):=(root,var(48)/10)%10)*(var(5):=1)
trigger5=var(7)-root,var(48)%10
trigger5=0*(var(7):=root,var(48)%10)*(var(5):=1)
trigger6=var(4)-root,var(47)
trigger6=0*(var(4):=root,var(47))*(var(5):=1)
trigger7=var(5)
trigger7=1||(var(5):=0)

[State 6010, Explod]
type = explod
trigger1 = Numexplod(6010)=0
ID = 6010
anim = IfElse(Teamside = 1,6010,6011)
pos = Ifelse(Teamside = 1,5,315),ifelse(1.0*gamewidth/gameheight<1.34,238,178)-(20*(var(0)))
postype = left
scale = 0.5,0.5
ownpal = 1
bindtime = -1
removetime = -1
ontop = 1
facing = 1
pausemovetime=-1
supermovetime=-1

[State 6010, Explod]
type = explod
trigger1 = NumExplod(6012) = 0
id = 6012
anim = 6012
pos = Ifelse(Teamside = 1,6,313),ifelse(1.0*gamewidth/gameheight<1.34,235,175)-(20*(var(0)))
postype = left
scale = 0.5,0.5
ownpal = 0
bindtime = -1
removetime = -1
ontop = 1
facing = ifelse(teamside=1,1,-1)
pausemovetime=-1
supermovetime=-1

[State 6010, ModifyExplod]
type = modifyexplod
trigger1 = 1
id = 6012
Scale = .5*Root,Var(45)/300,0.50

[State 6010, PalFX]
type = PalFx
trigger1 = Root,Var(46)
time = 1
add = (-12*(time+10))%240+240,(-12*(time+10))%240+240,(-12*(time+10))%240+240

[State 6010, Explod]
type = explod
trigger1 = NumExplod(6014) = 0
trigger1 = var(4)
id = 6014
anim = 6013+var(4)+3*(var(4)>6)
pos = Ifelse(Teamside = 1,3,316),ifelse(1.0*gamewidth/gameheight<1.34,229,169)-(20*(var(0)))
postype = left
scale = 0.5,0.5
ownpal = 1
bindtime = -1
removetime = -1
ontop = 1
facing = ifelse(teamside=1,1,-1)
pausemovetime=-1
supermovetime=-1

[State 6010, Explod]
type = Explod
trigger1 = NumExplod(6030) = 0
anim = 6030+Var(1)
ID = 6030
pos = Ifelse(Teamside = 1,75,226),ifelse(1.0*gamewidth/gameheight<1.34,238,178)-(20*(var(0)))
postype = left
bindtime = -1
removetime = -1
scale = 0.5,0.5
ontop = 1
ownpal = 1
pausemovetime=-1
supermovetime=-1

[State 6010, Explod]
type = Explod
trigger1 = NumExplod(6031) = 0
anim = 6030+Var(2)
ID = 6031
pos = Ifelse(Teamside = 1,81,232),ifelse(1.0*gamewidth/gameheight<1.34,238,178)-(20*(var(0)))
postype = left
bindtime = -1
removetime = -1
scale = 0.5,0.5
ontop = 1
ownpal = 1
pausemovetime=-1
supermovetime=-1

[State 6010, Explod]
type = Explod
trigger1 = NumExplod(6032) = 0
anim = 6030+Var(3)
ID = 6032
pos = Ifelse(Teamside = 1,87,238),ifelse(1.0*gamewidth/gameheight<1.34,238,178)-(20*(var(0)))
postype = left
bindtime = -1
removetime = -1
scale = 0.5,0.5
ontop = 1
ownpal = 1
pausemovetime=-1
supermovetime=-1

[State 6010, Explod]
type = explod
trigger1 = Numexplod(6040)=0
ID = 6040
anim = 6040
pos = Ifelse(Teamside = 1,110,210),ifelse(1.0*gamewidth/gameheight<1.34,239,179)-(20*(var(0)))
postype = left
scale = 1,1
ownpal = 1
bindtime = -1
removetime = -1
ontop = 1
facing = 1
pausemovetime=-1
supermovetime=-1

[State 6010, Explod]
type = Explod
trigger1 = NumExplod(6050) = 0
anim = 6050+Var(6)
ID = 6050
pos = Ifelse(Teamside = 1,113,189),ifelse(1.0*gamewidth/gameheight<1.34,230,170)-(20*(var(0)))
postype = left
bindtime = -1
removetime = -1
scale = 0.5,0.5
ontop = 1
ownpal = 1
pausemovetime=-1
supermovetime=-1

[State 6010, Explod]
type = Explod
trigger1 = NumExplod(6051) = 0
anim = 6050+Var(7)
ID = 6051
pos = Ifelse(Teamside = 1,121,197),ifelse(1.0*gamewidth/gameheight<1.34,230,170)-(20*(var(0)))
postype = left
bindtime = -1
removetime = -1
scale = 0.5,0.5
ontop = 1
ownpal = 1
pausemovetime=-1
supermovetime=-1

[StateDef 6200]
type = A
movetype= I
physics = N
poweradd= 0
velset = 0,0
anim = 99999
ctrl = 0
sprpriority = 4

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

[State 6200, ChangeAnim]
type = ChangeAnim
trigger1 = 1
value = Root,Anim
elem = Root,AnimElemNo(0)

[state 6200, Trans]
type = trans
trigger1 = 1||(fvar(0):=sin(time*pi/120))+(fvar(1):=sin(time*pi/60))
trans = AddAlpha
alpha = floor(256*(1-fvar(0))+.5),floor(256*fvar(0)+.5)

[State 6200, AngleDraw]
type = AngleDraw
trigger1 = 1
scale = 1+.25*fvar(1),1+.25*fvar(1)

[State 6200, PosSet]
type = Posset
trigger1 = 1
x = Root,Pos x
y = Root,Pos y+16*fvar(1)

[State 6200, PalFX]
type = PalFX
trigger1 = !time
time = -1
mul = 0,128,256
trigger1 = !time

[State 6200, Explod]
type = Explod
trigger1 = time = 0
Anim = 6200
ID = 6200
sprpriority = 20
postype = p1
pos = -10,0
bindtime = 1
ignorehitpause = 1
persistent = 0
under = 0
ownpal = 1
scale = 0.5,0.5
pausemovetime=-2**31-1
supermovetime=-2**31-1

[State 6200, Explod]
type = Explod
trigger1 = time = 0
anim = 6201
ID = 6201
sprpriority = 20
postype = p1
pos = -10,0
bindtime = 1
ignorehitpause = 1
persistent = 0
under = 0
ownpal = 1
scale = 0.5,0.5
pausemovetime=-2**31-1
supermovetime=-2**31-1

[State 6200, Explod]
type = Explod
trigger1 = time = 0
Anim = 6202
ID = 6202
sprpriority = -20
postype = p1
pos = -10,0
bindtime = 1
ignorehitpause = 1
persistent = 0
under = 0
ownpal = 1
scale = 0.5,0.5
pausemovetime=-2**31-1
supermovetime=-2**31-1

[State 6200, Explod]
type = Explod
trigger1 = time = 0
Anim = 6203
ID = 6200
sprpriority = -20
postype = p1
pos = -10,0
bindtime = 1
ignorehitpause = 1
persistent = 0
under = 0
ownpal = 1
scale = 0.5,0.5
pausemovetime=-2**31-1
supermovetime=-2**31-1

[State 6200, DestroySelf]
type = DestroySelf
trigger1 = Time >= 60
trigger2 = Root,MoveType = H

[StateDef 6210]
type = A
movetype= I
physics = N
poweradd= 0
velset = 0,0
anim = 99999
ctrl = 0
sprpriority = 4

[State 6210, Explod]
type = Explod
trigger1 = time = 0
Anim = 6210
ID = 6210
sprpriority = 20
postype = p1
pos = 0,0
bindtime = 1
ignorehitpause = 1
persistent = 0
under = 0
ownpal = 1
scale = 1,1
pausemovetime=-2**31-1
supermovetime=-2**31-1

[State 6210, Explod]
type = Explod
trigger1 = time = 0
anim = 6211
ID = 6211
sprpriority = 20
postype = p1
pos = 0,0
bindtime = 1
ignorehitpause = 1
persistent = 0
under = 0
ownpal = 1
scale = 1.5,1.5
pausemovetime=-2**31-1
supermovetime=-2**31-1

[State 6200, DestroySelf]
type = DestroySelf
trigger1 = Time >= 33

[StateDef 8030]
type = A
anim = 99999
velset = 0, 0
sprpriority = 5

[State 8030, PosSet]
type = PosSet
trigger1 = !time = 0
y = 0

[State 8030, Explod]
type = Explod
trigger1 = time = 0 || time = 3 || time = 6
anim = 8030
ID = ifelse((time = 6), 8032, ifelse((time = 3), 8031, 8030))
postype = p1
pos = 0, -4
random = 8, 8
vel = -3 -(random / 1000.0), -2 -(random / 2000.0)
facing = ifelse(random < 500, -1, 1)
vfacing = ifelse(random < 500, -1, 1)
removetime = 16
sprpriority = 3
pausemovetime = -1
supermovetime = -1

[State 8030, ModifyExplod]
type = ModifyExplod
trigger1 = NumExplod(8030)
ID = 8030
scale = 0.1 + (0.025 * time), 0.1 + (0.025 * time)
trans = addalpha
alpha = 256 -(16 * time), 256

[State 8030, ModifyExplod]
type = ModifyExplod
trigger1 = NumExplod(8031)
ID = 8031
scale = 0.1 + (0.025 * (time -3)), 0.1 + (0.025 * (time -3))
trans = addalpha
alpha = 256 -(16 * (time -3)), 256

[State 8030, ModifyExplod]
type = ModifyExplod
trigger1 = NumExplod(8032)
ID = 8032
scale = 0.1 + (0.025 * (time -6)), 0.1 + (0.025 * (time -6))
trans = addalpha
alpha = 256 -(16 * (time -6)), 256

[State 8030, RemoveExplod]
type = RemoveExplod
trigger1 = time >= 22

[State 8030, DestroySelf]
type = DestroySelf
trigger1 = !NumExplod

[StateDef 8050]
type = A
physics = N
movetype = I
anim = 8050
velset=0,0
sprpriority=5

[State 8050, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow

[State 8050, AngleSet]
type = AngleSet
trigger1 = !time
value = 30*(random%12)

[State 8050, AngleAdd]
type = AngleAdd
trigger1 = 1
value = 30

[State 8050, AngleDraw]
type = AngleDraw
trigger1 = time < 10
scale = .3-(time*.03), .3-(time*.03)

[State 8050, AngleDraw]
type = AngleDraw
trigger1= time >= 10
scale = 0,0

[State 8050, Trans]
type = trans
trigger1 = 1
trans = addalpha
alpha = 256,256

[State 8050, Explod]
type = Explod
trigger1 = !time
anim = 8051
ID = 8051
postype = p1
facing = ifelse(random<500,-1,1)
vfacing = ifelse(random<500,-1,1)
sprpriority = 5
removetime = 16
pausemovetime = -1
supermovetime = -1

[State 8050, ModifyExplod]
type = ModifyExplod
trigger1 = NumExplod(8051)
ID = 8051
scale = .15+(.009375*time),.15+(.009375*time)
trans = addalpha
alpha = 256-(16*time),256

[State 8050, Explod]
type = Explod
trigger1 = !time
anim = 8052
ID = 8052
postype = p1
facing = ifelse(random<500,-1,1)
vfacing = ifelse(random<500,-1,1)
sprpriority = 5
removetime = 16
pausemovetime = -1
supermovetime = -1

[State 8050, ModifyExplod]
type = ModifyExplod
trigger1 = numexplod(8052)
ID = 8052
scale = .15+(.009375*time),.15+(.009375*time)
trans = addalpha
alpha = 256-(16*time),256

[State 8050, Explod]
type = Explod
trigger1= !time
anim = 8053
ID = 8053
postype = p1
facing = ifelse(random<500,-1,1)
vfacing = ifelse(random<500,-1,1)
sprpriority = 3
removetime = 8
pausemovetime = -1
supermovetime = -1

[State 8050, ModifyExplod]
type = ModifyExplod
trigger1 = NumExplod(8053)
ID = 8053
scale = .3-(.0375*time),.3-(.0375*time)
trans = addalpha
alpha = 128-(16*time),256

[State 8050, RemoveExplod]
type = RemoveExplod
trigger1 = time >= 16

[State 8050, DestroySelf]
type = DestroySelf
trigger1 = time >= 16

[StateDef 8051]
type = A
physics = N
movetype = I
anim = 8050
velset = 0,0
sprpriority = 5

[State 8051, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow

[State 8051, AngleSet]
type = AngleSet
trigger1 = !time
value = 30*(random%12)

[State 8051, AngleAdd]
type = AngleAdd
trigger1 = 1
value = 30

[State 8051, AngleDraw]
type = AngleDraw
trigger1 = time<10
scale = .35-(time*.035), .35-(time*.035)

[State 8051, AngleDraw]
type = AngleDraw
trigger1 = time >= 10
scale = 0,0

[State 8051, Trans]
type = trans
trigger1 = 1
trans = addalpha
alpha = 256,256

[State 8051, Explod]
type = Explod
trigger1 = !time
anim = 8051
ID = 8051
postype = p1
facing = ifelse(random<500,-1,1)
vfacing = ifelse(random<500,-1,1)
sprpriority = 5
removetime = 16
pausemovetime = -1
supermovetime = -1

[State 8051, ModifyExplod]
type = ModifyExplod
trigger1 = NumExplod(8051)
ID = 8051
scale =.175+(.0109375*time),.175+(.0109375*time)
trans = addalpha
alpha = 256-(16*time),256

[State 8051, Explod]
type = Explod
trigger1 = !time
anim = 8052
ID = 8052
postype = p1
facing = ifelse(random<500,-1,1)
vfacing = ifelse(random<500,-1,1)
sprpriority = 5
removetime = 16
pausemovetime = -1
supermovetime = -1

[State 8051, ModifyExplod]
type = ModifyExplod
trigger1 = NumExplod(8052)
ID = 8052
scale = .175+(.0109375*time),.175+(.0109375*time)
trans = addalpha
alpha = 256-(16*time),256

[State 8051, Explod]
type = Explod
trigger1 = !time
anim = 8053
ID = 8053
postype = p1
facing = ifelse(random<500,-1,1)
vfacing = ifelse(random<500,-1,1)
sprpriority = 3
removetime = 8
pausemovetime = -1
supermovetime = -1

[State 8051, ModifyExplod]
type = ModifyExplod
trigger1= NumExplod(8053)
ID = 8053
scale = .35-(.04375*time),.35-(.04375*time)
trans = addalpha
alpha = 128-(16*time),256

[State 8051, RemoveExplod]
type = RemoveExplod
trigger1 = time >= 16

[State 8051, DestroySelf]
type = DestroySelf
trigger1 = time >= 16

[StateDef 8052]
type = A
physics = N
movetype = I
anim = 8050
velset=0,0
sprpriority=5

[State 8052, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoShadow

[State 8052, AngleSet]
type = AngleSet
trigger1 = !time
value = 30*(random%12)

[State 8052, AngleAdd]
type = AngleAdd
trigger1 = 1
value = 30

[State 8052, AngleDraw]
type = AngleDraw
trigger1 = time < 10
scale = .4-(time*.04), .4-(time*.04)

[State 8052, AngleDraw]
type = AngleDraw
trigger1 = time >= 10
scale = 0,0

[State 8052, Trans]
type = Trans
trigger1 = 1
trans = addalpha
alpha = 256,256

[State 8052, Explod]
type = Explod
trigger1 = !time
anim = 8051
ID = 8051
postype = p1
facing = ifelse(random<500,-1,1)
vfacing = ifelse(random<500,-1,1)
sprpriority = 5
removetime = 16
pausemovetime = -1
supermovetime = -1

[State 8052, ModifyExplod]
type = ModifyExplod
trigger1 = NumExplod(8051)
ID = 8051
scale =.2+(.0125*time),.2+(.0125*time)
trans = addalpha
alpha = 256-(16*time),256

[State 8052, Explod]
type = Explod
trigger1 = !time
anim = 8052
ID = 8052
postype = p1
facing = ifelse(random<500,-1,1)
vfacing = ifelse(random<500,-1,1)
sprpriority = 5
removetime = 16
pausemovetime = -1
supermovetime = -1

[State 8052, ModifyExplod]
type = ModifyExplod
trigger1 = NumExplod(8052)
ID = 8052
scale = .2+(.0125*time),.2+(.0125*time)
trans = addalpha
alpha = 256-(16*time),256

[State 8052, Explod]
type = Explod
trigger1 = !time
anim = 8053
ID = 8053
postype = p1
facing = ifelse(random<500,-1,1)
vfacing = ifelse(random<500,-1,1)
sprpriority = 3
removetime = 8
pausemovetime = -1
supermovetime = -1

[State 8052, ModifyExplod]
type = ModifyExplod
trigger1 = NumExplod(8053)
ID = 8053
scale = .4-(.05*time),.4-(.05*time)
trans = addalpha
alpha = 128-(16*time),256

[State 8052, RemoveExplod]
type = RemoveExplod
trigger1 = time >= 16

[State 8052, DestroySelf]
type = DestroySelf
trigger1 = time >= 16

[StateDef 8053]
type = A
physics = N
movetype = I
anim = 8050
velset = 0,0
sprpriority = 5

[State 8053, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[State 8053, AngleSet]
type = AngleSet
trigger1 = !time
value = 30*(random%12)

[State 8053, AngleAdd]
type = AngleAdd
trigger1 = 1
value = 30

[State 8053, AngelDraw]
type = AngleDraw
trigger1 = time < 10
scale = .5-(time*.05), .5-(time*.05)

[State 8053, AngleDraw]
type = AngleDraw
trigger1 = time >= 10
scale = 0,0

[State 8053, Trans]
type = Trans
trigger1 = 1
trans = addalpha
alpha = 256,256

[State 8053, Explod]
type = Explod
trigger1 = !time
anim = 8051
ID = 8051
postype = p1
facing = ifelse(random < 500,-1,1)
vfacing = ifelse(random < 500,-1,1)
sprpriority = 5
removetime = 16
pausemovetime = -1
supermovetime = -1

[State 8053, ModifyExplod]
type = ModifyExplod
trigger1 = numexplod(8051)
ID = 8051
scale = .25+(.015625*time),.25+(.015625*time)
trans = addalpha
alpha = 256-(16*time),256

[State 8053, Explod]
type = Explod
trigger1 = !time
anim = 8052
ID = 8052
postype = p1
facing = ifelse(random < 500,-1,1)
vfacing = ifelse(random < 500,-1,1)
sprpriority = 5
removetime = 16
pausemovetime = -1
supermovetime = -1

[State 8053, ModifyExplod]
type = ModifyExplod
trigger1 = numexplod(8052)
ID = 8052
scale = .25+(.015625*time),.25+(.015625*time)
trans = addalpha
alpha = 256-(16*time),256

[State 8053, Explod]
type = Explod
trigger1 = !time
anim = 8054
ID = 8054
postype = p1
vfacing = ifelse(random < 500,-1,1)
sprpriority = -3
removetime = 8
pausemovetime = -1
supermovetime = -1

[State 8053, ModifyExplod]
type = ModifyExplod
trigger1 = numexplod(8054)
ID = 8054
scale = .5,.5
trans = addalpha
alpha = 256-(32*time),256

[State 8053, Explod]
type = Explod
trigger1 = !time
anim = 8053
ID = 8053
postype = p1
facing = ifelse(random < 500,-1,1)
vfacing = ifelse(random < 500,-1,1)
sprpriority = 3
removetime = 8
pausemovetime = -1
supermovetime = -1

[State 8053, ModifyExplod]
type = ModifyExplod
trigger1 = numexplod(8053)
ID = 8053
scale = .5-(.0625*time),.5-(.0625*time)
trans = addalpha
alpha = 256-(32*time),256

[State 8053, RemoveExplod]
type = RemoveExplod
trigger1 = time >= 16

[State 8053, DestroySelf]
type = DestroySelf
trigger1 = time >= 16

[StateDef 8054]
type = A
physics = N
movetype = I
anim = 8050
velset = 0,0
sprpriority = 5

[State 8054, AssertSpecial]
type = assertspecial
trigger1 = 1
flag = noshadow

[State 8054, Angle]
type = angleset
trigger1 = !time
value = 30*(random%12)

[State 8054, AngleAdd]
type = angleadd
trigger1 = 1
value = 30

[State 8054, AngleDraw]
type = angledraw
trigger1 = time < 10
scale = .45-(time*.045), .45-(time*.045)

[State 8054, AngleDraw]
type = angledraw
trigger1 = time >= 10
scale = 0,0

[State 8054, Trans]
type = trans
trigger1 = 1
trans = addalpha
alpha = 256,256

[State 8054, Explod]
type = explod
trigger1 = !time
anim = 8051
ID = 8051
postype = p1
facing = ifelse(random<500,-1,1)
vfacing = ifelse(random<500,-1,1)
sprpriority = 5
removetime = 16
pausemovetime = -1
supermovetime = -1

[State 8054, ModifyExplod]
type = modifyexplod
trigger1 = numexplod(8051)
ID = 8051
scale = .225+(.0140625*time),.225+(.0140625*time)
trans = addalpha
alpha = 256-(16*time),256

[State 8054, Explod]
type = explod
trigger1 = !time
anim = 8052
ID = 8052
postype = p1
facing = ifelse(random<500,-1,1)
vfacing = ifelse(random<500,-1,1)
sprpriority = 5
removetime = 16
pausemovetime = -1
supermovetime = -1

[State 8054, ModifyExplod]
type = modifyexplod
trigger1 = numexplod(8052)
ID = 8052
scale = .225+(.0140625*time),.225+(.0140625*time)
trans = addalpha
alpha = 256-(16*time),256

[State 8054, Explod]
type = explod
trigger1 = !time
anim = 8054
ID = 8054
postype = p1
vfacing = ifelse(random < 500,-1,1)
sprpriority = -3
removetime = 8
pausemovetime = -1
supermovetime = -1

[State 8054, ModifyExplod]
type = modifyexplod
trigger1 = numexplod(8054)
ID = 8054
scale = .4,.4
trans = addalpha
alpha = 256-(32*time),256

[State 8054, Explod]
type = explod
trigger1 = !time
anim = 8053
ID = 8053
postype = p1
facing = ifelse(random < 500,-1,1)
vfacing = ifelse(random < 500,-1,1)
sprpriority = 3
removetime = 8
pausemovetime = -1
supermovetime = -1

[State 8054, ModifyExplod]
type = modifyexplod
trigger1 = numexplod(8053)
ID = 8053
scale = .45-(.05625*time),.45-(.05625*time)
trans = addalpha
alpha = 192-(24*time),256

[State 8054, RemoveExplod]
type = RemoveExplod
trigger1= time >= 16

[State 8054, DestroySelf]
type = DestroySelf
trigger1= time >= 16

[StateDef 8100]
type = A
velSet = 0,0
anim = 99999

[State 8100, VarSet]
type = VarSet
trigger1 = !Time
var(0) = Parent,var(43)

[State 8100, PosSet]
type = PosSet
trigger1 = PlayerIDexist(var(0))
x = ceil(PlayerID(var(0)), pos x)
y = ceil(PlayerID(var(0)), pos y) + (PlayerID(var(0)), const(size.mid.pos.y))

[State 8100, PosSet]
type = PosSet
trigger1 = PlayerIDexist(var(0))
trigger1 = PlayerID(var(0)), StateType = L
x = ceil(PlayerID(var(0)), pos x)
y = ceil(PlayerID(var(0)), pos y) - 20

[State 8100, Turn]
type = Turn
trigger1 = PlayerIDexist(var(0))
trigger1 = Facing != (PlayerID(var(0)), Facing)

[State 8100, Explod]
type = Explod
trigger1 = PlayerIDexist(var(0))
anim = 8100
sprPriority = 3
posType = P1
random = 40,40
vel = (Random / 2000.0), -0.5 - (Random / 2000.0)
facing = ifElse(Random < 500, -1, 1)
vfacing = ifElse(Random < 500, -1, 1)
scale = 0.5,0.5
ownpal = 1

[State 8100, Explod]
type = Explod
trigger1 = PlayerIDexist(var(0))
anim = 8100
sprPriority = 3
posType = P1
random = 60,60
vel = (Random / 2000.0), -0.5 - (Random / 2000.0)
facing = ifElse(Random < 500, -1, 1)
vfacing = ifElse(Random < 500, -1, 1)
scale = 0.5,0.5
ownpal = 1

[State 8100, DestroySelf]
type = DestroySelf
triggerAll = PlayerIDexist(var(0))
trigger1 = PlayerID(var(0)), ctrl
trigger2 = PlayerID(var(0)), Movetype != H || PlayerID(var(0)), StateNo = 5300
trigger3 = PlayerID(var(0)), StateType = L && (PlayerID(var(0)), StateNo != [5080,5081])
trigger4 = Root,Stateno = 4001

[StateDef 8700]
type = A
physics = N
velset = 0,0
anim = 99999

[State 8700, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S8700,0
channel = 2

[State 8700, Explod]
type = explod
trigger1 = Time = 0
anim = IfElse(TeamSide = 1,8700,8701)
pos = IfElse(Teamside = 1,0,320),110
ID = 8700
sprpriority = -1
postype = Left
removetime = 60
BindTime = -1
pausemovetime = -1
supermovetime = -1
ownpal = 1
scale = 0.335,0.335

[State 8700, RemoveExplod]
type = removeexplod
trigger1 = time >= 60

[State 8700, DestroySelf]
type = destroyself
trigger1 = time >= 60

[StateDef 8710]
type = A
physics = N
velset = 0,0
anim = 99999

[State 8710, PlaySnd]
type = PlaySnd
trigger1 = Time = 0
value = S8710,0+Random%3
channel = 2

[State 8710, Explod]
type = explod
trigger1 = Time = 0
anim = IfElse(TeamSide = 1,8710,8711)
pos = IfElse(Teamside = 1,0,320),125
ID = 8710
sprpriority = -1
postype = Left
removetime = 60
BindTime = -1
pausemovetime = -1
supermovetime = -1
ownpal = 1
scale = 0.335,0.335

[State 8710, RemoveExplod]
type = removeexplod
trigger1 = time >= 60

[State 8710, DestroySelf]
type = destroyself
trigger1 = time >= 60

[StateDef 9000]
type = A
physics = N
movetype = I
anim = 9000
velset = 0,0
sprpriority = 5

[State 9000, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[State 9000, AnglDraw]
type = AngleDraw
trigger1 = 1
scale = .125+(.046875*time), .125+(.046875*time)

[State 9000, Trans]
type = Trans
trigger1 = time < 4
trans = addalpha
alpha = 256, 256

[State 9000, Trans]
type = Trans
trigger1 = time >= 4
trans = addalpha
alpha = 256 - 64*(time-4), 256

[State 9000, DstroySelf]
type = DestroySelf
trigger1 = time >= 8

[statedef 20200]
anim=99999
[state ]
type=null
time=50
anim=-1
p2defmul=1
darken=0
trigger1=1||(var(0):=5*(random%3))||(var(1):=(floor((1.3333333 * GameHeight / GameWidth) * 121))-120)
[state ]
type=explod
anim=20200
id=20200
facing=root,facing
scale=.33333333,.33333333
ontop=1
pausemovetime=2147483647
supermovetime=2147483647
postype=left
pos=160,var(1)
trigger1=1
[state ]
type=explod
anim=20215
id=20200
facing=root,facing
scale=.33333333,.33333333
ontop=1
pausemovetime=2147483647
supermovetime=2147483647
postype=left
pos=160,var(1)
trigger1=1
[state ]
type=explod
anim=20202
id=20200
facing=root,facing
scale=.33333333,.33333333
ontop=1
pausemovetime=2147483647
supermovetime=2147483647
postype=left
pos=160,var(1)
trigger1=1
[state ]
type=explod
anim=20201
id=20200
facing=root,facing
scale=.33333333,.33333333
ontop=1
pausemovetime=2147483647
supermovetime=2147483647
postype=left
pos=160,var(1)
trigger1=1
[state ]
type=explod
anim=20200+var(0)
id=20200
scale=.33333333,.33333333
ontop=1
pausemovetime=2147483647
supermovetime=2147483647
postype=left
pos=160,var(1)
trigger1=var(0)
[state ]
type=explod
anim=20202+var(0)
id=20200
scale=.33333333,.33333333
ontop=1
pausemovetime=2147483647
supermovetime=2147483647
postype=left
pos=160,var(1)
trigger1=var(0)
[state ]
type=explod
anim=20201+var(0)
id=20200
scale=.33333333,.33333333
ontop=1
pausemovetime=2147483647
supermovetime=2147483647
postype=left
pos=160,var(1)
trigger1=var(0)
[state ]
type=playsnd
value=s20200,random%4
volumescale=140
abspan=0
trigger1=1
[state ]
type=changestate
value=20201
trigger1=1
[statedef 20201]
[state ]
type=destroyself
trigger1=numexplod=0
[state ]
type=modifyexplod
id=20200
postype=left
pos=160,var(1)
trigger1=1
[state ]
type=modifyexplod
id=20203
postype=left
pos=0,0
trigger1=numexplod(20203)

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

[StateDef -2]

[State -2, PlaySnd]
type = playsnd
triggerall = alive && time = 1
triggerall = stateno = 5000 || stateno = 5010
trigger1 = gethitvar(animtype) >= 2 && random < 500
trigger2 = gethitvar(animtype) = 1 && random < 500
trigger3 = gethitvar(animtype) = 0 && random < 500
value = S5000,0+random%7
channel = 0
ignorehitpause = 1

[State -2, PlaySnd]
type = playsnd
triggerall = alive && time = 1
trigger1 = (stateno = 5000 || stateno = 5010) && numenemy
trigger1 = gethitvar(fall) || (enemynear, hitdefattr = SCA, SA, HA)
trigger2 = (stateno = 5020 || stateno = 5070 || stateno = 5080)
trigger3 = (stateno = 5050 || stateno = 5100) && (prevstateno != [5000, 5199])
value = S5000,0+random%7
channel = 0
ignorehitpause = 1

[State -2, PlaySnd]
type = PlaySnd
triggerall = time = 1
trigger1 = StateNo = [5200,5210]
value = S5200,0+Random%5
persistent = 0
channel = 0

[State -2, PlaySnd]
type = PlaySnd
triggerall = time = 1
trigger1 = stateno = 5120
value = S5200,0+Random%5
persistent = 0
channel = 0

[State -2, VarSet]
type = VarSet
trigger1 = StateType != A || StateNo = 5210
var(18) = 0

[State -2, Null]
type = Null
trigger1 = StateType = A
trigger1 = var(18) >= 0
trigger1 = command != "holdup"
trigger1 = var(18):= -var(18)-1

[State -2, VarSet]
type = VarSet
trigger1 = MoveContact = 1 && var(40) < 0
var(40) = hitpausetime
ignorehitpause = 1

[State -2, Helper]
type = Helper
trigger1 = var(40) = hitpausetime
trigger1 = var(41) >0 || var(42) > 0
trigger1 = MoveContact = 1
helpertype = normal
name="Hit_Spark"
stateno = ifelse(movehit,var(41),var(42))
ID = 8050
postype = p1
pos = ceil(ifelse(p2dist x<0,0,ifelse(p2dist x<var(43),p2dist x,var(43)))*const(size.xscale)),ceil(var(44)*const(size.yscale))
ownpal = 1
keyctrl = 0
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1

[State -2, Helper]
type = Helper
trigger1 = MoveHit = 1 && Var(40) = HitPauseTime
trigger1 = NumEnemy && Var(10)
trigger1 = !(HitDefAttr = SCA, AT) && (EnemyNear,MoveReversed != 1)
trigger1 = StateNo != 2301
helpertype = normal
stateno = 8700
ID = 8700
name = "Counter"
postype = p1
pos = ifelse(p2dist x<40, 40, ifelse(p2dist x<140, ceil(p2dist x), 140)), -70
ownpal = 1
size.xscale = 1
size.yscale = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1

[State -2, VarSet]
type = Varset
trigger1 = NumEnemy
var(10) = (EnemyNear,MoveType = A)
ignorehitpause = 1

[State -2, VarSet]
type = VarSet
trigger1 = 1
var(40) = -1

[State -2, VarRangeSet]
type = VarRangeSet
trigger1 = movetype = I
trigger2 = movetype = H && time
trigger3 = var(41)>0||var(42)>0
trigger3 = movecontact=1
first = 40
last = 44
value = -1
ignorehitpause = 1

[State -2, VarSet]
type = VarSet
trigger1 = Var(46) = 1
trigger1 = Var(45) <= 0
trigger2 = Var(46) = 0
trigger2 = Var(45) <=0
v = 45
Value = 0

[State -2, VarAdd]
type = VarAdd
triggerall = Var(45) <= 300
triggerall = Var(46) = 0
trigger1 = MoveHit = 1
trigger1 = StateNo != [800,810]
trigger1 = StateNo != 950
trigger1 = StateNo != [2000,4999]
v = 45
value = 12

[State -2, VarAdd]
type = VarAdd
triggerall = Var(45) <= 300
triggerall = Var(46) = 0
trigger1 = MoveGuarded = 1
trigger1 = StateNo != [800,810]
trigger1 = StateNo != 950
trigger1 = StateNo != [2000,4999]
v = 45
value = 6

[State -2, VarAdd]
type = VarAdd
triggerall = Var(45) <= 300
triggerall = Var(46) = 1
trigger1 = MoveContact = 1
trigger1 = StateNo != [800,810]
trigger1 = StateNo != 950
trigger1 = StateNo != 6000
trigger1 = StateNo != [2000,4999]
v = 45
value = -15

[State -2, VarAdd]
type = VarAdd
triggerall = Var(45) <= 300
trigger1 = MoveType = H
trigger1 = GetHitVar(damage)!=0
trigger1 = StateNo != [120,159]
v = 45
value = 4

[State -2, VarAdd]
type = VarAdd
triggerall = Var(45) <= 300
trigger1 = MoveType = H
trigger1 = GetHitVar(damage)!=0
trigger1 = StateNo = [120,159]
v = 45
value = 2

[State -2, VarAdd]
type = VarAdd
triggerall = Var(45) <= 300
triggerall = Var(46) = 0
triggerall = Alive
triggerall = RoundState = 2
triggerall = ((Life*100)/LifeMax) <= 20
trigger1 = StateNo != 3000
trigger1 = StateNo != [4000,4099]
trigger1 = Gametime%10 = 0
v = 45
value = 1

[State -2, VarSet]
type = VarSet
trigger1 = Var(46) = 1
trigger1 = Var(45) <= 0
v = 46
Value = 0

[State -2, VarSet]
type = VarSet
trigger1 = RoundState < 2
trigger1 = Var(48) != 10
var(48) = 10

[State -2, VarAdd]
type = VarAdd
trigger1 = var(49) > 0
trigger1 = !numhelper(20100)
trigger1 = StateNo != 3000
var(49) = -1
IgnoreHitPause = 1

[State -2, VarSet]
type = VarSet
trigger1 = RoundState = 1 
v = 49
value = 0

;[State -2, VarAdd];Testing Purposes
;type = VarAdd
;triggerall = Var(45) <= 300
;trigger1 = Command = "c"
;v = 45
;value = 300

;[State -2, VarSet];Testing Purposes
;type = VarSet
;triggerall = Var(47) <= 10
;trigger1 = Command = "c"
;v = 47
;value = 10

[State -2, VarSet]
type = Varset
trigger1 = numenemy
fvar(0) = enemynear,gethitvar(hitcount)
ignorehitpause = 1

[State -2, VarSet]
type = VarSet
trigger1 = numenemy
trigger1 = (enemynear,movetype!=H)
trigger2 = !numenemy
fvar(0) = 1

[State -2, VarSet]
type = VarSet
trigger1 = 1
fvar(1) = ifelse(fvar(0) = 0, 1, ifelse(fvar(0) = 1, 1, .96875**fvar(0)))
ignorehitpause = 1

[State -2, AttackMulSet]
type = AttackMulSet
trigger1 = 1
value = fvar(1)*fvar(2)
ignorehitpause = 1

[State -2, VarSet]
type = VarSet
trigger1 = 1
fvar(2) = IfElse(Var(46) = 1,1.15,1)

[State -2, Helper]
type = Helper
trigger1 = 1
trigger1 = numhelper(6010) = 0
ID = 6010
name = "MAX_Bar"
stateno = 6010
ownpal = 1
postype = left
pos = 160,
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1

[State -2, PalFX]
type = PalFX
triggerall = Var(46) = 1
trigger1 = !(GameTime % 2)
time = 1
add = 60,60,60
ignorehitpause = 1

[State -2, Helper]
type = Helper
Trigger1 = Var(46) = 1
Trigger1 = NumHelper(6002) = 0
Trigger1 = Var(45) >= 0
helpertype = normal
name = "Aura"
ID = 6002
pos = 0, 0
postype = p1
facing = 1
stateno = 6002
keyctrl = 0
ownpal = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1

[State -2, AssertSpecial]
type = AssertSpecial
flag = NoKOSlow
trigger1 = StateNo = [4000,4099]
ignorehitpause = 1

[State -2, Helper]
type = Helper
triggerall = RoundState >= 2
triggerall = WinKo && !var(37)
trigger1 = StateNo = [4000,4099]
trigger2=movetype=h
trigger2=prevstateno=[4000,4099]
trigger3 = NumHelper(4006)
ID = 20150
stateno = 20100
Name = "Super_Combo_Finish"
postype = left
pos = 0,0
pausemovetime=-2**31-1
supermovetime=-2**31-1
ignorehitpause = 1
ownpal = 1
persistent = 0

[State -2, VarAdd]
type = VarAdd
trigger1 = roundstate = 3
ignorehitpause = 1
var(37) = 1

[State -2, VarSet]
type = Varset
trigger1 = roundstate = 0
ignorehitpause = 1
var(37) = 0

[State -2, VarAdd]
type = VarAdd
trigger1 = 100*Life/LifeMax <= 20
v = 11
value = 1

[State -2, VarSet]
type = VarSet
trigger1 = 100*Life/LifeMax > 20
v = 11
value = 0

[State -2, Helper]
type = Helper
trigger1 = Var(11) = 1
persistent = 0
id = 8710
name = "Danger"
pos = 0,0
postype = P1
stateno = 8710
helpertype = normal
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime=-2**31-1
supermovetime=-2**31-1

[State -2, DisplayToClipboard]
type = DisplayToClipboard
trigger1 = 1
text = "SP = %d"
params = var(47)

[State -2, RemoveExplod]
type = RemoveExplod
trigger1 = NumExplod(201)
trigger1 = Stateno != 200
ID = 201

[State -2, RemoveExplod]
type = RemoveExplod
trigger1 = NumExplod(221)
trigger1 = Stateno != 220
ID = 221

[State -2, RemoveExplod]
type = RemoveExplod
trigger1 = NumExplod(411)
trigger1 = Stateno != 410
ID = 411

[State -2, RemoveExplod]
type = RemoveExplod
trigger1 = NumExplod(601)
trigger1 = Stateno != 600
ID = 601

[State -2, LifeAdd]
type = LifeAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "VAkiha_K"
trigger1 = Enemy,Var(30) = 1
value = -5
kill = 0

[State -2, PowerAdd]
type = PowerAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "VAkiha_K"
trigger1 = Enemy,Var(30) = 1
value = -26

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Senna_K"
triggerall = Enemy,StateNo = 810
triggerall = MoveType = H
trigger1 = Enemy,AnimElem = 6
v = 45
value = 4

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Homura_K"
triggerall = Enemy,StateNo = 4003
triggerall = MoveType = H
trigger1 = Enemy,time = 203
v = 45
value = 46

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Taiga_K"
triggerall = Enemy,StateNo = 4103
triggerall = MoveType = H
trigger1 = Enemy,time%8 = 0
v = 45
value = 4

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Taiga_K"
triggerall = Enemy,StateNo = 4004
triggerall = MoveType = H
trigger1 = Enemy,AnimElem = 3
trigger2 = Enemy,AnimElem = 8
trigger3 = Enemy,AnimElem = 12
trigger4 = Enemy,AnimElem = 16
trigger5 = Enemy,AnimElem = 20
trigger6 = Enemy,AnimElem = 24
trigger7 = Enemy,AnimElem = 28
trigger8 = Enemy,AnimElem = 32
trigger9 = Enemy,AnimElem = 36
trigger10 = Enemy,AnimElem = 40
v = 45
value = 4

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Taiga_K"
triggerall = Enemy,StateNo = 4005
triggerall = MoveType = H
trigger1 = Enemy,AnimElem = 4
v = 45
value = 4

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Rentaro_K"
triggerall = Enemy,StateNo = 4005
triggerall = MoveType = H
trigger1 = Enemy,Time = 16
v = 45
value = 46

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Miyuki_K"
triggerall = Enemy,StateNo = 4104
triggerall = MoveType = H
trigger1 = Enemy,Time >= 24
trigger1 = Enemy,Time%3 = 0
trigger1 = Enemy,Time < 75
v = 45
value = 4

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Miyuki_K"
triggerall = Enemy,StateNo = 4105
triggerall = MoveType = H
trigger1 = Enemy,Time = 12
trigger2 = Enemy,Time = 137
v = 45
value = 4

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Kirino_K"
triggerall = Enemy,StateNo = 951
triggerall = MoveType = H
trigger1 = Enemy,AnimElem = 13
v = 45
value = 4

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Kirino_K"
triggerall = Enemy,StateNo = 4005
triggerall = MoveType = H
trigger1 = Enemy,Time = 184
v = 45
value = 50

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Kuroyukihime_K"
triggerall = Enemy,StateNo = 4002
triggerall = MoveType = H
trigger1 = Enemy,Time = 20
v = 45
value = 50

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Selvaria_K"
triggerall = Enemy,StateNo = 810
triggerall = MoveType = H
trigger1 = Enemy,AnimElem = 2
trigger2 = Enemy,AnimElem = 9
v = 45
value = 4

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Selvaria_K"
triggerall = Enemy,StateNo = 1503 
triggerall = MoveType = H
trigger1 = Enemy,AnimElem = 5
v = 45
value = 4

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Selvaria_K"
triggerall = Enemy,StateNo = 2502 
triggerall = MoveType = H
trigger1 = Enemy,AnimElem = 5
v = 45
value = 4

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Selvaria_K"
triggerall = Enemy,StateNo = 4003
triggerall = MoveType = H
trigger1 = Enemy,Time%2 = 0
trigger1 = Enemy,Time > 45
trigger1 = Enemy,Time <= 77
v = 45
value = 4

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Emi_K"
triggerall = Enemy,StateNo = 810 
triggerall = MoveType = H
trigger1 = Enemy,AnimElem = 4
v = 45
value = 4

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Emi_K"
triggerall = Enemy,StateNo = 4004 
triggerall = MoveType = H
trigger1 = Enemy,Time = 95
v = 45
value = 50

[State -2, VarAdd]
type = VarAdd
triggerall = NumEnemy
triggerall = Enemy,AuthorName = "Kohaku" && Enemy,Name = "Emi_K"
triggerall = Enemy,StateNo = 4108 
triggerall = MoveType = H
trigger1 = Enemy,Time = 4
trigger2 = Enemy,Time = 9
trigger3 = Enemy,Time = 14
trigger4 = Enemy,Time = 19
trigger5 = Enemy,Time = 24
trigger6 = Enemy,Time = 29
trigger7 = Enemy,Time = 34
trigger8 = Enemy,Time = 39
trigger9 = Enemy,Time = 44
trigger10 = Enemy,Time = 49
trigger11 = Enemy,Time = 52
trigger12 = Enemy,Time = 55
trigger13 = Enemy,Time = 58
trigger14 = Enemy,Time = 61
trigger15 = Enemy,Time = 64
trigger16 = Enemy,Time = 67
trigger17 = Enemy,Time = 70
trigger18 = Enemy,Time = 73
trigger19 = Enemy,Time = 74
trigger20 = Enemy,Time = 75
trigger21 = Enemy,Time = 76
trigger21 = Enemy,Time = 77
trigger22 = Enemy,Time = 78
trigger23 = Enemy,Time = 79
trigger24 = Enemy,Time = 80
trigger25 = Enemy,Time = 81
trigger26 = Enemy,Time = 104
v = 45
value = 2

;---------------------------------------------------------------------------
; States that are executed when in self's state file (use statedef -3)
;---------------------------------------------------------------------------

[Statedef -3]

[State -3, VarSet]
type = VarSet
trigger1 = 1
var(20) = 0

[State -3, VarSet]
type = VarSet
trigger1 = statetype != A
trigger1 = ctrl
trigger2 = (stateno = [200,299]) || (stateno = [400,499])
trigger2 = movecontact
trigger3 = Statetype = A
trigger3 = (Stateno = [600,699])
trigger3 = MoveContact
var(20) = 1

[State -3, VarSet]
type = VarSet
trigger1 = 1
var(21) = 0

[State -3, VarSet]
type = VarSet
trigger1 = statetype != A
trigger1 = ctrl
trigger2 = (stateno = [1000,1999])
trigger2 = MoveContact
var(21) = 1

[State -3, VarSet]
type = VarSet
trigger1 = 1
var(22) = 0

[State -3, VarSet]
type = VarSet
trigger1 = statetype != A
trigger1 = ctrl
trigger2 = (stateno = [2000,3999])
trigger2 = stateno != [4000,4999]
trigger2 = MoveContact
var(22) = 1

[State -3, ChangeState]
type = ChangeState
trigger1 = !alive && (stateno = [5000,5010])
trigger1 = (prevstateno = [120,121]) || (prevstateno = [130,131]) || (prevstateno = [140,141]) || (prevstateno = [150,153])
value = 5950
ignorehitpause = 1

[State -3, AssertSpecial]
type = AssertSpecial
trigger1 = (stateno = [5000,5010])
trigger1 = (prevstateno = [120,121]) || (prevstateno = [130,131]) || (prevstateno = [140,141]) || (prevstateno = [150,153])
flag = nokosnd
ignorehitpause = 1

[State -3, Width]
type = Width
trigger1 = 1
edge = 4,0
ignorehitpause = 1

;This controller plays a sound everytime the player lands from a jump, or
;from a back-dash.
[State -3, Landing Sound]
type = PlaySnd
triggerall = Time = 1
trigger1 = stateno = 52 ;Jump land
trigger2 = stateno = 106 ;Run-back land
value = 40, 0
