
;---------------------------------------------------------------------------
;無想転生
[Statedef 10000]
type = S
movetype = A
physics = S
ctrl = 0
sprpriority = 1

[State 10000, -1]
type = Helper
triggerall = PrevStateno != 5
trigger1 = time = 0
helpertype = Player
name = "cutin"
ID = 9999
stateno = 9999
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 0]
type = ChangeAnim
trigger1 = time = 0
value = 10000

[State 10000, 1]
type = Pause
trigger1 = 1
time = 2
movetime = 2

[State 10000, 2]
type = Explod
trigger1 = time = 0
anim = 8200
ID = 8200
sprpriority = 0
postype = p1
pos = 0,Const(size.mid.pos.y)
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 3]
type = PlaySnd
trigger1 = time = 0
value = s5,2
channel = 7

[State 10000, 4]
type = PlaySnd
trigger1 = time = 0
value = s5,3
channel = 5

[State 10000, 5]
type = BGPalFX
trigger1 = NumExplod(8200) = 1
time = 2
add = 0,0,0
mul = 0,0,0
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 10000, 5]
type = BGPalFX
trigger1 = NumExplod(8200) = 0
time = 2
add = 0,0,150
mul = 256,256,256
sinadd = 0,0,150,1
invertall = 0
color = 256

[State 10000, 6]
type = AssertSpecial
trigger1 = 1
flag = timerfreeze
flag2 = noFG
flag3 = globalnoshadow

[State 10000, 6]
type = AssertSpecial
trigger1 = RoundState < 2
flag = Intro

[State 10000, 7]
type = VarSet
triggerall = Var(59) = 0 || Var(59) >= 2
trigger1 = time = 0
v = 52
value = 1

[State 10000, 8]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) = 0
helpertype = normal
name = "tensei"
ID = 10100
stateno = 10100
pos = 20,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 9]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) = 0
helpertype = normal
name = "tensei"
ID = 10100
stateno = 10100
pos = -20,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 10]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) = 0
helpertype = normal
name = "tensei"
ID = 10100
stateno = 10100
pos = 40,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 11]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) = 0
helpertype = normal
name = "tensei"
ID = 10100
stateno = 10100
pos = -40,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 12]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) = 0
helpertype = normal
name = "tensei"
ID = 10100
stateno = 10100
pos = 60,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 13]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) = 0
helpertype = normal
name = "tensei"
ID = 10100
stateno = 10100
pos = -60,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 14]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) = 0
helpertype = normal
name = "tensei"
ID = 10100
stateno = 10100
pos = 80,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 15]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) = 0
helpertype = normal
name = "tensei"
ID = 10100
stateno = 10100
pos = -80,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 16]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) = 0
helpertype = normal
name = "tensei"
ID = 10100
stateno = 10100
pos = 100,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 17]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) = 0
helpertype = normal
name = "tensei"
ID = 10100
stateno = 10100
pos = -100,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 18]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) = 0
helpertype = normal
name = "tensei"
ID = 10200
stateno = 10200
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 8]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) != 0
helpertype = Player
name = "tensei"
ID = 10100
stateno = 10100
pos = 20,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 9]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) != 0
helpertype = Player
name = "tensei"
ID = 10100
stateno = 10100
pos = -20,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 10]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) != 0
helpertype = Player
name = "tensei"
ID = 10100
stateno = 10100
pos = 40,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 11]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) != 0
helpertype = Player
name = "tensei"
ID = 10100
stateno = 10100
pos = -40,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 12]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) != 0
helpertype = Player
name = "tensei"
ID = 10100
stateno = 10100
pos = 60,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 13]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) != 0
helpertype = Player
name = "tensei"
ID = 10100
stateno = 10100
pos = -60,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 14]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) != 0
helpertype = Player
name = "tensei"
ID = 10100
stateno = 10100
pos = 80,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 15]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) != 0
helpertype = Player
name = "tensei"
ID = 10100
stateno = 10100
pos = -80,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 16]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) != 0
helpertype = Player
name = "tensei"
ID = 10100
stateno = 10100
pos = 100,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 17]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) != 0
helpertype = Player
name = "tensei"
ID = 10100
stateno = 10100
pos = -100,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.ground.back = 1
size.ground.front = 1
size.air.back = 1
size.air.front = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 18]
type = Helper
trigger1 = time = 42
trigger1 = Fvar(25) != 0
helpertype = Player
name = "tensei"
ID = 10200
stateno = 10200
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10000, 19]
type = PowerAdd
triggerall = PalNo <= 10
triggerall = RoundState >= 2
trigger1 = time = 0
value = -3000

[State 10000, 20]
type = VarSet
triggerall = RoundState >= 2
trigger1 = time = 0
v = 50
value = 0

[State 10000, 21]
type = VarSet
triggerall = RoundState >= 2
trigger1 = time = 0
v = 51
value = 0

[State 10000, 22]
type = PalFX
trigger1 = time >= 120
time = 2
add = 120,120,0
mul = 256,256,256
sinadd = 120,120,0,1
invertall = 0
color = 256

[State 10000, 23]
type = ChangeState
trigger1 = time >= 50
trigger1 = NumHelper(10100) = 0
value = 10050

;---------------------------------------------------------------------------
;無想転生
[Statedef 10050]
type = S
movetype = A
physics = S
ctrl = 0

[State 10050, 0]
type = ChangeAnim
trigger1 = time = 0
value = 900

[State 10050, 1]
type = Pause
trigger1 = 1
time = 2
movetime = 2

[State 10050, 2]
type = Explod
trigger1 = Animelem = 3
anim = 7700
ID = 7700
sprpriority = 0
postype = p1
pos = 0,Const(size.mid.pos.y)
ownpal = 1
scale = 2,2
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10050, 3]
type = BGPalFX
trigger1 = 1
time = 1
add = 0,0,150
mul = 256,256,256
sinadd = 0,0,150,1
invertall = 0
color = 256

[State 10050, 4]
type = EnvShake
trigger1 = 1
time = 3
freq = 100
ampl = -5
phase = 90
persistent = 3

[State 10050, 5]
type = PlaySnd
trigger1 = Animelem = 3
value = s4,0
channel = 5

[State 10050, 6]
type = VarSet
trigger1 = time = 0
v = 52
value = 1

[State 10050, 7]
type = PalFX
trigger1 = 1
time = 2
add = 120,120,0
mul = 256,256,256
sinadd = 120,120,0,1
invertall = 0
color = 256

[State 10050, 8]
type = ChangeState
triggerall = RoundState >= 2
trigger1 = Animtime = 0
value = 0
ctrl = 1

[State 10050, 9]
type = AssertSpecial
trigger1 = RoundState < 2
flag = Intro

[State 10050, 10]
type = ChangeState
triggerall = RoundState < 2
trigger1 = Animtime = 0
value = 5900

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

;---------------------------------------------------------------------------
;分身
[Statedef 10100]
type = S
movetype = A
physics = S
ctrl = 0
anim = 10100
sprpriority = 2

[State 10100, 0]
type = PalFX
trigger1 = 1
time = 1
add = 120,120,0
mul = 256,256,256
sinadd = 120,120,0,1
invertall = 0
color = 256

[State 10100, 1]
type = VelSet
trigger1 = ParentDist X > 0
x = ParentDist X*0.02

[State 10100, 2]
type = VelSet
trigger1 = ParentDist X < 0
x = ParentDist X*0.02

[State 10100, 3]
type = PosSet
triggerall = time > 20
trigger1 = Vel X < 0
trigger1 = ParentDist X >= 0
trigger2 = Vel X > 0
trigger2 = ParentDist X <= 0
x = Parent,Pos X

[State 10100, 4]
type = DestroySelf
trigger1 = time > 260
trigger1 = ParentDist X = 0

;---------------------------------------------------------------------------
;分身2
[Statedef 10200]
type = S
movetype = A
physics = S
ctrl = 0
anim = 10100
sprpriority = 2

[State 10200, 0]
type = PalFX
trigger1 = 1
time = 10
add = 170,0,0
mul = 256,256,256
sinadd = 170,0,0,8
invertall = 0
color = 256
persistent = 10

[State 10200, 1]
type = VelSet
trigger1 = 1
x = 0
y = 0

[State 10200, 2]
type = Explod
trigger1 = Parent,Stateno = 10050
trigger1 = Parent,time = 10
anim = 10200
ID = 10200
sprpriority = 0
postype = p1
pos = 0,0
scale = 1.0*Fvar(1),1.0*Fvar(1)
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999
persistent = 0

[State 10200, 3]
type = ModifyExplod
trigger1 = NumExplod(10200) = 1
ID = 10200
scale = 1.0*Fvar(0),1.0*Fvar(0)

[State 10200, 4]
type = VarSet
trigger1 = time = 0
fv = 0
value = 1

[State 10200, 5]
type = VarAdd
trigger1 = Parent,Stateno = 10050
trigger1 = Parent,time >= 10
fvar(0) = 0.2

[State 10200, 6]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = timerfreeze
flag3 = invisible

[State 10200, 7]
type = DestroySelf
trigger1 = Parent,Stateno != [10000,10050]

;---------------------------------------------------------------------------
;北斗有情断迅拳
[Statedef 10500]
type = S
movetype = A
physics = N
ctrl = 0

[State -1]
type = VarAdd
trigger1 = 1
var(21) = 1

[State -1]
type = VarSet
triggerall = PrevStateno != 5
trigger1 = time = 0
var(21) = 0

[State 10500, -1]
type = Helper
triggerall = PrevStateno != 5
trigger1 = time = 0
helpertype = Player
name = "cutin"
ID = 9999
stateno = 9999
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10500, 0]
type = ChangeAnim
triggerall = PrevStateno != 5
trigger1 = time = 0
value = 10500

[State 10500, 0]
type = Helper
trigger1 = NumHelper(10790) = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "effect"
ID = 10790
stateno = 10790
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10500, 0]
type = Helper
trigger1 = NumHelper(10790) = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "effect"
ID = 10790
stateno = 10790
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10500, 1]
type = VelSet
triggerall = PrevStateno != 5
trigger1 = time = 0
x = 6

[State 10500, 2]
type = PowerAdd
triggerall = PrevStateno != 5
triggerall = !IsHelper
triggerall = PalNo <= 10
trigger1 = time = 0
value = -3000

[State 10500, 3]
type = Pause
triggerall = PrevStateno != 5
triggerall = !IsHelper
trigger1 = time = 0
time = 30
movetime = 1

[State 10500, 4]
type = Explod
triggerall = PrevStateno != 5
trigger1 = time = 0
anim = 8200
ID = 8200
sprpriority = 0
postype = p1
pos = 0,Const(size.mid.pos.y)
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10500, 5]
type = Explod
trigger1 = Animelem = 2
anim = 7000
ID = 7000
sprpriority = 0
postype = p1
pos = 0,0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999
persistent = 0

[State 10500, 6]
type = PlaySnd
triggerall = PrevStateno != 5
trigger1 = time = 0
value = s5,2
channel = 7

[State 10500, 7]
type = PlaySnd
triggerall = PrevStateno != 5
trigger1 = time = 0
value = s5,3
channel = 5

[State 10500, 8]
type = BGPalFX
triggerall = PrevStateno != 5
trigger1 = time = 0
time = 42
add = 0,0,0
mul = 128,128,128
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 10500, 9]
type = BGPalFX
trigger1 = NumExplod(8200) = 0
time = 2
add = 0,0,0
mul = 256,256,256
sinadd = 0,0,0,1
invertall = 1
color = 256

[State 10500, 10]
type = Hitdef
triggerall = !IsHelper
triggerall = Fvar(37) = 0
triggerall = Fvar(25) = 0
trigger1 = 1
attr = S,HA
damage = 0,0
animtype = Medium
hitflag = MAFD
priority = 3,Miss
pausetime = 0,3
sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 10
ground.hittime = 10
ground.velocity = 0,0
air.velocity = 0,0
p2facing = 1
p2stateno = 10800

[State 10500, 11]
type = PlaySnd
trigger1 = MoveGuarded
value = s3,2
channel = 4
persistent = 0

[State 10500, 12]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = noFG
flag3 = timerfreeze

[State 10500, 13]
type = ChangeState
trigger1 = MoveHit
value = 10600

[State 10500, 14]
type = ChangeState
trigger1 = Var(21) >= 60
value = 0
ctrl = 1

[State -1, NotHitBy]
type = NotHitBy
trigger1 = Var(21) < 8
value = SCA
time = 2

;---------------------------------------------------------------------------
;北斗有情断迅拳(成功)
[Statedef 10600]
type = S
movetype = A
physics = N
ctrl = 0

[State 10600, 0]
type = VelAdd
triggerall = Vel X > 0
trigger1 = P2BodyDist X <= -50
x = -0.3

[State 10600, 1]
type = ChangeAnim
trigger1 = 1
value = 10600

[State 10600, 2]
type = Explod
trigger1 = Anim = 10600
trigger1 = Animelem = 1
anim = 7000
ID = 7000
sprpriority = 0
postype = p1
pos = 0,0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999
persistent = 0

[State 10600, 3]
type = VelSet
trigger1 = Vel X <= 0
trigger2 = FrontEdgeBodyDist <= 0
x = 0

[State 10600, 4]
type = BGPalFX
trigger1 = 1
time = 61
add = 0,0,0
mul = 256,256,256
sinadd = 0,0,0,1
invertall = 1
color = 256

[State 10600, 5]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = noFG
flag3 = timerfreeze

[State 10600, 6]
type = TargetState
trigger1 = NumTarget > 0
value = 10800+(Fvar(20)!=0)

[State 10600, 7]
type = ChangeState
trigger1 = Vel X = 0
trigger2 = time >= 300
value = 10650

;---------------------------------------------------------------------------
;北斗有情断迅拳(追撃発生)
[Statedef 10650]
type = S
movetype = A
physics = S
ctrl = 0

[State 10650, 0]
type = Pause
trigger1 = time = 0
time = 60
movetime = 0

[State 10650, 1]
type = Helper
trigger1 = time != 0
trigger1 = time <= 60
trigger1 = Fvar(25) = 0
helpertype = normal
name = "ujyou"
ID = 10750
stateno = 10750
pos = enemy,Const(size.mid.pos.x),enemy,Const(size.mid.pos.y)
postype = p2
facing = -1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999
persistent = 3

[State 10650, 1]
type = Helper
trigger1 = time = 80
trigger1 = Fvar(25) = 0
helpertype = normal
name = "ujyou"
ID = 10780
stateno = 10780
pos = enemy,Const(size.mid.pos.x),enemy,Const(size.mid.pos.y)
postype = p2
facing = -1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10650, 1]
type = Helper
trigger1 = time != 0
trigger1 = time <= 60
trigger1 = Fvar(25) != 0
helpertype = Player
name = "ujyou"
ID = 10750
stateno = 10750
pos = enemy,Const(size.mid.pos.x),enemy,Const(size.mid.pos.y)
postype = p2
facing = -1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999
persistent = 3

[State 10650, 1]
type = Helper
trigger1 = time = 80
trigger1 = Fvar(25) != 0
helpertype = Player
name = "ujyou"
ID = 10780
stateno = 10780
pos = enemy,Const(size.mid.pos.x),enemy,Const(size.mid.pos.y)
postype = p2
facing = -1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10650, 2]
type = VelSet
trigger1 = 1
x = 0
y = 0

[State 10650, 3]
type = TargetLifeAdd
trigger1 = time != 0
trigger1 = time <= 60
value = -1*ifelse(ceil(20*Fvar(0))<=6,6,ceil(20*Fvar(0)))
absolute = 1
kill = 0
persistent = 3

[State 10650, 3]
type = TargetLifeAdd
trigger1 = time = 80
value = -1*ifelse(ceil(84*Fvar(0))<=25,25,ceil(84*Fvar(0)))
absolute = 1
kill = 1

[State 10650, 4]
type = TargetState
trigger1 = NumTarget > 0
trigger1 = time = 0
value = 10820+(Fvar(20)!=0)

[State 10650, 4]
type = TargetState
trigger1 = NumTarget > 0
trigger1 = time = 80
value = 10850+(Fvar(20)!=0)

[State 10650, 5]
type = VarSet
trigger1 = time != 0
trigger1 = time <= 60
fv = 0
value = Fvar(0)-(Fvar(0)*0.04)
persistent = 3

[State 10650, 5]
type = VarSet
trigger1 = time = 80
fv = 0
value = Fvar(0)-(Fvar(0)*0.12)

[State 10650, 7]
type = ChangeAnim
trigger1 = Anim = 10600
trigger1 = time >= 100
value = 10700

[State 10650, 8]
type = ChangeState
trigger1 = Anim = 10700
trigger1 = Animtime = 0
value = 0
ctrl = 1

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

;---------------------------------------------------------------------------
;追撃ヘルパー
[Statedef 10750]
type = A
movetype = A
physics = N
ctrl = 0
anim = 10750
sprpriority = 6

[State 10750, -1]
type = VarRandom
trigger1 = 1
v = 1
range = -40,40

[State 10750, -1]
type = VarRandom
trigger1 = 1
v = 2
range = -40,40

[State 10750, -1]
type = PosAdd
trigger1 = time = 0
x = Var(1)
y = Var(2)

[State 10750, 0]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10750, 1]
type = VelSet
trigger1 = 1
x = 0
y = 0

[State 10750, 2]
type = ParentVarSet
trigger1 = time = 0
var(16) = 1
ignorehitpause = 1

[State 10750, 3]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = noFG
flag3 = timerfreeze

[State 10750, 4]
type = DestroySelf
trigger1 = Animtime = 0

;---------------------------------------------------------------------------
;追撃ヘルパー(とどめ)
[Statedef 10780]
type = A
movetype = A
physics = N
ctrl = 0
anim = 10780
sprpriority = 6

[State 10780, 0]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10780, 1]
type = VelSet
trigger1 = 1
x = 0
y = 0

[State 10780, 2]
type = ParentVarSet
trigger1 = time = 0
var(16) = 100
ignorehitpause = 1

[State 10780, 3]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = noFG
flag3 = timerfreeze

[State 10780, 4]
type = DestroySelf
trigger1 = Animtime = 0

;---------------------------------------------------------------------------
;前景消去用ヘルパー
[Statedef 10790]
type = A
physics = N
anim = 999

[State 10790, 0]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = noFG
flag3 = timerfreeze
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 10790, 1]
type = DestroySelf
trigger1 = Root,Stateno != [10500,10700]

;---------------------------------------------------------------------------
;喰らった相手
[Statedef 10800]
type = A
movetype = H
physics = N
ctrl = 0
sprpriority = -2

[State 10800, 0]
type = ChangeAnim2
trigger1 = 1
value = 10800

[State 10800, 1]
type = VelSet
trigger1 = 1
x = 0
y = 0

[State 10800, 2]
type = PosSet
trigger1 = 1
y = 0

[State 10800, 3]
type = SelfState
trigger1 = time > 300
trigger1 = enemy,Stateno != [10600,10650]
value = 5100

;---------------------------------------------------------------------------
;喰らった相手
[Statedef 10801]
type = A
movetype = H
physics = N
ctrl = 0
sprpriority = -2

[State 10801, 0]
type = ChangeAnim2
trigger1 = 1
value = 10800

[State 10801, 1]
type = VelSet
trigger1 = 1
x = 0
y = 0

[State 10801, 2]
type = PosSet
trigger1 = 1
y = 0

[State 10801, 3]
type = SelfState
trigger1 = time > 300
trigger1 = enemy,Stateno != [10600,10650]
value = 5100

;---------------------------------------------------------------------------
;喰らった相手2
[Statedef 10820]
type = A
movetype = H
physics = N
ctrl = 0
sprpriority = -2

[State 10820, 0]
type = ChangeAnim2
trigger1 = 1
value = 10800

[State 10820, 1]
type = VelSet
trigger1 = 1
x = 0
y = 0

[State 10820, 2]
type = PosSet
trigger1 = 1
y = 0

[State 10820, 3]
type = PosAdd
trigger1 = time > 0
x = ifelse(Gametime%2=0,2,-2)

[State 10820, 4]
type = SelfState
trigger1 = time > 300
trigger1 = enemy,Stateno != [10600,10650]
value = 5100

;---------------------------------------------------------------------------
;喰らった相手2
[Statedef 10821]
type = A
movetype = H
physics = N
ctrl = 0
sprpriority = -2

[State 10821, -1]
type = LifeAdd
trigger1 = time > 0 && time < 60
trigger1 = time % 3 = 0
value = ceil(-.0153*((100-(10+((time/4+2)/3.5)*2))/100)*LifeMax)
kill = 0
absolute = 1

[State 10821, 0]
type = ChangeAnim2
trigger1 = 1
value = 10800

[State 10821, 1]
type = VelSet
trigger1 = 1
x = 0
y = 0

[State 10821, 2]
type = PosSet
trigger1 = 1
y = 0

[State 10821, 3]
type = PosAdd
trigger1 = time > 0
x = ifelse(Gametime%2=0,2,-2)

[State 10821, 4]
type = SelfState
trigger1 = time > 300
trigger1 = enemy,Stateno != [10600,10650]
value = 5100

;---------------------------------------------------------------------------
;喰らった相手3
[Statedef 10850]
type = A
movetype = H
physics = N
ctrl = 0

[State 10850, 0]
type = ChangeAnim2
trigger1 = time = 0
value = 10800

[State 10850, 1]
type = VelSet
trigger1 = time = 0
x = 0
y = -16.21*Const(movement.yaccel)

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

[State 10850, 3]
type = PosSet
trigger1 = time > 10
trigger1 = Pos Y >= 0
y = 0

[State 10850, 4]
type = LifeSet
trigger1 = Life <= 10
value = 0

[State 10850, 5]
type = SelfState
trigger1 = time > 30
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
value = 5100

;---------------------------------------------------------------------------
;喰らった相手3
[Statedef 10851]
type = A
movetype = H
physics = N
ctrl = 0

[State 10851, -1]
type = LifeAdd
trigger1 = time = 0
value = ceil(-0.204*LifeMax)
kill = 1
absolute = 1

[State 10851, -1]
type = PlaySnd
trigger1 = IsHelper
value = S11,0
freqmul = 1+(Random%5-2)*0.1

[State 10851, -1]
type = DestroySelf
trigger1 = IsHelper

[State 10851, 0]
type = ChangeAnim2
trigger1 = time = 0
value = 10800

[State 10851, 1]
type = VelSet
trigger1 = time = 0
x = 0
y = -16.21*Const(movement.yaccel)

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

[State 10851, 3]
type = PosSet
trigger1 = time > 10
trigger1 = Pos Y >= 0
y = 0

[State 10851, 4]
type = LifeSet
trigger1 = Life <= 10
value = 0

[State 10851, 5]
type = SelfState
trigger1 = time > 30
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
value = 5100

;---------------------------------------------------------------------------
;断固相殺拳
[Statedef 11000]
type = A
movetype = A
physics = N
ctrl = 0

[State 11000, -1]
type = VarSet
triggerall = PrevStateno != 5
trigger1 = time = 0
var(20) = 11100
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 11000, 0]
type = ChangeAnim
triggerall = PrevStateno != 11050
triggerall = PrevStateno != 5
trigger1 = time = 0
value = 11000

[State 11000, 1]
type = HitOverRide
trigger1 = Alive
trigger1 = Var(41) = 0 && Var(24) = 0
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
time = 2
stateno = 11050
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 11000, 2]
type = VelSet
triggerall = PrevStateno != 11050
triggerall = PrevStateno != 5
trigger1 = time = 0
x = 3
y = -8

[State 11000, 3]
type = VelAdd
trigger1 = 1
y = Const(Movement.yaccel)/2

[State 11000, 4]
type = VarSet
triggerall = PrevStateno != 11050
triggerall = PrevStateno != 5
trigger1 = time = 0
var(49) = 0

[State 11000, 5]
type = VarAdd
trigger1 = 1
var(49) = ifelse(Var(19)>=2,2,1)

[State 11000, 5]
type = VarSet
trigger1 = Var(49) > 60
trigger1 = Var(19) = 1
var(49) = 60

[State 11000, 6]
type = ChangeState
triggerall = Var(59) = 0
triggerall = command != "holdz"
trigger1 = Animelemtime(7) >= 0
value = 11100

[State 11000, 6]
type = ChangeState
triggerall = Var(59) != 0
triggerall = Animelemtime(7) >= 0
trigger1 = (Var(57) = [100,149]) && Var(59) != 24
trigger2 = Pos Y >= -20 && Var(59) = 24
trigger3 = Vel Y > 1 && NumHelper(11200) = 0 && NumHelper(11300) = 0 && Var(59) = 24
value = 11100

[State 11000, 7]
type = ChangeState
trigger1 = Pos Y > 0
trigger1 = Vel Y > 0
value = 52

;---------------------------------------------------------------------------
;スーパーアーマー
[Statedef 11050]
type = A
movetype = H
physics = N
ctrl = 0

[State 11050, 0]
type = HitOverRide
trigger1 = Alive
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
time = 2
stateno = 11050
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 11050, 1]
type = LifeAdd
trigger1 = time = 0
value = -GetHitVar(Damage)

[State 11050, 2]
type = PalFX
trigger1 = time = 0
time = 1
add = 200,0,0
mul = 256,256,256
sinadd = 200,0,0,1
invertall = 0
color = 256

[State 11050, 3]
type = VarAdd
trigger1 = 1
var(49) = ifelse(Var(19)>=2,2,1)

[State 11050, 3]
type = VarSet
trigger1 = Var(49) > 60
trigger1 = Var(19) = 1
var(49) = 60

[State 11050, 4]
type = ChangeState
triggerall = Var(59) = 0
triggerall = command != "holdz"
trigger1 = Animelemtime(7) >= 0
value = 11100

[State 11050, 4]
type = ChangeState
triggerall = Var(59) != 0
triggerall = Animelemtime(7) >= 0
trigger1 = (Var(57) = [100,149]) && Var(59) != 24
trigger2 = Pos Y >= -20 && Var(59) = 24
trigger3 = Vel Y > 1 && NumHelper(11200) = 0 && NumHelper(11300) = 0 && Var(59) = 24
value = 11100

[State 11050, 5]
type = ChangeState
trigger1 = Pos Y > 0
trigger1 = Vel Y > 0
value = 52

[State 11050, 6]
type = ChangeState
trigger1 = time = 0
value = 11000

;---------------------------------------------------------------------------
;断固相殺拳発動
[Statedef 11100]
type = A
movetype = A
physics = N
ctrl = 0

[State 11100, -1]
type = Helper
triggerall = PrevStateno != 5
trigger1 = time = 0
helpertype = Player
name = "cutin"
ID = 9999
stateno = 9999
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 11100, 0]
type = ChangeAnim
triggerall = PrevStateno != 5
trigger1 = time = 0
value = 11100

[State 11100, 1]
type = PowerAdd
triggerall = !IsHelper
triggerall = PrevStateno != 5
triggerall = PalNo <= 10
trigger1 = time = 0
value = -2000

[State 11100, 2]
type = PlaySnd
triggerall = PrevStateno != 5
trigger1 = time = 0
value = s5,1
channel = 7

[State 11100, 3]
type = Explod
triggerall = PrevStateno != 5
trigger1 = time = 0
anim = 8100
ID = 8100
sprpriority = 4
postype = p1
pos = 0,Const(size.mid.pos.y)
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 11100, 4]
type = Pause
triggerall = !IsHelper
triggerall = PrevStateno != 5
trigger1 = time = 0
time = 20
movetime = 1

[State 11100, 5]
type = BGPalFX
triggerall = PrevStateno != 5
trigger1 = time = 0
time = 20
add = 0,0,0
mul = 128,128,128
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 11100, 6]
type = VelSet
trigger1 = Animelem = 3
x = -2
y = -6

[State 11100, 7]
type = VelAdd
trigger1 = 1
y = Const(Movement.yaccel)

[State 11100, 8]
type = Helper
trigger1 = Animelem = 3
trigger1 = Fvar(25) = 0
helpertype = normal
name = "arrow"
ID = 11200
stateno = 11200
pos = -20+Random%40,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1

[State 11100, 8]
type = Helper
trigger1 = Animelem = 3
trigger1 = Fvar(25) = 0
helpertype = normal
name = "arrow"
ID = 11200
stateno = 11200
pos = -20+Random%40,0
postype = p1
facing = -1
keyctrl = 0
ownpal = 1
ignorehitpause = 1

[State 11100, 9]
type = Helper
trigger1 = Animelem = 3
trigger1 = Fvar(25) = 0
helpertype = normal
name = "arrow"
ID = 11300
stateno = 11300
pos = -20+Random%40,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1

[State 11100, 9]
type = Helper
trigger1 = Animelem = 3
trigger1 = Fvar(25) = 0
helpertype = normal
name = "arrow"
ID = 11300
stateno = 11300
pos = -20+Random%40,0
postype = p1
facing = -1
keyctrl = 0
ownpal = 1
ignorehitpause = 1

[State 11100, 8]
type = Helper
trigger1 = Animelem = 3
trigger1 = Fvar(25) != 0
helpertype = Player
name = "arrow"
ID = 11200
stateno = 11200
pos = -20+Random%40,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1

[State 11100, 8]
type = Helper
trigger1 = Animelem = 3
trigger1 = Fvar(25) != 0
helpertype = Player
name = "arrow"
ID = 11200
stateno = 11200
pos = -20+Random%40,0
postype = p1
facing = -1
keyctrl = 0
ownpal = 1
ignorehitpause = 1

[State 11100, 9]
type = Helper
trigger1 = Animelem = 3
trigger1 = Fvar(25) != 0
helpertype = Player
name = "arrow"
ID = 11300
stateno = 11300
pos = -20+Random%40,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1

[State 11100, 9]
type = Helper
trigger1 = Animelem = 3
trigger1 = Fvar(25) != 0
helpertype = Player
name = "arrow"
ID = 11300
stateno = 11300
pos = -20+Random%40,0
postype = p1
facing = -1
keyctrl = 0
ownpal = 1
ignorehitpause = 1

[State 11100, 10]
type = ChangeState
triggerall = Pos Y >= 0
triggerall = Vel Y >= 0
trigger1 = Animelemtime(4) >= 0
value = 52

[State 11100, 11]
type = ChangeState
triggerall = Var(59) = 0
triggerall = Var(50) >= 1000 || Var(51) = 1
triggerall = command = "IC"
trigger1 = Animelemtime(4) >= 0
value = 950

[State 11100, 12]
type = ChangeState
triggerall = Var(59) != 0
triggerall = Var(50) >= 1000 || Var(51) = 1
triggerall = (Var(57) = [0,39]) || (Var(57) % 2 = 0 && Var(59) = 24)
trigger1 = Animelemtime(4) >= 0
value = 950

;---------------------------------------------------------------------------
;羽下降ステート
[Statedef 11200]
type = A
movetype = A
physics = N
anim = 1940
ctrl = 0

[State 11200, -1]
type = ChangeState
trigger1 = !IsHelper
value = 53
ctrl = 1

[State 11200, 0]
type = VarSet
trigger1 = time = 0
trigger1 = Var(1) = 0
var(1) = ceil(Parent,Var(49)/3)

[State 11200, 1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 11200, 2]
type = VelSet
trigger1 = 1
x = 6
y = 12

[State 11200, 3]
type = Hitdef
trigger1 = IsHelper
trigger1 = Root,Fvar(25) = 0
attr = A,HP
damage = ifelse(ceil(Var(1)*Parent,Fvar(0))>=40,40,ceil(Var(1)*Parent,Fvar(0))),ceil(Var(1)/5)
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,3
guard.pausetime = 0,3
sparkno = s6600
guard.sparkno = s7100
sparkxy = -30,Const(size.mid.pos.y)
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 0
persistent = 3

[State 11200, 3]
type = Projectile
trigger1 = IsHelper
trigger1 = Root,Fvar(25) != 0
projanim = 1941
projhitanim = -1
projremovetime = 1
projremove = 1
projid = 11201
offset = 0,0
velocity = 0,0
accel = 0,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = A,HP
damage = ifelse(ceil(Var(1)*Parent,Fvar(0))>=40,40,ceil(Var(1)*Parent,Fvar(0))),ceil(Var(1)/5)
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,3
guard.pausetime = 0,3
sparkno = s6600
guard.sparkno = s7100
sparkxy = 0,Const(size.mid.pos.y)
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 0

[State 11200, 4]
type = ParentVarSet
trigger1 = MoveHit
trigger2 = IsHelper
trigger2 = Root,ProjHitTime(11201) = 1
fv = 0
value = Parent,Fvar(0)-(Parent,Fvar(0)*0.1)

[State 11200, 5]
type = ParentVarSet
triggerall = Parent,Var(19) <= 0
trigger1 = MoveGuarded
trigger2 = IsHelper
trigger2 = Root,ProjHitTime(11201) = 1
fv = 0
value = Parent,Fvar(0)+(Parent,Fvar(0)*0.008)

[State 11200, 5]
type = ParentVarSet
triggerall = Parent,Var(19) >= 2
trigger1 = MoveGuarded
trigger2 = IsHelper
trigger2 = Root,ProjHitTime(11201) = 1
fv = 0
value = Parent,Fvar(0)+(Parent,Fvar(0)*0.016)

[State 11200, 6]
type = ParentVarSet
trigger1 = MoveHit
trigger2 = IsHelper
trigger2 = Root,ProjHitTime(11201) = 1
var(16) = 1
ignorehitpause = 1

[State 11200, 7]
type = ParentVarSet
trigger1 = MoveGuarded
trigger2 = IsHelper
trigger2 = Root,ProjGuardedTime(11201) = 1
var(16) = 10000
ignorehitpause = 1

[State 11200, 8]
type = VarSet
trigger1 = time = 0
trigger1 = var(2) = 0
var(2) = 1+ceil(Parent,Var(49)/5)

[State 11200, 9]
type = Turn
trigger1 = FrontEdgeBodyDist <= 0

[State 11200, 10]
type = VarAdd
trigger1 = FrontEdgeBodyDist <= 0
trigger2 = PrevStateno = 11300
trigger2 = time = 0
var(2) = -1

[State 11200, 11]
type = MoveHitReset
trigger1 = MoveContact

[State 11200, 12]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[State 11200, 13]
type = ChangeState
trigger1 = Pos Y >= 0
trigger1 = Var(2) > 1
trigger1 = RoundState = 2
value = 11300

[State 11200, 14]
type = DestroySelf
trigger1 = Pos Y >= 100

;---------------------------------------------------------------------------
;羽上昇ステート
[Statedef 11300]
type = A
movetype = A
physics = N
anim = 1900
ctrl = 0

[State 11300, -1]
type = ChangeState
trigger1 = !IsHelper
value = 53
ctrl = 1

[State 11300, 0]
type = VarSet
trigger1 = time = 0
trigger1 = Var(1) = 0
var(1) = ceil(Parent,Var(49)/3)

[State 11300, 1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 11300, 2]
type = VelSet
trigger1 = 1
x = 6
y = -12

[State 11300, 3]
type = Hitdef
trigger1 = IsHelper
trigger1 = Root,Fvar(25) = 0
attr = A,HP
damage = ifelse(ceil(Var(1)*Parent,Fvar(0))>=40,40,ceil(Var(1)*Parent,Fvar(0))),ceil(Var(1)/5)
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,3
guard.pausetime = 0,3
sparkno = s6600
guard.sparkno = s7100
sparkxy = -30,Const(size.mid.pos.y)
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 0
persistent = 3

[State 11300, 3]
type = Projectile
trigger1 = IsHelper
trigger1 = Root,Fvar(25) != 0
projanim = 1901
projhitanim = -1
projremovetime = 1
projremove = 1
projid = 11301
offset = 0,0
velocity = 0,0
accel = 0,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = A,HP
damage = ifelse(ceil(Var(1)*Parent,Fvar(0))>=40,40,ceil(Var(1)*Parent,Fvar(0))),ceil(Var(1)/5)
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,3
guard.pausetime = 0,3
sparkno = s6600
guard.sparkno = s7100
sparkxy = 0,Const(size.mid.pos.y)
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 0

[State 11300, 4]
type = ParentVarSet
trigger1 = MoveHit
trigger2 = IsHelper
trigger2 = Root,ProjHitTime(11301) = 1
fv = 0
value = Parent,Fvar(0)-(Parent,Fvar(0)*0.1)

[State 11300, 5]
type = ParentVarSet
triggerall = Parent,Var(19) <= 0
trigger1 = MoveGuarded
trigger2 = IsHelper
trigger2 = Root,ProjGuardedTime(11301) = 1
fv = 0
value = Parent,Fvar(0)+(Parent,Fvar(0)*0.008)

[State 11300, 5]
type = ParentVarSet
triggerall = Parent,Var(19) >= 2
trigger1 = MoveGuarded
trigger2 = IsHelper
trigger2 = Root,ProjGuardedTime(11301) = 1
fv = 0
value = Parent,Fvar(0)+(Parent,Fvar(0)*0.016)

[State 11300, 6]
type = ParentVarSet
trigger1 = MoveHit
trigger2 = IsHelper
trigger2 = Root,ProjHitTime(11301) = 1
var(16) = 1
ignorehitpause = 1

[State 11300, 7]
type = ParentVarSet
trigger1 = MoveGuarded
trigger2 = IsHelper
trigger2 = Root,ProjGuardedTime(11301) = 1
var(16) = 10000
ignorehitpause = 1

[State 11300, 8]
type = VarSet
trigger1 = time = 0
trigger1 = var(2) = 0
var(2) = 1+ceil(Parent,Var(49)/5)

[State 11300, 9]
type = Turn
trigger1 = FrontEdgeBodyDist <= 0

[State 11300, 10]
type = VarAdd
trigger1 = FrontEdgeBodyDist <= 0
trigger2 = PrevStateno = 11200
trigger2 = time = 0
var(2) = -1

[State 11300, 11]
type = MoveHitReset
trigger1 = MoveContact

[State 11300, 12]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[State 11300, 13]
type = ChangeState
trigger1 = ScreenPos Y <= 0
trigger1 = Var(2) > 1
trigger1 = RoundState = 2
value = 11200

[State 11300, 14]
type = DestroySelf
trigger1 = ScreenPos Y <= -100

;---------------------------------------------------------------------------
;まだまだ読みが甘いよ
[Statedef 11500]
type = S
movetype = A
physics = N
ctrl = 0

[State 11500, -1]
type = Helper
trigger1 = Animelem = 3
helpertype = Player
name = "cutin"
ID = 9999
stateno = 9999
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 11500, 0]
type = ChangeAnim
triggerall = PrevStateno != 5
trigger1 = time = 0
value = 11500

[State 11500, 1]
type = PosSet
triggerall = PrevStateno != 5
trigger1 = time = 0
y = 0

[State 11500, 2]
type = VelSet
triggerall = PrevStateno != 5
trigger1 = time = 0
x = 0
y = 0

[State 11500, 3]
type = PowerAdd
triggerall = !IsHelper
triggerall = PalNo <= 10
trigger1 = Animelem = 3
value = -2000

[State 11500, 4]
type = Pause
triggerall = !IsHelper
trigger1 = Animelem = 3
time = 50
movetime = 50

[State 11500, 5]
type = BGPalFX
trigger1 = Animelem = 3
time = 51
add = 0,0,0
mul = 0,0,0
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 11500, 6]
type = Explod
trigger1 = Animelem = 3
anim = 8100
ID = 8100
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 11500, 7]
type = PlaySnd
trigger1 = Animelem = 3
value = S5,1
channel = 7

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) = 0
helpertype = normal
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) = 0
helpertype = normal
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) = 0
helpertype = normal
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) = 0
helpertype = normal
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) = 0
helpertype = normal
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) = 0
helpertype = normal
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) = 0
helpertype = normal
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) = 0
helpertype = normal
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) = 0
helpertype = normal
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) = 0
helpertype = normal
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) != 0
helpertype = Player
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) != 0
helpertype = Player
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) != 0
helpertype = Player
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) != 0
helpertype = Player
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) != 0
helpertype = Player
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) != 0
helpertype = Player
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) != 0
helpertype = Player
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) != 0
helpertype = Player
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) != 0
helpertype = Player
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 8]
type = Helper
trigger1 = Animelem = 4
trigger1 = Fvar(25) != 0
helpertype = Player
name = "taiyaki"
ID = 11600
stateno = 11600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 11500, 9]
type = PlaySnd
trigger1 = Animelem = 3
value = S17,Var(14)%2
channel = 8

[State 11500, 10]
type = ChangeState
trigger1 = Animtime = 0
value = 0
ctrl = 1

[State 11500, 11]
type = ChangeState
triggerall = Var(59) = 0
trigger1 = command = "IC"
trigger1 = Var(50) >= 1000 || Var(51) = 1
trigger1 = Animelemtime(4) >= 0
value = 900

[State 11500, 12]
type = ChangeState
triggerall = Var(59) != 0
trigger1 = (Var(57) = [0,39]) || (Var(57) % 2 = 0 && Var(59) = 24)
trigger1 = Var(50) >= 1000 || Var(51) = 1
trigger1 = Animelemtime(4) >= 0
value = 900

;---------------------------------------------------------------------------
;たいやき
[Statedef 11600]
type = A
movetype = A
physics = N
ctrl = 0

[State 11600, -1]
type = ChangeState
trigger1 = !IsHelper
value = 53
ctrl = 1

[State 11600, -1]
type = ChangeAnim
trigger1 = Anim != 11600
trigger2 = Vel X = 0
value = 11600

[State 11600, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 11700-((Root,Fvar(20)!=0)*100)
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 11600, 0]
type = VarRandom
trigger1 = Var(0) = 0
v = 0
range = 5,12

[State 11600, 0]
type = VarRandom
trigger1 = Var(1) = 0
v = 1
range = -15,-10

[State 11600, 1]
type = VelSet
trigger1 = Vel X = 0
x = var(0)
y = var(1)

[State 11600, 2]
type = Hitdef
trigger1 = IsHelper
trigger1 = Root,Fvar(25) = 0
attr = S,HP
damage = ceil(11*Parent,Fvar(0)),2
animtype = Hard
hitflag = MAFD
guardflag = M
priority = 3,Miss
pausetime = 3,6
guard.pausetime = 3,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -5.3,-4.4
guard.velocity = -7.6
air.velocity = -5.3,-3.8
airguard.velocity = -7.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 0
givepower = Var(4),Var(5)
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 220,0,0
palfx.sinadd = 50,50,50,10

[State 11600, 2]
type = Projectile
trigger1 = IsHelper
trigger1 = Root,Fvar(25) != 0
projanim = 11601
projhitanim = -1
projremovetime = 1
projremove = 1
projid = 11601
offset = 0,0
velocity = 0,0
accel = 0,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = S,HP
damage = ceil(11*Parent,Fvar(0)),2
animtype = Hard
hitflag = MAFD
guardflag = M
priority = 3,Miss
pausetime = 3,6
guard.pausetime = 3,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -5.3,-4.4
guard.velocity = -7.6
air.velocity = -5.3,-3.8
airguard.velocity = -7.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 0
givepower = Var(4),Var(5)
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 220,0,0
palfx.sinadd = 50,50,50,10

[State 11600, 6]
type = ParentVarSet
trigger1 = MoveHit
;trigger2 = IsHelper
;trigger2 = Root,ProjHitTime(11601) = 1
fv = 0
value = Parent,Fvar(0)-(Parent,Fvar(0)*0.07)
ignorehitpause = 1

[State 11600, 7]
type = ParentVarSet
trigger1 = MoveContact
trigger2 = IsHelper
trigger2 = Root,ProjContactTime(11601) = 1
v = 34
value = 1
ignorehitpause = 1

[State 11600, 8]
type = ParentVarSet
trigger1 = MoveHit
trigger2 = IsHelper
trigger2 = Root,ProjHitTime(11601) = 1
var(16) = 1
ignorehitpause = 1

[State 11600, 9]
type = ParentVarSet
trigger1 = MoveGuarded
trigger2 = IsHelper
trigger2 = Root,ProjGuardedTime(11601) = 1
var(16) = 10000
ignorehitpause = 1

[State 11600, 10]
type = VarRandom
trigger1 = 1
v = 2
range = -40,40

[State 11600, 10]
type = VarRandom
trigger1 = 1
v = 3
range = -40,40

[State 11600, 11]
type = Explod
trigger1 = MoveHit
trigger2 = IsHelper
trigger2 = Root,ProjHitTime(11601) = 1
anim = 6200
ID = 6200
sprpriority = 3
postype = p2
pos = Var(2),Var(3)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 11600, 12]
type = Explod
trigger1 = MoveGuarded
trigger2 = IsHelper
trigger2 = Root,ProjGuardedTime(11601) = 1
anim = 7100
ID = 7100
sprpriority = 3
postype = p2
pos = Var(2),Var(3)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 11600, 13]
type = MoveHitReset
trigger1 = MoveContact
ignorehitpause = 1

[State 11600, 14]
type = AssertSpecial
trigger1 = 1
flag = noshadow
ignorehitpause = 1

[State 11600, 15]
type = VelAdd
trigger1 = 1
y = Const(movement.yaccel)*1.5

[State 11600, 16]
type = VarSet
trigger1 = Parent,Var(19) <= 0
var(4) = -100

[State 11600, 16]
type = VarSet
trigger1 = Parent,Var(19) <= 0
var(5) = -20

[State 11600, 16]
type = VarSet
trigger1 = Parent,Var(19) = 1
var(4) = -30

[State 11600, 16]
type = VarSet
trigger1 = Parent,Var(19) = 1
var(5) = 0

[State 11600, 16]
type = VarSet
trigger1 = Parent,Var(19) >= 2
var(4) = -1000

[State 11600, 16]
type = VarSet
trigger1 = Parent,Var(19) >= 2
var(5) = -50

[State 11600, 17]
type = DestroySelf
trigger1 = Pos Y >= 80
trigger1 = Vel Y >= 0

;---------------------------------------------------------------------------
;たいやき撃墜
[Statedef 11700]
type = A
movetype = A
physics = N
ctrl = 0

[State 11700, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 11700
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 11700, 0]
type = NotHitBy
trigger1 = 1
time = -1
value = SCA

[State 11700, 1]
type = VelSet
trigger1 = time = 0
x = -0.3*(Vel X)

[State 11700, 2]
type = VelAdd
trigger1 = time = 0
y = -4

[State 11700, 3]
type = VelAdd
trigger1 = 1
y = Const(movement.yaccel)*1.5

[State 11700, 4]
type = AssertSpecial
trigger1 = 1
flag = noshadow
ignorehitpause = 1

[State 11700, 5]
type = DestroySelf
trigger1 = Pos Y >= 80
trigger1 = Vel Y >= 0

;---------------------------------------------------------------------------
;生命の青(地上)
[Statedef 12000]
type = S
movetype = A
physics = N
sprpriority = 0
ctrl = 0

[State 12000, -1]
type = Helper
triggerall = PrevStateno != 5
trigger1 = time = 0
helpertype = Player
name = "cutin"
ID = 9999
stateno = 9999
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 12000, 0]
type = ChangeAnim
trigger1 = time = 0
value = 20100

[State 12000, 1]
type = PosSet
trigger1 = time = 0
y = 0

[State 12000, 2]
type = VelSet
trigger1 = time = 0
x = 0
y = 0

[State 12000, 3]
type = PowerAdd
triggerall = !IsHelper
triggerall = PalNo <= 10
trigger1 = time = 0
value = -1500

[State 12000, 3]
type = LifeAdd
trigger1 = time = 0
trigger1 = Var(19) < 2
value = -1*ceil(Var(54)/8)
kill = 0
absolute = 1

[State 12000, 4]
type = Pause
triggerall = !IsHelper
trigger1 = time = 0
time = 50
movetime = 1

[State 12000, 5]
type = BGPalFX
trigger1 = time = 0
time = 51
add = 0,0,0
mul = 0,0,0
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 12000, 6]
type = Explod
trigger1 = time = 0
anim = 8000
ID = 8000
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 12000, 7]
type = PlaySnd
trigger1 = time = 0
value = S5,0
channel = 7

[State 12000, 8]
type = Helper
trigger1 = Anim = 20100
trigger1 = Animelemtime(2) = 3
trigger1 = Fvar(25) = 0
helpertype = normal
name = "beam"
ID = 12500
stateno = 12500
pos = 0,Const(size.head.pos.y)+7
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 12000, 8]
type = Helper
trigger1 = Anim = 20100
trigger1 = Animelemtime(2) = 3
trigger1 = Fvar(25) != 0
helpertype = Player
name = "beam"
ID = 12500
stateno = 12500
pos = 0,Const(size.head.pos.y)+7
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 12000, 9]
type = ChangeAnim
trigger1 = Anim = 20100
trigger1 = NumHelper(12500) = 0
trigger1 = time >= 10
value = 14000

[State 12000, 10]
type = ChangeState
trigger1 = Anim = 14000
trigger1 = Animtime = 0
value = 0
ctrl = 1

[State 12000, 11]
type = ChangeState
triggerall = Var(59) = 0
trigger1 = command = "IC"
trigger1 = Var(50) >= 1000 || Var(51) = 1
trigger1 = NumHelper(12500) > 0 && time >= 10
value = 900

[State 12000, 12]
type = ChangeState
triggerall = Var(59) != 0
trigger1 = (Var(57) = [0,39]) || (Var(57) % 2 = 0 && Var(59) = 24)
trigger1 = Var(50) >= 1000 || Var(51) = 1
trigger1 = NumHelper(12500) > 0 && time >= 10
value = 900

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

;---------------------------------------------------------------------------
;地上ビーム
[Statedef 12500]
type = S
movetype = A
physics = N
sprpriority = 3
anim = 14500
ctrl = 0

[State 12500, -1]
type = ChangeState
trigger1 = !IsHelper
value = 53
ctrl = 1

[State 12500, 0]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 12500, 1]
type = VelSet
trigger1 = 1
x = 0
y = 0

[State 12500, 2]
type = VarRandom
trigger1 = 1
v = 2
range = -40,40
ignorehitpause = 1

[State 12500, 3]
type = VarRandom
trigger1 = 1
v = 3
range = -40,40
ignorehitpause = 1

[State 12500, 4]
type = PlaySnd
trigger1 = time = 0
value = s8,0
channel = 9

[State 12500, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(19) != 1
trigger1 = Root,Fvar(25) = 0
attr = S,HP
damage = ifelse(ceil(15*Parent,Fvar(0))<=15,15,ceil(15*Parent,Fvar(0))),5
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 3,6
guard.pausetime = 3,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -21.8,4.4
guard.velocity = -2.6
air.velocity = -21.8,4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 1
p2facing = 1
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10

[State 12500, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(19) = 1
trigger1 = Root,Fvar(25) = 0
attr = S,HP
damage = ifelse(ceil(7*Parent,Fvar(0))<=7,7,ceil(7*Parent,Fvar(0))),2
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 3,6
guard.pausetime = 3,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -21.8,4.4
guard.velocity = -2.6
air.velocity = -21.8,4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 1
p2facing = 1
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10

[State 12500, 5]
type = Projectile
trigger1 = IsHelper
trigger1 = Parent,Var(19) != 1
trigger1 = Root,Fvar(25) != 0
trigger1 = Animelemtime(5) >= 0
trigger1 = Animelemtime(25) < 0
projanim = 14501
projhitanim = -1
projremovetime = 1
projremove = 1
projid = 14501
offset = 0,0
velocity = 0,0
accel = 0,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = S,HP
damage = ifelse(ceil(15*Parent,Fvar(0))<=15,15,ceil(15*Parent,Fvar(0))),5
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 3,6
guard.pausetime = 3,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -21.8,4.4
guard.velocity = -2.6
air.velocity = -21.8,4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 1
p2facing = 1
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10
p2stateno = 20300

[State 12500, 5]
type = Projectile
trigger1 = IsHelper
trigger1 = Parent,Var(19) = 1
trigger1 = Root,Fvar(25) != 0
trigger1 = Animelemtime(5) >= 0
trigger1 = Animelemtime(25) < 0
projanim = 14501
projhitanim = -1
projremovetime = 1
projremove = 1
projid = 14501
offset = 0,0
velocity = 0,0
accel = 0,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = S,HP
damage = ifelse(ceil(7*Parent,Fvar(0))<=7,7,ceil(7*Parent,Fvar(0))),2
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 3,6
guard.pausetime = 3,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -21.8,4.4
guard.velocity = -2.6
air.velocity = -21.8,4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 1
p2facing = 1
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10
p2stateno = 20300

[State 12500, 6]
type = ParentVarSet
trigger1 = MoveHit
trigger2 = IsHelper
trigger2 = Root,ProjHitTime(14501) = 1
fv = 0
value = Parent,Fvar(0)-(Parent,Fvar(0)*0.1)
ignorehitpause = 1

[State 12500, 7]
type = ParentVarSet
trigger1 = MoveGuarded
trigger1 = Parent,Var(19) <= 0
trigger2 = IsHelper
trigger2 = Root,ProjGuardedTime(14501) = 1
fv = 0
value = Parent,Fvar(0)+(Parent,Fvar(0)*0.02)
ignorehitpause = 1

[State 12500, 7]
type = ParentVarSet
trigger1 = MoveGuarded
trigger1 = Parent,Var(19) >= 2
trigger2 = IsHelper
trigger2 = Root,ProjGuardedTime(14501) = 1
fv = 0
value = Parent,Fvar(0)+(Parent,Fvar(0)*0.04)
ignorehitpause = 1

[State 12500, 8]
type = ParentVarSet
trigger1 = MoveHit
trigger2 = IsHelper
trigger2 = Root,ProjHitTime(14501) = 1
var(16) = 1
ignorehitpause = 1

[State 12500, 9]
type = ParentVarSet
trigger1 = MoveGuarded
trigger2 = IsHelper
trigger2 = Root,ProjGuardedTime(14501) = 1
var(16) = 10000
ignorehitpause = 1

[State 12500, 10]
type = TargetState
trigger1 = MoveHit
trigger1 = NumTarget > 0
trigger1 = Target,isHelper = 0
trigger1 = Target,stateno != [120,155]
value = 20300
ignorehitpause = 1

[State 12500, 11]
type = Explod
trigger1 = MoveHit
trigger2 = IsHelper
trigger2 = Root,ProjHitTime(14501) = 1
anim = 6600
ID = 6600
sprpriority = 3
postype = p2
pos = Var(2),Var(3)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 12500, 12]
type = Explod
trigger1 = MoveGuarded
trigger2 = IsHelper
trigger2 = Root,ProjGuardedTime(14501) = 1
anim = 7100
ID = 7100
sprpriority = 3
postype = p2
pos = Var(2),Var(3)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 12500, 13]
type = MoveHitReset
trigger1 = MoveContact
ignorehitpause = 1

[State 12500, 14]
type = EnvShake
trigger1 = 1
time = 10
freq = 120
ampl = -10
persistent = 10
ignorehitpause = 1

[State 12500, 15]
type = AssertSpecial
trigger1 = 1
flag = noshadow
ignorehitpause = 1

[State 12500, 16]
type = ScreenBound
trigger1 = 1
value = 1

[State 12500, 17]
type = DestroySelf
trigger1 = Animtime = 0

;---------------------------------------------------------------------------
;生命の青(空中)
[Statedef 12100]
type = A
movetype = A
physics = N
sprpriority = 0
ctrl = 0

[State 12100, -1]
type = Helper
triggerall = PrevStateno != 5
trigger1 = time = 0
helpertype = Player
name = "cutin"
ID = 9999
stateno = 9999
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 12100, 0]
type = ChangeAnim
trigger1 = time = 0
value = 11100

[State 12100, 1]
type = VelSet
trigger1 = Animelemtime(4) < 0
trigger2 = NumHelper(12600) = 1
x = 0
y = 0

[State 12100, 2]
type = PowerAdd
triggerall = !IsHelper
triggerall = PalNo <= 10
trigger1 = time = 0
value = -1500

[State 12100, 2]
type = LifeAdd
trigger1 = time = 0
trigger1 = Var(19) < 2
value = -1*ceil(Var(54)/8)
kill = 0
absolute = 1

[State 12100, 3]
type = Pause
triggerall = !IsHelper
trigger1 = time = 0
time = 50
movetime = 1

[State 12100, 4]
type = BGPalFX
trigger1 = time = 0
time = 51
add = 0,0,0
mul = 0,0,0
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 12100, 5]
type = Explod
trigger1 = time = 0
anim = 8000
ID = 8000
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 12100, 6]
type = PlaySnd
trigger1 = time = 0
value = S5,0
channel = 7

[State 12100, 7]
type = Helper
trigger1 = Animelemtime(2) = 3
trigger1 = Fvar(25) = 0
helpertype = normal
name = "beam"
ID = 12600
stateno = 12600
pos = 10,-10
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 12100, 7]
type = Helper
trigger1 = Animelemtime(2) = 3
trigger1 = Fvar(25) != 0
helpertype = Player
name = "beam"
ID = 12600
stateno = 12600
pos = 10,-10
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 12100, 8]
type = VelAdd
trigger1 = NumHelper(12600) = 0
trigger1 = time >= 10
y = Const(movement.yaccel)

[State 12100, 9]
type = NotHitBy
trigger1 = 1
value = SCA
time = 2

[State 12100, 10]
type = ChangeState
triggerall = Pos Y >= 0
triggerall = Vel Y >= 0
trigger1 = Animelemtime(4) >= 0
value = 52

[State 12100, 11]
type = ChangeState
triggerall = Var(59) = 0
trigger1 = command = "IC"
trigger1 = Var(50) >= 1000 || Var(51) = 1
trigger1 = Animelemtime(4) >= 0
value = 950

[State 12100, 12]
type = ChangeState
triggerall = Var(59) != 0
trigger1 = (Var(57) = [0,39]) || (Var(57) % 2 = 0 && Var(59) = 24)
trigger1 = Var(50) >= 1000 || Var(51) = 1
trigger1 = Animelemtime(4) >= 0
value = 950

;---------------------------------------------------------------------------
;空中ビーム
[Statedef 12600]
type = A
movetype = A
physics = N
sprpriority = 3
anim = 14600
ctrl = 0

[State 12600, -1]
type = ChangeState
trigger1 = !IsHelper
value = 53
ctrl = 1

[State 12600, 0]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 12600, 1]
type = VelSet
trigger1 = 1
x = 0
y = 0

[State 12600, 2]
type = VarRandom
trigger1 = 1
v = 2
range = -40,40
ignorehitpause = 1

[State 12600, 3]
type = VarRandom
trigger1 = 1
v = 3
range = -40,40
ignorehitpause = 1

[State 12600, 4]
type = PlaySnd
trigger1 = time = 0
value = s8,0
channel = 9

[State 12600, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(19) != 1
trigger1 = Root,Fvar(25) = 0
attr = S,HP
damage = ifelse(ceil(15*Parent,Fvar(0))<=15,15,ceil(15*Parent,Fvar(0))),5
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 3,6
guard.pausetime = 3,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -21.8,4.4
guard.velocity = -2.6
air.velocity = -21.8,4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 1
p2facing = 1
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10

[State 12600, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(19) = 1
trigger1 = Root,Fvar(25) = 0
attr = S,HP
damage = ifelse(ceil(7*Parent,Fvar(0))<=7,7,ceil(7*Parent,Fvar(0))),2
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 3,6
guard.pausetime = 3,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -21.8,4.4
guard.velocity = -2.6
air.velocity = -21.8,4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 1
p2facing = 1
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10

[State 12600, 5]
type = Projectile
trigger1 = IsHelper
trigger1 = Parent,Var(19) != 1
trigger1 = Root,Fvar(25) != 0
trigger1 = Animelemtime(5) >= 0
trigger1 = Animelemtime(25) < 0
projanim = 14601
projhitanim = -1
projremovetime = 1
projremove = 1
projid = 14601
offset = 0,0
velocity = 0,0
accel = 0,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = S,HP
damage = ifelse(ceil(15*Parent,Fvar(0))<=15,15,ceil(15*Parent,Fvar(0))),5
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 3,6
guard.pausetime = 3,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -21.8,4.4
guard.velocity = -2.6
air.velocity = -21.8,4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 1
p2facing = 1
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10
p2stateno = 20300

[State 12600, 5]
type = Projectile
trigger1 = IsHelper
trigger1 = Parent,Var(19) = 1
trigger1 = Root,Fvar(25) != 0
trigger1 = Animelemtime(5) >= 0
trigger1 = Animelemtime(25) < 0
projanim = 14601
projhitanim = -1
projremovetime = 1
projremove = 1
projid = 14601
offset = 0,0
velocity = 0,0
accel = 0,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = S,HP
damage = ifelse(ceil(7*Parent,Fvar(0))<=7,7,ceil(7*Parent,Fvar(0))),2
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 3,6
guard.pausetime = 3,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -21.8,4.4
guard.velocity = -2.6
air.velocity = -21.8,4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 1
p2facing = 1
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10
p2stateno = 20300

[State 12600, 6]
type = ParentVarSet
trigger1 = MoveHit
trigger2 = IsHelper
trigger2 = Root,ProjHitTime(14601) = 1
fv = 0
value = Parent,Fvar(0)-(Parent,Fvar(0)*0.1)
ignorehitpause = 1

[State 12600, 7]
type = ParentVarSet
trigger1 = MoveGuarded
trigger1 = Parent,Var(19) <= 0
trigger2 = IsHelper
trigger2 = Root,ProjGuardedTime(14601) = 1
fv = 0
value = Parent,Fvar(0)+(Parent,Fvar(0)*0.02)
ignorehitpause = 1

[State 12600, 7]
type = ParentVarSet
trigger1 = MoveGuarded
trigger1 = Parent,Var(19) >= 2
trigger2 = IsHelper
trigger2 = Root,ProjGuardedTime(14601) = 1
fv = 0
value = Parent,Fvar(0)+(Parent,Fvar(0)*0.04)
ignorehitpause = 1

[State 12600, 8]
type = ParentVarSet
trigger1 = MoveHit
trigger2 = IsHelper
trigger2 = Root,ProjHitTime(14601) = 1
var(16) = 1
ignorehitpause = 1

[State 12600, 9]
type = ParentVarSet
trigger1 = MoveGuarded
trigger2 = IsHelper
trigger2 = Root,ProjGuardedTime(14601) = 1
var(16) = 10000
ignorehitpause = 1

[State 12600, 10]
type = TargetState
trigger1 = MoveHit
trigger1 = NumTarget > 0
trigger1 = Target,isHelper = 0
trigger1 = Target,stateno != [120,155]
value = 20300
ignorehitpause = 1

[State 12600, 11]
type = Explod
trigger1 = MoveHit
trigger2 = IsHelper
trigger2 = Root,ProjHitTime(14601) = 1
anim = 6600
ID = 6600
sprpriority = 3
postype = p2
pos = Var(2),Var(3)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 12600, 12]
type = Explod
trigger1 = MoveGuarded
trigger2 = IsHelper
trigger2 = Root,ProjGuardedTime(14601) = 1
anim = 7100
ID = 7100
sprpriority = 3
postype = p2
pos = Var(2),Var(3)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 12600, 13]
type = MoveHitReset
trigger1 = MoveContact
ignorehitpause = 1

[State 12600, 14]
type = AssertSpecial
trigger1 = 1
flag = noshadow
ignorehitpause = 1

[State 12600, 15]
type = AngleDraw
trigger1 = 1
ignorehitpause = 1

[State 12600, 16]
type = AngleSet
trigger1 = time = 0
value = 315
ignorehitpause = 1

[State 12600, 17]
type = Trans
trigger1 = 1
trans = Add
ignorehitpause = 1

[State 12600, 18]
type = EnvShake
trigger1 = 1
time = 10
freq = 120
ampl = -10
persistent = 10
ignorehitpause = 1

[State 12600, 19]
type = ScreenBound
trigger1 = 1
value = 1

[State 12600, 20]
type = DestroySelf
trigger1 = Animtime = 0

;---------------------------------------------------------------------------
;転生の見切り
[Statedef 13000]
type = S
movetype = I
physics = S
ctrl = 0

[State 13000, -1]
type = NotHitBy
trigger1 = Fvar(20) != 0
value = SCA
time = 10

[State 13000, 0]
type = ChangeAnim
triggerall = PrevStateno != 5
trigger1 = time = 0
trigger2 = Fvar(20) != 0
trigger2 = time < 120
value = 13000

[State 13000, 1]
type = SuperPause
triggerall = Fvar(20) != 0
triggerall = !IsHelper
triggerall = PrevStateno != 5
trigger1 = time = 0
time = 50
anim = -1
sound = -1
pos = 0,0
movetime = 1
darken = 1

[State 13000, 2]
type = Explod
triggerall = Fvar(20) != 0
triggerall = PrevStateno != 5
trigger1 = time = 0
anim = 8200
ID = 8200
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 13000, 3]
type = Explod
triggerall = Fvar(20) != 0
triggerall = PrevStateno != 5
trigger1 = time = 0
anim = 8300
ID = 8300
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 13000, 4]
type = PlaySnd
triggerall = Fvar(20) != 0
triggerall = PrevStateno != 5
trigger1 = time = 0
value = S5,2
channel = 7

[State 13000, 5]
type = PlaySnd
triggerall = Fvar(20) != 0
triggerall = PrevStateno != 5
trigger1 = time = 0
value = S5,3
channel = 9

[State 13000, 6]
type = Reversaldef
trigger1 = Fvar(20) = 0
reversal.attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
hitflag = MAFD
sparkno = -1
sparkxy = 0,0
pausetime = 0,10
hitsound = -1
priority = 7,Hit
numhits = 0
p1stateno = 13100

[State 13000, 6]
type = Reversaldef
trigger1 = Fvar(20) != 0
reversal.attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
hitflag = MAFD
sparkno = -1
sparkxy = 0,0
pausetime = 0,20
hitsound = -1
priority = 7,Hit
numhits = 0
p2stateno = 38534

[State 13000, 7]
type = HitOverRide
trigger1 = Fvar(20) = 0
trigger1 = Alive
trigger1 = Animelemtime(1) >= 0
trigger1 = Animelemtime(2) < 0
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
time = 2
stateno = 13100
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 13000, 8]
type = ChangeState
trigger1 = Fvar(20) = 0
trigger1 = MoveHit
value = 13100

[State 13000, 9]
type = ChangeState
trigger1 = Animtime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
;見切り成功
[Statedef 13100]
type = S
movetype = I
physics = S
ctrl = 0

[State 13100, 0]
type = ChangeAnim
trigger1 = time = 0
value = 10000

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

[State 13100, 2]
type = PosAdd
trigger1 = time = 0
x = ceil(P2Dist X)+60

[State 13100, 3]
type = PlaySnd
trigger1 = time = 0
value = S7,3
channel = 6

[State 13100, 4]
type = Turn
trigger1 = time = 1
persistent = 0

[State 13100, 5]
type = Pause
triggerall = !IsHelper
trigger1 = time = 0
time = 120
movetime = 120

[State 13100, 6]
type = CtrlSet
trigger1 = time > 1
value = 1

[State 13100, 7]
type = ChangeState
trigger1 = time > 10
value = 0
ctrl = 1

;---------------------------------------------------------------------------
;滅殺
[Statedef 13150]
type = S
movetype = I
physics = S
ctrl = 0

[State 13150, -1]
type = StopSnd
trigger1 = Fvar(0) != 0
channel = -1
ignorehitpause = 1
pausemovetime = 9999999
supermovetime = 9999999

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

[State 13150, 0]
type = ChangeAnim
trigger1 = time = 0
value = 999

[State 13150, 1]
type = SuperPause
trigger1 = 1
time = 2
anim = -1
sound = -1
pos = 0,0
movetime = 2
darken = 0

[State 13150, 2]
type = EnvColor
trigger1 = 1
value = 0,0,0
time = 2
under = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 13150, 3]
type = Explod
trigger1 = 1
anim = 8000
ID = 8000
sprpriority = 3
postype = left
pos = (Random%320),(Random%240)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 13150, 4]
type = PlaySnd
trigger1 = 1
value = S2,8
;channel = (Random%5)

[State 13150, 5]
type = PlaySnd
trigger1 = 1
value = S3,3
;channel = 5+(Random%5)

[State 13150, 6]
type = HitOverRide
trigger1 = 1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
time = -1
stateno = 13150
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 13150, 7]
type = AssertSpecial
trigger1 = 1
flag = nobardisplay
flag2 = nokoslow

[State 13150, 8]
type = ChangeState
trigger1 = time > 180
value = 2

;---------------------------------------------------------------------------
;論外滅殺
[Statedef 13151]
type = S
movetype = I
physics = S
ctrl = 0

[State 13151, -1]
type = PalFX
trigger1 = 1
time = 20
add = 256,-128,-128
mul = 256,256,256
sinadd = 0,0,0,1
invertall = 0
color = 256
ignorehitpause = 1
pausemovetime = 9999999
supermovetime = 9999999

[State 13151, -1]
type = StopSnd
trigger1 = Fvar(0) != 0
channel = -1
ignorehitpause = 1
pausemovetime = 9999999
supermovetime = 9999999

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

[State 13151, 0]
type = ChangeAnim
trigger1 = time = 0
value = 999

[State 13151, 1]
type = SuperPause
trigger1 = 1
time = 2
anim = -1
sound = -1
pos = 0,0
movetime = 2
darken = 0

[State 13151, 2]
type = EnvColor
trigger1 = 1
value = 0,0,0
time = 2
under = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 13151, 3]
type = Explod
trigger1 = time > 0
anim = 8000
ID = 8000
sprpriority = 3
postype = left
pos = (Random%320),(Random%240)
ontop = 1
ownpal = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 13151, 4]
type = PlaySnd
trigger1 = 1
value = S3,3
;channel = (Random%5)

[State 13151, 5]
type = PlaySnd
trigger1 = 1
value = S7,3
;channel = 5+(Random%5)

[State 13151, 6]
type = HitOverRide
trigger1 = 1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
time = -1
stateno = 13150
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 13151, 7]
type = AssertSpecial
trigger1 = 1
flag = nobardisplay
flag2 = nokoslow

[State 13151, 8]
type = ChangeState
trigger1 = time > 180
value = 2

;---------------------------------------------------------------------------
;終了
[Statedef 13200]
type = S
movetype = I
physics = S
ctrl = 0

[State 13200, -1]
type = StopSnd
triggerall = NumHelper(2)
triggerall = Helper(2),Fvar(0) != 0
trigger1 = Animelemtime(3) < 0
channel = -1
ignorehitpause = 1
pausemovetime = 9999999
supermovetime = 9999999

[State 13200, -1]
type = PosSet
trigger1 = 1
y = 0

[State 13200, -1]
type = VelSet
trigger1 = 1
x = 0
y = 0

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

[State 13200, 0]
type = ChangeAnim
trigger1 = time = 0
value = 13200

[State 13200, 1]
type = SuperPause
trigger1 = 1
time = 2
anim = -1
sound = -1
pos = 0,0
movetime = 2
darken = 0

[State 13200, 2]
type = Explod
trigger1 = Animelemtime(3) = 0
anim = 8200
ID = 8200
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 13200, 3]
type = Explod
trigger1 = Animelemtime(3) = 0
anim = 8300
ID = 8300
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 13200, 4]
type = PlaySnd
trigger1 = Animelemtime(3) = 0
value = S5,2
channel = 7

[State 13200, 5]
type = PlaySnd
trigger1 = Animelemtime(3) = 0
value = S5,3
channel = 9

[State 13200, 6]
type = Explod
trigger1 = Animelemtime(4) = 0
anim = 31500
ID = 31500
sprpriority = 3
postype = p1
pos = 0,0
ontop = 1
ownpal = 1
scale = 2,2
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999
persistent = 0

[State 13200, 7]
type = PlaySnd
trigger1 = Animelemtime(4) = 0
value = S4,0
channel = 7
persistent = 0

[State 13200, 8]
type = AssertSpecial
trigger1 = 1
flag = nobardisplay
flag2 = nokoslow

[State 13200, 9]
type = ChangeState
trigger1 = Animtime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
;秘孔新血愁
[Statedef 14000]
type = S
movetype = A
physics = S
ctrl = 0

[State 14000, -1]
type = Helper
triggerall = PrevStateno != 14050
triggerall = PrevStateno != 5
trigger1 = time = 0
helpertype = Player
name = "cutin"
ID = 9999
stateno = 9999
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State -1]
type = VarAdd
trigger1 = 1
var(21) = 1

[State -1]
type = VarSet
triggerall = PrevStateno != 14050
triggerall = PrevStateno != 5
trigger1 = time = 0
var(21) = 0

[State 14000, 0]
type = ChangeAnim
triggerall = PrevStateno != 14050
triggerall = PrevStateno != 5
trigger1 = time = 0
value = 13300

[State 14000, 1]
type = VarSet
triggerall = PrevStateno != 14050
triggerall = PrevStateno != 5
trigger1 = time = 0
var(3) = Power

[State 14000, 2]
type = PowerSet
triggerall = !IsHelper
triggerall = PalNo <= 10
triggerall = PrevStateno != 14050
triggerall = PrevStateno != 5
trigger1 = time = 0
trigger1 = Var(3) > 0
value = 0

[State 14000, 3]
type = SuperPause
triggerall = !IsHelper
triggerall = PrevStateno != 14050
triggerall = PrevStateno != 5
trigger1 = time = 0
time = 50
anim = -1
sound = -1
pos = 0,0
movetime = 1
darken = 0

[State 14000, 4]
type = BGPalFX
triggerall = PrevStateno != 14050
triggerall = PrevStateno != 5
trigger1 = time = 0
time = 52
add = 0,0,0
mul = 0,0,0
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 14000, 4]
type = BGPalFX
trigger1 = Var(21) > 1
time = 15
add = 0,0,0
mul = 256,256,256
sinadd = 0,0,0,1
invertall = 1
color = 256

[State 14000, 5]
type = Explod
triggerall = PrevStateno != 14050
triggerall = PrevStateno != 5
trigger1 = time = 0
anim = 8200
ID = 8200
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 14000, 6]
type = Explod
triggerall = PrevStateno != 14050
triggerall = PrevStateno != 5
trigger1 = time = 0
anim = 8300
ID = 8300
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 14000, 7]
type = PlaySnd
triggerall = PrevStateno != 14050
triggerall = PrevStateno != 5
trigger1 = time = 0
value = S5,2
channel = 7

[State 14000, 8]
type = PlaySnd
triggerall = PrevStateno != 14050
triggerall = PrevStateno != 5
trigger1 = time = 0
value = S5,3
channel = 9

[State 14000, 9]
type = Hitdef
triggerall = !IsHelper
triggerall = Fvar(37) = 0
triggerall = Fvar(25) = 0
trigger1 = Var(43) = 0
attr = S,HA
damage = 0,0
animtype = Hard
hitflag = AF
priority = 7,Miss
pausetime = 0,10
guard.pausetime = 0,10
sparkno = s6600
guard.sparkno = s7100
sparkxy = -10,Const(size.mid.pos.y)-60
hitsound = s2,3
guardsound = s3,2
ground.type = High
ground.slidetime = 22
ground.hittime = 27
guard.slidetime = 18
guard.hittime = 21
ground.velocity = 0,-5.6
guard.velocity = -2.2
air.velocity = 0,-6.5
airguard.velocity = -2.8,-4.5
fall = 1
air.fall = 1
fall.recover = 0
getpower = 0,0
ground.cornerpush.veloff = 0
air.cornerpush.veloff = 0
kill = 0
guard.kill = 0
p1stateno = 14100
p2stateno = 14120+(Fvar(20) != 0)
p2facing = 1

[State 14000, 9]
type = Hitdef
triggerall = !IsHelper
triggerall = Fvar(37) = 0
triggerall = Fvar(25) = 0
trigger1 = Var(43) > 1
attr = S,HA
damage = 0,0
animtype = Hard
hitflag = MAFD
priority = 7,Miss
pausetime = 0,10
guard.pausetime = 0,10
sparkno = s6600
guard.sparkno = s7100
sparkxy = -10,Const(size.mid.pos.y)-60
hitsound = s2,3
guardsound = s3,2
ground.type = High
ground.slidetime = 22
ground.hittime = 27
guard.slidetime = 18
guard.hittime = 21
ground.velocity = 0,-5.6
guard.velocity = -2.2
air.velocity = 0,-6.5
airguard.velocity = -2.8,-4.5
fall = 1
air.fall = 1
fall.recover = 0
getpower = 0,0
ground.cornerpush.veloff = 0
air.cornerpush.veloff = 0
kill = 0
guard.kill = 0
p1stateno = 14100
p2stateno = 14120+(Fvar(20) != 0)
p2facing = 1

[State 14000, 10]
type = HitOverRide
trigger1 = Var(41) = 0 && Var(24) = 0
time = 2
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 14050
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 14000, 11]
type = ChangeState
trigger1 = Animtime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
;スーパーアーマー
[Statedef 14050]
type = U
movetype = H
physics = U
ctrl = 0

[State 14050, 0]
type = HitOverRide
trigger1 = Var(41) = 0 && Var(24) = 0
time = 2
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 14050
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 14050, 1]
type = LifeAdd
trigger1 = time = 0
value = -GetHitVar(Damage)

[State 14050, 2]
type = ChangeState
trigger1 = time = 0
value = 14000

[State 14050, 3]
type = ChangeState
trigger1 = Animtime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
;秘孔新血愁(ヒット)
[Statedef 14100]
type = S
movetype = A
physics = N
sprpriority = 3
ctrl = 0

[State 14100, 0]
type = ChangeAnim
trigger1 = time = 0
value = 13400

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

[State 14100, 2]
type = TargetState
trigger1 = Animelemtime(5) < 0
value = 14120+(Fvar(20) != 0)

[State 14100, 3]
type = TargetBind
trigger1 = time = 0
time = 1
pos = 40,-100

[State 14100, 4]
type = TargetLifeAdd
trigger1 = time = 0
trigger1 = Var(19) != 1
value = ifelse(Fvar(0)>=1,ceil(-50*(Var(3)/1000)*Fvar(0)),ceil(-50*(Var(3)/1000)))
kill = 0
absolute = 1

[State 14100, 4]
type = TargetLifeAdd
trigger1 = time = 0
trigger1 = Var(19) = 1
value = ceil(-50*(Var(3)/1000))
kill = 0
absolute = 1

[State 14100, 5]
type = Helper
trigger1 = Animelem = 5
trigger1 = Fvar(25) = 0
helpertype = normal
name = "Arrow"
ID = 14110
stateno = 14110
pos = 0,-20
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 14100, 5]
type = Helper
trigger1 = Animelem = 5
trigger1 = Fvar(25) != 0
helpertype = Player
name = "Arrow"
ID = 14110
stateno = 14110
pos = 0,-20
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 14100, 6]
type = TargetLifeAdd
trigger1 = Animelem = 5
trigger1 = Var(19) != 1
value = ifelse(Fvar(0)>=1,ceil(-150*(Var(3)/1000)*Fvar(0)),ceil(-150*(Var(3)/1000)))
kill = 1
absolute = 1

[State 14100, 6]
type = TargetLifeAdd
trigger1 = Animelem = 5
trigger1 = Var(19) = 1
value = ceil(-150*(Var(3)/1000))
kill = 1
absolute = 1

[State 14100, 7]
type = HitAdd
trigger1 = Animelem = 5
value = 1

[State 14100, 8]
type = VelSet
trigger1 = Animelem = 5
x = 2
y = -10

[State 14100, 8]
type = VelAdd
trigger1 = Animelemtime(5) >= 0
y = Const(movement.yaccel)

[State 14100, 9]
type = PosSet
trigger1 = time = 0
trigger2 = Animelemtime(7) >= 0 || Animelemtime(8) >= 0
trigger2 = Vel Y > 0
trigger2 = Pos Y >= 0
y = 0

[State 14100, 10]
type = BGPalFX
trigger1 = 1
time = 30
add = 0,0,0
mul = 256,256,256
sinadd = 0,0,0,1
invertall = 1
color = 256

[State 14100, 11]
type = ChangeState
trigger1 = Pos Y = 0
trigger1 = Vel Y > 0
trigger1 = Animelemtime(7) >= 0
value = 52

;---------------------------------------------------------------------------
;貫通アロー
[Statedef 14110]
type = A
movetype = A
physics = N
ctrl = 0
sprpriority = 3
anim = 1900

[State 14410, 0]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 14410, 1]
type = VelSet
trigger1 = 1
x = 4
y = -12

[State 14110, 2]
type = PlaySnd
trigger1 = time = 0
value = s4,1
channel = 4

[State 14110, 3]
type = Explod
trigger1 = time = 0
anim = 7700
ID = 7700
sprpriority = 1
postype = p2
pos = 0,0
ontop = 1
ownpal = 1
facing = -1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 14110, 4]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[State 14110, 5]
type = DestroySelf
trigger1 = ScreenPos Y <= -300
trigger2 = time >= 300

;---------------------------------------------------------------------------
;捕まった相手
[Statedef 14120]
type = A
movetype = H
physics = N
sprpriority = 5
ctrl = 0

[State 14120, 0]
type = ChangeAnim2
trigger1 = time = 0
value = 13500

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

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

[State 14120, 3]
type = ChangeState
trigger1 = time > 1
value = 14130

;---------------------------------------------------------------------------
;捕まった相手
[Statedef 14121]
type = A
movetype = H
physics = N
sprpriority = 5
ctrl = 0

[State 14121, 0]
type = ChangeAnim2
trigger1 = time = 0
value = 13500

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

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

[State 14121, 3]
type = ChangeState
trigger1 = time > 0
value = 14131

;---------------------------------------------------------------------------
;貫かれた相手
[Statedef 14130]
type = A
movetype = H
physics = N
sprpriority = 5
ctrl = 0

[State 14130, -1]
type = PlaySnd
trigger1 = IsHelper
value = S11,0

[State 14130, -1]
type = DestroySelf
trigger1 = IsHelper

[State 14130, 0]
type = ChangeAnim2
trigger1 = time = 0
value = 13500

[State 14130, 1]
type = AngleDraw
trigger1 = time > 1

[State 14130, 2]
type = AngleAdd
trigger1 = time > 1
value = 60

[State 14130, 3]
type = VelSet
trigger1 = time = 1
x = -4
y = -12

[State 14130, 4]
type = VelAdd
trigger1 = time > 0
y = Const(movement.yaccel)

[State 14130, 5]
type = PosSet
trigger1 = Pos Y >= 0
trigger1 = time > 10
y = 0

[State 14130, 6]
type = LifeSet
trigger1 = Life <= 10
value = 0

[State 14130, 7]
type = SprPriority
trigger1 = Vel Y > 0
value = -1

[State 14130, 8]
type = HitBy
trigger1 = 1
value = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
time = -1

[State 14130, 9]
type = SelfState
trigger1 = Pos Y >= 0
trigger1 = Vel Y > 0
trigger1 = time > 10
value = 5100

;---------------------------------------------------------------------------
;貫かれた相手
[Statedef 14131]
type = A
movetype = H
physics = N
sprpriority = 5
ctrl = 0

[State 14131, -1]
type = LifeAdd
trigger1 = time = 0
value = ceil(-0.32*LifeMax)
kill = 1
absolute = 1

[State 14131, -1]
type = PlaySnd
trigger1 = IsHelper
value = S11,0
freqmul = 1+(Random%5-2)*0.1

[State 14131, -1]
type = DestroySelf
trigger1 = IsHelper

[State 14131, 0]
type = ChangeAnim2
trigger1 = time = 0
value = 13500

[State 14131, 1]
type = AngleDraw
trigger1 = time > 1

[State 14131, 2]
type = AngleAdd
trigger1 = time > 1
value = 60

[State 14131, 3]
type = VelSet
trigger1 = time = 1
x = -4
y = -12

[State 14131, 4]
type = VelAdd
trigger1 = time > 0
y = Const(movement.yaccel)

[State 14131, 5]
type = PosSet
trigger1 = Pos Y >= 0
trigger1 = time > 10
y = 0

[State 14131, 6]
type = LifeSet
trigger1 = Life <= 10
value = 0

[State 14131, 7]
type = SprPriority
trigger1 = Vel Y > 0
value = -1

[State 14131, 8]
type = HitBy
trigger1 = 1
value = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
time = -1

[State 14131, 9]
type = SelfState
trigger1 = Pos Y >= 0
trigger1 = Vel Y > 0
trigger1 = time > 10
value = 5100

;---------------------------------------------------------------------------
;リザレクション発動
[Statedef 20000]
type = S
movetype = I
physics = N
sprpriority = 6
ctrl = 0

[State 20000, 0]
type = ChangeAnim
trigger1 = time = 0
value = 20000

[State 20000, 1]
type = PosSet
trigger1 = 1
y = 0

[State 20000, 2]
type = VelSet
trigger1 = 1
x = 0
y = 0

[State 20000, 3]
type = AttackDist
trigger1 = 1
value = 0

[State 20000, 4]
type = Helper
trigger1 = NumHelper(20250) = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "counter"
ID = 20250
stateno = 20250
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20000, 4]
type = Helper
trigger1 = NumHelper(20250) = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "counter"
ID = 20250
stateno = 20250
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20000, 5]
type = VarSet
triggerall = Fvar(20) = 0
trigger1 = time = 0
var(49) = Life

[State 20000, 6]
type = PlaySnd
trigger1 = Animelemtime(1) = 1
value = S20,0
channel = 8

[State 20000, 7]
type = PlaySnd
trigger1 = Animelemtime(2) = 0
value = S20,1
channel = 8

[State 20000, 8]
type = PlaySnd
trigger1 = Animelemtime(3) = 0
value = S20,2
channel = 8

[State 20000, 9]
type = AssertSpecial
trigger1 = 1
flag = timerfreeze
flag2 = noFG
flag3 = globalnoshadow

[State 20000, 10]
type = ChangeState
trigger1 = Animtime = 0
value = 20100

;---------------------------------------------------------------------------
;リザレクション実行中
[Statedef 20100]
type = S
movetype = I
physics = N
sprpriority = 6
ctrl = 0

[State 20100, 0]
type = ChangeAnim
trigger1 = time = 0
value = 20100

[State 20100, 1]
type = AssertSpecial
trigger1 = 1
flag = timerfreeze
flag2 = noFG
flag3 = globalnoshadow

[State 20100, 2]
type = Explod
trigger1 = time = 0
anim = 20300
ID = 20300
sprpriority = 5
postype = p1
pos = 0,Const(size.mid.pos.y)+10
ownpal = 1
removetime = -1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20100, 3]
type = RemoveExplod
triggerall = NumExplod(20300) = 1
trigger1 = Life = LifeMAX
trigger1 = time >= 300
trigger2 = RoundState != 2
trigger3 = Time >= 1800
ID = 20300

[State 20100, 4]
type = VarSet
trigger1 = Fvar(20) = 0
var(49) = Var(49)+(Var(54)/200)
persistent = 2

[State 20100, 4]
type = LifeAdd
trigger1 = Fvar(20) != 0
value = (Var(54)/200)
persistent = 2

[State 20100, 4]
type = null;VarAdd
trigger1 = Fvar(20) != 0
trigger1 = Gametime % 2 = 0
var(17) = -1*(Var(54)/200)

[State 20100, 5]
type = PowerAdd
trigger1 = 1
value = 4

[State 20100, 6]
type = Helper
trigger1 = NumHelper(20250) = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "counter"
ID = 20250
stateno = 20250
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20100, 6]
type = Helper
trigger1 = NumHelper(20250) = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "counter"
ID = 20250
stateno = 20250
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20100, 7]
type = VarSet
trigger1 = time = 0
v = 53
value = 1

[State 20100, 8]
type = VarSet
trigger1 = time = 0
v = 52
value = 1

[State 20100, 9]
type = VarSet
trigger1 = time = 0
v = 56
value = 1

[State 20100, 10]
type = AttackDist
trigger1 = 1
value = 0

[State 20200, 11]
type = PlaySnd
trigger1 = time = 50
value = S20,3
channel = 8

[State 20100, 12]
type = ChangeState
trigger1 = time > 0
trigger1 = NumExplod(20300) = 0
value = 20200

;---------------------------------------------------------------------------
;リザレクション終了
[Statedef 20200]
type = S
movetype = I
physics = S
sprpriority = 6
ctrl = 0

[State 20200, 0]
type = ChangeAnim
trigger1 = time = 0
value = 20200

[State 20200, 1]
type = Explod
trigger1 = time = 0
anim = 7700
ID = 7700
sprpriority = 1
postype = p1
pos = 0,Const(size.mid.pos.y)
ownpal = 1
scale = 2,2
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20200, 2]
type = AssertSpecial
trigger1 = 1
flag = timerfreeze
flag2 = noFG
flag3 = globalnoshadow

[State 20200, 3]
type = PlaySnd
trigger1 = time = 0
value = s4,0
channel = 5

[State 20200, 4]
type = PowerSet
trigger1 = 1
value = PowerMAX

[State 20200, 5]
type = LifeSet
trigger1 = 1
value = LifeMAX

[State 20200, 6]
type = NotHitBy
trigger1 = 1
time = 120
value = SCA

[State 20200, 7]
type = ChangeState
trigger1 = Animtime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
;カウンター
[Statedef 20250]
type = A
movetype = A
physics = N
ctrl = 0

[State 20250, -1]
type = ChangeAnim
trigger1 = time = 0
trigger1 = Root,Fvar(20) = 0
value = 20500
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20250, -1]
type = ChangeAnim
trigger1 = time = 0
trigger1 = Root,Fvar(20) != 0
value = 38722
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20250, 0]
type = AttackMulSet
trigger1 = 1
value = Root,Fvar(0)
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20250, 0]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 20251
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20250, 1]
type = Reversaldef
trigger1 = 1
reversal.attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
hitflag = MAFD
sparkno = -1
sparkxy = 0,0
pausetime = 0,0
hitsound = -1
priority = 7,Dodge
getpower = 0,0
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)
numhits = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20250, 2]
type = Projectile
trigger1 = MoveHit
trigger2 = Enemynear,Movetype = A
projanim = 20500
projhitanim = -1
projremovetime = -1
projremove = 1
projid = 20500
offset = 0,0
velocity = 0,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = S,HA
animtype = hard
damage = 50,20
pausetime = 0,15
guard.pausetime = 0,20
hitflag = MAFD
guardflag = M
sparkno = -1
sparkky = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 1
ground.hittime = 1
ground.velocity = 0,0
fall = 1
fall.recover = 0
kill = 0
guard.kill = 0
p2stateno = 20300
getpower = 0,0
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)
numhits = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20250, 3]
type = AttackDist
trigger1 = 1
value = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20250, 4]
type = MoveHitReset
trigger1 = MoveContact
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20250, 5]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = timerfreeze
flag3 = invisible
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20250, 6]
type = AssertSpecial
trigger1 = 1
flag = nomusic
flag = noFG
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20250, 7]
type = DestroySelf
trigger1 = Parent,Stateno = 20200
trigger1 = Parent,Animtime = 0
trigger2 = Parent,Stateno != [20000,20200]
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

;---------------------------------------------------------------------------
;カウンター
[Statedef 20251]
type = A
movetype = A
physics = N
ctrl = 0

[State 20251, -1]
type = LifeSet
trigger1 = 1
value = Const(data.life)
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20251, 0]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 20251
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20251, 1]
type = Projectile
trigger1 = 1
projanim = 20500
projhitanim = -1
projremovetime = -1
projremove = 1
projid = 20500
offset = 0,0
velocity = 0,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = S,HA
animtype = hard
damage = 50,20
pausetime = 0,15
guard.pausetime = 0,20
hitflag = MAFD
guardflag = M
sparkno = -1
sparkky = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 1
ground.hittime = 1
ground.velocity = 0,0
fall = 1
fall.recover = 0
kill = 0
guard.kill = 0
p2stateno = 20300
getpower = 0,0
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)
numhits = 0

[State 20251, 2]
type = AttackDist
trigger1 = 1
value = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20251, 3]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = timerfreeze
flag3 = invisible
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20251, 4]
type = AssertSpecial
trigger1 = 1
flag = nomusic
flag = noFG
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20251, 5]
type = ChangeState
trigger1 = time = 0
value = 20250
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 20251, 6]
type = DestroySelf
trigger1 = Parent,Stateno = 20200
trigger1 = Parent,Animtime = 0
trigger2 = Parent,Stateno != [20000,20200]
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

;---------------------------------------------------------------------------
;叩き付け
[Statedef 20300]
type = A
movetype = H
physics = N
ctrl = 0

[State 20300, -1]
type = DefenceMulSet
trigger1 = 1
value = 1
ignorehitpause = 1

[State 20300, 0]
type = ChangeAnim
trigger1 = 1
value = 5010

[State 20300, 1]
type = VelSet
trigger1 = 1
x = -10
y = 0

[State 20300, 2]
type = PosSet
trigger1 = Pos Y >= 0
y = -1

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

[State 20300, 4]
type = PlayerPush
trigger1 = 1
value = 0

[State 20300, 5]
type = ChangeState
triggerall = Alive
trigger1 = BackEdgeBodyDist <= 0
value = 20310

[State 20300, 6]
type = ChangeState
trigger1 = !Alive
value = 5150

;---------------------------------------------------------------------------
;打ち上げ
[Statedef 20301]
type = A
movetype = H
physics = N
ctrl = 0

[State 20301, 0]
type = ChangeAnim2
trigger1 = time < 5
value = 5670

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

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

[State 20301, 3]
type = PlayerPush
trigger1 = 1
value = 0

[State 20301, 4]
type = LifeSet
trigger1 = time >= 5
trigger1 = Name != "Ayu Tukimiya" || (Name = "Ayu Tukimiya" && Gametime != Var(23))
value = 0
ignorehitpause = 1

[State 20301, 5]
type = PowerSet
trigger1 = 1
value = 0

[State 20301, 6]
type = VelAdd
trigger1 = 1
y = Const(movement.yaccel)

[State 20301, 7]
type = ChangeState
trigger1 = !Alive
trigger1 = IsHelper = 0
value = 5150

[State 20301, 8]
type = SelfState
triggerall = time > 10
triggerall = Vel Y > 0
triggerall = Pos Y > 0
trigger1 = Alive
trigger2 = IsHelper = 1
value = 5100

;---------------------------------------------------------------------------
;落下
[Statedef 20310]
type = A
movetype = H
physics = N
ctrl = 0

[State 20310, 0]
type = ChangeAnim
trigger1 = time = 0
value = 5050

[State 20310, 1]
type = VelSet
trigger1 = time = 0
x = 3
y = 0

[State 20310, 2]
type = VelAdd
trigger1 = Vel X > 0
x = -0.3

[State 20310, 3]
type = VelSet
trigger1 = Vel X < 0
x = 0

[State 20310, 4]
type = VelAdd
trigger1 = Vel X = 0
trigger1 = Pos Y < 0
y = Const(movement.yaccel)

[State 20310, 5]
type = PosSet
trigger1 = time > 0
trigger1 = Vel X = 0
trigger1 = Pos Y > 0
y = 0

[State 20310, 6]
type = VelSet
trigger1 = time > 0
trigger1 = Pos Y = 0
y = 0

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

[State 20310, 8]
type = PlayerPush
trigger1 = 1
value = 0

[State 20310, 9]
type = SelfState
trigger1 = Alive
trigger1 = Pos Y = 0
value = 5100

[State 20310, 10]
type = ChangeState
trigger1 = !Alive
value = 5150

;---------------------------------------------------------------------------
;セイントクロス
[Statedef 30000]
type = S
movetype = A
physics = S
ctrl = 0
sprpriority = 4

[State 30000, -1]
type = Helper
triggerall = PrevStateno != 5
trigger1 = time = 0
helpertype = Player
name = "cutin"
ID = 9999
stateno = 9999
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 30000, 0]
type = ChangeAnim
trigger1 = time = 0
value = 30000

[State 30000, 1]
type = Pause
trigger1 = 1
time = 2
movetime = 2

[State 30000, 2]
type = Explod
trigger1 = time = 0
anim = 8200
ID = 8200
sprpriority = 0
postype = p1
pos = 0,Const(size.mid.pos.y)
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 30000, 3]
type = PlaySnd
trigger1 = time = 0
value = s5,2
channel = 7

[State 30000, 4]
type = PlaySnd
trigger1 = time = 0
value = s5,3
channel = 5

[State 30000, 5]
type = BGPalFX
trigger1 = 1
time = 2
add = 0,0,0
mul = 0,0,0
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 30000, 6]
type = Explod
trigger1 = Animelem = 3
anim = 30100
ID = 30100
sprpriority = 2
postype = p1
pos = -60,0
ownpal = 1
facing = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 30000, 7]
type = Explod
trigger1 = Animelem = 3
anim = 30100
ID = 30100
sprpriority = 2
postype = p1
pos = 60,0
ownpal = 1
facing = -1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 30000, 8]
type = Explod
trigger1 = Animelem = 3
anim = 30200
ID = 30200
sprpriority = 2
postype = p1
pos = -60,5
ownpal = 1
facing = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 30000, 9]
type = Explod
trigger1 = Animelem = 3
anim = 30200
ID = 30200
sprpriority = 2
postype = p1
pos = 60,5
ownpal = 1
facing = -1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 30000, 10]
type = Explod
trigger1 = Animelem = 3
anim = 30400
ID = 30400
sprpriority = 0
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 30000, 11]
type = PlaySnd
trigger1 = Animelem = 3
value = s4,0
channel = 9

[State 30000, 12]
type = VarSet
trigger1 = time = 0
var(56) = 1

[State 30000, 13]
type = VarSet
triggerall = RoundState >= 2
trigger1 = time = 0
var(50) = 0

[State 30000, 14]
type = VarSet
triggerall = RoundState >= 2
trigger1 = time = 0
var(51) = 0

[State 30000, 15]
type = PowerAdd
triggerall = RoundState >= 2
triggerall = PalNo <= 10
trigger1 = time = 0
value = -3000

[State 30000, 16]
type = ChangeState
triggerall = RoundState >= 2
trigger1 = Animtime = 0
value = 0
ctrl = 1

[State 30000, 17]
type = AssertSpecial
trigger1 = RoundState < 2
flag = Intro

[State 30000, 18]
type = ChangeState
triggerall = RoundState < 2
trigger1 = Animtime = 0
value = 5900

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

;---------------------------------------------------------------------------
;ドラゴンブレス
[Statedef 30500]
type = S
movetype = A
physics = S
ctrl = 0
sprpriority = 3

[State -1]
type = VarAdd
trigger1 = 1
var(21) = 1

[State -1]
type = VarSet
triggerall = PrevStateno != 5
trigger1 = time = 0
var(21) = 0

[State 30500, -1]
type = Helper
triggerall = PrevStateno != 5
trigger1 = time = 0
helpertype = Player
name = "cutin"
ID = 9999
stateno = 9999
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 30500, -1]
type = VarSet
triggerall = PrevStateno != 5
trigger1 = time = 0
var(3) = 0

[State 30500, 0]
type = ChangeAnim
triggerall = PrevStateno != 5
trigger1 = time = 0
value = 30500

[State 30500, 1]
type = PowerAdd
triggerall = PrevStateno != 5
triggerall = !IsHelper
triggerall = PalNo <= 10
trigger1 = time = 0
value = -2000

[State 30500, 2]
type = PlaySnd
triggerall = PrevStateno != 5
trigger1 = time = 0
value = s5,1
channel = 7

[State 30500, 3]
type = Explod
triggerall = PrevStateno != 5
trigger1 = time = 0
anim = 8100
ID = 8100
sprpriority = 4
postype = p1
pos = 0,Const(size.mid.pos.y)
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 30500, 4]
type = Pause
triggerall = PrevStateno != 5
triggerall = !IsHelper
trigger1 = time = 0
time = 38
movetime = 38

[State 30500, 5]
type = BGPalFX
triggerall = PrevStateno != 5
trigger1 = time = 0
time = 38
add = 0,0,0
mul = 128,128,128
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 30500, 5]
type = BGPalFX
trigger1 = Var(21) >= 38
time = 15
add = 0,0,0
mul = 256,256,256
sinadd = 0,0,0,1
invertall = 1
color = 256

[State 30500, 6]
type = Explod
trigger1 = Var(21) = 38
anim = 30300
ID = 30300
sprpriority = 4
postype = p1
pos = 0,0
ownpal = 1
scale = 0.5,0.5
removeongethit = 1
ignorehitpause = 0

[State 30500, 7]
type = Explod
trigger1 = Var(21) = 38
anim = 30100
ID = 30100
sprpriority = 1
postype = p1
pos = -40,0
ownpal = 1
removeongethit = 1
ignorehitpause = 0

[State 30500, 8]
type = Explod
trigger1 = Var(21) = 38
anim = 30200
ID = 30200
sprpriority = 2
postype = p1
pos = -40,5
ownpal = 1
removeongethit = 1
ignorehitpause = 0

[State 30500, 9]
type = Explod
trigger1 = Var(21) = 38
anim = 30100
ID = 30100
sprpriority = 1
postype = p1
pos = 40,0
ownpal = 1
removeongethit = 1
ignorehitpause = 0

[State 30500, 10]
type = Explod
trigger1 = Var(21) = 38
anim = 30200
ID = 30200
sprpriority = 2
postype = p1
pos = 40,5
ownpal = 1
removeongethit = 1
ignorehitpause = 0

[State 30500, 11]
type = Explod
trigger1 = Var(21) = 40
anim = 30100
ID = 30100
sprpriority = 1
postype = p1
pos = -80,0
ownpal = 1
removeongethit = 1
ignorehitpause = 0

[State 30500, 12]
type = Explod
trigger1 = Var(21) = 40
anim = 30200
ID = 30200
sprpriority = 2
postype = p1
pos = -80,5
ownpal = 1
removeongethit = 1
ignorehitpause = 0

[State 30500, 13]
type = Explod
trigger1 = Var(21) = 40
anim = 30100
ID = 30100
sprpriority = 1
postype = p1
pos = 80,0
ownpal = 1
removeongethit = 1
ignorehitpause = 0

[State 30500, 14]
type = Explod
trigger1 = Var(21) = 40
anim = 30200
ID = 30200
sprpriority = 2
postype = p1
pos = 80,5
ownpal = 1
removeongethit = 1
ignorehitpause = 0

[State 30500, 15]
type = Explod
trigger1 = Var(21) = 42
anim = 30100
ID = 30100
sprpriority = 1
postype = p1
pos = -120,0
ownpal = 1
removeongethit = 1
ignorehitpause = 0

[State 30500, 16]
type = Explod
trigger1 = Var(21) = 42
anim = 30200
ID = 30200
sprpriority = 2
postype = p1
pos = -120,5
ownpal = 1
removeongethit = 1
ignorehitpause = 0

[State 30500, 17]
type = Explod
trigger1 = Var(21) = 42
anim = 30100
ID = 30100
sprpriority = 1
postype = p1
pos = 120,0
ownpal = 1
removeongethit = 1
ignorehitpause = 0

[State 30500, 18]
type = Explod
trigger1 = Var(21) = 42
anim = 30200
ID = 30200
sprpriority = 2
postype = p1
pos = 120,5
ownpal = 1
removeongethit = 1
ignorehitpause = 0

[State 30500, 19]
type = Hitdef
trigger1 = Fvar(25) = 0
attr = S,HP
damage = 40,10
animtype = hard
hitflag = MAFD
guardflag = MA
priority = 5,Hit
pausetime = 3,6
guard.pausetime = 3,6
sparkno = s6200
guard.sparkno = s7100
sparkxy = -10,-100
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 22
ground.hittime = 27
guard.slidetime = 18
guard.hittime = 21
ground.velocity = -1.2,-12.7
guard.velocity = -2.2
air.velocity = -1.4,-12.2
airguard.velocity = -2.2,-15.5
fall = 1
air.fall = 1
fall.recover = 1
fall.recovertime = ceil(100*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 1
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10

[State 30500, 19]
type = Projectile
trigger1 = Fvar(25) != 0
trigger1 = Animelemtime(6) >= 0
trigger1 = Animelemtime(7) < 0
projanim = 30501
projhitanim = -1
projremovetime = 1
projremove = 1
projid = 30501
offset = 0,0
velocity = 0,0
accel = 0.1,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = S,HP
damage = 40,10
animtype = hard
hitflag = MAFD
guardflag = MA
priority = 5,Hit
pausetime = 3,6
guard.pausetime = 3,6
sparkno = s6200
guard.sparkno = s7100
sparkxy = -10,-100
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 22
ground.hittime = 27
guard.slidetime = 18
guard.hittime = 21
ground.velocity = -1.2,-12.7
guard.velocity = -2.2
air.velocity = -1.4,-12.2
airguard.velocity = -2.2,-15.5
fall = 1
air.fall = 1
fall.recover = 1
fall.recovertime = ceil(100*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 1
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10

[State 30500, 20]
type = VarSet
trigger1 = MoveContact
trigger2 = !IsHelper
trigger2 = ProjContactTime(30501) = 1
trigger3 = IsHelper
trigger3 = Root,ProjContactTime(30501) = 1
var(3) = 1
ignorehitpause = 1

[State 30500, 21]
type = PlaySnd
trigger1 = MoveHit
trigger2 = !IsHelper
trigger2 = ProjHitTime(30501) = 1
trigger3 = IsHelper
trigger3 = Root,ProjHitTime(30501) = 1
value = S2,2
channel = 4
ignorehitpause = 1

[State 30500, 22]
type = PlaySnd
trigger1 = MoveGuarded
trigger2 = !IsHelper
trigger2 = ProjGuardedTime(30501) = 1
trigger3 = IsHelper
trigger3 = ProjGuardedTime(30501) = 1
value = S3,2
channel = 4
ignorehitpause = 1

[State 30500, 23]
type = VarSet
trigger1 = MoveHit
trigger2 = !IsHelper
trigger2 = ProjHitTime(30501) = 1
trigger3 = IsHelper
trigger3 = Root,ProjHitTime(30501) = 1
fv = 0
value = Fvar(0)-(Fvar(0)*0.08)
ignorehitpause = 1

[State 30500, 24]
type = MoveHitReset
trigger1 = MoveContact
ignorehitpause = 1

[State 30500, 25]
type = ChangeState
trigger1 = Animtime = 0
value = 0
ctrl = 1

[State 30500, 26]
type = RemoveExplod
triggerall = NumExplod(30300) > 0
triggerall = (Var(59) = 0 && command = "IC") || (Var(59) != 0 && Var(57) = [120,199])
triggerall = Var(50) >= 1000 || Var(51) = 1
trigger1 = Var(3) = 1
ID = 30300

[State 30500, 27]
type = RemoveExplod
triggerall = NumExplod(30200) > 0
triggerall = (Var(59) = 0 && command = "IC") || (Var(59) != 0 && Var(57) = [120,199])
triggerall = Var(50) >= 1000 || Var(51) = 1
trigger1 = Var(3) = 1
ID = 30200

[State 30500, 28]
type = RemoveExplod
triggerall = NumExplod(30100) > 0
triggerall = (Var(59) = 0 && command = "IC") || (Var(59) != 0 && Var(57) = [120,199])
triggerall = Var(50) >= 1000 || Var(51) = 1
trigger1 = Var(3) = 1
ID = 30100

[State 30500, 29]
type = ChangeState
triggerall = Var(59) = 0
triggerall = Var(50) >= 1000 || Var(51) = 1
triggerall = command = "IC"
trigger1 = Var(3) = 1
value = 900

[State 30500, 30]
type = ChangeState
triggerall = Var(59) != 0
triggerall = Var(50) >= 1000 || Var(51) = 1
triggerall = Var(57) = [0,39]
trigger1 = Var(3) = 1
value = 900

;---------------------------------------------------------------------------
;メギドラオン
[Statedef 31000]
type = U
movetype = A
physics = N
ctrl = 0
sprpriority = 6

[State 31000, -1]
type = Helper
trigger1 = time = 10
helpertype = Player
name = "cutin"
ID = 9999
stateno = 9999
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 31000, 0]
type = ChangeAnim
trigger1 = time = 0
value = 31000

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

[State 31000, 2]
type = PowerAdd
triggerall = !IsHelper
triggerall = PalNo <= 10
trigger1 = time = 10
value = -3000

[State 31000, 3]
type = SuperPause
triggerall = !IsHelper
trigger1 = time = 10
time = 50
anim = -1
sound = -1
pos = 0,0
movetime = 1
darken = 0

[State 31000, 4]
type = BGPalFX
trigger1 = time = 10
time = 50
add = 0,0,0
mul = 0,0,0
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 31000, 5]
type = Explod
trigger1 = time = 10
anim = 8200
ID = 8200
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 31000, 6]
type = Explod
trigger1 = time = 10
anim = 8300
ID = 8300
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 31000, 7]
type = PlaySnd
trigger1 = time = 10
value = S5,2
channel = 7

[State 31000, 8]
type = PlaySnd
trigger1 = time = 10
value = S5,3
channel = 9

[State 31000, 9]
type = Explod
trigger1 = Anim = 31000
trigger1 = Animelem = 6
anim = 4600
ID = 4600
sprpriority = -1
postype = p1
pos = 0,Const(size.mid.pos.y)+10
ownpal = 1
bindtime = -1
removetime = -1
removeongethit = 1
ignorehitpause = 1

[State 31000, 10]
type = Explod
trigger1 = Anim = 31000
trigger1 = Animelem = 6
anim = 4700
ID = 4700
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
removeongethit = 1
ignorehitpause = 1

[State 31000, 11]
type = PlaySnd
trigger1 = Anim = 31000
trigger1 = Animelem = 6
value = S7,0
channel = 12

[State 31000, 12]
type = PlaySnd
trigger1 = Anim = 31000
trigger1 = Animelem = 6
value = S7,1
channel = 5

[State 31000, 13]
type = Helper
trigger1 = time = 12
trigger1 = Fvar(25) = 0
helpertype = normal
name = "Megidoraon"
ID = 31500
stateno = 31500
pos = 0,Floor(-500-(Pos Y))
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 31000, 13]
type = Helper
trigger1 = time = 12
trigger1 = Fvar(25) != 0
helpertype = Player
name = "Megidoraon"
ID = 31500
stateno = 31500
pos = 0,Floor(-500-(Pos Y))
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 31000, 14]
type = RemoveExplod
triggerall = NumExplod(4600) > 0
trigger1 = Fvar(20) = 0
trigger1 = time >= 240
trigger2 = Fvar(20) != 0
trigger2 = time >= 620
ID = 4600

[State 31000, 15]
type = Explod
trigger1 = Fvar(20) = 0
trigger1 = time >= 240
trigger2 = Fvar(20) != 0
trigger2 = time >= 620
anim = 4700
ID = 4700
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 31000, 16]
type = PlaySnd
trigger1 = Fvar(20) = 0
trigger1 = time >= 240
trigger2 = Fvar(20) != 0
trigger2 = time >= 620
value = S7,0
channel = 12
persistent = 0

[State 31000, 17]
type = ChangeState
triggerall = Statetype != A
trigger1 = Fvar(20) = 0
trigger1 = time >= 240
trigger2 = Fvar(20) != 0
trigger2 = time >= 620
value = 0
ctrl = 1

[State 31000, 18]
type = ChangeAnim
triggerall = Statetype = A
triggerall = Anim != 4550
trigger1 = Fvar(20) = 0
trigger1 = time >= 240
trigger2 = Fvar(20) != 0
trigger2 = time >= 620
value = 4550

[State 31000, 19]
type = VelAdd
trigger1 = Anim = 4550
y = Const(movement.yaccel)

[State 31000, 20]
type = CtrlSet
trigger1 = Anim = 4550
value = 1

[State 31000, 21]
type = NotHitBy
trigger1 = Var(41) = 1 || Var(24) >= 1
value = SCA
time = 3

[State 31000, 22]
type = ChangeState
trigger1 = Anim = 4550
trigger1 = Pos Y >= 0
value = 52

[State 31000, 23]
type = Projectile
triggerall = Fvar(20) != 0
trigger1 = time = [180,550]
trigger1 = Gametime%3 = 0
projanim = 20500
projhitanim = -1
projremovetime = 1
projremove = 1
projid = 1
offset = 0,0
velocity = 0,0
projehits = 1
projemisstime = 0
projpriority = 9999999
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = A,NP
animtype = hard
damage = 21474836
pausetime = 8,15
guard.pausetime = 10,20
hitflag = MAFPD
guardflag = 
sparkno = -1
sparkky = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 1
ground.hittime = 1
ground.velocity = 0,0
fall = 1
fall.recover = 0
getpower = 0,0
givepower = -99999999999999
p2stateno = 38533

[State 31000, 24]
type = Projectile
triggerall = Fvar(20) != 0
trigger1 = time = [180,550]
trigger1 = Gametime%3 = 1
projanim = 20500
projhitanim = -1
projremovetime = 1
projremove = 1
projid = 1
offset = 0,0
velocity = 0,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = A,SP
animtype = hard
damage = 30
pausetime = 6,9
guard.pausetime = 5,8
hitflag = MAFPD
guardflag = M
sparkno = -1
sparkky = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 10
ground.hittime = 10
ground.velocity = -2
fall = 1
fall.recover = 0
getpower = 10,0
givepower = 0,0

[State 31000, 25]
type = Reversaldef
trigger1 = Fvar(20) != 0
reversal.attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
hitflag = MAFD
sparkno = -1
sparkxy = 0,0
pausetime = 0,20
hitsound = -1
priority = 7,Hit
numhits = 0
p2stateno = 38534
ignorehitpause = 1

[State 31000, 26]
type = TargetState
triggerall = Fvar(20) != 0
trigger1 = time = [180,550]
value = 5150;38534-((RoundState>2)*33384)
ignorehitpause = 1
pausemovetime = 999999999
supermovetime = 999999999

[State 31000, 27]
type = TargetLifeAdd
trigger1 = Fvar(20) != 0
trigger1 = time = [180,550]
value = -9999999999999999999999999
absolute = 1
ignorehitpause = 1
pausemovetime = 999999999
supermovetime = 999999999

;---------------------------------------------------------------------------
;球体生成
[Statedef 31500]
type = A
movetype = A
physics = N
ctrl = 0
sprpriority = 5

[State 31500, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 31500, 0]
type = ChangeAnim
trigger1 = time = 0
value = 999

[State 31500, 1]
type = VelSet
trigger1 = time = 0
y = 4

[State 31500, 2]
type = Helper
trigger1 = time = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "Ball"
ID = 31800
stateno = 31800
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 31500, 3]
type = Helper
trigger1 = time = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "Ball"
ID = 31850
stateno = 31850
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 31500, 4]
type = Helper
trigger1 = time = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "Ball"
ID = 31800
stateno = 31800
pos = 200,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 31500, 5]
type = Helper
trigger1 = time = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "Ball"
ID = 31850
stateno = 31850
pos = -200,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 31500, 2]
type = Helper
trigger1 = time = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "Ball"
ID = 31800
stateno = 31800
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 31500, 3]
type = Helper
trigger1 = time = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "Ball"
ID = 31850
stateno = 31850
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 31500, 4]
type = Helper
trigger1 = time = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "Ball"
ID = 31800
stateno = 31800
pos = 200,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 31500, 5]
type = Helper
trigger1 = time = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "Ball"
ID = 31850
stateno = 31850
pos = -200,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 31500, 6]
type = ChangeState
trigger1 = time > 0
trigger1 = NumHelper(31800) = 0
trigger1 = NumHelper(31850) = 0
value = 31600

[State 31500, 6]
type = ChangeState
trigger1 = time > 120
value = 31600

;---------------------------------------------------------------------------
;爆発
[Statedef 31600]
type = A
movetype = A
physics = N
ctrl = 0
sprpriority = 5

[State 31600, -1]
type = PosSet
trigger1 = 1
y = 0

[State 31600, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 31600, 0]
type = ChangeAnim
trigger1 = time = 0
value = 20500

[State 31600, 1]
type = VarSet
trigger1 = time = 0
var(1) = 0
ignorehitpause = 1

[State 31600, 2]
type = VarAdd
trigger1 = Var(2) = 0
var(1) = 10
ignorehitpause = 1

[State 31600, 3]
type = VarAdd
trigger1 = Var(2) = 1
var(1) = -10
ignorehitpause = 1

[State 31600, 4]
type = VarSet
trigger1 = Var(1) < 0
var(1) = 0
ignorehitpause = 1

[State 31600, 5]
type = VarSet
trigger1 = Var(1) > 256
var(1) = 256
ignorehitpause = 1

[State 31600, 6]
type = VarSet
trigger1 = Var(1) <= 0
trigger1 = Var(3) = 0
var(2) = 0
ignorehitpause = 1

[State 31600, 7]
type = VarSet
trigger1 = Var(1) >= 256
var(2) = 1
ignorehitpause = 1

[State 31600, 8]
type = VarSet
trigger1 = Var(1) >= 256
var(3) = 1
ignorehitpause = 1

[State 31600, 9]
type = VarSet
trigger1 = Var(1) <= 0
trigger1 = Var(3) = 1
var(2) = 2
ignorehitpause = 1

[State 31600, 10]
type = ALLPalFX
trigger1 = 1
time = 20
add = Var(1),Var(1),Var(1)
mul = 256,256,256
sinadd = 0,0,0,1
invertall = 0
color = 256
ignorehitpause = 1

[State 31600, 11]
type = Explod
trigger1 = Root,Fvar(20) = 0
trigger1 = Var(1) = 256
anim = 31500
ID = 31500
sprpriority = 1
postype = p1
pos = 0,0
scale = 2,2
ontop = 1
ownpal = 1
ignorehitpause = 0

[State 31600, 12]
type = PlaySnd
trigger1 = Root,Fvar(20) = 0
trigger1 = Var(1) = 256
value = S4,0
channel = 6
ignorehitpause = 1

[State 31600, 13]
type = Hitdef
trigger1 = IsHelper
trigger1 = Root,Fvar(20) = 0
trigger1 = NumExplod(31500) = 1
trigger1 = Parent,Var(19) != 1
trigger1 = Root,Fvar(25) = 0
attr = A,HA
damage = ifelse(Ceil(Parent,Fvar(0)*20)<=20,20,Ceil(Parent,Fvar(0)*20)),5
animtype = hard
hitflag = MAFD
guardflag = MA
priority = 5,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 22
ground.hittime = 27
guard.slidetime = 18
guard.hittime = 21
ground.velocity = -20.7,7.9
guard.velocity = 4.2
air.velocity = -21.6,7.7
airguard.velocity = 3.8,-4.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(83*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 1
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10

[State 31600, 13]
type = Hitdef
trigger1 = IsHelper
trigger1 = Root,Fvar(20) = 0
trigger1 = NumExplod(31500) = 1
trigger1 = Parent,Var(19) != 1
trigger1 = Root,Fvar(25) = 0
attr = A,HA
damage = ifelse(Ceil(Parent,Fvar(0)*10)<=10,10,Ceil(Parent,Fvar(0)*10)),2
animtype = hard
hitflag = MAFD
guardflag = MA
priority = 5,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 22
ground.hittime = 27
guard.slidetime = 18
guard.hittime = 21
ground.velocity = -20.7,7.9
guard.velocity = 4.2
air.velocity = -21.6,7.7
airguard.velocity = 3.8,-4.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(83*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 1
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10

[State 31600, 13]
type = Projectile
trigger1 = IsHelper
trigger1 = Root,Fvar(20) = 0
trigger1 = NumExplod(31500) = 1
trigger1 = Parent,Var(19) != 1
trigger1 = Root,Fvar(25) != 0
projanim = 20500
projhitanim = -1
projremovetime = 1
projremove = 1
projid = 31601
offset = 0,0
velocity = 0,0
accel = 0,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = A,HA
damage = ifelse(Ceil(Parent,Fvar(0)*20)<=20,20,Ceil(Parent,Fvar(0)*20)),5
animtype = hard
hitflag = MAFD
guardflag = MA
priority = 5,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 22
ground.hittime = 27
guard.slidetime = 18
guard.hittime = 21
ground.velocity = -20.7,7.9
guard.velocity = 4.2
air.velocity = -21.6,7.7
airguard.velocity = 3.8,-4.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(83*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 1
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10
p2stateno = 20300

[State 31600, 13]
type = Projectile
trigger1 = IsHelper
trigger1 = Root,Fvar(20) = 0
trigger1 = NumExplod(31500) = 1
trigger1 = Parent,Var(19) != 1
trigger1 = Root,Fvar(25) != 0
projanim = 20500
projhitanim = -1
projremovetime = 1
projremove = 1
projid = 31601
offset = 0,0
velocity = 0,0
accel = 0,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = A,HA
damage = ifelse(Ceil(Parent,Fvar(0)*10)<=10,10,Ceil(Parent,Fvar(0)*10)),2
animtype = hard
hitflag = MAFD
guardflag = MA
priority = 5,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 22
ground.hittime = 27
guard.slidetime = 18
guard.hittime = 21
ground.velocity = -20.7,7.9
guard.velocity = 4.2
air.velocity = -21.6,7.7
airguard.velocity = 3.8,-4.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(83*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 1
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10
p2stateno = 20300

[State 31600, 14]
type = Null;PlaySnd
trigger1 = MoveHit
value = S4,1
channel = 4
ignorehitpause = 1

[State 31600, 15]
type = Null;PlaySnd
trigger1 = MoveGuarded
value = S3,2
channel = 4
ignorehitpause = 1

[State 31600, 16]
type = ParentVarSet
trigger1 = MoveHit
trigger2 = IsHelper
trigger2 = Root,ProjHitTime(31601) = 1
fv = 0
value = Parent,Fvar(0)-(Parent,Fvar(0)*0.04)
ignorehitpause = 1

[State 31600, 16]
type = ParentVarSet
trigger1 = MoveGuarded
trigger1 = Parent,Var(19) <= 0
trigger2 = IsHelper
trigger2 = Root,ProjGuardedTime(31601) = 1
fv = 0
value = Parent,Fvar(0)+(Parent,Fvar(0)*0.03)
ignorehitpause = 1

[State 31600, 16]
type = ParentVarSet
trigger1 = MoveGuarded
trigger1 = Parent,Var(19) >= 2
trigger2 = IsHelper
trigger2 = Root,ProjGuardedTime(31601) = 1
fv = 0
value = Parent,Fvar(0)+(Parent,Fvar(0)*0.06)
ignorehitpause = 1

[State 31600, 17]
type = VarSet
trigger1 = Var(3) = 1
trigger1 = Var(4) = 0
var(4) = 1

[State 31600, 18]
type = VarAdd
trigger1 = MoveContact
var(4) = 1
ignorehitpause = 1

[State 31600, 19]
type = TargetState
triggerall = Root,Fvar(20) = 0
trigger1 = MoveHit
trigger1 = NumTarget > 0
trigger1 = Target,isHelper = 0
trigger1 = Target,stateno != [120,155]
value = 20300
ignorehitpause = 1

[State 31600, 20]
type = VarSet
trigger1 = time = 0
fvar(0) = 1
ignorehitpause = 1

[State 31600, 20]
type = VarAdd
trigger1 = MoveContact
trigger1 = P2Stateno != [20300,20310]
fvar(0) = 0.5
ignorehitpause = 1

[State 31600, 21]
type = AttackMulSet
trigger1 = Root,Fvar(20) = 0
value = Fvar(0)

[State 31600, 22]
type = MoveHitReset
trigger1 = MoveContact
ignorehitpause = 1

[State 31600, 23]
type = VelSet
trigger1 = 1
x = 0
y = 0

[State 31600, 24]
type = VarRandom
trigger1 = 1
v = 11
range = -1000,1000

[State 31600, 24]
type = VarRandom
trigger1 = 1
v = 12
range = -150,150

[State 31600, 25]
type = Explod
trigger1 = Root,Fvar(20) != 0
trigger1 = Var(2) > 0
trigger1 = time < 400
trigger1 = Var(11)%5 = 0
anim = 31500
ID = 31500
sprpriority = 1
postype = p1
pos = Var(12),0
scale = 2,2
ontop = 1
ownpal = 1
ignorehitpause = 1

[State 31600, 26]
type = PlaySnd
trigger1 = Root,Fvar(20) != 0
trigger1 = Var(2) > 0
trigger1 = time < 400
trigger1 = Var(11)%5 = 0
value = S2,8
channel = (Random%4)
ignorehitpause = 1

[State 31600, 27]
type = EnvShake
trigger1 = Root,Fvar(20) != 0
trigger1 = time % 5 = 0
trigger1 = time < 400 || NumExplod(31500) > 0
time  = 10
ampl  = 20
phase = 150

[State 31600, 28]
type = PlaySnd
trigger1 = Root,Fvar(20) != 0
trigger1 = time = 0
value = S7,1
channel = 6
ignorehitpause = 1

[State 31600, 29]
type = DestroySelf
trigger1 = Root,Fvar(20) = 0
trigger1 = time >= 100
trigger2 = Root,Fvar(20) != 0
trigger2 = time >= 500
ignorehitpause = 1

;---------------------------------------------------------------------------
;回転球体(＋方向)
[Statedef 31800]
type = A
movetype = A
physics = N
ctrl = 0
sprpriority = 4

[State 31800, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 31800, 0]
type = ChangeAnim
trigger1 = time = 0
trigger1 = Anim != 31200
value = 31200

[State 31800, 1]
type = VelSet
trigger1 = 1
x = 10

[State 31800, 2]
type = PosSet
trigger1 = 1
y = Parent,Pos Y

[State 31800, 3]
type = VarSet
trigger1 = 1
fvar(1) = ifelse((Pos Y)*(-1)>=200,200,(Pos Y)*(-1))

[State 31800, 4]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[State 31800, 5]
type = PosSet
trigger1 = Fvar(1) = 0
trigger1 = time > 10
x = Parent,Pos X

[State 31800, 6]
type = Hitdef
trigger1 = Root,Fvar(20) = 0
trigger1 = Root,Fvar(25) = 0
attr = A,HA
damage = 2,1
animtype = hard
hitflag = MAFD
guardflag = MA
priority = 5,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 22
ground.hittime = 27
guard.slidetime = 18
guard.hittime = 21
ground.velocity = 0,-17.9
guard.velocity = 3.2
air.velocity = 0,-17.7
airguard.velocity = 3.6,-24.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(83*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 0
guard.kill = 0

[State 31800, 7]
type = DestroySelf
trigger1 = Pos Y >= 0

[State 31800, 8]
type = ChangeState
trigger1 = ParentDist X <= -Fvar(1)
trigger1 = Fvar(1) > 0
value = 31850

;---------------------------------------------------------------------------
;回転球体(−方向)
[Statedef 31850]
type = A
movetype = A
physics = N
ctrl = 0
sprpriority = -4

[State 31850, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 31850, 0]
type = ChangeAnim
trigger1 = time = 0
trigger1 = Anim != 31200
value = 31200

[State 31850, 1]
type = VelSet
trigger1 = 1
x = -10

[State 31850, 2]
type = PosSet
trigger1 = 1
y = Parent,Pos Y

[State 31850, 3]
type = VarSet
trigger1 = 1
fvar(1) = ifelse((Pos Y)*(-1)>=200,200,(Pos Y)*(-1))

[State 31850, 4]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[State 31850, 5]
type = PosSet
trigger1 = Fvar(1) = 0
trigger1 = time > 10
x = Parent,Pos X

[State 31850, 6]
type = Hitdef
trigger1 = Root,Fvar(20) = 0
trigger1 = Root,Fvar(25) = 0
attr = A,HA
damage = 2,1
animtype = hard
hitflag = MAFD
guardflag = MA
priority = 5,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 22
ground.hittime = 27
guard.slidetime = 18
guard.hittime = 21
ground.velocity = 0,-17.9
guard.velocity = 3.2
air.velocity = 0,-17.7
airguard.velocity = 3.6,-24.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(83*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 0
guard.kill = 0

[State 31850, 7]
type = DestroySelf
trigger1 = Pos Y >= 0

[State 31850, 8]
type = ChangeState
trigger1 = ParentDist X >= Fvar(1)
trigger1 = Fvar(1) > 0
value = 31800

;---------------------------------------------------------------------------
;ガンブレイズ
[Statedef 32000]
type = S
movetype = A
physics = S
ctrl = 0

[State 32000, -1]
type = Helper
triggerall = PrevStateno != 5
trigger1 = time = 0
helpertype = Player
name = "cutin"
ID = 9999
stateno = 9999
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 32000, 0]
type = ChangeAnim
trigger1 = time = 0
value = 900

[State 32000, 1]
type = PosSet
trigger1 = time = 0
y = 0

[State 32000, 2]
type = VelSet
trigger1 = time = 0
x = 0
y = 0

[State 32000, 3]
type = PowerAdd
triggerall = !IsHelper
triggerall = PalNo <= 10
trigger1 = time = 0
value = -1000

[State 32000, 4]
type = Pause
triggerall = !IsHelper
trigger1 = time = 0
time = 50
movetime = 1

[State 32000, 5]
type = BGPalFX
trigger1 = time = 0
time = 51
add = 0,0,0
mul = 0,0,0
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 32000, 6]
type = Explod
trigger1 = time = 0
anim = 8000
ID = 8000
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 32000, 7]
type = PlaySnd
trigger1 = time = 0
value = S5,0
channel = 7

[State 32000, 8]
type = Helper
trigger1 = Fvar(25) = 0
trigger1 = Animelem = 3
helpertype = normal
name = "blaze"
ID = 32100
stateno = 32100
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
size.xscale = 2
size.yscale = 2

[State 32000, 9]
type = Projectile
trigger1 = Fvar(25) != 0
trigger1 = Animelem = 3
projanim = 32000
projhitanim = -1
projremovetime = 300
projremove = 1
projid = 32000
offset = 0,Const(size.mid.pos.y)
velocity = 0,0
accel = 0.1,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = S,HP
damage = ifelse(ceil(100*Fvar(0))<=100,100,ceil(100*Fvar(0))),60
animtype = hard
hitflag = MAFD
guardflag = MA
priority = 3,Hit
pausetime = 0,6
guard.pausetime = 0,60
sparkno = s32100
guard.sparkno = s32100
sparkxy = 0,0
hitsound = s4,0
guardsound = s4,0
ground.type = High
ground.slidetime = 22
ground.hittime = 27
guard.slidetime = 18
guard.hittime = 21
ground.velocity = -6.2,-11.4
guard.velocity = -2.2
air.velocity = -5.4,-12.2
airguard.velocity = -2.2,-15.5
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(100*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 1
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 32000, 9]
type = ChangeState
trigger1 = Animtime = 0
value = 0
ctrl = 1

[State 32000, 10]
type = ChangeState
triggerall = Var(59) = 0
trigger1 = command = "IC"
trigger1 = Var(50) >= 1000 || Var(51) = 1
trigger1 = Animelemtime(3) >= 0
value = 900

[State 32000, 11]
type = ChangeState
triggerall = Var(59) != 0
trigger1 = (Var(57) = [0,39]) || (Var(57) % 2 = 0 && Var(59) = 24)
trigger1 = Var(50) >= 1000 || Var(51) = 1
trigger1 = Animelemtime(3) >= 0
value = 900

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

;---------------------------------------------------------------------------
;火炎弾
[Statedef 32100]
type = A
movetype = A
physics = N
ctrl = 0
sprpriority = 3

[State 32100, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 32100, 0]
type = ChangeAnim
trigger1 = time = 0
value = 32000

[State 32100, 1]
type = VelAdd
trigger1 = 1
x = 0.1

[State 32100, 2]
type = Hitdef
trigger1 = 1
attr = S,HP
damage = ifelse(ceil(100*Parent,Fvar(0))<=100,100,ceil(100*Parent,Fvar(0))),60
animtype = hard
hitflag = MAFD
guardflag = MA
priority = 3,Hit
pausetime = 0,6
guard.pausetime = 0,60
sparkno = -1
guard.sparkno = -1
sparkxy = -10,-100
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 22
ground.hittime = 27
guard.slidetime = 18
guard.hittime = 21
ground.velocity = -6.2,-11.4
guard.velocity = -2.2
air.velocity = -5.4,-12.2
airguard.velocity = -2.2,-15.5
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(100*Parent,Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
guard.kill = 1
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10

[State 32100, 3]
type = ChangeState
trigger1 = MoveContact
trigger2 = MoveReversed
value = 32200

[State 32100, 4]
type = DestroySelf
trigger1 = time >= 360
trigger2 = FrontEdgeBodyDist <= -100

;---------------------------------------------------------------------------
;爆発
[Statedef 32200]
type = A
movetype = A
physics = N
ctrl = 0

[State 32200, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 32200, 0]
type = ChangeAnim
trigger1 = time = 0
value = 32100

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

[State 32200, 2]
type = PlaySnd
trigger1 = time = 0
value = S4,0
channel = 6

[State 32200, 3]
type = Explod
trigger1 = time = 0
anim = 32200
ID = 32200
sprpriority = -1
postype = p1
pos = 0,0
ownpal = 1

[State 32200, 4]
type = DestroySelf
trigger1 = Animtime = 0

;---------------------------------------------------------------------------
;セラフコート
[Statedef 33000]
type = S
movetype = A
physics = S
ctrl = 0

[State 33000, -1]
type = Helper
triggerall = PrevStateno != 5
trigger1 = time = 0
helpertype = Player
name = "cutin"
ID = 9999
stateno = 9999
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 33000, 0]
type = VarSet
trigger1 = time = 0
trigger1 = Var(24) <= 0 && Var(41) = 0
var(3) = 0

[State 33000, 0]
type = VarSet
trigger1 = time = 0
trigger1 = Var(24) >= 1 || Var(41) = 1
var(3) = 1

[State 33000, 0]
type = ChangeAnim
trigger1 = time = 0
trigger2 = NumHelper(33100) = 1
value = 33000

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

[State 33000, 2]
type = Pause
trigger1 = !IsHelper
time = 2
movetime = 2

[State 33000, 3]
type = Explod
trigger1 = time = 0
anim = 8200
ID = 8200
sprpriority = 0
postype = p1
pos = 0,Const(size.mid.pos.y)
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 33000, 4]
type = PlaySnd
trigger1 = time = 0
value = s5,2
channel = 7

[State 33000, 5]
type = PlaySnd
trigger1 = time = 0
value = s5,3
channel = 5

[State 33000, 6]
type = BGPalFX
trigger1 = time = 0
time = 50
add = 0,0,0
mul = 0,0,0
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 33000, 7]
type = BGPalFX
trigger1 = time >= 50
time = 15
add = 0,0,0
mul = 256,256,256
sinadd = 0,0,0,1
invertall = 1
color = 256

[State 33000, 8]
type = Helper
trigger1 = time = 50
trigger1 = Fvar(25) = 0
helpertype = normal
name = "barrier"
ID = 33100
stateno = 33100
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 33000, 8]
type = Helper
trigger1 = time = 50
trigger1 = Fvar(25) != 0
helpertype = Player
name = "barrier"
ID = 33100
stateno = 33100
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 33000, 9]
type = VarSet
trigger1 = Animelemtime(2) >= 0
trigger1 = Var(3) = 0
var(24) = 1

[State 33000, 10]
type = PowerAdd
triggerall = RoundState >= 2
triggerall = PalNo <= 10
trigger1 = time = 0
value = -3000

[State 33000, 11]
type = PlaySnd
trigger1 = Animelem = 3
value = S7,6
channel = 9

[State 33000, 12]
type = Explod
trigger1 = Animelem = 3
anim = 4700
ID = 4700
sprpriority = 0
postype = p1
pos = 0,Const(size.mid.pos.y)
ownpal = 1
ontop = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 33000, 13]
type = VelSet
trigger1 = 1
x = 0
y = 0

[State 33000, 14]
type = LifeAdd
;triggerall = Fvar(20) = 0
trigger1 = Var(3) = 1
trigger1 = Var(19) <= 0
trigger1 = NumHelper(33100) = 1
trigger1 = Gametime % 2 = 0
value = (Var(54)/500)+((Var(54)/1000)*Var(53))
absolute = 1

[State 33000, 14]
type = LifeAdd
;triggerall = Fvar(20) = 0
trigger1 = Var(3) = 1
trigger1 = Var(19) <= 0
trigger1 = Animelem = 3
value = (Var(54)/7)+((Var(54)/20)*Var(53))
absolute = 1

[State 33000, 14]
type = LifeAdd
;triggerall = Fvar(20) = 0
trigger1 = Var(3) = 1
trigger1 = Var(19) = 1
trigger1 = NumHelper(33100) = 1
trigger1 = Gametime % 2 = 0
value = (Var(54)/1000)+((Var(54)/1000)*Var(53))
absolute = 1

[State 33000, 14]
type = LifeAdd
;triggerall = Fvar(20) = 0
trigger1 = Var(3) = 1
trigger1 = Var(19) = 1
trigger1 = Animelem = 3
value = (Var(54)/10)+((Var(54)/20)*Var(53))
absolute = 1

[State 33000, 14]
type = LifeAdd
;triggerall = Fvar(20) = 0
trigger1 = Var(3) = 1
trigger1 = Var(19) = 2
trigger1 = NumHelper(33100) = 1
trigger1 = Gametime % 2 = 0
value = (Var(54)/300)+((Var(54)/500)*Var(53))
absolute = 1

[State 33000, 14]
type = LifeAdd
;triggerall = Fvar(20) = 0
trigger1 = Var(3) = 1
trigger1 = Var(19) = 2
trigger1 = Animelem = 3
value = (Var(54)/3)+((Var(54)/4)*Var(53))
absolute = 1

[State 33000, 14]
type = null;VarAdd
triggerall = Fvar(20) != 0
trigger1 = NumHelper(33100) = 1
trigger1 = Gametime % 2 = 0
var(17) = -1*((Var(54)/300)+((Var(54)/500)*Var(53)))

[State 33000, 14]
type = null;VarAdd
triggerall = Fvar(20) != 0
trigger1 = Animelem = 3
var(17) = -1*((Var(54)/3)+((Var(54)/4)*Var(53)))

[State 33000, 15]
type = AssertSpecial
trigger1 = RoundState < 2
flag = Intro

[State 33000, 16]
type = VarSet
triggerall = Var(59) = 24
trigger1 = Animelemtime(2) >= 0
var(41) = 1

[State 33000, 17]
type = ChangeState
triggerall = RoundState >= 2
trigger1 = Animtime = 0
value = 0
ctrl = 1

[State 33000, 18]
type = ChangeState
triggerall = RoundState < 2
trigger1 = Animtime = 0
value = 5900

;---------------------------------------------------------------------------
;バリア
[Statedef 33100]
type = A
movetype = A
physics = N
ctrl = 0
sprpriority = 5

[State 33100, 0]
type = ChangeAnim
trigger1 = time = 0
value = 33100

[State 33100, 1]
type = Trans
trigger1 = 1
trans = AddAlpha
alpha = 256-Var(1),256

[State 33100, 2]
type = VarAdd
triggerall = time >= 40
triggerall = Var(1) < 256
trigger1 = Animelemtime(7) >= 0
var(1) = 2

[State 33100, 3]
type = VarSet
trigger1 = Var(1) >= 256
var(1) = 256

[State 33100, 4]
type = DestroySelf
trigger1 = Var(1) = 256

;---------------------------------------------------------------------------
;ジャッジメント(飛び退き)
[Statedef 35000]
type = A
movetype = A
physics = N
ctrl = 0
sprpriority = 5

[State 35000, 0]
type = ChangeAnim
trigger1 = time = 0
value = 35000

[State 35000, 0]
type = Turn
trigger1 = facing = Enemynear,facing
trigger1 = time = 0

[State 35000, 1]
type = VarSet
trigger1 = time = 0
var(3) = 0

[State 35000, 1]
type = StatetypeSet
trigger1 = time > 2 && Pos Y >= 0
statetype = S

[State 35000, 2]
type = VelSet
trigger1 = Statetype != A
x = 0
y = 0

[State 35000, 3]
type = PosSet
trigger1 = Statetype != A
y = 0

[State 35000, 4]
type = Helper
trigger1 = NumHelper(35990) = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "Armor"
ID = 35990
stateno = 35990
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35000, 4]
type = Helper
trigger1 = NumHelper(35990) = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "Armor"
ID = 35990
stateno = 35990
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35000, 5]
type = VelSet
trigger1 = Statetype = A
trigger1 = time = 0
x = -4
y = -10

[State 35000, 6]
type = VelAdd
trigger1 = Statetype = A
y = Const(movement.yaccel)

[State 35000, 7]
type = VarRandom
trigger1 = 1
v = 30
range = 1,3

[State 35000, 8]
type = VarSet
trigger1 = time = 0
var(31) = 0

[State 35000, 9]
type = VarSet
trigger1 = time = 0
var(32) = 0

[State 35000, 10]
type = VarSet
trigger1 = time = 0
trigger1 = Var(33)%10 = 1
var(33) = Var(33)+1

[State 35000, 10]
type = VarSet
trigger1 = time = 0
trigger1 = Var(33)%10 = 3
trigger1 = Var(33)/10%10 = 1
var(33) = Var(33)+10

[State 35000, 10]
type = VarSet
trigger1 = time = 0
trigger1 = Var(33)%10 = 3
trigger1 = Var(33)/10%10 = 3
trigger1 = Var(33)/100%10 = 1
var(33) = Var(33)+100

[State 35000, 10]
type = VarSet
trigger1 = time = 0
trigger1 = Var(33)%10 = 3
trigger1 = Var(33)/10%10 = 3
trigger1 = Var(33)/100%10 = 3
trigger1 = Var(33)/1000%10 = 1
var(33) = Var(33)+1000

[State 35000, 10]
type = ChangeState
trigger1 = Statetype = S
trigger1 = Pos Y = 0
trigger1 = Vel Y = 0
trigger1 = Var(30) = 1
value = 35100

[State 35000, 11]
type = ChangeState
trigger1 = Statetype = S
trigger1 = Pos Y = 0
trigger1 = Vel Y = 0
trigger1 = Var(30) = 2
value = 35200

[State 35000, 12]
type = ChangeState
trigger1 = Statetype = S
trigger1 = Pos Y = 0
trigger1 = Vel Y = 0
trigger1 = Var(30) = 3
value = 35300

[State 35000, 13]
type = VarSet
trigger1 = Fvar(21) = 0
trigger1 = time = 0
trigger1 = (100*Life/Var(54)) > 20
var(49) = Life

[State 35000, 13]
type = VarSet
trigger1 = Fvar(21) = 0
trigger1 = (100*Life/Var(54)) <= 20
var(49) = Var(54)/5

;---------------------------------------------------------------------------
;発射準備(拡散型)
[Statedef 35100]
type = S
movetype = A
physics = S
ctrl = 0
sprpriority = 5

[State 35100, 0]
type = ChangeAnim
trigger1 = time = 0
value = 35100

[State 35100, 1]
type = Explod
trigger1 = timemod = 10,0
trigger1 = time < 150
anim = ifelse(facing=1,35400,35500)
ID = 35400
sprpriority = 3
postype = p1
pos = ifelse(time=0,0,0+floor(time*3)),Const(size.mid.pos.y)
ontop = 1
ownpal = 1
scale = 0.5,0.5

[State 35100, 2]
type = Explod
trigger1 = timemod = 10,0
trigger1 = time < 150
anim = ifelse(facing=1,35400,35500)
ID = 35400
sprpriority = 3
postype = p1
pos = ifelse(time=0,0,0+floor(time*2.3)),Const(size.mid.pos.y)+floor(time*0.7)
ontop = 1
ownpal = 1
scale = 0.5,0.5

[State 35100, 3]
type = Explod
trigger1 = timemod = 10,0
trigger1 = time < 150
anim = ifelse(facing=1,35400,35500)
ID = 35400
sprpriority = 3
postype = p1
pos = ifelse(time=0,0,0+floor(time*2.3)),Const(size.mid.pos.y)-floor(time*0.7)
ontop = 1
ownpal = 1
scale = 0.5,0.5

[State 35100, 4]
type = VarSet
triggerall = Var(59) = 0
triggerall = Animelemtime(2) < 0
trigger1 = command = "a"
var(30) = 1

[State 35100, 4]
type = VarSet
triggerall = Var(59) > 0
triggerall = Animelemtime(2) < 0
trigger1 = Var(57) = [0,199]
var(30) = 1

[State 35100, 4]
type = VarSet
triggerall = Var(59) = 0
triggerall = Animelemtime(2) < 0
trigger1 = command = "b"
var(30) = 2

[State 35100, 4]
type = VarSet
triggerall = Var(59) > 0
triggerall = Animelemtime(2) < 0
trigger1 = Var(57) = [200,299]
var(30) = 2

[State 35100, 4]
type = VarSet
triggerall = Var(59) = 0
triggerall = Animelemtime(2) < 0
trigger1 = command = "c"
var(30) = 3

[State 35100, 4]
type = VarSet
triggerall = Var(59) > 0
triggerall = Animelemtime(2) < 0
trigger1 = Var(57) = [300,399]
var(30) = 3

[State 35100, 5]
type = VarSet
trigger1 = time = 0
trigger2 = Var(30) != [1,3]
var(30) = 1

[State 35100, 6]
type = VarSet
triggerall = Var(59) = 0
trigger1 = command = "x"
trigger2 = command = "y"
trigger3 = command = "z"
var(31) = (command="x")+(command="y"*2)+(command="z"*3)

[State 35100, 6]
type = VarRandom
triggerall = Var(59) > 0
trigger1 = 1
v = 31
range = 1,3

[State 35100, 7]
type = VarSet
trigger1 = Var(31) != [1,3]
var(31) = 1

[State 35100, 8]
type = VarSet
trigger1 = time = 0
var(32) = 0

[State 35100, 9]
type = VarSet
triggerall = Animelemtime(3) >= 0
triggerall = RoundState < 3
trigger1 = P2Movetype = H
trigger2 = P2BodyDist X <= -15
var(32) = 1

[State 35100, 11]
type = Explod
trigger1 = NumExplod(20300) = 0
anim = 20300
ID = 20300
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)+10
ownpal = 1
bindtime = -1
removetime = -1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35100, 12]
type = Helper
trigger1 = NumHelper(35990) = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "Armor"
ID = 35990
stateno = 35990
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35100, 12]
type = Helper
trigger1 = NumHelper(35990) = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "Armor"
ID = 35990
stateno = 35990
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35100, 13]
type = Helper
trigger1 = Fvar(25) = 0
trigger1 = Animelemtime(3) >= 0
trigger1 = time <= 300
helpertype = normal
name = "wing"
ID = 35500
stateno = 35500
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
persistent = 3

[State 35100, 13]
type = Helper
trigger1 = Fvar(25) != 0
trigger1 = Animelemtime(3) >= 0
trigger1 = time <= 300
helpertype = player
name = "wing"
ID = 35500
stateno = 35500
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
persistent = 3

[State 35100, 14]
type = Explod
trigger1 = time = 0
anim = 8100
ID = 8100
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1

[State 35100, 15]
type = PlaySnd
trigger1 = time = 0
value = S5,1
channel = 7

[State 35100, 15]
type = PlaySnd
trigger1 = Animelemtime(3) = 0
value = S7,1
channel = 10

[State 35100, 16]
type = VarAdd
trigger1 = time = 0
var(3) = 1

[State 35100, 17]
type = VarSet
trigger1 = RoundState > 2
var(3) = 5

[State 35100, 17]
type = VarSet
trigger1 = RoundState > 2
var(32) = 0

[State 35100, 18]
type = ChangeState
trigger1 = Var(30) = 2
trigger1 = Animelemtime(2) = 0
trigger1 = Var(3) < 5
value = 35200

[State 35100, 18]
type = ChangeState
trigger1 = Var(30) = 3
trigger1 = Animelemtime(2) = 0
trigger1 = Var(3) < 5
value = 35300

[State 35100, 19]
type = ChangeState
trigger1 = Var(32) = 1
value = 35350

[State 35100, 18]
type = ChangeState
trigger1 = time >= 360
value = 35400

;---------------------------------------------------------------------------
;発射準備(上昇型)
[Statedef 35200]
type = S
movetype = A
physics = S
ctrl = 0
sprpriority = 5

[State 35200, 0]
type = ChangeAnim
trigger1 = time = 0
value = 35100

[State 35200, 1]
type = Explod
trigger1 = timemod = 10,0
trigger1 = time < 150
anim = ifelse(facing=1,35400,35500)
ID = 35400
sprpriority = 3
postype = p1
pos = ifelse(time=0,0,0+floor(time*3)),Const(size.mid.pos.y)-10-floor(time*1.5)
ontop = 1
ownpal = 1
scale = 0.5,0.5

[State 35200, 2]
type = VarSet
triggerall = Var(59) = 0
triggerall = Animelemtime(2) < 0
trigger1 = command = "a"
var(30) = 1

[State 35200, 2]
type = VarSet
triggerall = Var(59) > 0
triggerall = Animelemtime(2) < 0
trigger1 = Var(57) = [200,299]
var(30) = 1

[State 35200, 2]
type = VarSet
triggerall = Var(59) = 0
triggerall = Animelemtime(2) < 0
trigger1 = command = "b"
var(30) = 2

[State 35200, 2]
type = VarSet
triggerall = Var(59) > 0
triggerall = Animelemtime(2) < 0
trigger1 = Var(57) = [0,199]
var(30) = 2

[State 35200, 2]
type = VarSet
triggerall = Var(59) = 0
triggerall = Animelemtime(2) < 0
trigger1 = command = "c"
var(30) = 3

[State 35200, 2]
type = VarSet
triggerall = Var(59) > 0
triggerall = Animelemtime(2) < 0
trigger1 = Var(57) = [300,399]
var(30) = 3

[State 35200, 3]
type = VarSet
trigger1 = Var(30) != [1,3]
var(30) = 2

[State 35200, 4]
type = VarSet
triggerall = Var(59) = 0
trigger1 = command = "x"
trigger2 = command = "y"
trigger3 = command = "z"
var(31) = (command="x")+(command="y"*2)+(command="z"*3)

[State 35200, 4]
type = VarRandom
triggerall = Var(59) > 0
trigger1 = 1
v = 31
range = 1,3

[State 35200, 5]
type = VarSet
trigger1 = Var(31) != [1,3]
var(31) = 1

[State 35200, 6]
type = VarSet
trigger1 = time = 0
var(32) = 0

[State 35200, 7]
type = VarSet
triggerall = Animelemtime(3) >= 0
triggerall = RoundState < 3
trigger1 = P2Movetype = H
trigger2 = P2BodyDist X <= -15
var(32) = 1

[State 35200, 8]
type = Explod
trigger1 = NumExplod(20300) = 0
anim = 20300
ID = 20300
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)+10
ownpal = 1
bindtime = -1
removetime = -1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35200, 9]
type = Helper
trigger1 = NumHelper(35990) = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "Armor"
ID = 35990
stateno = 35990
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35200, 9]
type = Helper
trigger1 = NumHelper(35990) = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "Armor"
ID = 35990
stateno = 35990
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35200, 10]
type = Helper
trigger1 = Fvar(25) = 0
trigger1 = Animelemtime(3) >= 0
trigger1 = time <= 540
helpertype = normal
name = "wing"
ID = 35600
stateno = 35600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
persistent = 5

[State 35200, 10]
type = Helper
trigger1 = Fvar(25) != 0
trigger1 = Animelemtime(3) >= 0
trigger1 = time <= 540
helpertype = player
name = "wing"
ID = 35600
stateno = 35600
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
persistent = 5

[State 35200, 11]
type = Explod
trigger1 = time = 0
anim = 8100
ID = 8100
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1

[State 35200, 12]
type = PlaySnd
trigger1 = time = 0
value = S5,1
channel = 7

[State 35200, 12]
type = PlaySnd
trigger1 = Animelemtime(3) = 0
value = S7,1
channel = 10

[State 35200, 12]
type = VarAdd
trigger1 = time = 0
var(3) = 1

[State 35200, 13]
type = VarSet
trigger1 = RoundState > 2
var(3) = 5

[State 35200, 13]
type = VarSet
trigger1 = RoundState > 2
var(32) = 0

[State 35200, 14]
type = ChangeState
trigger1 = Var(30) = 1
trigger1 = Animelemtime(2) = 0
trigger1 = Var(3) < 5
value = 35100

[State 35200, 14]
type = ChangeState
trigger1 = Var(30) = 3
trigger1 = Animelemtime(2) = 0
trigger1 = Var(3) < 5
value = 35300

[State 35200, 15]
type = ChangeState
trigger1 = Var(32) = 1
value = 35350

[State 35200, 16]
type = ChangeState
trigger1 = time >= 600
value = 35400

;---------------------------------------------------------------------------
;発射準備(放物型)
[Statedef 35300]
type = S
movetype = A
physics = S
ctrl = 0
sprpriority = 5

[State 35300, 0]
type = ChangeAnim
trigger1 = time = 0
value = 35100

[State 35300, 1]
type = Explod
trigger1 = timemod = 10,0
trigger1 = time < 60
anim = ifelse(facing=1,35400,35500)
ID = 35400
sprpriority = 3
postype = p1
pos = ifelse(time=0,0,0+floor(time*3)),Const(size.mid.pos.y)-10-floor(time*1.2)
ontop = 1
ownpal = 1
scale = 0.5,0.5

[State 35300, 1]
type = Explod
trigger1 = timemod = 10,0
trigger1 = time >= 60
trigger1 = time < 150
anim = ifelse(facing=1,35400,35500)
ID = 35400
sprpriority = 3
postype = p1
pos = ifelse(time=0,0,0+floor(time*3)),Const(size.mid.pos.y)-10-floor(time*1.2)+floor((time-59)*2.4)
ontop = 1
ownpal = 1
scale = 0.5,0.5

[State 35300, 2]
type = VarSet
triggerall = Var(59) = 0
triggerall = Animelemtime(2) < 0
trigger1 = command = "a"
var(30) = 1

[State 35300, 2]
type = VarSet
triggerall = Var(59) > 0
triggerall = Animelemtime(2) < 0
trigger1 = Var(57) = [200,299]
var(30) = 1

[State 35300, 2]
type = VarSet
triggerall = Var(59) = 0
triggerall = Animelemtime(2) < 0
trigger1 = command = "b"
var(30) = 2

[State 35300, 2]
type = VarSet
triggerall = Var(59) > 0
triggerall = Animelemtime(2) < 0
trigger1 = Var(57) = [300,399]
var(30) = 2

[State 35300, 2]
type = VarSet
triggerall = Var(59) = 0
triggerall = Animelemtime(2) < 0
trigger1 = command = "c"
var(30) = 3

[State 35300, 2]
type = VarSet
triggerall = Var(59) > 0
triggerall = Animelemtime(2) < 0
trigger1 = Var(57) = [0,199]
var(30) = 3

[State 35300, 3]
type = VarSet
trigger1 = Var(30) != [1,3]
var(30) = 3

[State 35300, 4]
type = VarSet
triggerall = Var(59) = 0
trigger1 = command = "x"
trigger2 = command = "y"
trigger3 = command = "z"
var(31) = (command="x")+(command="y"*2)+(command="z"*3)

[State 35300, 4]
type = VarRandom
triggerall = Var(59) > 0
trigger1 = 1
v = 31
range = 1,3

[State 35300, 5]
type = VarSet
trigger1 = Var(31) != [1,3]
var(31) = 1

[State 35300, 6]
type = VarSet
trigger1 = time = 0
var(32) = 0

[State 35300, 7]
type = VarSet
triggerall = Animelemtime(3) >= 0
triggerall = RoundState < 3
trigger1 = P2Movetype = H
trigger2 = P2BodyDist X <= -15
var(32) = 1

[State 35300, 8]
type = Explod
trigger1 = NumExplod(20300) = 0
anim = 20300
ID = 20300
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)+10
ownpal = 1
bindtime = -1
removetime = -1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35300, 9]
type = Helper
trigger1 = NumHelper(35990) = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "Armor"
ID = 35990
stateno = 35990
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35300, 9]
type = Helper
trigger1 = NumHelper(35990) = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "Armor"
ID = 35990
stateno = 35990
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35300, 10]
type = Helper
trigger1 = Fvar(25) = 0
trigger1 = Animelemtime(3) >= 0
trigger1 = time <= 540
helpertype = normal
name = "wing"
ID = 35700
stateno = 35700
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
persistent = 5

[State 35300, 10]
type = Helper
trigger1 = Fvar(25) != 0
trigger1 = Animelemtime(3) >= 0
trigger1 = time <= 540
helpertype = player
name = "wing"
ID = 35700
stateno = 35700
pos = 0,Const(size.mid.pos.y)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
persistent = 5

[State 35300, 11]
type = Explod
trigger1 = time = 0
anim = 8100
ID = 8100
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1

[State 35300, 12]
type = PlaySnd
trigger1 = time = 0
value = S5,1
channel = 7

[State 35300, 12]
type = PlaySnd
trigger1 = Animelemtime(3) = 0
value = S7,1
channel = 10

[State 35300, 12]
type = VarAdd
trigger1 = time = 0
var(3) = 1

[State 35300, 13]
type = VarSet
trigger1 = RoundState > 2
var(3) = 5

[State 35300, 13]
type = VarSet
trigger1 = RoundState > 2
var(32) = 0

[State 35300, 14]
type = ChangeState
trigger1 = Var(30) = 1
trigger1 = Animelemtime(2) = 0
trigger1 = Var(3) < 5
value = 35100

[State 35300, 14]
type = ChangeState
trigger1 = Var(30) = 2
trigger1 = Animelemtime(2) = 0
trigger1 = Var(3) < 5
value = 35200

[State 35300, 15]
type = ChangeState
trigger1 = Var(32) = 1
value = 35350

[State 35300, 16]
type = ChangeState
trigger1 = time >= 600
value = 35400

;---------------------------------------------------------------------------
;暴走弾発射
[Statedef 35350]
type = S
movetype = A
physics = S
ctrl = 0

[State 35350, 0]
type = VarRandom
trigger1 = 1
v = 30
range = 0,1

[State 35350, 1]
type = VarRandom
trigger1 = 1
v = 32
range = 0,1

[State 35350, 2]
type = Helper
trigger1 = Fvar(25) = 0
trigger1 = Var(30) = 0 && Var(32) = 0
helpertype = normal
name = "wing"
ID = 35900
stateno = 35900
pos = 0,Const(size.mid.pos.y)+Var(3)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
persistent = 5

[State 35350, 2]
type = Helper
trigger1 = Fvar(25) != 0
trigger1 = Var(30) = 0 && Var(32) = 0
helpertype = player
name = "wing"
ID = 35900
stateno = 35900
pos = 0,Const(size.mid.pos.y)+Var(3)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
persistent = 5

[State 35350, 3]
type = Helper
trigger1 = Fvar(25) = 0
trigger1 = Var(30) = 1 && Var(32) = 0
helpertype = normal
name = "wing"
ID = 35950
stateno = 35950
pos = 0,Const(size.mid.pos.y)+Var(3)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
persistent = 5

[State 35350, 3]
type = Helper
trigger1 = Fvar(25) != 0
trigger1 = Var(30) = 1 && Var(32) = 0
helpertype = player
name = "wing"
ID = 35950
stateno = 35950
pos = 0,Const(size.mid.pos.y)+Var(3)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
persistent = 5

[State 35350, 4]
type = Helper
trigger1 = Fvar(25) = 0
trigger1 = Var(30) = 0 && Var(32) = 1
helpertype = normal
name = "wing"
ID = 35900
stateno = 35900
pos = 0,Const(size.mid.pos.y)+Var(3)
postype = p1
facing = -1
keyctrl = 0
ownpal = 1
persistent = 5

[State 35350, 4]
type = Helper
trigger1 = Fvar(25) != 0
trigger1 = Var(30) = 0 && Var(32) = 1
helpertype = player
name = "wing"
ID = 35900
stateno = 35900
pos = 0,Const(size.mid.pos.y)+Var(3)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
persistent = 5

[State 35350, 5]
type = Helper
trigger1 = Fvar(25) = 0
trigger1 = Var(30) = 1 && Var(32) = 1
helpertype = normal
name = "wing"
ID = 35950
stateno = 35950
pos = 0,Const(size.mid.pos.y)+Var(3)
postype = p1
facing = -1
keyctrl = 0
ownpal = 1
persistent = 5

[State 35350, 5]
type = Helper
trigger1 = Fvar(25) != 0
trigger1 = Var(30) = 1 && Var(32) = 1
helpertype = player
name = "wing"
ID = 35950
stateno = 35950
pos = 0,Const(size.mid.pos.y)+Var(3)
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
persistent = 5

[State 35350, 6]
type = Helper
trigger1 = NumHelper(35990) = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "Armor"
ID = 35990
stateno = 35990
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35350, 6]
type = Helper
trigger1 = NumHelper(35990) = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "Armor"
ID = 35990
stateno = 35990
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35350, 7]
type = VarSet
triggerall = Var(59) = 0
trigger1 = command = "x"
trigger2 = command = "y"
trigger3 = command = "z"
var(31) = (command="x")+(command="y"*2)+(command="z"*3)

[State 35350, 7]
type = VarRandom
triggerall = Var(59) > 0
trigger1 = 1
v = 31
range = 1,3

[State 35350, 7]
type = VarRandom
trigger1 = 1
v = 3
range = -200,20

[State 35350, 8]
type = VarSet
trigger1 = Var(31) != [1,3]
var(31) = 1

[State 35350, 9]
type = ChangeState
trigger1 = time >= 400
trigger1 = Var(19) <= 0
value = 35400

[State 35350, 9]
type = ChangeState
trigger1 = time >= 200
trigger1 = Var(19) = 1
value = 35400

[State 35350, 9]
type = ChangeState
trigger1 = time >= 800
trigger1 = Var(19) >= 2
value = 35400

;---------------------------------------------------------------------------
;ジャッジメント終了
[Statedef 35400]
type = S
movetype = A
physics = S
ctrl = 0

[State 35400, 0]
type = ChangeAnim
trigger1 = time = 0
value = 35200

[State 35400, 1]
type = RemoveExplod
trigger1 = NumExplod(20300) > 0
ID = 20300

[State 35400, 2]
type = VarRangeSet
trigger1 = time = 0
first = 30
last = 32
value = 0

[State 35400, 3]
type = VarSet
trigger1 = time = 0
trigger1 = Var(33)%10 = 2
var(33) = Var(33)+1

[State 35400, 4]
type = VarSet
trigger1 = time = 0
trigger1 = Var(33)/10%10 = 2
var(33) = Var(33)+10

[State 35400, 5]
type = VarSet
trigger1 = time = 0
trigger1 = Var(33)/100%10 = 2
var(33) = Var(33)+100

[State 35400, 6]
type = VarSet
trigger1 = time = 0
trigger1 = Var(33)/1000%10 = 2
var(33) = Var(33)+1000

[State 35400, 7]
type = ChangeState
trigger1 = Animtime = 0
value = 0
ctrl = 1

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

;---------------------------------------------------------------------------
;拡散型
[Statedef 35500]
type = A
movetype = A
physics = N
ctrl = 0

[State 35500, -1]
type = ChangeState
trigger1 = !IsHelper
value = 53
ctrl = 1

[State 35500, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35500, 0]
type = ChangeAnim
trigger1 = Anim != 4800 && Anim != 4900
trigger1 = Gametime % 2 = 0
value = 4800

[State 35500, 1]
type = ChangeAnim
trigger1 = Anim != 4800 && Anim != 4900
trigger1 = Gametime % 2 = 1
value = 4900

[State 35500, 2]
type = VelSet
trigger1 = 1
x = 10
y = Var(1)

[State 35500, 3]
type = VarRandom
trigger1 = time = 0
v = 1
range = -4,4

[State 35500, 4]
type = VarAdd
trigger1 = 1
var(2) = 1

[State 35500, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(31) = 1
attr = A,HA
damage = ifelse(ceil(20*Parent,Fvar(0))<=10,10,ceil(20*Parent,Fvar(0))),1
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 1
guard.kill = 1
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)

[State 35500, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(31) = 2
attr = A,HP
damage = ifelse(ceil(20*Parent,Fvar(0))<=10,10,ceil(20*Parent,Fvar(0))),1
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 1
guard.kill = 1
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)

[State 35500, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(31) = 3
attr = A,HT
damage = ifelse(ceil(20*Parent,Fvar(0))<=10,10,ceil(20*Parent,Fvar(0))),1
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 1
guard.kill = 1
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)

[State 35500, 6]
type = ParentVarSet
trigger1 = MoveHit
fv = 0
value = Parent,Fvar(0)-(Parent,Fvar(0)*0.07)

[State 35500, 6]
type = ParentVarSet
trigger1 = MoveGuarded
trigger1 = Parent,Var(19) != 1
fv = 0
value = Parent,Fvar(0)+(Parent,Fvar(0)*0.05)

[State 35500, 7]
type = ParentVarSet
trigger1 = MoveHit
var(16) = 10
ignorehitpause = 1

[State 35500, 8]
type = ParentVarSet
trigger1 = MoveGuarded
var(16) = 10000
ignorehitpause = 1

[State 35500, 9]
type = TargetState
trigger1 = MoveHit
trigger1 = NumTarget > 0
trigger1 = Target,isHelper = 0
trigger1 = Target,stateno != [120,155]
value = 35973+(Root,Fvar(20)!=0)

[State 35500, 10]
type = ParentVarSet
trigger1 = MoveContact
var(32) = 1

[State 35500, 11]
type = MoveHitReset
trigger1 = MoveContact

[State 35500, 12]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[State 35500, 13]
type = ChangeState
trigger1 = Parent,Var(32) = 1
value = 35900

[State 35500, 14]
type = DestroySelf
trigger1 = Var(2) >= 80
trigger2 = FrontEdgeBodydist <= -50
trigger3 = Parent,Stateno = 35400

;---------------------------------------------------------------------------
;上昇型
[Statedef 35600]
type = A
movetype = A
physics = N
ctrl = 0

[State 35600, -1]
type = ChangeState
trigger1 = !IsHelper
value = 53
ctrl = 1

[State 35600, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35600, 0]
type = ChangeAnim
trigger1 = Anim != 4800 && Anim != 4900
trigger1 = Gametime % 2 = 0
value = 4800

[State 35600, 1]
type = ChangeAnim
trigger1 = Anim != 4800 && Anim != 4900
trigger1 = Gametime % 2 = 1
value = 4900

[State 35600, 2]
type = VelSet
trigger1 = 1
x = 10
y = Fvar(1)

[State 35600, 3]
type = VarAdd
trigger1 = 1
fvar(1) = -0.4

[State 35600, 3]
type = VarSet
trigger1 = Fvar(1) <= -8
fvar(1) = -8

[State 35600, 4]
type = VarAdd
trigger1 = 1
var(2) = 1

[State 35600, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(31) = 1
attr = A,HA
damage = ifelse(ceil(20*Parent,Fvar(0))<=10,10,ceil(20*Parent,Fvar(0))),1
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 1
guard.kill = 1
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)

[State 35600, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(31) = 2
attr = A,HP
damage = ifelse(ceil(20*Parent,Fvar(0))<=10,10,ceil(20*Parent,Fvar(0))),1
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 1
guard.kill = 1
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)

[State 35600, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(31) = 3
attr = A,HT
damage = ifelse(ceil(20*Parent,Fvar(0))<=10,10,ceil(20*Parent,Fvar(0))),1
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 1
guard.kill = 1
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)

[State 35600, 6]
type = ParentVarSet
trigger1 = MoveHit
fv = 0
value = Parent,Fvar(0)-(Parent,Fvar(0)*0.07)

[State 35600, 6]
type = ParentVarSet
trigger1 = MoveGuarded
trigger1 = Parent,Var(19) != 1
fv = 0
value = Parent,Fvar(0)+(Parent,Fvar(0)*0.05)

[State 35600, 7]
type = ParentVarSet
trigger1 = MoveHit
var(16) = 10
ignorehitpause = 1

[State 35600, 8]
type = ParentVarSet
trigger1 = MoveGuarded
var(16) = 10000
ignorehitpause = 1

[State 35600, 9]
type = TargetState
trigger1 = MoveHit
trigger1 = NumTarget > 0
trigger1 = Target,isHelper = 0
trigger1 = Target,stateno != [120,155]
value = 35973+(Root,Fvar(20)!=0)

[State 35600, 10]
type = ParentVarSet
trigger1 = MoveContact
var(32) = 1

[State 35600, 11]
type = MoveHitReset
trigger1 = MoveContact

[State 35600, 12]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[State 35600, 13]
type = ChangeState
trigger1 = Parent,Var(32) = 1
value = 35900

[State 35600, 14]
type = DestroySelf
trigger1 = Var(2) >= 80
trigger2 = FrontEdgeBodydist <= -50
trigger3 = Parent,Stateno = 35400

;---------------------------------------------------------------------------
;放物型
[Statedef 35700]
type = A
movetype = A
physics = N
ctrl = 0

[State 35700, -1]
type = ChangeState
trigger1 = !IsHelper
value = 53
ctrl = 1

[State 35700, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35700, 0]
type = ChangeAnim
trigger1 = Anim != 4800 && Anim != 4900
trigger1 = Gametime % 2 = 0
value = 4800

[State 35700, 1]
type = ChangeAnim
trigger1 = Anim != 4800 && Anim != 4900
trigger1 = Gametime % 2 = 1
value = 4900

[State 35700, 2]
type = VelSet
trigger1 = 1
x = 10
y = Fvar(1)

[State 35700, 3]
type = VarAdd
trigger1 = time < 10
fvar(1) = -0.5

[State 35700, 3]
type = VarAdd
trigger1 = time > 10
fvar(1) = 0.7

[State 35700, 4]
type = VarAdd
trigger1 = 1
var(2) = 1

[State 35700, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(31) = 1
attr = A,HA
damage = ifelse(ceil(20*Parent,Fvar(0))<=10,10,ceil(20*Parent,Fvar(0))),1
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 1
guard.kill = 1
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)

[State 35700, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(31) = 2
attr = A,HP
damage = ifelse(ceil(20*Parent,Fvar(0))<=10,10,ceil(20*Parent,Fvar(0))),1
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 1
guard.kill = 1
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)

[State 35700, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(31) = 3
attr = A,HT
damage = ifelse(ceil(20*Parent,Fvar(0))<=10,10,ceil(20*Parent,Fvar(0))),1
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 1
guard.kill = 1
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)

[State 35700, 6]
type = ParentVarSet
trigger1 = MoveHit
fv = 0
value = Parent,Fvar(0)-(Parent,Fvar(0)*0.07)

[State 35700, 6]
type = ParentVarSet
trigger1 = MoveGuarded
trigger1 = Parent,Var(19) != 1
fv = 0
value = Parent,Fvar(0)+(Parent,Fvar(0)*0.05)

[State 35700, 7]
type = ParentVarSet
trigger1 = MoveHit
var(16) = 10
ignorehitpause = 1

[State 35700, 8]
type = ParentVarSet
trigger1 = MoveGuarded
var(16) = 10000
ignorehitpause = 1

[State 35700, 9]
type = TargetState
trigger1 = MoveHit
trigger1 = NumTarget > 0
trigger1 = Target,isHelper = 0
trigger1 = Target,stateno != [120,155]
value = 35973+(Root,Fvar(20)!=0)

[State 35700, 10]
type = ParentVarSet
trigger1 = MoveContact
var(32) = 1

[State 35700, 11]
type = MoveHitReset
trigger1 = MoveContact

[State 35700, 12]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[State 35700, 13]
type = ChangeState
trigger1 = Parent,Var(32) = 1
value = 35900

[State 35700, 14]
type = DestroySelf
trigger1 = Var(2) >= 80
trigger2 = FrontEdgeBodydist <= -50
trigger3 = Parent,Stateno = 35400

;---------------------------------------------------------------------------
;暴走(下降)
[Statedef 35900]
type = A
movetype = A
physics = N
ctrl = 0

[State 35900, -1]
type = ChangeState
trigger1 = !IsHelper
value = 53
ctrl = 1

[State 35900, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35900, 0]
type = ChangeAnim
trigger1 = time = 0
trigger1 = Gametime % 2 = 0
trigger1 = Anim != 4800 && Anim != 4900
value = 4800

[State 35900, 1]
type = ChangeAnim
trigger1 = time = 0
trigger1 = Gametime % 2 = 1
trigger1 = Anim != 4800 && Anim != 4900
value = 4900

[State 35900, 2]
type = VelSet
trigger1 = 1
x = Var(4)

[State 35900, 3]
type = VelSet
trigger1 = 1
y = Var(3)

[State 35900, 4]
type = VarRandom
trigger1 = time = 0
trigger2 = time%20 = 0
v = 3
range = 1,10

[State 35900, 4]
type = VarRandom
trigger1 = time = 0
trigger2 = time%20 = 0
v = 4
range = -10,10

[State 35900, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(31) = 1
attr = A,HA
damage = ifelse(ceil(20*Parent,Fvar(0))<=10,10,ceil(20*Parent,Fvar(0))),1
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 1
guard.kill = 1
persistent = 5
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)

[State 35900, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(31) = 2
attr = A,HP
damage = ifelse(ceil(20*Parent,Fvar(0))<=10,10,ceil(20*Parent,Fvar(0))),1
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 1
guard.kill = 1
persistent = 5
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)

[State 35900, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(31) = 3
attr = A,HT
damage = ifelse(ceil(20*Parent,Fvar(0))<=10,10,ceil(20*Parent,Fvar(0))),1
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 1
guard.kill = 1
persistent = 5
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)

[State 35900, 6]
type = ParentVarSet
trigger1 = MoveHit
fv = 0
value = Parent,Fvar(0)-(Parent,Fvar(0)*0.07)

[State 35900, 6]
type = ParentVarSet
trigger1 = MoveGuarded
trigger1 = Parent,Var(19) != 1
fv = 0
value = Parent,Fvar(0)+(Parent,Fvar(0)*0.05)

[State 35900, 7]
type = ParentVarSet
trigger1 = MoveHit
var(16) = 10
ignorehitpause = 1

[State 35900, 8]
type = ParentVarSet
trigger1 = MoveGuarded
var(16) = 10000
ignorehitpause = 1

[State 35900, 9]
type = TargetState
trigger1 = MoveHit
trigger1 = NumTarget > 0
trigger1 = Target,isHelper = 0
trigger1 = Target,stateno != [120,155]
value = 35973+(Root,Fvar(20)!=0)

[State 35900, 10]
type = MoveHitReset
trigger1 = MoveContact

[State 35900, 11]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[State 35900, 12]
type = VarAdd
trigger1 = 1
var(2) = 1

[State 35900, 13]
type = null;Turn
triggerall = Var(2) <= 80
trigger1 = FrontEdgeBodyDist < 0
trigger2 = BackEdgeBodyDist < 0

[State 35900, 14]
type = ChangeState
trigger1 = Pos Y >= 0
trigger1 = Var(2) <= 80
value = 35950

[State 35900, 15]
type = DestroySelf
trigger1 = Var(2) >= 100
trigger2 = Parent,Stateno = 35400

;---------------------------------------------------------------------------
;暴走(上昇)
[Statedef 35950]
type = A
movetype = A
physics = N
ctrl = 0

[State 35950, -1]
type = ChangeState
trigger1 = !IsHelper
value = 53
ctrl = 1

[State 35950, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35950, 0]
type = ChangeAnim
trigger1 = time = 0
trigger1 = Gametime % 2 = 0
trigger1 = Anim != 4800 && Anim != 4900
value = 4800

[State 35950, 1]
type = ChangeAnim
trigger1 = time = 0
trigger1 = Gametime % 2 = 1
trigger1 = Anim != 4800 && Anim != 4900
value = 4900

[State 35950, 2]
type = VelSet
trigger1 = 1
x = Var(4)

[State 35950, 3]
type = VelSet
trigger1 = 1
y = Var(3)

[State 35950, 4]
type = VarRandom
trigger1 = time = 0
trigger2 = time%20 = 0
v = 3
range = -10,-1

[State 35900, 4]
type = VarRandom
trigger1 = time = 0
trigger2 = time%20 = 0
v = 4
range = -10,10

[State 35950, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(31) = 1
attr = A,HA
damage = ifelse(ceil(20*Parent,Fvar(0))<=10,10,ceil(20*Parent,Fvar(0))),1
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 1
guard.kill = 1
persistent = 5
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)

[State 35950, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(31) = 2
attr = A,HP
damage = ifelse(ceil(20*Parent,Fvar(0))<=10,10,ceil(20*Parent,Fvar(0))),1
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 1
guard.kill = 1
persistent = 5
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)

[State 35950, 5]
type = Hitdef
trigger1 = IsHelper
trigger1 = Parent,Var(31) = 3
attr = A,HT
damage = ifelse(ceil(20*Parent,Fvar(0))<=10,10,ceil(20*Parent,Fvar(0))),1
animtype = Hard
hitflag = MAFD
guardflag = MA
priority = 7,Hit
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -1.8,-4.4
guard.velocity = -2.6
air.velocity = -1.8,-4.8
airguard.velocity = -2.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 1
guard.kill = 1
persistent = 5
givepower = ifelse((Parent,Var(19)=1),0,-100000000),ifelse((Parent,Var(19)=1),0,-100000000)

[State 35950, 6]
type = ParentVarSet
trigger1 = MoveHit
fv = 0
value = Parent,Fvar(0)-(Parent,Fvar(0)*0.07)

[State 35950, 6]
type = ParentVarSet
trigger1 = MoveGuarded
trigger1 = Parent,Var(19) != 1
fv = 0
value = Parent,Fvar(0)+(Parent,Fvar(0)*0.05)

[State 35950, 7]
type = ParentVarSet
trigger1 = MoveHit
var(16) = 10
ignorehitpause = 1

[State 35950, 8]
type = ParentVarSet
trigger1 = MoveGuarded
var(16) = 10000
ignorehitpause = 1

[State 35950, 9]
type = TargetState
trigger1 = MoveHit
trigger1 = NumTarget > 0
trigger1 = Target,isHelper = 0
trigger1 = Target,stateno != [120,155]
value = 35973+(Root,Fvar(20)!=0)

[State 35950, 10]
type = MoveHitReset
trigger1 = MoveContact

[State 35950, 11]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[State 35950, 12]
type = VarAdd
trigger1 = 1
var(2) = 1

[State 35950, 13]
type = null;Turn
triggerall = Var(2) <= 80
trigger1 = FrontEdgeBodyDist < 0
trigger2 = BackEdgeBodyDist < 0

[State 35950, 14]
type = ChangeState
trigger1 = ScreenPos Y <= 0
trigger1 = Var(2) <= 80
value = 35900

[State 35950, 15]
type = DestroySelf
trigger1 = Var(2) >= 100
trigger2 = Parent,Stateno = 35400

;---------------------------------------------------------------------------
;やられステート
[Statedef 35973]
type = A
movetype = H
physics = N
ctrl = 0

[State 35973, 0]
type = ChangeAnim2
trigger1 = time = 0
value = 35973

[State 35973, 0]
type = ChangeAnim2
trigger1 = time >= 40
trigger1 = Anim = 35973
value = 5670

[State 35973, 1]
type = LifeSet
trigger1 = Life <= 10
value = 0

[State 35973, 2]
type = VelSet
trigger1 = time = 0
trigger2 = Anim = 5670
trigger2 = Animelemtime(6) >= 0
trigger2 = Pos Y >= 0
x = 0
y = 0

[State 35973, 3]
type = VelSet
trigger1 = time = 40
x = -6
y = -20*Const(movement.yaccel)

[State 35973, 4]
type = VelAdd
trigger1 = time > 40
y = Const(movement.yaccel)

[State 35973, 5]
type = PosSet
trigger1 = Anim = 5670
trigger1 = Animelemtime(6) >= 0
trigger1 = Pos Y >= 0
y = 0

[State 35973, 6]
type = SelfState
trigger1 = Anim = 5670
trigger1 = Animelemtime(6) >= 0
trigger1 = Pos Y >= 0
value = 5100

;---------------------------------------------------------------------------
;やられステート
[Statedef 35974]
type = A
movetype = H
physics = N
ctrl = 0

[State 35974, 0]
type = ChangeAnim2
trigger1 = time = 0
value = 35973

[State 35974, 0]
type = ChangeAnim2
trigger1 = time >= 40
trigger1 = Anim = 35973
value = 5670

[State 35974, 1]
type = LifeAdd
trigger1 = time = 0
value = (-Random%101-Life/10)-(RoundState > 2 || !Alive || IsHelper)*LifeMax
absolute = 1

[State 35974, 1]
type = LifeSet
trigger1 = Life <= Const(Data.Life)/2
value = 0

[State 35974, 2]
type = VelSet
trigger1 = time = 0
trigger2 = Anim = 5670
trigger2 = Animelemtime(6) >= 0
trigger2 = Pos Y >= 0
x = 0
y = 0

[State 35974, 3]
type = VelSet
trigger1 = time = 40
x = -6
y = -20*Const(movement.yaccel)

[State 35974, 4]
type = VelAdd
trigger1 = time > 40
y = Const(movement.yaccel)

[State 35974, 5]
type = PosSet
trigger1 = Anim = 5670
trigger1 = Animelemtime(6) >= 0
trigger1 = Pos Y >= 0
y = 0

[State 35974, 6]
type = SelfState
trigger1 = Anim = 5670
trigger1 = Animelemtime(6) >= 0
trigger1 = Pos Y >= 0
value = 5100

[State 35974, 7]
type = ChangeState
trigger1 = !Alive
value = 38533

;---------------------------------------------------------------------------
;ハイパーアーマー
[Statedef 35990]
type = S
movetype = I
physics = S
ctrl = 0

[State 35990, -1]
type = null;NotHitBy
trigger1 = 1
value = SCA
time = -1

[State 35990, 0]
type = ChangeAnim
trigger1 = time = 0
trigger1 = Anim != 35300
value = 35300

[State 35990, 1]
type = BindtoParent
trigger1 = 1
time = -1
facing = 1
pos = 0,0

[State 35990, 2]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 35990
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35990, 3]
type = BGPalFX
trigger1 = 1
time = 5
add = 0,0,0
mul = 0,0,0
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 35990, 4]
type = PlayerPush
trigger1 = 1
value = 1

[State 35990, 5]
type = PosFreeze
trigger1 = 1
value = 1

[State 35990, 6]
type = AssertSpecial
trigger1 = 1
flag = timerfreeze
flag2 = noshadow
flag3 = noFG

[State 35990, 7]
type = Reversaldef
trigger1 = Root,Fvar(20) = 0
reversal.attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
hitflag = MAFD
sparkno = -1
sparkxy = 0,0
pausetime = 0,0
hitsound = -1
priority = 7,Hit
numhits = 0
givepower = -100000000,-100000000

[State 35990, 7]
type = Reversaldef
trigger1 = Root,Fvar(20) != 0
reversal.attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
hitflag = MAFD
sparkno = -1
sparkxy = 0,0
pausetime = 0,10
hitsound = -1
priority = 7,Hit
numhits = 0
givepower = -100000000,-100000000
p2stateno = 38533*(Enemynear,name!="Ayu Tukimiya")

[State 35990, 8]
type = Explod
trigger1 = MoveHit
anim = 7200
ID = 7200
sprpriority = 3
postype = p1
pos = 0,0
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 35990, 9]
type = PlaySnd
trigger1 = MoveHit
value = S3,3
channel = 6
ignorehitpause = 1

[State 35990, 10]
type = VarSet
triggerall = Parent,Fvar(20) != 0
trigger1 = Var(2) < P2Life
var(2) = P2Life

[State 35990, 10]
type = VarSet
triggerall = Parent,Fvar(20) != 0
trigger1 = Var(2) > P2Life
trigger2 = P2Movetype = H
trigger2 = Var(2) >= P2Life
var(3) = 1

[State 35990, 10]
type = VarSet
triggerall = Parent,Fvar(20) != 0
trigger1 = MoveHit
trigger2 = PrevStateno = 35990
trigger3 = NumHelper(35900)
trigger3 = Helper(35900),Stateno != 35900
trigger4 = NumHelper(35950)
trigger4 = Helper(35950),Stateno != 35950
trigger5 = Var(3) = 1
var(1) = 1

[State 35990, 11]
type = MoveHitReset
trigger1 = MoveContact
ignorehitpause = 1

[State 35990, 12]
type = Projectile
triggerall = Var(1) = 1
triggerall = RoundState = 2
trigger1 = time % 20 = 0
projanim = 20500
;projhitanim = -1
projremovetime = -1
projremove = 1
projid = 20500
offset = 0,0
velocity = 0,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = S,HA
animtype = hard
damage = 99999999,99999999
pausetime = 0,15
guard.pausetime = 0,20
hitflag = MAFD
sparkno = -1
sparkky = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 1
ground.hittime = 1
ground.velocity = 0,0
fall = 1
fall.recover = 0
p2stateno = 38533
getpower = 0,0
givepower = -1000000000000000000000000000000000000000
numhits = 1

[State 35990, 13]
type = TargetLifeAdd
trigger1 = Root,Fvar(20) != 0
value = -99999999999999999
absolute = 1

[State 35990, 14]
type = DestroySelf
trigger1 = Parent,Stateno != [35000,35400]

;---------------------------------------------------------------------------
;赤黒き世界への導き
[Statedef 36000]
type = S
movetype = A
physics = S
ctrl = 0

[State 36000, 0]
type = ChangeAnim
trigger1 = time = 0
value = 33000

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

[State 36000, 2]
type = PowerAdd
triggerall = PalNo <= 10
trigger1 = time = 0
value = -3000

[State 36000, 3]
type = VarSet
trigger1 = time = 0
var(50) = 0

[State 36000, 4]
type = Helper
trigger1 = Animelemtime(3) >= 0
trigger1 = NumHelper(36490) = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "HELL"
ID = 36490
stateno = 36490
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36000, 4]
type = Helper
trigger1 = Animelemtime(3) >= 0
trigger1 = NumHelper(36490) = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "HELL"
ID = 36490
stateno = 36490
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36000, 5]
type = VarSet
trigger1 = Animelemtime(3) >= 0
var(42) = 1

[State 36000, 6]
type = ChangeState
trigger1 = Animtime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
;1000000000000℃
[Statedef 36100]
type = S
movetype = A
physics = S
ctrl = 0

[State 36100, -1]
type = Helper
triggerall = PrevStateno != 5
trigger1 = time = 0
helpertype = Player
name = "cutin"
ID = 9999
stateno = 9999
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36100, 0]
type = ChangeAnim
trigger1 = time = 0
value = 36000

[State 36100, 1]
type = SuperPause
triggerall = !IsHelper
trigger1 = time = 0
time = 50
anim = -1
sound = -1
pos = 0,0
movetime = 7
darken = 0

[State 36100, 2]
type = BGPalFX
trigger1 = 1
time = 51
add = 256,0,0
mul = 256,256,256
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 36100, 3]
type = Explod
trigger1 = time = 0
anim = 8200
ID = 8200
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36100, 4]
type = Explod
trigger1 = time = 0
anim = 8300
ID = 8300
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36100, 5]
type = PlaySnd
trigger1 = time = 0
value = S5,2
channel = 7

[State 36100, 6]
type = PlaySnd
trigger1 = time = 0
value = S5,3
channel = 9

[State 36100, 7]
type = Helper
trigger1 = Animelemtime(9) >= 0
trigger1 = NumHelper(36300) = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "flame"
ID = 36300
stateno = 36300
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999
persistent = 0

[State 36100, 7]
type = Helper
trigger1 = Animelemtime(9) >= 0
trigger1 = NumHelper(36300) = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "flame"
ID = 36300
stateno = 36300
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999
persistent = 0

[State 36100, 8]
type = Explod
trigger1 = time = 0
anim = 36200
ID = 36200
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36100, 9]
type = VarRandom
trigger1 = 1
v = 3
range = -300,300

[State 36100, 10]
type = Helper
trigger1 = Animelemtime(9) >= 0
trigger1 = Gametime % 2 = 0
trigger1 = NumHelper(36300) = 1
trigger1 = Helper(36300),Anim != 36400
trigger1 = Fvar(25) = 0
helpertype = normal
name = "braze"
ID = 36250
stateno = 36250
pos = Var(3),0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36100, 10]
type = Helper
trigger1 = Animelemtime(9) >= 0
trigger1 = Gametime % 2 = 0
trigger1 = NumHelper(36300) = 1
trigger1 = Helper(36300),Anim != 36400
trigger1 = Fvar(25) != 0
helpertype = player
name = "braze"
ID = 36250
stateno = 36250
pos = Var(3),0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36100, 10]
type = Helper
trigger1 = NumHelper(36400) = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "field"
ID = 36400
stateno = 36400
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36100, 10]
type = Helper
trigger1 = NumHelper(36400) = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "field"
ID = 36400
stateno = 36400
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State -2]
type = Projectile
triggerall = Fvar(20) != 0
trigger1 = Animelemtime(9) >= 0
trigger1 = Gametime % 2 = 1
trigger1 = NumHelper(36300) = 1
trigger1 = Helper(36300),Anim != 36400
projanim = 36500
;projhitanim = -1
projremovetime = 20
projremove = 1
projid = 20500
offset = Var(3),0
velocity = 0,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = S,HA
animtype = hard
damage = 42,30
pausetime = 0,15
guard.pausetime = 0,20
hitflag = MAFD
sparkno = -1
sparkky = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 1
ground.hittime = 1
ground.velocity = 0,0
fall = 1
fall.recover = 0
p2stateno = 38533
getpower = 0,0
givepower = -1000000000000000000000000000000000000000
numhits = 1

[State 36100, 11]
type = PlaySnd
trigger1 = Animelemtime(9) >= 0
trigger1 = Gametime % 2 = 0
trigger1 = NumHelper(36300) = 1
trigger1 = Helper(36300),Anim != 36400
value = S3,4
channel = 12

[State 36100, 12]
type = ChangeState
trigger1 = time >= 100
trigger1 = NumHelper(36300) = 0
value = 36200

;---------------------------------------------------------------------------
;終了
[Statedef 36200]
type = S
movetype = A
physics = S
ctrl = 0

[State 36200, 0]
type = ChangeAnim
trigger1 = time = 0
value = 36100

[State 36200, 1]
type = VarSet
trigger1 = 1
var(42) = 0

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

[State 36200, 3]
type = ChangeState
trigger1 = Animtime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
;攻撃用
[Statedef 36250]
type = A
movetype = A
physics = N
ctrl = 0
sprpriority = 5

[State 36250, -1]
type = ChangeState
trigger1 = !IsHelper
value = 53
ctrl = 1

[State 36250, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36250, 0]
type = ChangeAnim
trigger1 = time = 0
value = 36500

[State 36250, 1]
type = Explod
trigger1 = time = 0
anim = 36300
ID = 36300
sprpriority = 3
postype = p1
pos = 0,0
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36250, 2]
type = Hitdef
trigger1 = IsHelper
trigger1 = NumHelper(36300) > 0
trigger1 = Helper(36300),Anim != 36400
attr = S,HA
damage = ceil(27*Parent,Fvar(0)),18
animtype = Hard
hitflag = MAFD
guardflag = M
priority = 3,Miss
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -5.3,-4.4
guard.velocity = -7.6
air.velocity = -5.3,-3.8
airguard.velocity = -7.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 0
guard.kill = 0
givepower = -1000000000,-1000000000
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 220,0,0
palfx.sinadd = 50,50,50,10

[State 36250, 3]
type = TargetState
trigger1 = MoveHit
trigger1 = NumTarget > 0
trigger1 = Target,isHelper = 0
trigger1 = Target,stateno != [120,155]
value = 36432

[State 36250, 3]
type = null;TargetState
trigger1 = 1
value = 38533

[State 36250, 4]
type = Helper
trigger1 = NumHelper(36251) = 0
trigger1 = MoveHit
trigger1 = Root,Fvar(25) = 0
helpertype = normal
name = "count"
ID = 36251
stateno = 36251
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36250, 5]
type = MoveHitReset
trigger1 = MoveContact

[State 36250, 6]
type = AttackDist
trigger1 = 1
value = 0

[State 36250, 7]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = timerfreeze

[State 36250, 8]
type = DestroySelf
trigger1 = Animtime = 0

;---------------------------------------------------------------------------
;攻撃用
[Statedef 36251]
type = A
movetype = A
physics = N
ctrl = 0
sprpriority = 5

[State 36251, -1]
type = ChangeState
trigger1 = !IsHelper
value = 53
ctrl = 1

[State 36251, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36251, 0]
type = ChangeAnim
trigger1 = time = 0
value = 4950

[State 36251, 1]
type = Hitdef
trigger1 = IsHelper
attr = S,HA
damage = 0,0
animtype = Hard
hitflag = MAFD
guardflag = M
priority = 3,Miss
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -5.3,-4.4
guard.velocity = -7.6
air.velocity = -5.3,-3.8
airguard.velocity = -7.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 0
guard.kill = 0
givepower = -1000000000,-1000000000
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 220,0,0
palfx.sinadd = 50,50,50,10
numhits = 0
persistent = 0

[State 36251, 3]
type = TargetState
trigger1 = MoveHit
value = 36432

[State 36251, 4]
type = MoveHitReset
trigger1 = MoveContact

[State 36251, 5]
type = AttackDist
trigger1 = 1
value = 0

[State 36251, 6]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = timerfreeze

[State 36251, 7]
type = DestroySelf
trigger1 = P2Movetype != H
trigger2 = P2Stateno = 5150

;---------------------------------------------------------------------------
;爆発用
[Statedef 36300]
type = A
movetype = A
physics = N
ctrl = 0
sprpriority = 6

[State 36300, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36300, 0]
type = ChangeAnim
trigger1 = time = 0
value = 999

[State 36300, 1]
type = VarSet
trigger1 = time = 0
var(1) = floor(Parent,Var(42)/8)

[State 36300, 2]
type = AttackDist
trigger1 = 1
value = 0

[State 36300, 3]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = timerfreeze
flag3 = invisible

[State 36300, 4]
type = BindtoParent
trigger1 = 1
time = -1
facing = 1
pos = 0,0

[State 36300, 5]
type = ChangeState
trigger1 = time >= Var(1)
value = 36350

;---------------------------------------------------------------------------
;爆発
[Statedef 36350]
type = A
movetype = A
physics = N
ctrl = 0

[State 36350, -1]
type = AllPalFX
trigger1 = 1
time = 2
add = Var(4),Var(4),Var(4)
mul = 256,256,256
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 36350, 0]
type = VarAdd
trigger1 = Var(5) = 0
trigger1 = Var(6) = 0
var(4) = -4

[State 36350, 0]
type = VarAdd
trigger1 = Var(5) = 1
trigger1 = Var(6) = 0
var(4) = 4

[State 36350, 0]
type = VarSet
trigger1 = Var(4) = -256
var(5) = 1

[State 36350, 0]
type = VarSet
trigger1 = Var(4) = 0
trigger1 = Var(5) = 1
var(6) = 1

[State 36350, 0]
type = VarSet
trigger1 = Var(4) < -256
var(4) = -256

[State 36350, 0]
type = VarSet
trigger1 = Var(4) > 0
var(4) = 0

[State 36350, 1]
type = ChangeAnim
trigger1 = Var(4) = -256
value = 36400

[State 36350, 2]
type = Projectile
trigger1 = Anim = 36400
projanim = 20500
projhitanim = -1
projremovetime = -1
projremove = 1
projid = 36450
offset = 0,0
velocity = 0,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = S,HA
animtype = hard
damage = (Parent,Var(42)),(Parent,Var(42))
pausetime = 0,15
guard.pausetime = 0,20
hitflag = MAFD
guardflag = MA
sparkno = -1
sparkky = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 130
ground.hittime = 150
ground.velocity = 0,0
fall = 1
fall.recover = 0
kill = ifelse(Animelemtime(14)<0,0,1)
guard.kill = ifelse(Animelemtime(14)<0,0,1)
getpower = 0,0
givepower = -1000000000,-1000000000
numhits = 1
p2stateno = 20301
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 220,0,0
palfx.sinadd = 50,50,50,10

[State 36350, 3]
type = AttackDist
trigger1 = 1
value = 0

[State 36350, 4]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = timerfreeze

[State 36350, 5]
type = BindtoParent
trigger1 = 1
time = -1
facing = 1
pos = 0,0

[State 36350, 6]
type = DestroySelf
trigger1 = Animtime = 0

;---------------------------------------------------------------------------
;バリア
[Statedef 36400]
type = S
movetype = A
physics = S
ctrl = 0

[State 36400, 0]
type = ChangeAnim
trigger1 = time = 0
trigger1 = Anim != 35300
value = 35300

[State 36400, 1]
type = BindtoParent
trigger1 = 1
time = -1
facing = 1
pos = 0,0

[State 36400, 2]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 36400
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36400, 3]
type = null;BGPalFX
trigger1 = 1
time = 5
add = 0,0,0
mul = 0,0,0
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 36400, 4]
type = PlayerPush
trigger1 = 1
value = 1

[State 36400, 5]
type = PosFreeze
trigger1 = 1
value = 1

[State 36400, 6]
type = AssertSpecial
trigger1 = 1
flag = timerfreeze
flag2 = noshadow
flag3 = noFG

[State 36400, 7]
type = Reversaldef
trigger1 = Root,Fvar(20) != 0
reversal.attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
hitflag = MAFD
sparkno = -1
sparkxy = 0,0
pausetime = 0,10
hitsound = -1
priority = 7,Hit
numhits = 0
givepower = -100000000,-100000000
p2stateno = 38533*(Enemynear,name!="Ayu Tukimiya")

[State 36400, 8]
type = Explod
trigger1 = MoveHit
anim = 7200
ID = 7200
sprpriority = 3
postype = p1
pos = 0,0
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36400, 9]
type = PlaySnd
trigger1 = MoveHit
value = S3,3
channel = 6
ignorehitpause = 1

[State 36400, 10]
type = MoveHitReset
trigger1 = MoveContact
ignorehitpause = 1

[State 36400, 11]
type = TargetLifeAdd
trigger1 = Root,Fvar(20) != 0
value = -99999999999999999
absolute = 1

[State 36400, 12]
type = DestroySelf
trigger1 = Parent,Stateno != [36100,36200]
trigger1 = Parent,Stateno != [36600,36700]

;---------------------------------------------------------------------------
;やられステート
[Statedef 36432]
type = A
movetype = H
physics = N
ctrl = 0

[State 36432, 0]
type = ChangeAnim2
trigger1 = time = 0
value = 36432

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

[State 36432, 2]
type = PosSet
trigger1 = 1
y = -1

[State 36432, 3]
type = ChangeState
trigger1 = !Alive
value = 20300

[State 36432, 4]
type = SelfState
trigger1 = Alive
trigger1 = time > 100
value = 0
ctrl = 1

;---------------------------------------------------------------------------
;準備用
[Statedef 36490]
type = A
movetype = I
physics = N
ctrl = 0

[State 36490, -1]
type = BindtoParent
trigger1 = 1
time = -1
facing = 1
pos = 0,0

[State 36490, 0]
type = ChangeAnim
trigger1 = time = 0
value = 999

[State 36490, 1]
type = BGPalFX
trigger1 = Root,Var(29) = 1
time = 2
add = Var(1),Var(2),Var(3)
mul = 256,256,256
sinadd = 0,0,0,0
invertall = 0
color = 256

[State 36490, 2]
type = VarSet
trigger1 = Var(1) > 256
var(1) = 256

[State 36490, 2]
type = VarSet
trigger1 = Var(2) > 256
var(2) = 256

[State 36490, 2]
type = VarSet
trigger1 = Var(3) > 256
var(3) = 256

[State 36490, 2]
type = VarSet
trigger1 = Var(1) < -256
var(1) = -256

[State 36490, 2]
type = VarSet
trigger1 = Var(2) < -256
var(2) = -256

[State 36490, 2]
type = VarSet
trigger1 = Var(3) < -256
var(3) = -256

[State 36490, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [0,99]
var(1) = 4*Var(4)

[State 36490, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [100,199]
var(1) = 8*Var(4)

[State 36490, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [200,299]
var(1) = 12*Var(4)

[State 36490, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [300,399]
var(1) = 16*Var(4)

[State 36490, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [400,499]
var(1) = 20*Var(4)

[State 36490, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [500,599]
var(1) = 24*Var(4)

[State 36490, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [600,699]
var(1) = 28*Var(4)

[State 36490, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [700,799]
var(1) = 32*Var(4)

[State 36490, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [800,899]
var(1) = 36*Var(4)

[State 36490, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [900,999]
var(1) = 40*Var(4)

[State 36490, 3]
type = VarAdd
trigger1 = Parent,Var(42) >= 1000
var(1) = 60*Var(4)

[State 36490, 4]
type = VarSet
trigger1 = Var(1) <= -256
trigger2 = time = 0
var(4) = 1

[State 36490, 4]
type = VarSet
trigger1 = Var(1) >= 256
var(4) = -1

[State 36490, 5]
type = VarSet
trigger1 = 1
var(2) = ifelse(Var(1)-256<=-256,-256,Var(1)-256)

[State 36490, 5]
type = VarSet
trigger1 = 1
var(3) = ifelse(Var(1)-256<=-256,-256,Var(1)-256)

[State 36490, 6]
type = ParentVarAdd
trigger1 = Parent,Var(42) >= 1
trigger1 = Gametime % 2 = 0
var(42) = ifelse(Var(19)=1,1,2)

[State 36490, 7]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = invisible
;flag3 = timerfreeze

[State 36490, 8]
type = Explod
trigger1 = Random%4 = 0
trigger1 = RoundState < 3
anim = 37200
ID = 37200
sprpriority = 6
postype = p1
pos = (Var(5)),-ceil(Pos Y)
ontop = 0
ownpal = 0
facing = 1
scale = 0.5,0.25
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36490, 9]
type = PalFX
trigger1 = 1
time = -1
add = 256,-256,-256
mul = 256,256,256
sinadd = 0,0,0,0
invertall = 0
color = 256

[State 36490, 10]
type = VarRandom
trigger1 = 1
v = 5
range = -40,40

[State 36490, 11]
type = DestroySelf
trigger1 = Parent,Stateno = [36100,36200]

;---------------------------------------------------------------------------
;青白き世界への導き
[Statedef 36500]
type = S
movetype = A
physics = S
ctrl = 0

[State 36500, 0]
type = ChangeAnim
trigger1 = time = 0
value = 33000

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

[State 36500, 2]
type = PowerAdd
triggerall = PalNo <= 10
trigger1 = time = 0
value = -3000

[State 36500, 3]
type = VarSet
trigger1 = time = 0
var(50) = 0

[State 36500, 4]
type = Helper
trigger1 = Animelemtime(3) >= 0
trigger1 = NumHelper(36990) = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "HELL"
ID = 36990
stateno = 36990
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36500, 4]
type = Helper
trigger1 = Animelemtime(3) >= 0
trigger1 = NumHelper(36990) = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "HELL"
ID = 36990
stateno = 36990
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36500, 5]
type = VarSet
trigger1 = Animelemtime(3) >= 0
var(42) = -1

[State 36500, 6]
type = ChangeState
trigger1 = Animtime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
;-1000000000000℃
[Statedef 36600]
type = S
movetype = A
physics = S
ctrl = 0

[State 36600, -1]
type = Helper
triggerall = PrevStateno != 5
trigger1 = time = 0
helpertype = Player
name = "cutin"
ID = 9999
stateno = 9999
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36600, 0]
type = ChangeAnim
trigger1 = time = 0
value = 36000

[State 36600, 1]
type = SuperPause
triggerall = !IsHelper
trigger1 = time = 0
time = 50
anim = -1
sound = -1
pos = 0,0
movetime = 7
darken = 0

[State 36600, 2]
type = BGPalFX
trigger1 = 1
time = 51
add = 0,0,256
mul = 256,256,256
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 36600, 3]
type = Explod
trigger1 = time = 0
anim = 8200
ID = 8200
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36600, 4]
type = Explod
trigger1 = time = 0
anim = 8300
ID = 8300
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36600, 5]
type = PlaySnd
trigger1 = time = 0
value = S5,2
channel = 7

[State 36600, 6]
type = PlaySnd
trigger1 = time = 0
value = S5,3
channel = 9

[State 36600, 7]
type = Helper
trigger1 = Animelemtime(9) >= 0
trigger1 = NumHelper(36800) = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "ice"
ID = 36800
stateno = 36800
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999
persistent = 0

[State 36600, 7]
type = Helper
trigger1 = Animelemtime(9) >= 0
trigger1 = NumHelper(36800) = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "ice"
ID = 36800
stateno = 36800
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999
persistent = 0

[State 36600, 8]
type = Explod
trigger1 = time = 0
anim = 36800
ID = 36800
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)*-1
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36600, 8]
type = Explod
trigger1 = time = 0
anim = 36900
ID = 36900
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)*-1
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36600, 9]
type = VarRandom
trigger1 = 1
v = 3
range = -300,300

[State 36600, 10]
type = Helper
trigger1 = Animelemtime(9) >= 0
trigger1 = Gametime % 2 = 0
trigger1 = NumHelper(36800) = 1
trigger1 = Helper(36800),Anim != 36700
trigger1 = Fvar(25) = 0
helpertype = normal
name = "freeze"
ID = 36750
stateno = 36750
pos = Var(3),0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36600, 10]
type = Helper
trigger1 = Animelemtime(9) >= 0
trigger1 = Gametime % 2 = 0
trigger1 = NumHelper(36800) = 1
trigger1 = Helper(36800),Anim != 36700
trigger1 = Fvar(25) != 0
helpertype = player
name = "freeze"
ID = 36750
stateno = 36750
pos = Var(3),0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36100, 10]
type = Helper
trigger1 = NumHelper(36400) = 0
trigger1 = Fvar(25) = 0
helpertype = normal
name = "field"
ID = 36400
stateno = 36400
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36100, 10]
type = Helper
trigger1 = NumHelper(36400) = 0
trigger1 = Fvar(25) != 0
helpertype = Player
name = "field"
ID = 36400
stateno = 36400
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State -2]
type = Projectile
triggerall = Fvar(20) != 0
trigger1 = Animelemtime(9) >= 0
trigger1 = Gametime % 2 = 1
trigger1 = NumHelper(36800) = 1
trigger1 = Helper(36800),Anim != 36700
projanim = 36600
;projhitanim = -1
projremovetime = 20
projremove = 1
projid = 20500
offset = Var(3),0
velocity = 0,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = S,HA
animtype = hard
damage = 42,31
pausetime = 0,15
guard.pausetime = 0,20
hitflag = MAFD
sparkno = -1
sparkky = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 1
ground.hittime = 1
ground.velocity = 0,0
fall = 1
fall.recover = 0
p2stateno = 38533
getpower = 0,0
givepower = -1000000000000000000000000000000000000000
numhits = 1

[State 36600, 11]
type = PlaySnd
trigger1 = Animelemtime(9) >= 0
trigger1 = Gametime % 2 = 0
trigger1 = NumHelper(36800) = 1
trigger1 = Helper(36800),Anim != 36700
value = S3,4
channel = 12

[State 36600, 12]
type = ChangeState
trigger1 = time >= 100
trigger1 = NumHelper(36800) = 0
value = 36700

;---------------------------------------------------------------------------
;終了
[Statedef 36700]
type = S
movetype = A
physics = S
ctrl = 0

[State 36700, 0]
type = ChangeAnim
trigger1 = time = 0
value = 36100

[State 36700, 1]
type = VarSet
trigger1 = 1
var(42) = 0

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

[State 36700, 3]
type = ChangeState
trigger1 = Animtime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
;攻撃用
[Statedef 36750]
type = A
movetype = A
physics = N
ctrl = 0
sprpriority = 5

[State 36750, -1]
type = ChangeState
trigger1 = !IsHelper
value = 53
ctrl = 1

[State 36750, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36750, 0]
type = ChangeAnim
trigger1 = time = 0
value = 36600

[State 36750, 1]
type = Hitdef
trigger1 = IsHelper
trigger1 = Helper(36800),Anim != 36700
attr = S,HA
damage = ceil(27*Parent,Fvar(0)),18
animtype = Hard
hitflag = MAFD
guardflag = M
priority = 3,Miss
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -5.3,-4.4
guard.velocity = -7.6
air.velocity = -5.3,-3.8
airguard.velocity = -7.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 0
guard.kill = 0
givepower = -1000000000,-1000000000
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10

[State 36750, 3]
type = TargetState
trigger1 = MoveHit
trigger1 = NumTarget > 0
trigger1 = Target,isHelper = 0
trigger1 = Target,stateno != [120,155]
value = 36432

[State 36750, 4]
type = Helper
trigger1 = NumHelper(36751) = 0
trigger1 = MoveHit
trigger1 = Root,Fvar(25) = 0
helpertype = normal
name = "count"
ID = 36751
stateno = 36751
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36750, 5]
type = MoveHitReset
trigger1 = MoveContact

[State 36750, 6]
type = AttackDist
trigger1 = 1
value = 0

[State 36750, 7]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = timerfreeze

[State 36750, 8]
type = DestroySelf
trigger1 = Animtime = 0

;---------------------------------------------------------------------------
;攻撃用
[Statedef 36751]
type = A
movetype = A
physics = N
ctrl = 0
sprpriority = 5

[State 36751, -1]
type = ChangeState
trigger1 = !IsHelper
value = 53
ctrl = 1

[State 36751, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36751, 0]
type = ChangeAnim
trigger1 = time = 0
value = 4950

[State 36751, 1]
type = Hitdef
trigger1 = IsHelper
attr = S,HA
damage = 0,0
animtype = Hard
hitflag = MAFD
guardflag = M
priority = 3,Miss
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -5.3,-4.4
guard.velocity = -7.6
air.velocity = -5.3,-3.8
airguard.velocity = -7.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 0
guard.kill = 0
givepower = -1000000000,-1000000000
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10
numhits = 0
persistent = 0

[State 36751, 3]
type = TargetState
trigger1 = MoveHit
value = 36432

[State 36751, 4]
type = MoveHitReset
trigger1 = MoveContact

[State 36751, 5]
type = AttackDist
trigger1 = 1
value = 0

[State 36751, 6]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = timerfreeze

[State 36751, 7]
type = DestroySelf
trigger1 = P2Movetype != H
trigger2 = P2Stateno = 5150

;---------------------------------------------------------------------------
;竜巻用
[Statedef 36800]
type = A
movetype = A
physics = N
ctrl = 0
sprpriority = 6

[State 36800, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36800, 0]
type = ChangeAnim
trigger1 = time = 0
value = 999

[State 36800, 1]
type = VarSet
trigger1 = time = 0
var(1) = floor(Parent,Var(42)/-8)

[State 36800, 2]
type = AttackDist
trigger1 = 1
value = 0

[State 36800, 3]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = timerfreeze
flag3 = invisible

[State 36800, 4]
type = BindtoParent
trigger1 = 1
time = -1
facing = 1
pos = 0,0

[State 36800, 5]
type = ChangeState
trigger1 = time >= Var(1)
value = 36850

;---------------------------------------------------------------------------
;竜巻
[Statedef 36850]
type = A
movetype = A
physics = N
ctrl = 0

[State 36850, -1]
type = AllPalFX
trigger1 = 1
time = 2
add = Var(4),Var(4),Var(4)
mul = 256,256,256
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 36850, 0]
type = VarAdd
trigger1 = Var(5) = 0
trigger1 = Var(6) = 0
var(4) = 4

[State 36850, 0]
type = VarAdd
trigger1 = Var(5) = 1
trigger1 = Var(6) = 0
var(4) = -4

[State 36850, 0]
type = VarSet
trigger1 = Var(4) = 256
var(5) = 1

[State 36850, 0]
type = VarSet
trigger1 = Var(4) = 0
trigger1 = Var(5) = 1
var(6) = 1

[State 36850, 0]
type = VarSet
trigger1 = Var(4) > 256
var(4) = 256

[State 36850, 0]
type = VarSet
trigger1 = Var(4) < 0
var(4) = 0

[State 36850, 1]
type = ChangeAnim
trigger1 = Var(4) = 256
value = 36700

[State 36850, 1]
type = Explod
trigger1 = Var(4) = 256
anim = 36800
ID = 36800
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)*-1
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36850, 1]
type = Explod
trigger1 = Var(4) = 256
anim = 36900
ID = 36900
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)*-1
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36850, 2]
type = Projectile
trigger1 = Anim = 36700
projanim = 20500
projhitanim = -1
projremovetime = -1
projremove = 1
projid = 36950
offset = 0,0
velocity = 0,0
projehits = 1
projemisstime = 0
projpriority = 7
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = S,HA
animtype = hard
damage = -1*(Parent,Var(42)),-1*(Parent,Var(42))
pausetime = 0,15
guard.pausetime = 0,20
hitflag = MAFD
guardflag = MA
sparkno = -1
sparkky = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 130
ground.hittime = 150
ground.velocity = 0,0
fall = 1
fall.recover = 0
kill = ifelse(Animelemtime(29)<0,0,1)
guard.kill = ifelse(Animelemtime(29)<0,0,1)
getpower = 0,0
givepower = -1000000000,-1000000000
numhits = 1
p2stateno = 20301
palfx.time = 200
palfx.add = 0,0,0
palfx.mul = 0,0,220
palfx.sinadd = 50,50,50,10

[State 36850, 3]
type = AttackDist
trigger1 = 1
value = 0

[State 36850, 4]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = timerfreeze

[State 36850, 5]
type = BindtoParent
trigger1 = 1
time = -1
facing = 1
pos = 0,0

[State 36850, 6]
type = DestroySelf
trigger1 = Animtime = 0

;---------------------------------------------------------------------------
;準備用
[Statedef 36990]
type = A
movetype = I
physics = N
ctrl = 0

[State 36990, -1]
type = BindtoParent
trigger1 = 1
time = -1
facing = 1
pos = 0,0

[State 36990, 0]
type = ChangeAnim
trigger1 = time = 0
value = 999

[State 36990, 1]
type = BGPalFX
trigger1 = Root,Var(29) = 1
time = 2
add = Var(1),Var(2),Var(3)
mul = 256,256,256
sinadd = 0,0,0,0
invertall = 0
color = 256

[State 36990, 2]
type = VarSet
trigger1 = Var(1) > 256
var(1) = 256

[State 36990, 2]
type = VarSet
trigger1 = Var(2) > 256
var(2) = 256

[State 36990, 2]
type = VarSet
trigger1 = Var(3) > 256
var(3) = 256

[State 36990, 2]
type = VarSet
trigger1 = Var(1) < -256
var(1) = -256

[State 36990, 2]
type = VarSet
trigger1 = Var(2) < -256
var(2) = -256

[State 36990, 2]
type = VarSet
trigger1 = Var(3) < -256
var(3) = -256

[State 36990, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [-99,0]
var(3) = 4*Var(4)

[State 36990, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [-199,-100]
var(3) = 8*Var(4)

[State 36990, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [-299,-200]
var(3) = 12*Var(4)

[State 36990, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [-399,-300]
var(3) = 16*Var(4)

[State 36990, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [-499,-400]
var(3) = 20*Var(4)

[State 36990, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [-599,-500]
var(3) = 24*Var(4)

[State 36990, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [-699,-600]
var(3) = 28*Var(4)

[State 36990, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [-799,-700]
var(3) = 32*Var(4)

[State 36990, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [-899,-800]
var(3) = 36*Var(4)

[State 36990, 3]
type = VarAdd
trigger1 = Parent,Var(42) = [-999,-900]
var(3) = 40*Var(4)

[State 36990, 3]
type = VarAdd
trigger1 = Parent,Var(42) <= -1000
var(3) = 60*Var(4)

[State 36990, 4]
type = VarSet
trigger1 = Var(3) <= -256
trigger2 = time = 0
var(4) = 1

[State 36990, 4]
type = VarSet
trigger1 = Var(3) >= 256
var(4) = -1

[State 36990, 5]
type = VarSet
trigger1 = 1
var(1) = ifelse(Var(3)-256<=-256,-256,Var(3)-256)

[State 36990, 5]
type = VarSet
trigger1 = 1
var(2) = ifelse(Var(3)-256<=-256,-256,Var(3)-256)

[State 36990, 6]
type = ParentVarAdd
trigger1 = Parent,Var(42) <= -1
trigger1 = Gametime % 2 = 0
var(42) = ifelse(Var(19)=1,-1,-2)

[State 36990, 7]
type = AssertSpecial
trigger1 = 1
flag = noshadow
flag2 = invisible
;flag3 = timerfreeze

[State 36990, 8]
type = Explod
trigger1 = Random%4 = 0
trigger1 = RoundState < 3
anim = 37200
ID = 37200
sprpriority = 6
postype = p1
pos = (Var(5)),-ceil(Pos Y)
ontop = 0
ownpal = 0
facing = 1
scale = 0.5,0.25
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 36990, 9]
type = PalFX
trigger1 = 1
time = -1
add = 0,0,256
mul = 256,256,256
sinadd = 0,0,0,0
invertall = 0
color = 256

[State 36990, 10]
type = VarRandom
trigger1 = 1
v = 5
range = -40,40

[State 36990, 11]
type = DestroySelf
trigger1 = Parent,Stateno = [36600,36700]

;---------------------------------------------------------------------------
;ブラックノヴァ
[Statedef 37000]
type = U
movetype = A
physics = N
ctrl = 0
sprpriority = 6

[State 37000, -1]
type = Helper
trigger1 = time = 10
helpertype = Player
name = "cutin"
ID = 9999
stateno = 9999
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37000, 0]
type = ChangeAnim
trigger1 = time = 0
value = 31000

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

[State 37000, 2]
type = PowerAdd
triggerall = !IsHelper
triggerall = PalNo <= 10
trigger1 = time = 10
value = -3000

[State 37000, 3]
type = SuperPause
triggerall = !IsHelper
trigger1 = time = 10
time = 50
anim = -1
sound = -1
pos = 0,0
movetime = 1
darken = 0

[State 37000, 4]
type = BGPalFX
trigger1 = time = 10
time = 50
add = 0,0,0
mul = 0,0,0
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 37000, 5]
type = Explod
trigger1 = time = 10
anim = 8200
ID = 8200
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37000, 6]
type = Explod
trigger1 = time = 10
anim = 8300
ID = 8300
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37000, 7]
type = PlaySnd
trigger1 = time = 10
value = S5,2
channel = 7

[State 37000, 8]
type = PlaySnd
trigger1 = time = 10
value = S5,3
channel = 9

[State 37000, 9]
type = Explod
trigger1 = Anim = 31000
trigger1 = Animelem = 6
anim = 4600
ID = 4600
sprpriority = -1
postype = p1
pos = 0,Const(size.mid.pos.y)+10
ownpal = 1
bindtime = -1
removetime = -1
removeongethit = 1
ignorehitpause = 1

[State 37000, 10]
type = Explod
trigger1 = Anim = 31000
trigger1 = Animelem = 6
anim = 4700
ID = 4700
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
removeongethit = 1
ignorehitpause = 1

[State 37000, 11]
type = PlaySnd
trigger1 = Anim = 31000
trigger1 = Animelem = 6
value = S7,0
channel = 12

[State 37000, 12]
type = PlaySnd
trigger1 = Anim = 31000
trigger1 = Animelem = 6
value = S7,1
channel = 5

[State 37000, 13]
type = RemoveExplod
triggerall = NumExplod(4600) > 0
trigger1 = Fvar(20) = 0
trigger1 = time >= 240
trigger2 = Fvar(20) != 0
trigger2 = time >= 620
ID = 4600

[State 37000, 14]
type = Explod
trigger1 = Fvar(20) = 0
trigger1 = time >= 240
trigger2 = Fvar(20) != 0
trigger2 = time >= 620
anim = 4700
ID = 4700
sprpriority = 3
postype = p1
pos = 0,Const(size.mid.pos.y)
ontop = 1
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 37000, 15]
type = PlaySnd
trigger1 = Fvar(20) = 0
trigger1 = time >= 240
trigger2 = Fvar(20) != 0
trigger2 = time >= 620
value = S7,0
channel = 12
persistent = 0

[State 37000, 16]
type = ChangeState
triggerall = Statetype != A
trigger1 = Fvar(20) = 0
trigger1 = time >= 240
trigger2 = Fvar(20) != 0
trigger2 = time >= 620
value = 0
ctrl = 1

[State 37000, 17]
type = ChangeAnim
triggerall = Statetype = A
triggerall = Anim != 4550
trigger1 = Fvar(20) = 0
trigger1 = time >= 240
trigger2 = Fvar(20) != 0
trigger2 = time >= 620
value = 4550

[State 37000, 18]
type = VelAdd
trigger1 = Anim = 4550
y = Const(movement.yaccel)

[State 37000, 19]
type = CtrlSet
trigger1 = Anim = 4550
value = 1

[State 37000, 20]
type = NotHitBy
trigger1 = Var(41) = 1 || Var(24) >= 1
value = SCA
time = 3

[State 37000, 21]
type = ChangeState
trigger1 = Anim = 4550
trigger1 = Pos Y >= 0
value = 52

[State 37000, 22]
type = Projectile
trigger1 = time = [180,550]
trigger1 = Gametime%3 = 0
projanim = 20500
projhitanim = -1
projremovetime = 1
projremove = 1
projid = 1
offset = 0,0
velocity = 0,0
projehits = 1
projemisstime = 0
projpriority = 9999999
projedgebound = 1000
projstagebound = 1000
projheightbound = -1000,1000
attr = A,NP
animtype = hard
damage = 9999999999999999999999
pausetime = 8,15
guard.pausetime = 10,20
hitflag = MAFPD
guardflag = 
sparkno = -1
sparkky = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 1
ground.hittime = 1
ground.velocity = 0,0
fall = 1
fall.recover = 0
getpower = 0,0
givepower = -99999999999999
p2stateno = 38533

[State 37000, 23]
type = Reversaldef
trigger1 = Fvar(20) != 0
reversal.attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
hitflag = MAFD
sparkno = -1
sparkxy = 0,0
pausetime = 0,20
hitsound = -1
priority = 7,Hit
numhits = 0
p2stateno = 38534
ignorehitpause = 1

[State 37000, 24]
type = TargetState
triggerall = Fvar(20) != 0
trigger1 = time = [180,550]
value = 32555
ignorehitpause = 1
pausemovetime = 999999999
supermovetime = 999999999

[State 37000, 24]
type = TargetLifeAdd
triggerall = Fvar(20) != 0
trigger1 = 1
value = -999999999999999999999999999
absolute = 1
ignorehitpause = 1
pausemovetime = 999999999
supermovetime = 999999999

[State 37000, 24]
type = TargetDrop
triggerall = Fvar(20) != 0
trigger1 = time = [180,550]
trigger1 = NumTarget > 6
ignorehitpause = 1

[State 37000, 25]
type = MoveHitReset
trigger1 = MoveHit
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37000, 26]
type = Helper
triggerall = !IsHelper
triggerall = Fvar(20) != 0
triggerall = NumHelper(4) < 5
triggerall = Gametime%5 = 0
trigger1 = time >= 150
helpertype = Player
name = "Clsh2"
ID = 4
stateno = 4
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37000, 26]
type = Helper
triggerall = !IsHelper
triggerall = Fvar(20) != 0
triggerall = NumHelper(4) < 5
triggerall = Gametime%5 = 1
trigger1 = time >= 150
helpertype = Player
name = "Clsh2"
ID = 4
stateno = 4
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37000, 26]
type = Helper
triggerall = !IsHelper
triggerall = Fvar(20) != 0
triggerall = NumHelper(4) < 5
triggerall = Gametime%5 = 2
trigger1 = time >= 150
helpertype = Player
name = "Clsh2"
ID = 4
stateno = 4
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37000, 26]
type = Helper
triggerall = !IsHelper
triggerall = Fvar(20) != 0
triggerall = NumHelper(4) < 5
triggerall = Gametime%5 = 3
trigger1 = time >= 150
helpertype = Player
name = "Clsh2"
ID = 4
stateno = 4
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37000, 26]
type = Helper
triggerall = !IsHelper
triggerall = Fvar(20) != 0
triggerall = NumHelper(4) < 5
triggerall = Gametime%5 = 4
trigger1 = time >= 150
helpertype = Player
name = "Clsh2"
ID = 4
stateno = 4
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37000, 27]
type = Helper
triggerall = !IsHelper
triggerall = Fvar(20) != 0
triggerall = NumHelper(5) = 0
trigger1 = time >= 150
helpertype = Player
name = "Clsh2"
ID = 5
stateno = 4
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37000, 28]
type = Helper
triggerall = !IsHelper
triggerall = Fvar(20) != 0
triggerall = NumHelper(3) = 0
trigger1 = time >= 150
helpertype = Player
name = "Clsh2"
ID = 3
stateno = 3
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37000, 29]
type = Helper
triggerall = !IsHelper
trigger1 = Anim = 31000
trigger1 = time >= 120
trigger1 = NumHelper(37100) = 0
trigger1 = time < 400
helpertype = Player
name = "BlackNova"
ID = 37100
stateno = 37100
pos = 0,ceil(-(Pos Y))
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 37000, 30]
type = Helper
triggerall = !IsHelper
trigger1 = Anim = 31000
trigger1 = Animelemtime(6) >= 0
trigger1 = time < 180
trigger1 = Var(39) = 0 || Var(40) = 0
trigger1 = NumHelper(37500) = 0
helpertype = Player
name = "Hitdef"
ID = 37500
stateno = 37500
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37100, 31]
type = EnvShake
trigger1 = Fvar(20) != 0
trigger1 = time % 5 = 0
trigger1 = NumHelper(37100)
trigger1 = time < 600
time  = 10
ampl  = 20
phase = 150

;---------------------------------------------------------------------------
;爆発
[Statedef 37100]
type = S
movetype = A
physics = N
sprpriority = -5
ctrl = 0

[State 37100, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 37100
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37100, -1]
type = NotHitBy
trigger1 = 1
value = SCA
time = -1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37100, 0]
type = ChangeAnim
trigger1 = time = 0
value = 999

[State 37100, 1]
type = Helper
triggerall = time >= 60
trigger1 = Var(3)%3 = 0
helpertype = Player
name = "bomb"
ID = 37200
stateno = 37200
pos = Var(1),ceil(-(Pos Y))
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 37100, 2]
type = Helper
triggerall = time >= 60
trigger1 = Var(3)%3 != 0
trigger1 = NumHelper(37200) > 0
helpertype = Player
name = "smoke"
ID = 37300
stateno = 37300
pos = (Var(1)+Var(2)),ceil(-(Pos Y))
postype = p1
facing = 1
keyctrl = 0
ownpal = 1

[State 37100, 1]
type = null;Explod
triggerall = time >= 60
trigger1 = Var(3)%4 = 0
anim = 37000
ID = 37000
sprpriority = 4
postype = p1
pos = Var(1),0
ontop = 0
ownpal = 1
facing = 1
bindtime = -1
;scale = 0.5,0.5

[State 37100, 2]
type = null;Explod
triggerall = time >= 60
trigger1 = Var(3)%4 != 0
trigger1 = NumExplod(37000) > 0
anim = 37100
ID = 37100
sprpriority = 6
postype = p1
pos = (Var(1)+Var(2)),0
ontop = 0
ownpal = 1
facing = 1
bindtime = -1
;scale = 0.5,0.5

[State 37100, 3]
type = PlaySnd
triggerall = time >= 60
trigger1 = Var(3)%4 = 0
value = S2,8
channel = (Random%5)
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37100, 4]
type = VarRandom
trigger1 = 1
v = 1
range = -200,200
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37100, 4]
type = VarRandom
trigger1 = 1
v = 2
range = -80,80
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37100, 5]
type = VarRandom
trigger1 = 1
v = 3
range = 0,1000
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37100, 6]
type = BGPalFX
trigger1 = 1
time = 30
add = 0,0,0
mul = Var(4),Var(4),Var(4)
sinadd = 0,0,0,1
invertall = 0
color = 256
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37100, 7]
type = VarSet
trigger1 = time = 0
var(4) = 256
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37100, 8]
type = VarAdd
trigger1 = Var(5) = 0
var(4) = -5
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37100, 9]
type = VarSet
trigger1 = Var(4) < 0
var(4) = 0
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37100, 10]
type = VarSet
trigger1 = Var(4) < 0
var(5) = 1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37100, 11]
type = DestroySelf
trigger1 = time >= 500
ignorehitpause = 1

;---------------------------------------------------------------------------
;エフェクト
[Statedef 37200]
type = A
movetype = A
physics = N
sprpriority = -5
ctrl = 0

[State 37200, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 4
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37200, 0]
type = ChangeAnim
trigger1 = time = 0
value = 37000

[State 37200, 1]
type = AngleDraw
trigger1 = 1
scale = Fvar(29),Fvar(29)

[State 37200, 2]
type = Trans
trigger1 = 1
trans = AddAlpha
alpha = 256-Var(36),256

[State 37200, 3]
type = VarSet
trigger1 = time = 0
fvar(29) = 0.5

[State 37200, 4]
type = VarAdd
trigger1 = time > 0
fvar(29) = 0.023+((time>10=1)*0.054)

[State 37200, 5]
type = VarSet
trigger1 = time = 0
var(36) = 0

[State 37200, 6]
type = VarAdd
trigger1 = time > 0
var(36) = 8+((time>10=1)*8)

[State 37200, 7]
type = VarSet
trigger1 = Var(36) > 256
var(36) = 256

[State 37200, 8]
type = DestroySelf
trigger1 = Animtime = 0

;---------------------------------------------------------------------------
;エフェクト
[Statedef 37300]
type = A
movetype = A
physics = N
sprpriority = -5
ctrl = 0

[State 37300, -1]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 4
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37300, 0]
type = ChangeAnim
trigger1 = time = 0
value = 37100

[State 37300, 1]
type = AngleDraw
trigger1 = 1
scale = Fvar(29),Fvar(29)

[State 37300, 2]
type = Trans
trigger1 = 1
trans = AddAlpha
alpha = 256-Var(36),256

[State 37300, 3]
type = VarSet
trigger1 = time = 0
fvar(29) = 0.5

[State 37300, 4]
type = VarAdd
trigger1 = time > 0
fvar(29) = 0.021

[State 37300, 5]
type = VarSet
trigger1 = time = 0
var(36) = 0

[State 37300, 6]
type = VarAdd
trigger1 = time > 0
var(36) = 8

[State 37300, 7]
type = VarSet
trigger1 = Var(36) > 256
var(36) = 256

[State 37300, 8]
type = VelSet
trigger1 = time = 0
x = (ifelse(Random%3=0,3.65,(ifelse(Random%3=1,2.89,4.57))))*ifelse(Random%2=0,1,-1)
y = (ifelse(Random%3=0,3.65,(ifelse(Random%3=1,2.89,4.57))))*-1

[State 37300, 9]
type = DestroySelf
trigger1 = Animtime = 0

;---------------------------------------------------------------------------
;hitdef
[Statedef 37500]
type = S
movetype = A
physics = N
sprpriority = -5
ctrl = 0

[State 37500, -1]
type = NotHitBy
trigger1 = 1
value = SCA
time = -1
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 37500, 0]
type = ChangeAnim
trigger1 = time = 0
value = 20500;38722

[State 37500, 1]
type = Hitdef
trigger1 = IsHelper
attr = S,HA
damage = 0,0
animtype = Hard
hitflag = MAFD
priority = 3,Miss
pausetime = 0,6
guard.pausetime = 0,6
sparkno = -1
guard.sparkno = -1
sparkxy = 0,0
hitsound = -1
guardsound = -1
ground.type = High
ground.slidetime = 14
ground.hittime = 26
guard.slidetime = 12
guard.hittime = 19
ground.velocity = -5.3,-4.4
guard.velocity = -7.6
air.velocity = -5.3,-3.8
airguard.velocity = -7.7,-5.6
fall = 1
air.fall = 1
fall.recover = 0
fall.recovertime = ceil(40*Fvar(0))
getpower = 0,0
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
kill = 0
guard.kill = 0
numhits = 0

[State 37500, 2]
type = DestroySelf
trigger1 = Root,Stateno != 37000
ignorehitpause = 1

;---------------------------------------------------------------------------
;未使用
[Statedef 99999]
type = S
movetype = A
physics = N
sprpriority = -5
ctrl = 0

[State 99999, 0]
type = ChangeAnim
trigger1 = time = 0
value = 36600

[State 99999, 1]
type = AngleDraw
trigger1 = 1
scale = Fvar(1),Fvar(2)

[State 99999, 2]
type = AngleSet
trigger1 = 1
value = 0

[State 99999, 3]
type = Trans
trigger1 = 1
trans = Add

[State 99999, 4]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[State 99999, 5]
type = NotHitBy
trigger1 = 1
time = -1
value = SCA

[State 99999, 6]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 99999
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 99999, 7]
type = VarSet
trigger1 = time = 0
trigger2 = root,command = "start"
fvar(1) = 1

[State 99999, 7]
type = VarSet
trigger1 = time = 0
trigger2 = root,command = "start"
fvar(2) = 1

[State 99999, 8]
type = VarAdd
trigger1 = root,command = "y"
fvar(1) = -0.1

[State 99999, 8]
type = VarAdd
trigger1 = root,command = "z"
fvar(2) = -0.1

[State 99999, 8]
type = VarAdd
trigger1 = root,command = "a"
fvar(1) = 0.1

[State 99999, 8]
type = VarAdd
trigger1 = root,command = "b"
fvar(2) = 0.1

[State 99999, 10]
type = DestroySelf
trigger1 = root,command = "x"

;---------------------------------------------------------------------------
;カットイン
[Statedef 9999]
type = A
physics = N
sprpriority = -5
ctrl = 0

[State 9999, 0]
type = ChangeAnim
trigger1 = time = 0
value = 999

[State 9999, 1]
type = Null;AngleDraw
trigger1 = 1
;scale = 1,1

[State 9999, 2]
type = Null;AngleSet
trigger1 = 1
value = 0

[State 9999, 3]
type = Null;Trans
trigger1 = 1
trans = Add

[State 9999, 4]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[State 9999, 5]
type = NotHitBy
trigger1 = 1
time = -1
value = SCA

[State 9999, 6]
type = HitOverRide
trigger1 = 1
time = -1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
stateno = 99999
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 9999, 7]
type = Explod
trigger1 = time = 0
trigger1 = facing = 1
anim = 99999
ID = 99999
sprpriority = -1
postype = left
pos = 0,23
ontop = 0
ownpal = 1
facing = 1
bindtime = -1
scale = 0.5,0.5
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 9999, 7]
type = Explod
trigger1 = time = 0
trigger1 = facing = -1
anim = 99999
ID = 99999
sprpriority = -1
postype = right
pos = 0,23
ontop = 0
ownpal = 1
facing = -1
bindtime = -1
scale = 0.5,0.5
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 9999, 8]
type = ModifyExplod
trigger1 = NumExplod(99999) = 1
trigger1 = time >= 32
trigger1 = facing = 1
trigger1 = Root,Fvar(9) = 2
ID = 99999
pos = 0,Var(0)
postype = left
scale = Fvar(0),Fvar(0)
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 9999, 8]
type = ModifyExplod
trigger1 = NumExplod(99999) = 1
trigger1 = time >= 32
trigger1 = facing = -1
trigger1 = Root,Fvar(9) = 2
ID = 99999
pos = 0,Var(0)
postype = right
scale = Fvar(0),Fvar(0)
ignorehitpause = 1
pausemovetime = 99999
supermovetime = 99999

[State 9999, 9]
type = VarSet
trigger1 = time = 0
fvar(0) = 0.5

[State 9999, 9]
type = VarAdd
trigger1 = time >= 32
fvar(0) = 0.06

[State 9999, 10]
type = VarSet
trigger1 = time = 0
var(0) = 23

[State 29999, 10]
type = VarAdd
trigger1 = time >= 32
var(0) = -20

[State 9999, 11]
type = RemoveExplod
trigger1 = NumExplod(99999) > 0
trigger1 = Root,Fvar(9) = 0
ID = 99999

[State 9999, 12]
type = DestroySelf
trigger1 = time > 0
trigger1 = NumExplod(99999) = 0

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