;--------------------------------------------------------------------
;基本データ
[Data]
life = 1000  ;変えちゃダメ、ゼッタイ

power = -777000  ;パワーゲージを一切使わない為無意味でゴンス
attack = 5   ;ランダムダメージなので設定変えてもほとんど意味無しでござる
defence = 2  ;どれだけ設定しても固定ダメージなので変わりませぬ
fall.defence_up = 0  ;そもそもダウンしません
liedown.time = 0
airjuggle = 99999999
sparkno = 2
guard.sparkno = 40
KO.echo = 0
volume = 240
IntPersistIndex = 59
FloatPersistIndex = 40

[Size]
xscale = 1
yscale = 1
ground.back = 10
ground.front = 10
air.back = 10
air.front = 10
height = 180
attack.dist = 320
proj.attack.dist = 320
proj.doscale = 0
head.pos = 0, -118
mid.pos = -4, -86
shadowoffset = 0
draw.offset = 0,0

[Velocity]
walk.fwd  = 20
walk.back = -13
run.fwd  = 13,0
run.back = -24,-3
jump.neu = 0,-50
jump.back = -20
jump.fwd = 20
runjump.back = -7,-8
runjump.fwd = 9,-8
airjump.neu = 0,-50
airjump.back = -13
airjump.fwd = 13

[Movement]
airjump.num = 0      
airjump.height = 0
yaccel = 10
stand.friction = 3
crouch.friction = 3
;--------------------------------------------------------------------
;通常立ち
[Statedef 0]
type = S
physics = S
sprpriority = 0

[state ]
type = selfstate
trigger1 = !ishelper
value = 5150
ctrl = 0

[State ]
type = Helper
triggerall = ishelper(0)
trigger1 = NumHelper(1) = 0
trigger1 = root,var(59)!=9999
trigger1 = root,life>0
name = "damage"
id = 1
pos = 0,0
postype = p1
sprpriority = 0
stateno = 9999
Helpertype = player
keyctrl = 0
ownpal = 1
size.ground.back = 0
size.ground.front = 0
size.air.back = 0
size.air.front = 0
supermove = 1
pausemovetime=2147483647
supermovetime=2147483647
ignorehitpause = 1

[State ]
type = Helper
triggerall = numhelper(2)=0
trigger1 = roundstate >=2&&time=0
trigger1 = root,life>0
trigger1 = root,var(59)!=9999
name = "wall"
stateno = 8888
ID = 2
helpertype = player
pos = 0,0
postype = p2
facing = 1
keyctrl = 0
ownpal = 1
supermove = 1
pausemovetime=2147483647
supermovetime=2147483647
ignorehitpause = 1

[State ]
type = Helper
triggerall = numhelper(3)=0
trigger1 = root,life>0
name = "death"
stateno = 9900
ID = 3
helpertype = player
pos = 0,0
postype = p1
facing = 1
keyctrl = 0
ownpal = 1
supermove = 1
pausemovetime=2147483647
supermovetime=2147483647
ignorehitpause = 1

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

[State ]
type = VelSet
trigger1 = (abs(Vel X) < 2)
trigger2 = Time = 4
trigger3 = (PrevStateNo = 20) && (Time = 0)
x = 0

[State ]
type = turn
trigger1 = fvar(0)<0

[State ]
type = posset
trigger1 = ishelper(0)
y = 0

[State ]
type = velset
trigger1 = 1
x = 0
y = 0

[State ]
type = changeanim
trigger1 = anim!=0
trigger1 = root,stateno!=51515
value = 0

[State ]
type = changeanim
trigger1 = anim!=4101
trigger1 = root,stateno=51515
value = 4101

[State ]
type = SelfState
triggerall = ishelper(0)
trigger1 = root,life <= 0
value = 5150

[State ]
type = SelfState
triggerall = ishelper(0)
trigger1 = roundstate = 0
trigger1 = roundno = 1
value = 190

[State ]
type = SelfState
triggerall = ishelper(0)
trigger1 = roundstate = 4
trigger1 = WIN
value = 180

[State ]
type = SelfState
triggerall = ishelper(0)
trigger1 = roundstate = 4
trigger1 = DRAWGAME
value = 175

[State ]
type = SelfState
triggerall = ishelper(0)
trigger1 = roundstate = 4
trigger1 = LOSE
trigger1 = life>0 ;alive
trigger1 = !loseko
value = 170

[State ]
type = DestroySelf
trigger1 = root,var(59)=9999
trigger1 = roundstate=2
ignorehitpause = 1

;--------------------------------------------------------------------
;しゃがむ動作
[Statedef 10]
type    = C
physics = C
anim = 10

[State ]
type = posset
trigger1 = time = 0
Y = 0

[State ]
type = turn
trigger1 = fvar(0)<0

[State ]
type = VelMul
trigger1 = Time = 0
x = 0.75

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = AnimTime = 0
trigger2 = command = "holddown"
value = 11

;--------------------------------------------------------------------
;しゃがみ
[Statedef 11]
type    = C
physics = C
anim = 11
sprpriority = 0

[State ]
type = posset
triggerall = ishelper(0)
trigger1 = time = 0
Y = 0

[State ]
type = turn
trigger1 = fvar(0)<0

[State ]
type = ChangeAnim
triggerall = ishelper(0)
trigger1 = Anim = 6 && AnimTime = 0
value = 11

[State ]
type = changestate
triggerall = ishelper(0)
trigger1 = command != "holddown"
value = 12

;--------------------------------------------------------------------
;立ち上がる動作
[Statedef 12]
type    = S
physics = S
anim = 12

[State ]
type = posset
trigger1 = time = 0
Y = 0

[State ]
type = turn
trigger1 = fvar(0)<0

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = AnimTime = 0
value = 0


;--------------------------------------------------------------------
;前進＆後退
[Statedef 20]
type    = S
physics = S
sprpriority = 0

[State ]
type = posset
triggerall = ishelper(0)
trigger1 = time = 0
Y = 0

[State ]
type = VelSet
trigger1 = command = "holdfwd"
x = const(velocity.walk.fwd.x)

[State ]
type = VelSet
trigger1 = command = "holdback"
x = const(velocity.walk.back.x)

[State ]
type = ChangeAnim
triggerall = ishelper(0)
triggerall = vel x > 0
trigger1 = Anim != 20 && Anim != 5
trigger2 = Anim = 5 && AnimTime = 0
value = 20

[State ]
type = ChangeAnim
triggerall = ishelper(0)
triggerall = vel x < 0
trigger1 = Anim != 21 && Anim != 5
trigger2 = Anim = 5 && AnimTime = 0
value = 21

[State ]
type = ChangeState
triggerall = ishelper(0)
triggerall = roundstate = 2
trigger1 = command != "holdfwd"
trigger1 = command != "holdback"
value = 0

[State ]
type = changestate
triggerall = ishelper(0)
triggerall = roundstate = 2
trigger1 = command = "holdup"
value = 40

;--------------------------------------------------------------------
;ジャンプ開始
[Statedef 40]
type    = S
physics = S
anim = 40
ctrl = 0
sprpriority = 1

[State ]
type = turn
trigger1 = fvar(0)<0

[State ]
type = VarSet
triggerall = ishelper(0)
trigger1 = Time = 0
sysvar(1) = 0

[State ]
type = VarSet
triggerall = ishelper(0)
trigger1 = command = "holdfwd"
sysvar(1) = 1

[State ]
type = VarSet
triggerall = ishelper(0)
trigger1 = command = "holdback"
sysvar(1) = -1

[State ]
type = VelSet
triggerall = ishelper(0)
trigger1 = time = 0
x = ifelse(sysvar(1)=0, const(velocity.jump.neu.x), ifelse(sysvar(1)=1, const(velocity.jump.fwd.x), const(velocity.jump.back.x)))
y = const(velocity.jump.y)

[State ]
type = VelSet
triggerall = ishelper(0)
trigger1 = AnimTime = 0
trigger1 = prevstateno = 100
trigger1 = sysvar(1) = 1
x = const(velocity.runjump.fwd.x)

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = time = 0
value = 50
ctrl = 0
;--------------------------------------------------------------------
;ジャンプ
[Statedef 50]
type    = A
physics = A

[State ]
type = VarSet
triggerall = ishelper(0)
trigger1 = Time = 0
sysvar(1) = 0

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

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

;--------------------------------------------------------------------
;ジャンプ後の下降
[Statedef 51]
type    = A
physics = A

[State ]
type = null
trigger1 = 1

;--------------------------------------------------------------------
;着地
[Statedef 52]
type    = S
physics = S
ctrl = 0
anim = 47

[State ]
type = VelSet
triggerall = ishelper(0)
trigger1 = time = 0
y = 0

[State ]
type = PosSet
triggerall = ishelper(0)
trigger1 = time = 0
y = 0

[State ]
type = turn
trigger1 = fvar(0)<0

[State ]
type = CtrlSet
triggerall = ishelper(0)
trigger1 = time = 1
value = 1

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;--------------------------------------------------------------------
;ガード開始
[Statedef 120]
type = U
physics = U

[State ]
type = ChangeAnim
triggerall = ishelper(0)
trigger1 = Time = 0
value = 120 + (statetype = C) + (statetype = A)*2

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = Time = 0 && statetype = S
physics = S

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = Time = 0 && statetype = C
physics = C

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = Time = 0 && statetype = A
physics = A

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = statetype = S && command = "holddown"
statetype = C
physics = C

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = statetype = C && command != "holddown"
statetype = S
physics = S

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = AnimTime = 0
value = 130 + (statetype = C) + (statetype = A)*2

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = command != "holdback"
trigger2 = !inguarddist
value = 140

;--------------------------------------------------------------------
;ガード受付（立ち）
[Statedef 130]
type    = S
physics = S

[State ]
type = posset
triggerall = ishelper(0)
trigger1 = time = 0
Y = 0

[State ]
type = ChangeAnim
triggerall = ishelper(0)
trigger1 = Anim != 130
value = 130

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = command = "holddown"
value = 131

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = command != "holdback"
trigger2 = !inguarddist
value = 140
;--------------------------------------------------------------------
;ガード受付（しゃがみ）
[Statedef 131]
type    = C
physics = C

[State ];地面に立ってろ
type = posset
triggerall = ishelper(0)
trigger1 = time = 0
Y = 0

[State ]
type = ChangeAnim
triggerall = ishelper(0)
trigger1 = Anim != 131
value = 131

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = command != "holddown"
value = 130

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = command != "holdback"
trigger2 = !inguarddist
value = 140

;--------------------------------------------------------------------
;ガード受付（空中）
[Statedef 132]
type    = A
physics = N

[State ]
type = ChangeAnim
triggerall = ishelper(0)
trigger1 = Anim != 132
value = 132

[State ]
type = VelAdd
triggerall = ishelper(0)
trigger1 = 1
y = Const(movement.yaccel)

[State ]
type = VarSet
triggerall = ishelper(0)
trigger1 = 1
sysvar(0) = (pos y >= 0) && (vel y > 0)

[State ]
type = VelSet
triggerall = ishelper(0)
trigger1 = sysvar(0)
y = 0

[State ]
type = PosSet
triggerall = ishelper(0)
trigger1 = sysvar(0)
y = 0

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = sysvar(0)
trigger1 = command = "holdback"
trigger1 = inguarddist
value = 130

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = sysvar(0)
value = 52

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = command != "holdback"
trigger2 = !inguarddist
value = 140

;--------------------------------------------------------------------
;ガード終了
[Statedef 140]
type = U
physics = U
ctrl = 1

[State ]
type = ChangeAnim
triggerall = ishelper(0)
trigger1 = Time = 0
value = 140 + (statetype = C) + (statetype = A)*2

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = Time = 0 && statetype = S
physics = S

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = Time = 0 && statetype = C
physics = C

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = Time = 0 && statetype = A
physics = A

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = statetype = S && command = "holddown"
statetype = C
physics = C

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = statetype = C && command != "holddown"
statetype = S
physics = S

;--------------------------------------------------------------------
;ガード硬直（立ち）
[Statedef 150]
type    = S
movetype= I
physics = N
velset = 0,0

[State ]
type = posset
triggerall = ishelper(0)
trigger1 = time = 0
Y = 0

[State ]
type = ChangeAnim
trigger1 = ishelper(0)
value = 150

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = HitShakeOver
value = 151 + 2*(command = "holddown")

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = statetype = S && command = "holddown"
statetype = C
physics = C

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = statetype = C && command != "holddown"
statetype = S
physics = S

[State ]
type = ForceFeedback
triggerall = ishelper(0)
trigger1 = time = 0
waveform = square
time = 3

[State ]
type = selfstate
trigger1 = ishelper(0)
trigger1 = pos Y >= 0
value = 0

[State ]
type = selfstate
trigger1 = ishelper(0)
trigger1 = pos Y < 0
value = 52

;--------------------------------------------------------------------
;ガード硬直解除後の後退（立ち）
[Statedef 151]
type    = S
movetype= I
physics = S
anim = 150

[State ]
type = posset
triggerall = ishelper(0)
trigger1 = time = 0
Y = 0

[State ]
type = HitVelSet
triggerall = ishelper(0)
trigger1 = Time = 0
x = 1

[State ]
type = VelSet
triggerall = ishelper(0)
trigger1 = Time = GetHitVar(slidetime)
trigger2 = HitOver
x = 0

[State ]
type = CtrlSet
triggerall = ishelper(0)
trigger1 = Time = GetHitVar(ctrltime)
value = 1

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = statetype = S && command = "holddown"
statetype = C
physics = C

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = statetype = C && command != "holddown"
statetype = S
physics = S

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = HitOver
value = 130
ctrl = 1

;--------------------------------------------------------------------
;ガード硬直（しゃがみ）
[Statedef 152]
type    = C
movetype= I
physics = N
velset = 0,0

[State ]
type = posset
triggerall = ishelper(0)
trigger1 = time = 0
Y = 0

[State ]
type = ChangeAnim
triggerall = ishelper(0)
trigger1 = 1
value = 151

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = HitShakeOver
value = 151 + 2*(command = "holddown")

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = statetype = S && command = "holddown"
statetype = C
physics = C

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = statetype = C && command != "holddown"
statetype = S
physics = S

[State ]
type = ForceFeedback
triggerall = ishelper(0)
trigger1 = time = 0
waveform = square
time = 4

;--------------------------------------------------------------------
;ガード硬直解除後の後退（しゃがみ）
[Statedef 153]
type    = C
movetype= I
physics = C
anim = 151

[State ]
type = posset
triggerall = ishelper(0)
trigger1 = time = 0
Y = 0

[State ]
type = HitVelSet
triggerall = ishelper(0)
trigger1 = Time = 0
x = 1

[State ]
type = VelSet
triggerall = ishelper(0)
trigger1 = Time = GetHitVar(slidetime)
trigger2 = HitOver
x = 0

[State ]
type = CtrlSet
triggerall = ishelper(0)
trigger1 = Time = GetHitVar(ctrltime)
value = 1

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = statetype = S && command = "holddown"
statetype = C
physics = C

[State ]
type = StateTypeSet
triggerall = ishelper(0)
trigger1 = statetype = C && command != "holddown"
statetype = S
physics = S

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = HitOver
value = 131
ctrl = 1

;--------------------------------------------------------------------
;ガード硬直（空中）
[Statedef 154]
type    = A
movetype= I
physics = N
velset = 0,0

[State ]
type = ChangeAnim
triggerall = ishelper(0)
trigger1 = 1
value = 152

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = HitShakeOver
value = 155

[State ]
type = ForceFeedback
triggerall = ishelper(0)
trigger1 = time = 0
waveform = square
time = 4

;--------------------------------------------------------------------
;ガード硬直解除後の後退（空中）
[Statedef 155]
type    = A
movetype= I
physics = N
anim = 152

[State ]
type = HitVelSet
triggerall = ishelper(0)
trigger1 = Time = 0
x = 1
y = 1

[State ]
type = VelAdd
triggerall = ishelper(0)
trigger1 = 1
y = Const(movement.yaccel)

[State ]
type = CtrlSet
triggerall = ishelper(0)
trigger1 = Time = GetHitVar(ctrltime)
value = 1

[State ]
type = VarSet
triggerall = ishelper(0)
trigger1 = 1
sysvar(0) = (pos y >= 0) && (vel y > 0)

[State ]
type = VelSet
triggerall = ishelper(0)
trigger1 = sysvar(0)
y = 0

[State ]
type = PosSet
triggerall = ishelper(0)
trigger1 = sysvar(0)
y = 0

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = sysvar(0)
trigger1 = command = "holdback"
trigger1 = inguarddist
value = 130

[State ]
type = ChangeState
triggerall = ishelper(0)
trigger1 = sysvar(0)
value = 52

;--------------------------------------------------------------------
;タイムオーバーで負けた時
[Statedef 170]
type = S
ctrl = 0
anim = 170
velset = 0,0

[State ]
type = assertspecial
triggerall = name = "Crazy-Catastrophe"
trigger1 = roundstate >=3
flag = roundnotover
ignorehitpause = 1

[state ]
type = selfstate
trigger1 = !ishelper && var(59)!=9999
trigger1 = roundstate <= 2
value = 5150
ignorehitpause = 1

[state ]
type = selfstate
trigger1 = !ishelper && var(59)=9999
trigger1 = roundstate <= 2
value = 51500
ignorehitpause = 1

[State ]
type = VarRandom
triggerall = ishelper(0)
trigger1 = time = 0
trigger2 = !ishelper && var(59)=9999
trigger2 = time = 0
v = 3
range = 0,1

[State ]
Type = ChangeState
triggerall = ishelper(0)
Trigger1 = Var(3) = 0
trigger2 = !ishelper && var(59)=9999
trigger2 = Var(3) = 0
Value = 171

[State ]
Type = ChangeState
triggerall = ishelper(0)
Trigger1 = Var(3) = 1
trigger2 = !ishelper && var(59)=9999
trigger2 = Var(3) = 1
Value = 172

;--------------------------------------------------------------------
;タイムオーバーで引き分けた時
[Statedef 175]
type = S
ctrl = 0
velset = 0,0

[State ]
type = assertspecial
triggerall = name = "Crazy-Catastrophe"
trigger1 = roundstate >=3
flag = roundnotover
ignorehitpause = 1

[state ]
type = selfstate
trigger1 = !ishelper && var(59)!=9999
trigger1 = roundstate <= 2
value = 5150
ignorehitpause = 1

[state ]
type = selfstate
trigger1 = !ishelper && var(59)=9999
trigger1 = roundstate <= 2
value = 51500
ignorehitpause = 1

[State ]
type = VarRandom
trigger1 = ishelper(0)
trigger1 = time = 0
trigger2 = !ishelper && var(59)=9999
trigger2 = time = 0
v = 3
range = 0,1

[State ]
Type = ChangeState
trigger1 = ishelper(0)
Trigger1 = Var(3) = 0
trigger2 = !ishelper && var(59)=9999
trigger2 = Var(3) = 0
Value = 171

[State ]
Type = ChangeState
trigger1 = ishelper(0)
Trigger1 = Var(3) = 1
trigger2 = !ishelper && var(59)=9999
trigger2 = Var(3) = 1
Value = 172

;--------------------------------------------------------------------
[Statedef 171];「下の下だな…」
type = S
ctrl = 0
anim = 172
velset = 0,0

[state ]
type = selfstate
trigger1 = !ishelper && var(59)!=9999
value = 5150
ignorehitpause = 1

[State ]
type = AssertSpecial
trigger1 = time <= 260
flag = roundnotover

[state ]
type = PlaySnd
trigger1 = animelem = 5
value = 190,1
volume = 240
freqmul = 1
loop = 0

[state ]
type = PlaySnd
trigger1 = animelemtime(54) = 10
value = 182, 0
volume = 240
freqmul = 1
loop = 0

[state ]
type = PlaySnd
trigger1 = animelemtime(55) = 0
value = 211,0
volume = 240
freqmul = 1
loop = 0

;--------------------------------------------------------------------
[Statedef 172];「天上天下」
type = S
ctrl = 0
anim = 181
velset = 0,0

[state ]
type = selfstate
trigger1 = !ishelper && var(59)!=9999
value = 5150
ignorehitpause = 1

[State ]
type = AssertSpecial
trigger1 = time <= 240
flag = roundnotover

[state ]
type = Explod
trigger1 = time = 0
anim = 182
ID = 182
pos = 0, 0
postype = p1
facing = 1
vfacing = 1
bindtime = -1
removetime = -1
scale = 1,1
sprpriority = -1
ontop = 0
shadow = 0, 0, 0
ownpal = 1
supermove = 1
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[state ]
type = PlaySnd
trigger1 = time = 100
value = 181, 0
volume = 240
freqmul = 1
loop = 0

[State ]
type = AssertSpecial
trigger1 = time >= 200
flag = invisible

[State ]
type = removeexplod
trigger1 = time >= 200
ID=182

[state ]
type = PlaySnd
trigger1 = time = 200
value = 211,0
volume = 240
freqmul = 1
loop = 0

;--------------------------------------------------------------------
;勝利演出分岐
[Statedef 180]
type = S
ctrl = 0
velset = 0,0
sprpriority = 1

[State ]
type = assertspecial
triggerall = name = "Crazy-Catastrophe"
trigger1 = roundstate >=3
flag = roundnotover
ignorehitpause = 1

[state ]
type = selfstate
trigger1 = !ishelper && var(59)!=9999
trigger1 = roundstate <= 2
value = 5150
ignorehitpause = 1

[state ]
type = selfstate
trigger1 = !ishelper && var(59)=9999
trigger1 = roundstate <= 2
value = 51500
ignorehitpause = 1

[state ];分岐
type = VarRandom
trigger1 = ishelper(0)
trigger1 = time = 0
trigger2 = !ishelper && var(59)=9999
trigger2 = time = 0
v = 1
range = 2

[state ]
type = changestate
trigger1 = ishelper(0)
trigger1 = Var(1) = 0
trigger2 = !ishelper && var(59)=9999
trigger2 = Var(1) = 0
value = 181

[state ]
type = changestate
trigger1 = ishelper(0)
trigger1 = Var(1) = 1
trigger2 = !ishelper && var(59)=9999
trigger2 = Var(1) = 1
value = 182

[state ]
type = changestate
trigger1 = ishelper(0)
trigger1 = Var(1) = 2
trigger2 = !ishelper && var(59)=9999
trigger2 = Var(1) = 2
value = 183
;--------------------------------------------------------------------
;勝利 その１
[Statedef 181]
Type = S
Ctrl = 0
VelSet = 0,0
anim = 181
sprpriority = 1

[state ]
type = selfstate
trigger1 = !ishelper && var(59)!=9999
value = 5150
ignorehitpause = 1

[state ]
type = selfstate
trigger1 = ishelper(0) && stateno !=181
value = 181
ignorehitpause = 1

[state ]
type = changeanim
trigger1 = anim != 181
value = 181

[State ]
type = pause
trigger1 = ishelper
time = 0
movetime = 0
ignorehitpause = 1

[State ]
type = superpause
trigger1 = ishelper
anim = -1
time = 0
movetime = 0
darken = 0
ignorehitpause = 1

[State ]
type = AssertSpecial
trigger1 = roundstate =4
trigger1 = time <= 600
flag = roundnotover

[state ]
type = Explod
trigger1 = time = 0
anim = 182
ID = 182
pos = 0, 0
postype = p1
facing = 1
vfacing = 1
bindtime = -1
removetime = -1
scale = 1,1
sprpriority = -1
ontop = 0
shadow = 0, 0, 0
ownpal = 1
supermove = 1
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[state ]
type = PlaySnd
trigger1 = time = 100
value = 181, 0
volume = 240
freqmul = 1
loop = 0

[State ]
type = AssertSpecial
trigger1 = time >= 200
flag = invisible

[State ]
type = removeexplod
trigger1 = time >= 200
ID=182

[state ]
type = PlaySnd
trigger1 = time = 200
value = 211,0
volume = 240
freqmul = 1
loop = 0


[state ]
type = Explod
trigger1 = time = 200
anim = 4000
ID = 4000
pos = 0, 0
postype = left
facing = 1
vfacing = 1
bindtime = -1
removetime = -1
scale = 1,1
sprpriority = 999999999999
ontop = 1
shadow = 0, 0, 0
ownpal = 1
supermove = 1
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[state ]
type = PlaySnd
trigger1 = numexplod(4000)>0
trigger1 = time = 200
value = 1,1
volume = 240
freqmul = 1
loop = 0

[State ]
type = AssertSpecial
trigger1 = numexplod(4000)>0
flag = nobardisplay
flag2 = nomusic

;--------------------------------------------------------------------
;勝利 その２
[Statedef 182]
Type = S
Ctrl = 0
VelSet = 0,0
anim = 172
sprpriority = 1

[state ]
type = selfstate
trigger1 = !ishelper && var(59)!=9999
value = 5150
ignorehitpause = 1

[state ]
type = selfstate
trigger1 = ishelper(0) && stateno !=182
value = 182
ignorehitpause = 1

[state ]
type = changeanim
trigger1 = anim != 172
value = 172

[State ]
type = pause
trigger1 = ishelper
time = 0
movetime = 0
ignorehitpause = 1

[State ]
type = superpause
trigger1 = ishelper
anim = -1
time = 0
movetime = 0
darken = 0
ignorehitpause = 1

[State ]
type = AssertSpecial
trigger1 = roundstate =4
trigger1 = time <= 680
flag = roundnotover

[state ]
type = PlaySnd
trigger1 = animelem = 5
value = 190,1
volume = 240
freqmul = 1
loop = 0

[state ]
type = PlaySnd
trigger1 = animelemtime(54) = 10
value = 182, 0
volume = 240
freqmul = 1
loop = 0

[state ]
type = PlaySnd
trigger1 = animelemtime(55) = 0
value = 211,0
volume = 240
freqmul = 1
loop = 0

[state ]
type = Explod
trigger1 = animelemtime(55) = 0
anim = 4000
ID = 4000
pos = 0, 0
postype = left
facing = 1
vfacing = 1
bindtime = -1
removetime = -1
scale = 1,1
sprpriority = 999999999999
ontop = 1
shadow = 0, 0, 0
ownpal = 1
supermove = 1
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[state ]
type = PlaySnd
trigger1 = numexplod(4000)>0
trigger1 = animelemtime(55) = 0
value = 1,1
volume = 240
freqmul = 1
loop = 0

[State ]
type = AssertSpecial
trigger1 = numexplod(4000)>0
flag = nobardisplay
flag2 = nomusic

;--------------------------------------------------------------------
;勝利 その３
[Statedef 183]
Type = S
Ctrl = 0
VelSet = 0,0
anim = 173
sprpriority = 1

[state ]
type = selfstate
trigger1 = !ishelper && var(59)!=9999
value = 5150
ignorehitpause = 1

[state ]
type = selfstate
trigger1 = ishelper(0) && stateno !=183
value = 183
ignorehitpause = 1

[state ]
type = changeanim
trigger1 = anim != 173
value = 173

[State ]
type = pause
trigger1 = ishelper
time = 0
movetime = 0
ignorehitpause = 1

[State ]
type = superpause
trigger1 = ishelper
anim = -1
time = 0
movetime = 0
darken = 0
ignorehitpause = 1

[State ]
type = AssertSpecial
trigger1 = roundstate =4
trigger1 = time <= 260
flag = roundnotover

[state ]
type = PlaySnd
trigger1 = animelemtime(2) = 1
value = 0,22
volume = 240
freqmul = 1
loop = 0

[state ]
type = PlaySnd
trigger1 = animelemtime(11) = 2
value = 0,23
volume = 240
freqmul = 1
loop = 0

[state ]
type = PlaySnd
trigger1 = animelemtime(14) = 1
value = 211,0
volume = 240
freqmul = 1
loop = 0

;--------------------------------------------------------------------
;イントロ準備
[Statedef 190]
type = S
ctrl = 0
velset = 0,0

[State ];特殊イントロ
Type = SelfState
triggerall = ishelper(0)
Trigger1 = Var(5) = 8901 ;VS鬼巫女
Value = 19000

[State ]
type = VarRandom
triggerall = ishelper(0)
trigger1 = time = 0
trigger1 = var(5)=0 ;特殊イントロでは無い
v = 2
range = 2

[State ]
Type = SelfState
triggerall = ishelper(0)
Trigger1 = Var(2) = 0
Value = 191

[State ]
Type = SelfState
triggerall = ishelper(0)
Trigger1 = Var(2) = 1
Value = 192

[State ]
Type = SelfState
triggerall = ishelper(0)
Trigger1 = Var(2) = 2
Value = 193

;--------------------------------------------------------------------
;イントロ その１ 「……………倒してみせよ…………ｱﾘｴﾝ!」
[Statedef 191]
type = S
ctrl = 0
anim = 190

[State ]
type = AssertSpecial
trigger1 = anim = 190
flag = intro

[State ]
type = AngleDraw 
trigger1 = 1

[State ]
type = Angleadd
trigger1 = time = [282,401]
value = 30

[state ]
type = PlaySnd
trigger1 = animelem = 13
value = 190, 0
volume = 240
freqmul = 0.8
loop = 0

[state ]
type = PlaySnd
trigger1 = animtime = 0
value = 10,11
volume = 240
freqmul = 2.5
loop = 0

[state ]
type = Explod
trigger1 = animelem = 13
anim = 191
ID = 191
pos = 0, 0
postype = p1
facing = 1
vfacing = 1
bindtime = -1
removetime = -2
scale = 1,1
sprpriority = 1
ontop = 0
shadow = 0, 0, 0
ownpal = 1
supermove = 1
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[state ]
type = PlaySnd
trigger1 = animelemtime(13) = 1
value = 190,1
volume = 240
freqmul = 1
loop = 0
[state ]
type = PlaySnd
trigger1 = animelem = 14
value = 190,2
volume = 240
freqmul = 1
loop = 0

[State ]
type = SelfState
trigger1 = ishelper(0)
trigger1 = animTime = 0
value = 0

;--------------------------------------------------------------------
;イントロ その２　「血が…血が…ありえん！………倒してみせよ」
[Statedef 192]
type = S
ctrl = 0
anim = 192

[State ]
type = AssertSpecial
trigger1 = stateno = 192
flag = intro

[state ]
type = PlaySnd
trigger1 = time = 1
value = 2000,0
volume = 240
freqmul = 1
loop = 0

[state ]
type = PlaySnd
trigger1 = animelemtime(4) = 1
trigger2 = animelemtime(20) = 1
trigger3 = animelemtime(36) = 1
value = 1500,0
volume = 240
freqmul = 1
loop = 0

[state ]
type = PlaySnd
trigger1 = animelemtime(40) = 1
value = 10,10
volume = 240
freqmul = 1
loop = 0

[state ]
type = PlaySnd
trigger1 = animelemtime(10) = 1
trigger2 = animelemtime(26) = 1
value = 192,0
volume = 240
freqmul = 1
loop = 0

[state ]
type = PlaySnd
trigger1 = animelemtime(53) = 1
value = 190, 0
volume = 240
freqmul = 0.8
loop = 0

[state ]
type = Explod
trigger1 = animelemtime(35) = 0
anim = 193
ID = 193
pos = 0, 0
postype = p1
facing = 1
vfacing = 1
bindtime = -1
removetime = -2
scale = 1,1
sprpriority = 1
ontop = 0
shadow = 0, 0, 0
ownpal = 1
supermove = 1
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[state ]
type = Explod
trigger1 = animelem = 51
anim = 191
ID = 191
pos = 0, 0
postype = p1
facing = 1
vfacing = 1
bindtime = -1
removetime = -2
scale = 1,1
sprpriority = 1
ontop = 0
shadow = 0, 0, 0
ownpal = 1
supermove = 1
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[state ]
type = PlaySnd
trigger1 = animelemtime(53) = 1
value = 190,1
volume = 240
freqmul = 1
loop = 0
[state ]
type = PlaySnd
trigger1 = animelemtime(54) = 1
value = 190,2
volume = 240
freqmul = 1
loop = 0

[state ]
type = lifeadd
trigger1 = animelem = 5
trigger2 = animelem = 21
trigger3 = animelem = 37
value = -200
absolute = 1
kill = 0

[state ]
type = PlaySnd
trigger1 = animelem = 5
trigger2 = animelem = 21
trigger3 = animelem = 37
value = 240,0
volume = 240
freqmul = 1
loop = 0

[State ]
type = SelfState
trigger1 = ishelper(0)
trigger1 = animTime = 0
value = 0

;--------------------------------------------------------------------
;イントロ その３　caved!!!!
[Statedef 193]
type = S
ctrl = 0
anim = 194

[State ]
type = AssertSpecial
trigger1 = stateno = 193
flag = intro

[state ]
type = PlaySnd
trigger1 = animelemtime(5) = 1
value = 0,26
volume = 240
freqmul = 1
loop = 0

[state ]
type = PlaySnd
trigger1 = animelemtime(65) = 1
value = 0,27
volume = -200
freqmul = 1
loop = 0

[state ]
type = PlaySnd
trigger1 = animelemtime(67) = 1
value = 0,29
volume = 240
freqmul = 1
loop = 0

[state ]
type = PlaySnd
trigger1 = animelemtime(74) = 10
value = 0,30
volume = 240
freqmul = 1
loop = 0

[state ]
type = Explod
trigger1 = animelemtime(11) = 1
anim = 1
ID = 193
pos = 60, 0
postype = p1
facing = 1
vfacing = 1
bindtime = -1
removetime = -1
scale = 1,1
sprpriority = 1
ontop = 0
shadow = 30,30,30
ownpal = 1
supermove = 1
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[state ]
type = PlaySnd
trigger1 = numexplod(193)=1
trigger1 = animelemtime(11) = 1
value = 211,0
volume = 240
freqmul = 1
loop = 0

[State ]
type = removeexplod
trigger1 = animelemtime(64)=4
ID=193

[state ]
type = Explod
trigger1 = animelemtime(64) = 4
anim = 5012
ID = 5012
pos = 60, 0
postype = p1
facing = 1
vfacing = 1
bindtime = -1
removetime = -1
scale = 1,1
sprpriority = 1
ontop = 0
shadow = 30,30,30
ownpal = 1
supermove = 1
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[state ];!
type = Explod
trigger1 = animelemtime(64) = 4
anim = 3033
ID = 3033
pos = 80, -130
postype = p1
facing = 1
vfacing = 1
bindtime = -1
removetime = 15
scale = 1,1
sprpriority = 1
ontop = 0
shadow = 0,0,0
ownpal = 1
supermove = 1
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[state ]
type = PlaySnd
trigger1 = numexplod(5012)=1
trigger1 = animelemtime(65) = 1
value = 2300,3
volume = 240
freqmul = 1
loop = 0

[state ]
type = PlaySnd
trigger1 = numexplod(5012)=1
trigger1 = animelemtime(65) = 1
value = 1,0
volume = 240
freqmul = 1
loop = 0

[State ]
type = removeexplod
trigger1 = animelemtime(67)=1
ID=5012

[state ]
type = Explod
trigger1 = animelemtime(67) = 1
anim = 5050
ID = 5050
pos = 60, 0
postype = p1
facing = 1
vfacing = 1
bindtime = 1
removetime = 45
scale = 1,1
vel = -7,-6.5
accel = 0,0.5
sprpriority = 1
ontop = 0
shadow = 30,30,30
ownpal = 1
supermove = 1
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[state ]
type = PlaySnd
trigger1 = numexplod(5050)=1
trigger1 = animelemtime(67) = 1
value = 10,10
volume = 240
freqmul = 1
loop = 0

[State ]
type = SelfState
trigger1 = ishelper(0)
trigger1 = animTime = 0
value = 0

;--------------------------------------------------------------------
;特殊イントロその１　VS鬼巫女
[Statedef 19000]
type = S
ctrl = 0
anim = 19000
sprpriority = 2

[State ]
type = AssertSpecial
trigger1 = stateno = 19000
flag = intro

[State ]
type = superPause
trigger1 = stateno = 19000
trigger1 = time = 0
time = 1672
movetime = 1672
pos = 999, 999
anim = -1
sound = -1
poweradd = 0
p2defmul = 1
unhittable = 1
darken = 0
ignorehitpause = 1
pausemovetime=2147483647
supermovetime=2147483647

[State ]
type = Pause
trigger1 = stateno = 19000
trigger1 = time = 0
time = 1672
movetime = 1672
pos = 999, 999
anim = -1
sound = -1
poweradd = 0
p2defmul = 1
unhittable = 1
darken = 0
ignorehitpause = 1
pausemovetime=2147483647
supermovetime=2147483647

[state ]
type = PlaySnd
trigger1 = animelemtime(17) = 1
value = 0,26
volume = 240
freqmul = 1
loop = 0

[state ]
type = PlaySnd
trigger1 = time = 280
value = 2000,0
volume = 240
freqmul = 1
loop = 0
channel = 0
[state ]
type = PlaySnd
trigger1 = time = 370
value = 2000,1
volume = 240
freqmul = 1
loop = 0
channel = 0
[state ]
type = PlaySnd
trigger1 = time = 440
value = 2000,2
volume = 240
freqmul = 1
loop = 0
channel = 0

[State ]
type = Projectile
trigger1 = time = [360,600]
trigger1 = gametime%3
projID = 3015
projanim = 3015
projremanim = 3016
projscale = 0.4,0.4
projremove = 0
projremovetime = -1
velocity = 0,6
remvelocity = 0, 0
accel = 0, 0
velmul = 1, 1
projsprpriority = 1
projedgebound = 10000
projstagebound = 10000
projheightbound = -240, -60
offset = var(6),-250
postype = p1
projshadow = 0,0,0
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[State ]
type = Projectile
trigger1 = time = [360,600]
trigger1 = gametime%2
projID = 3015
projanim = 3015
projremanim = 3016
projscale = 0.4,0.4
projremove = 0
projremovetime = -1
velocity = 0,6
remvelocity = 0, 0
accel = 0, 0
velmul = 1, 1
projsprpriority = 1
projedgebound = 10000
projstagebound = 10000
projheightbound = -240, -60
offset = var(6),-250
postype = p1
projshadow = 0,0,0
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[state ]
type = PlaySnd
trigger1 = time = [390,631]
value = 1,6
volume = -150
freqmul = 1
loop = 0
channel = 1

[state ]
type = Explod
trigger1 = animelemtime(105) = 110
trigger2 = animelemtime(105) = 150
anim = 3017
ID = 3017
pos = ifelse(teamside=1,30,150), -135
postype = p1
facing = ifelse(teamside=1,1,-1)
vfacing = 1
bindtime = -1
vel = 0,0
accel = 0,0
removetime = 90
scale = 1,1
sprpriority = 5
ontop = 0
shadow = 0, 0, 0
ownpal = 1
supermove = 1
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[State ]
type = removeexplod
trigger1 = animelemtime(105)=130
trigger2 = animelemtime(106)=5
ID=3017

[state ]
type = PlaySnd
trigger1 = animelemtime(106) = 1
value = 10,10
volume = 240
freqmul = 1
loop = 0

[state ]
type = Explod
trigger1 = animelemtime(106) = 95
anim = 3005
ID = 3005
pos = 75, -50
postype = p1
facing = 1
vfacing = 1
bindtime = 1
vel = -0.1,-1.5
accel = -0.003,0
removetime = -1
scale = 1,1
sprpriority = 2
ontop = 0
shadow = 0, 0, 0
ownpal = 1
supermove = 1
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[state ]
type = PlaySnd
trigger1 = animelemtime(106) = 95
trigger1 = numexplod(3005)=1
value = 1,4
volume = 240
freqmul = 1
loop = 0

[State ]
type = removeexplod
trigger1 = animelemtime(106)=219
ID=3005

[state ]
type = Explod
trigger1 = animelemtime(106) = 220
anim = 3005
ID = 3005
pos = 10, -200
postype = p1
facing = 1
vfacing = 1
bindtime = 1
vel = 0,0.57
accel = 0,0
removetime = -1
scale = 1,1
sprpriority = 2
ontop = 0
shadow = 0, 0, 0
ownpal = 1
supermove = 1
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[state ]
type = PlaySnd
trigger1 = animelemtime(106) = 220
trigger1 = numexplod(3005)=1
value = 0,28
volume = 240
freqmul = 1
loop = 0

[State ]
type = removeexplod
trigger1 = animelemtime(106)=540
ID=3005

[state ]
type = Explod
trigger1 = animelemtime(106) = 540
trigger1 = numhelper(0)>0
anim = 3006
ID = 3006
pos = 10,-40
postype = p1
facing = ifelse(teamside=1,1,-1)
vfacing = 1
bindtime = 1
vel = 0,0
accel = 0,0
removetime = -2
scale = 1,1
sprpriority = 2
ontop = 0
shadow = 0, 0, 0
ownpal = 1
supermove = 1
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[state ]
type = PlaySnd
trigger1 = animelemtime(106) = 540
trigger1 = numexplod(3005)=0
value = 1,5
volume = 240
freqmul = 1
loop = 0

[state ]
type = Explod
trigger1 = animelemtime(119) = 1
anim = 191
ID = 191
pos = 0, 0
postype = p1
facing = 1
vfacing = 1
bindtime = -1
removetime = -2
scale = 1,1
sprpriority = 4
ontop = 0
shadow = 0, 0, 0
ownpal = 1
supermove = 1
pausemovetime = 99999999999999999999
supermovetime = 99999999999999999999
ignorehitpause = 1

[state ]
type = PlaySnd
trigger1 = animelemtime(119) = 1
trigger1 = numexplod(191)=1
value = 190,1
volume = 240
freqmul = 1
loop = 0
[state ]
type = PlaySnd
trigger1 = animelemtime(120) = 1
value = 190,2
volume = 240
freqmul = 1
loop = 0

[state ]
type = PlaySnd
trigger1 = animelemtime(125) = 1
value = 0,31
volume = 240
freqmul = 1
loop = 0

[State ]
type = SelfState
trigger1 = ishelper(0)
trigger1 = animTime = 0
value = 0

;--------------------------------------------------------------------
;コモンにあった共通食らいステート(不必要な為廃止、でもNullで残しておく)
[Statedef 5000]
[State ]
type = Null
trigger1 = 0
[Statedef 5001]
[State ]
type = Null
trigger1 = 0
[Statedef 5010]
[State ]
type = Null
trigger1 = 0
[Statedef 5011]
[State ]
type = Null
trigger1 = 0
[Statedef 5020]
[State ]
type = Null
trigger1 = 0
[Statedef 5030]
[State ]
type = Null
trigger1 = 0
[Statedef 5035]
[State ]
type = Null
trigger1 = 0
[Statedef 5040]
[State ]
type = Null
trigger1 = 0
[Statedef 5050]
[State ]
type = Null
trigger1 = 0
[Statedef 5070]
[State ]
type = Null
trigger1 = 0
[Statedef 5071]
[State ]
type = Null
trigger1 = 0
[Statedef 5080]
[State ]
type = Null
trigger1 = 0
[Statedef 5081]
[State ]
type = Null
trigger1 = 0
[Statedef 5100]
[State ]
type = Null
trigger1 = 0
[Statedef 5101]
[State ]
type = Null
trigger1 = 0
[Statedef 5110]
[State ]
type = Null
trigger1 = 0
[Statedef 5120]
[State ]
type = Null
trigger1 = 0
[Statedef 5200]
[State ]
type = Null
trigger1 = 0
[Statedef 5201]
[State ]
type = Null
trigger1 = 0
[Statedef 5210]
[State ]
type = Null
trigger1 = 0
;--------------------------------------------------------------------
;死亡
[Statedef 5150]
type    = L
movetype= I
physics = N
sprpriority = 0

[State ]
type = destroyself
trigger1 = !ishelper(0)

[State ]
type = selfstate
trigger1 = ishelper(0)
value = 0

[State ]
type = assertspecial
triggerall = name = "Crazy-Catastrophe"
triggerall = !LOSE
trigger1 = var(59)=9999
trigger1 = roundstate >=3
trigger2 = var(59)!=9999
trigger2 = roundstate >=3
trigger2 = numhelper(0)>0
trigger2 = helper(0),stateno!=[170,199]
flag = roundnotover
ignorehitpause = 1

[state ]
type = DisplayToClipboard
trigger1 = !ishelper
text="e-life:%d, e-state:%d, e-anim:%d, e-helper:%d, helper:%d"
params=(enemynear,life),(enemynear,stateno),(enemynear,anim),(enemynear,numhelper),(numhelper)
ignorehitpause=1

[state ]
type=AppendToClipboard
trigger1 = !ishelper
text="\n v59 %d,round %d,v4 %d,v5 %d,v6 %d"
params= (var(59)),(roundstate),(var(4)),(var(5)),(var(6))
ignorehitpause=1

[state ]
type = nothitby
trigger1 = !ishelper && name = "Crazy-Catastrophe"
value = SCA
time = -1
ignorehitpause = 1

[State ]
type = assertspecial
trigger1 = name = "Crazy-Catastrophe"
trigger1 = !ishelper
trigger1 = var(59)!=9999
flag = invisible
flag2 = noautoturn
flag3 = nokoslow
ignorehitpause = 1

[state ]
type = changeanim
trigger1 = name = "Crazy-Catastrophe"
trigger1 = !ishelper
trigger1 = var(59)!=9999
value = 9999

[state ]
type = posset
trigger1 = numhelper(0)=1
trigger1 = !ishelper
trigger1 = name = "Crazy-Catastrophe"
x = helper(0),pos X
y = helper(0),pos Y

[State ]
type = Helper
trigger1 = !ishelper && name = "Crazy-Catastrophe"
trigger1 = NumHelper(0) = 0
trigger1 = roundstate = 0
name = "CCMizuchi"
id = 0
pos = 0,0
postype = p1
sprpriority = 0
stateno = 0
Helpertype = player
keyctrl = 1
ownpal = 1
supermove = 1
size.ground.back = 0
size.ground.front = 0
size.air.back = 0
size.air.front = 0
pausemovetime=2147483647
supermovetime=2147483647
ignorehitpause = 1

[State ]
type = lifeset
trigger1 = !ishelper && name="Crazy-Catastrophe"
trigger1 = numhelper(1)>0
trigger1 = numhelper(0)>0
trigger1 = helper(0),var(0)=gametime
value = lifemax-(helper(1),var(2))

[state ]
type=selfstate
trigger1 = roundstate >1
trigger1 = numhelper>99999
trigger1 = !ishelper && name = "Crazy-Catastrophe"
trigger1 = var(59)!=9999
value=5150
ignorehitpause=1

[state ]
type=selfstate
trigger1 = !ishelper
trigger1 = var(59)=9999
trigger1 = roundstate =2
value=51500
ignorehitpause=1




[State ]
type = velset
triggerall = ishelper(0)
triggerall = root,name = "Crazy-Catastrophe"
trigger1 = time = 0
x = 0
y = 0

[State ]
type = NotHitBy
triggerall = ishelper(0)
triggerall = root,name = "Crazy-Catastrophe"
trigger1 = 1
value = SCA
time = 1

[State ];演出中です
type = null;assertspecial
triggerall = name = "Crazy-Catastrophe"
trigger1 = loseko
trigger1 = matchover ;もう後がない
trigger1 = time <= 1250
flag = roundnotover
ignorehitpause = 1

;--------------------------------------------------------------------
;裏モード
[Statedef 51500]
type    = S
movetype= I
physics = N
sprpriority = 0

[state ]
type = changeanim
trigger1 = name = "Crazy-Catastrophe"
trigger1 = !ishelper
trigger1 = stateno=51500
trigger1 = roundstate=2
value = 10000


[State ]
type = turn
trigger1 = fvar(0)<0
[State ]
type = screenbound
trigger1 = 1
value = 0
movecamera = 0,0
[state ]
type = posset
trigger1 = !ishelper
trigger1 = name = "Crazy-Catastrophe"
trigger1 = var(59)=9999
trigger1 = roundstate=2
trigger1 = numenemy>0
trigger1 = enemy,facing = 1
trigger1 = var(5)>0
x = (enemy,pos X - 10)
y = (enemy,pos Y + 5)
[state ]
type = posset
trigger1 = !ishelper
trigger1 = name = "Crazy-Catastrophe"
trigger1 = var(59)=9999
trigger1 = roundstate=2
trigger1 = numenemy>0
trigger1 = enemy,facing = -1
trigger1 = var(5)>0
x = (enemy,pos X + 10)
y = (enemy,pos Y + 5)
[state ]
type = posset
triggerall = !ishelper
triggerall = name = "Crazy-Catastrophe"
trigger1 = roundstate>=3
trigger2 = stateno=51515
y = 0

[State ]
type = StateTypeSet
trigger1 = name = "Crazy-Catastrophe"
trigger1 = !ishelper
trigger1 = stateno=51500
type    = S
movetype= A
physics = N

[State ]
type = ReversalDef
trigger1 = var(5)<=2
reversal.attr = SCA,AP,AA,AT
hitflag = MAFDP
priority = 99999999
pausetime = 0,10
guard,dist = 0
numhits = 0
p2stateno = 512
supermovetime = 999000
pausemovetime = 999000

[State ]
type = ReversalDef
trigger1 = var(5)>=3
reversal.attr = SCA,AP,AA,AT
hitflag = MAFDP
priority = 99999999
pausetime = 0,10
guard,dist = 0
numhits = 0
p2stateno = 461349010
supermovetime = 999000
pausemovetime = 999000

[state ]
type = HitOverride
trigger1 = 1
attr = SCA,AA,AT,AP
slot = 1
stateno = 51500
time = -1
forceair = 0

[State ]
type = assertspecial
triggerall = name = "Crazy-Catastrophe"
triggerall = !LOSE
trigger1 = roundstate =4
flag = roundnotover
ignorehitpause = 1

[State ]
type = assertspecial
trigger1 = !ishelper && name="Crazy-Catastrophe"
trigger1 = roundstate=0
flag = invisible
ignorehitpause = 1

[State ]
type = destroyself
trigger1 = var(59)=9999
trigger1 = 1

[state ]
type = PlayerPush
trigger1 = 1
value = 0

[State ]
type = turn
triggerall = name = "Crazy-Catastrophe"
triggerall = time = 0
triggerall = enemynear,alive || numenemy = 1
trigger1 = enemynear,facing = -facing
trigger1 = frontedgedist<enemynear,backedgedist
trigger2 = enemynear,facing = facing
trigger2 = frontedgedist<enemynear,frontedgedist

[state ]
type = DisplayToClipboard
trigger1 = !ishelper
trigger1 = var(59)=9999
text="e-life:%d, e-state:%d, e-anim:%d, e-helper:%d, helper:%d"
params=(enemynear,life),(enemynear,stateno),(enemynear,anim),(enemynear,numhelper),(numhelper)
ignorehitpause=1

[state ]
type=AppendToClipboard
trigger1 = !ishelper
text="\n v59 %d,round %d,v4 %d,v5 %d,v6 %d"
params= (var(59)),(roundstate),(var(4)),(var(5)),(var(6))
ignorehitpause=1

[state ]
type = nothitby
trigger1 = !ishelper && name = "Crazy-Catastrophe"
trigger1 = var(59)=9999
value = SCA
time = -1
ignorehitpause = 1

[State ]
type = lifeset
trigger1 = var(59)=9999
trigger1 = roundstate >=3
trigger1 = alive
value = lifemax
[State ]
type = lifeset
triggerall = var(59)=9999
triggerall = numenemy>0
triggerall = enemynear,life>0
trigger1 = roundstate <=2
value = ifelse(numenemy>0,(enemynear,life),lifemax)
[State ]
type = lifeset
triggerall = var(59)=9999
triggerall = numenemy>0
triggerall = enemynear,life<=0
trigger1 = roundstate <=2
value = ifelse(numenemy>0,1,lifemax)

[state ]
type = changeanim
trigger1 = name = "Crazy-Catastrophe"
trigger1 = !ishelper
trigger1 = anim != 0 && stateno = 51500
trigger1 = roundstate <=3
trigger1 = anim!=10000
value = 0

[State ]
type = Projectile
triggerall = !WIN
triggerall = enemy,alive
triggerall = life>0
triggerall = var(1)>0
triggerall = var(5)=1
trigger1 = var(4)>=3000
projID = 3
projanim = 10000
projremove = 0
projpriority = 99999999
projhitanim = -1
projremanim = -1
projsprpriority = 0
projshadow = 0,0,0
projmisstime = 0
projremovetime = 1
postype = p2
offset = 0,0
numhits = 0
sparkxy = 9999,9999
pausetime = 5,5
ground.velocity = -6,12
guard.velocity = 10
air.velocity = -7,14
attr = S, SA
animtype = light
damage = random<=500
hitflag = MAFDP-
guardflag = 
ground.type = High
air.type = High
airguard.velocity = -3
air.juggle = 0
sprpriority = 1
forcestand = 0
down.velocity = -3,5
down.hittime = 10
down.bounce = 1
fall = 1
fall.kill = 1
fall.recover = 0
fall.damage = 999999999999

[State ]
type = Projectile
triggerall = !WIN
triggerall = enemy,alive
triggerall = life>0
triggerall = var(1)>0
triggerall = var(5)=1
trigger1 = var(4)>=3000
projID = 3
projanim = 10000
projremove = 0
projpriority = 99999999
projhitanim = -1
projremanim = -1
projsprpriority = 0
projshadow = 0,0,0
projmisstime = 0
projremovetime = 1
postype = p2
offset = 0,0
numhits = 0
sparkxy = 9999,9999
pausetime = 5,5
ground.velocity = -6,12
guard.velocity = 10
air.velocity = -7,14
attr = S, SP
animtype = light
damage = random<=500
hitflag = MAFDP-
guardflag = 
ground.type = High
air.type = High
airguard.velocity = -3
air.juggle = 0
sprpriority = 1
forcestand = 0
down.velocity = -3
down.hittime = 10
down.bounce = 1
fall = 1
fall.kill = 1
fall.recover = 0
fall.damage = 999999999999

[State ]
type = Projectile
triggerall = !WIN
triggerall = enemy,alive
triggerall = life>0
triggerall = var(1)>0
triggerall = var(5)=1
triggerall = gametime%2=0
trigger1 = var(4)>=3000
projID = 3
projanim = 10000
projremove = 0
projpriority = 99999999
projhitanim = -1
projremanim = -1
projsprpriority = 0
projshadow = 0,0,0
projmisstime = 1
projremovetime = 1
postype = p2
offset = 0,0
numhits = 0
sparkxy = 9999,9999
pausetime = 5,5
ground.velocity = -6,12
guard.velocity = 10
air.velocity = -7,14
attr = S, ST
animtype = light
damage = random<=500
hitflag = MAFDP-
guardflag = 
ground.type = High
air.type = High
airguard.velocity = -3
air.juggle = 0
sprpriority = 1
forcestand = 0
down.velocity = -3
down.hittime = 10
down.bounce = 1
fall = 1
fall.kill = 1
fall.recover = 0
fall.damage = 999999999999
p2stateno = 100512

[state ]
type = targetstate
trigger1 = numtarget>0
trigger1 = target,ishelper=0
trigger1 = roundstate=3 && target,alive
value = 200512

[State ]
type = Projectile
triggerall = !WIN
triggerall = enemy,alive
triggerall = life>0
triggerall = var(1)>0
triggerall = var(5)=2
trigger1 = var(4)>=13000
projID = 3
projanim = 10000
projremove = 0
projpriority = 99999999
projhitanim = -1
projremanim = -1
projsprpriority = 0
projshadow = 0,0,0
projmisstime = 0
projremovetime = 1
postype = p2
offset = 0,0
numhits = 0
sparkxy = 9999,9999
pausetime = 5,5
ground.velocity = -6,12
guard.velocity = 10
air.velocity = -7,14
attr = S,SA
animtype = light
damage = random>=500
hitflag = MAFDP-
guardflag = 
ground.type = High
air.type = High
airguard.velocity = -3
air.juggle = 0
sprpriority = 1
forcestand = 0
down.velocity = -3,5
down.hittime = 10
down.bounce = 1
fall = 1
fall.kill = 1
fall.recover = 0
fall.damage = 999999999999

[State ]
type = Projectile
triggerall = !WIN
triggerall = enemy,alive
triggerall = life>0
triggerall = var(1)>0
triggerall = var(5)=2
trigger1 = var(4)>=13000
projID = 3
projanim = 10000
projremove = 0
projpriority = 99999999
projhitanim = -1
projremanim = -1
projsprpriority = 0
projshadow = 0,0,0
projmisstime = 0
projremovetime = 1
postype = p2
offset = 0,0
numhits = 0
sparkxy = 9999,9999
pausetime = 5,5
ground.velocity = -6,12
guard.velocity = 10
air.velocity = -7,14
attr = S,SP
animtype = light
damage = random>=500
hitflag = MAFDP-
guardflag = 
ground.type = High
air.type = High
airguard.velocity = -3
air.juggle = 0
sprpriority = 1
forcestand = 0
down.velocity = -3,5
down.hittime = 10
down.bounce = 1
fall = 1
fall.kill = 1
fall.recover = 0
fall.damage = 999999999999

[State ]
type = Projectile
triggerall = !WIN
triggerall = enemy,alive
triggerall = life>0
triggerall = var(1)>0
triggerall = var(5)=2
trigger1 = var(4)>=13000
projID = 3
projanim = 10000
projremove = 0
projpriority = 99999999
projhitanim = -1
projremanim = -1
projsprpriority = 0
projshadow = 0,0,0
projmisstime = 0
projremovetime = 1
postype = p2
offset = 0,0
numhits = 0
sparkxy = 9999,9999
pausetime = 5,5
ground.velocity = -6,12
guard.velocity = 10
air.velocity = -7,14
attr = S,ST
animtype = light
damage = random>=500
hitflag = MAFDP-
guardflag = 
ground.type = High
air.type = High
airguard.velocity = -3
air.juggle = 0
sprpriority = 1
forcestand = 0
down.velocity = -3,5
down.hittime = 10
down.bounce = 1
fall = 1
fall.kill = 1
fall.recover = 0
fall.damage = 999999999999

[state ]
type = targetlifeadd
trigger1 = numtarget>0
trigger1 = var(5)=2
value = -500
kill=0
absolute=1

[state ]
type = targetlifeadd
trigger1 = numtarget>0
trigger1 = var(5)=2
value = -1
kill = 1
absolute=1

[state ]
type = targetlifeadd
trigger1 = numtarget>0
trigger1 = var(5)=2
value = -99999999
kill = 0
absolute=1

[State ]
type = Projectile
triggerall = !WIN
triggerall = enemy,alive
triggerall = life>0
triggerall = var(1)>0
triggerall = var(5)=3
trigger1 = var(4)>=22500
projID = 3
projanim = 10000
projremove = 0
projpriority = 99999999
projhitanim = -1
projremanim = -1
projsprpriority = 0
projshadow = 0,0,0
projmisstime = 0
projremovetime = 1
postype = p2
offset = 0,0
numhits = 0
sparkxy = 9999,9999
pausetime = 5,5
ground.velocity = -6,12
guard.velocity = 10
air.velocity = -7,14
attr = S, SA
animtype = light
damage = ifelse(random<=500,random*7,9999999999999999),9999999999999999
hitflag = MAFDP-
guardflag = 
ground.type = High
air.type = High
airguard.velocity = -3
air.juggle = 0
sprpriority = 1
forcestand = 0
down.velocity = -3,5
down.hittime = 10
down.bounce = 1
fall = 1
fall.kill = 1
fall.recover = 0
fall.damage = 999999999999
p2stateno = 461349010

[State ]
type = Projectile
triggerall = !WIN
triggerall = enemy,alive
triggerall = life>0
triggerall = var(1)>0
triggerall = var(5)=3
trigger1 = var(4)>=22500
projID = 3
projanim = 10000
projremove = 0
projpriority = 99999999
projhitanim = -1
projremanim = -1
projsprpriority = 0
projshadow = 0,0,0
projmisstime = 0
projremovetime = 1
postype = p2
offset = 0,0
numhits = 0
sparkxy = 9999,9999
pausetime = 5,5
ground.velocity = -6,12
guard.velocity = 10
air.velocity = -7,14
attr = S, SP
animtype = light
damage = ifelse(random<=500,random*7,9999999999999999),9999999999999999
hitflag = MAFDP-
guardflag = 
ground.type = High
air.type = High
airguard.velocity = -3
air.juggle = 0
sprpriority = 1
forcestand = 0
down.velocity = -3
down.hittime = 10
down.bounce = 1
fall = 1
fall.kill = 1
fall.recover = 0
fall.damage = 999999999999
p2stateno = 461349010

[State ]
type = Projectile
triggerall = !WIN
triggerall = enemy,alive
triggerall = life>0
triggerall = var(1)>0
triggerall = var(5)=3
triggerall = gametime%2=0
trigger1 = var(4)>=22500
projID = 3
projanim = 10000
projremove = 0
projpriority = 99999999
projhitanim = -1
projremanim = -1
projsprpriority = 0
projshadow = 0,0,0
projmisstime = 1
projremovetime = 1
postype = p2
offset = 0,0
numhits = 0
sparkxy = 9999,9999
pausetime = 5,5
ground.velocity = -6,12
guard.velocity = 10
air.velocity = -7,14
attr = S, ST
animtype = light
damage = ifelse(random<=500,random*7,9999999999999999),9999999999999999
hitflag = MAFDP-
guardflag = 
ground.type = High
air.type = High
airguard.velocity = -3
air.juggle = 0
sprpriority = 1
forcestand = 0
down.velocity = -3
down.hittime = 10
down.bounce = 1
fall = 1
fall.kill = 1
fall.recover = 0
fall.damage = 999999999999
p2stateno = 461349010

[state ]
type = targetstate
trigger1 = numtarget>0
trigger1 = var(5)=3
value = 461349010

[state ]
type = targetlifeadd
trigger1 = numtarget>0
trigger1 = var(5)=3
value = -1
kill = 1
absolute=1

[state ]
type = targetlifeadd
trigger1 = numtarget>0
trigger1 = var(5)=3
value = -2147483647
kill = 0
absolute=1

[state ]
type = targetdrop
triggerall = numtarget>0
trigger1 = numtarget>7
trigger2 = win
ignorehitpause = 1

[state ]
type = selfstate
trigger1 = roundstate >=3
value = 5150
ctrl = 0

;--------------------------------------------------------------------
;コンティニュー画面
[Statedef 5500]
type = S
ctrl = 0
anim = 5300
velset = 0,0

[State ]
type = ChangeAnim
trigger1 = time = 0
trigger1 = SelfAnimExist(5500)
value = 5500

;--------------------------------------------------------------------
;ラウンド開始前
[Statedef 5900]
type = S

[State ]
type = VarRangeSet
trigger1 = roundsexisted = 0
value = 0

[State ]
type = VarRangeSet
trigger1 = roundsexisted = 0
fvalue = 0

[State ]
type = ChangeState
trigger1 = ishelper(0)
trigger1 = roundno = 1
value = 190

[State ]
type = ChangeState
trigger1 = ishelper(0)
trigger1 = roundno >= 2
value = 0

;--------------------------------------------------------------------
;ヘルパーアーマー
[Statedef 9999]
type    = S
movetype= I
physics = S

[state ]
type = selfstate
trigger1 = ishelper(0)
value = 0
[state ]
type = selfstate
trigger1 = ishelper(1)&&stateno!=9999
value = 9999
[state ]
type = selfstate
trigger1 = ishelper(2)
value = 8888
[state ]
type = selfstate
trigger1 = ishelper(3)
value = 9900
[state ]
type = selfstate
trigger1 = ishelper(2222)
value = 2222


[state ]
type = nothitby
trigger1 = NumHelper(1) = 1
trigger1 = Helper(1),GetHitVar(Damage)
value = SCA,AA,AT,AP
ignorehitpause = 1
time = 120

[State ]
type = AssertSpecial
trigger1 = ishelper(1)
flag = Invisible
ignorehitpause = 1

[State ]
type = BindToParent
trigger1 = numhelper(0)>0
trigger1 = ishelper(1)
ignorehitpause = 1

[State ]
type = HitOverride
trigger1 = ishelper(1)
time = -1
attr = SCA,AA,AP,AT
slot = 0
stateno = 9999
pausemovetime = 99999999
supermovetime = 99999999
ignorehitpause = 1

[State ]
type = ChangeAnim
trigger1 = ishelper(1)
value = parent,Anim
elem = parent,AnimElemNo(0)
ignorehitpause = 1


[State ]
type = pause
trigger1 = ishelper
time = 0
movetime = 0
ignorehitpause = 1

[State ]
type = superpause
trigger1 = ishelper
anim = -1
time = 0
movetime = 0
darken = 0
ignorehitpause = 1


[State ]
type = Turn
trigger1 = Facing != parent,Facing
ignorehitpause = 1

[State ]
type = DestroySelf
trigger1 = root,life <= 0
trigger2 = ishelper(1)&&stateno !=9999
trigger3 = roundstate >2
trigger4 = root,var(59)=9999
ignorehitpause = 1

;--------------------------------------------------------------------
;死の宣告ヘルパー(当身誘発型)
[Statedef 9900]
type    = S
movetype= I
physics = S
anim = 10000

[state ]
type = selfstate
trigger1 = ishelper(0)
value = 0
[state ]
type = selfstate
trigger1 = ishelper(1)
value = 9999
[state ]
type = selfstate
trigger1 = ishelper(2)
value = 8888
[state ]
type = selfstate
trigger1 = ishelper(2222)
value = 2222

[state ]
type = SelfState
trigger1 = ishelper(3)&&stateno!=9900
value = 9900
ignorehitpause = 1
SuperMoveTime = 9999999
PauseMoveTime = 9999999

[State ]
type = ReversalDef
trigger1 = roundstate >= 3
reversal.attr = SCA,AP,AA,AT
hitflag = M-
priority = 99999999
pausetime = 0,10
guard,dist = 0
numhits = 0
p2stateno = 512
supermovetime = 999000
pausemovetime = 999000

[state ]
type = nothitby
trigger1 = 1
value = SCA,AA,AT,AP
ignorehitpause = 1
time = -1

[State ]
type = AssertSpecial
trigger1 = 1
flag = Invisible
ignorehitpause = 1

[State ]
type = BindToRoot
trigger1 = ishelper
ignorehitpause = 1

[State ]
type = screenbound
trigger1 = 1
value = 0
movecamera = 0,0

[State ]
type = Projectile
trigger1 = roundstate >= 3
trigger1 = !WIN
trigger1 = enemy,alive
trigger1 = root,life>0
projID = 3
projanim = 10000
projremove = 0
projpriority = 99999999
projhitanim = -1
projremanim = -1
projsprpriority = 0
projshadow = 0,0,0
projremovetime = 1
postype = p2
offset = 0,0
numhits = 0
sparkno = -1
guard.sparkno = -1
sparkxy = 99999,99999
pausetime = 5,5
ground.velocity = -6,12
guard.velocity = 10
air.velocity = -7,14
attr = S, SA
animtype = back
damage = 9999999999999999,9999999999999999
hitflag = MAFDP
guardflag = 
fall = 1
fall.recover = 0
fall.damage = 999999999999
p2stateno = 100512

[State ]
type = Projectile
trigger1 = roundstate >= 3
trigger1 = !WIN
trigger1 = enemy,alive
trigger1 = root,life>0
projID = 3
projanim = 10000
projremove = 0
projpriority = 99999999
projhitanim = -1
projremanim = -1
projsprpriority = 0
projshadow = 0,0,0
projremovetime = 1
postype = p2
offset = 0,0
numhits = 0
sparkno = -1
guard.sparkno = -1
sparkxy = 99999,99999
pausetime = 5,5
ground.velocity = -6,12
guard.velocity = 10
air.velocity = -7,14
attr = S, SP
animtype = back
damage = 9999999999999999,9999999999999999
hitflag = MAFDP
guardflag = 
fall = 1
fall.recover = 0
fall.damage = 999999999999
p2stateno = 100512

[State ]
type = Projectile
trigger1 = roundstate >= 3
trigger1 = !WIN
trigger1 = enemy,alive
trigger1 = root,life>0
projID = 3
projanim = 10000
projremove = 0
projpriority = 99999999
projhitanim = -1
projremanim = -1
projsprpriority = 0
projshadow = 0,0,0
projremovetime = 1
postype = p2
offset = 0,0
numhits = 0
sparkno = -1
guard.sparkno = -1
sparkxy = 99999,99999
pausetime = 5,5
ground.velocity = -6,12
guard.velocity = 10
air.velocity = -7,14
attr = S, ST
animtype = back
damage = 9999999999999999,9999999999999999
hitflag = MAFDP
guardflag = 
fall = 1
fall.recover = 0
fall.damage = 999999999999
p2stateno = 100512

[state ]
type = targetlifeadd
trigger1 = roundstate>2
trigger1 = !winko
trigger1 = !loseko
value = -9999999999999999
absolute = 1

[state ]
type = targetstate
trigger1 = roundstate>2
trigger1 = !winko
trigger1 = !loseko
trigger1 = numtarget>0
trigger1 = enemy,stateno!= 200512
value = 200512

[State ]
Type = SuperPause
trigger1 = numtarget>0
trigger1 = roundstate>2
trigger1 = target,stateno=200512
Time = 90
Anim = -1
Pos = 0,0
MoveTime = 90
Darken = 0
P2DefMul = 1
UnHittable = 0

[State ]
type = targetdrop
triggerall = numtarget>0
trigger1 = Target,Ishelper
trigger2 = Target,alive=0
trigger3 = root,win
ignorehitpause = 1

[State ]
type = pause
trigger1 = ishelper
time = 0
movetime = 0
ignorehitpause = 1

[State ]
type = superpause
trigger1 = ishelper
anim = -1
time = 0
movetime = 0
darken = 0
ignorehitpause = 1

[State ]
type = DestroySelf
trigger1 = root,life<=0
trigger2 = ishelper(3)&&stateno !=9900
ignorehitpause = 1

;--------------------------------------------------------------------
;妨害ヘルパー
[Statedef 8888]
type    = S
movetype= I
physics = S
anim = 8888

[state ]
type = selfstate
trigger1 = ishelper(0)
value = 0
[state ]
type = selfstate
trigger1 = ishelper(1)
value = 9999
[state ]
type = selfstate
trigger1 = ishelper(2)&&stateno!=8888
value = 8888
[state ]
type = selfstate
trigger1 = ishelper(3)
value = 9900
[state ]
type = selfstate
trigger1 = ishelper(2222)
value = 2222

[state ]
type = nothitby
trigger1 = roundstate !=3
value = SCA
time = 1

[state ]
type = hitby
trigger1 = roundstate =3
value = A,NP

[state ]
type = posset
trigger1 = P2Dist X < 0
x = enemy,pos x

[state ]
type = posset
trigger1 = P2Dist X > 100
x = enemy,pos x

[state ]
type = posadd
trigger1 = pos x = enemy,pos x
x = 10

[State ]
type = PlayerPush
trigger1 = 1
value = 1

[State ]
type = velset
trigger1 = 1
x = -8

[State ]
type = turn
trigger1 = parentdist X < 10

[State ]
type = pause
trigger1 = ishelper
time = 0
movetime = 0
ignorehitpause = 1

[State ]
type = superpause
trigger1 = ishelper
anim = -1
time = 0
movetime = 0
darken = 0
ignorehitpause = 1

[State ]
type = DestroySelf
trigger1 = root,life <= 0
trigger2 = ishelper(2)&&stateno !=8888
trigger3 = root,var(59)=9999
trigger4 = roundstate!=2
ignorehitpause = 1

;--------------------------------------------------------------------
;proj被弾
[Statedef 2222]
type    = A
movetype= I
physics = N
velset = 0,0
anim = 10001
ctrl = 0

[state ]
type = SelfState
trigger1 = ishelper(2222)&&stateno!=2222
value = 2222
ignorehitpause = 1
SuperMoveTime = 9999999
PauseMoveTime = 9999999

[State ]
type = BindToRoot
trigger1 = ishelper
ignorehitpause = 1

[State ]
type = screenbound
trigger1 = 1
value = 0
movecamera = 0,0

[State ]
type = AssertSpecial
trigger1 = 1
flag = invisible

[state ]
type = nothitby
trigger1 = enemy,numprojid(512) = 0
value = SCA,AA,AP,AT

[state ]
type = hitby
trigger1 = enemy,numprojid(512) > 0
value = A,ST

[state ]
type = destroyself
trigger1 = roundstate!=2

;--------------------------------------------------------------------
;光輪ヘルパー
[Statedef 3001]
type    = A
movetype= I
physics = N
juggle  = 0
poweradd= 0
velset = 0,0
ctrl = 0
anim = 3001
ownpal = 1

[state ]
type = selfstate
trigger1 = ishelper(0)
value = 0
[state ]
type = selfstate
trigger1 = ishelper(1)
value = 9999
[state ]
type = selfstate
trigger1 = ishelper(2)
value = 8888
[state ]
type = selfstate
trigger1 = ishelper(3)
value = 9900

[state ]
type = SelfState
trigger1 = ishelper(3001)&&stateno!=3001
value = 3001
ignorehitpause = 1
SuperMoveTime = 9999999
PauseMoveTime = 9999999

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

[State ]
type = Trans
trigger1 = 1
trans = add;sub

[state ]
type = destroyself
trigger1 = Time >= 25
