;===================================
;　超必殺技 の設定
;===================================

;------------------------------------------------------------------------------------------
;聖杖・真十鏡（地上）
;------------------------------------------------------------------------------------------
[Statedef 8000]
type = S
movetype = A
physics = S
velset = 0,0
anim = 8000
sprpriority = 1
ctrl = 0

[State 8000, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S3,8
channel = 1
volume = var(21)
persistent = 0

[State 8000, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S9,3
channel = 0
volume = var(21)
persistent = 0

[State 8000, PlaySnd]
type = PlaySnd
trigger1 = animelemno(0) = 25
value = S9,4
channel = 0
volume = var(21)
persistent = 0


;衝撃波
[State -2, 1]
type = helper
trigger1 = time = 0
trigger1 = Numhelper(7002) = 0
helpertype = normal
name = "syougekiha_masokagami"
ID = 7002
pos = 0,0
postype = p1
stateno = 7002
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 9999
pausemovetime = 9999
persistent = 0

[State 8000, 2];カットインエフェクト
type = Explod
trigger1 = time = 0
anim = 6103
ID = 6103
pos = 0,-72
postype = p1
facing = 1
bindtime = -1
removetime = -2
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
;ignorehitpause = 1
persistent = 0

[State 8000, 2];背景1
type = Explod
trigger1 = time = 0
anim = 6101
ID = 6101
pos = 0,240
postype = back
facing = 1
bindtime = -1
removetime = 70
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = -2
ownpal = 1
removeongethit = 1
;ignorehitpause = 1
persistent = 0

[State 8000, 2];背景2
type = Explod
trigger1 = time = 0
anim = 6102
ID = 6102
pos = 0,240
postype = back
facing = 1
bindtime = -1
removetime = 70
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = -2
ownpal = 1
removeongethit = 1
;ignorehitpause = 1
persistent = 0

;カットインはヘルパー

[State 8000, 3]
type = SuperPause
trigger1 = time = 0
time = 40
anim = -1
;sound = S100,1
pos = 0,0
movetime = 40
darken = 0
p2defmul = 1
poweradd = -1000
unhittable = 1
persistent = 0


[State 8000, 1]
type = HitDef
trigger1 = animelemtime(7) >= 1
trigger1 = animelemtime(18) <= 1
attr = S,HP
hitflag = MAF
guardflag = MA
affectteam = E
animtype = medium
air.animtype = medium
fall.animtype = medium
priority = 1,Hit
damage = ceil(40*ifelse(palno=12,1.5,1)),4*ifelse(palno=12,5,1)
getpower = 0, 0
givepower = 33, 17
pausetime = 0, 10
guard.pausetime = 0, 10
sparkno = -1
guard.sparkno = -1
sparkxy = 0, 0
hitsound = S0,ifelse(random <= 499,2,3)
guardsound = S3, 7
ground.type = High
air.type = High
ground.hittime = 20
ground.slidetime = 20
guard.hittime = ifelse(enemynear(0),statetype != A,24,28)
guard.slidetime = ifelse(enemynear(0),statetype != A,24,28)
air.hittime = ceil(40*var(26)*0.01) + ifelse(palno=12,ceil(40*var(26)*0.01),0)
;guard.ctrltime = 0
;airguard.ctrltime = 0
yaccel = 0.2
ground.velocity = -6.5, -4
guard.velocity = -1
air.velocity = -6.5, -3.5
airguard.velocity = -0.5, -1
ground.cornerpush.veloff = 0
air.cornerpush.veloff = 0
down.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
air.juggle = 0
fall = 1
fall.recovertime = ceil(40*var(26)*0.01) + ifelse(palno=12,ceil(40*var(26)*0.01),0)
down.velocity = -3, 0
down.hittime = 20
down.bounce = 0
id = 8000
hitonce = 0
kill = 1
numhits = 1
persistent = 0
guard.dist = 300
p2facing = 1

[State 8000, 1];ヒットスパーク（線）
type = helper
triggerall = enemynear(0),stateno != [120,155]
triggerall = movehit
trigger1 = animelemtime(7) >= 1
trigger1 = animelemtime(18) <= 1
helpertype = normal
name = "hitspark"
ID = 6040
pos = 0,-60
postype = p2
stateno = 6040
keyctrl = 0
ownpal = 1
facing = 1
size.xscale = 0.5
size.yscale = 0.5
supermovetime = 0
pausemovetime = 0
sprpriority = 5
ignorehitpause=1
persistent = 0

[State 8000, 2];ヒットスパーク（草）
type = Explod
triggerall = enemynear(0),stateno != [120,155]
trigger1 = animelemtime(7) >= 1
trigger1 = animelemtime(18) <= 1
trigger1 = movehit
anim = 6041
ID = 6041
pos = -5+random%10,-60+random%5
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8000, 2];ヒットスパーク（草）
type = Explod
triggerall = enemynear(0),stateno != [120,155]
trigger1 = animelemtime(7) >= 1
trigger1 = animelemtime(18) <= 1
trigger1 = movehit
anim = 6044
ID = 6044
pos = -5+random%10,-60+random%5
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8000, 2];ガードスパーク
type = Explod
triggerall = enemynear(0),stateno != [5000,5999]
trigger1 = animelemtime(7) >= 1
trigger1 = animelemtime(18) <= 1
trigger1 = moveguarded
anim = 6050
ID = 6050
pos = 10,-55
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0




[State 8000, PlaySnd]
type = PlaySnd
trigger1 = enemynear(0),stateno != [5000,5999]
trigger1 = AnimElemTime(29) >= 0
trigger1 = animelemtime(56) <= 1
value = S3,3
channel = 2
volume = var(21)
persistent = 5
ignorehitpause = 1


[State 8000, 1]
type = HitDef
trigger1 = AnimElemTime(29) >= 1
trigger1 = animelemtime(55) <= 1
attr = S,HP
hitflag = MAF
guardflag = MA
affectteam = E
animtype = medium
air.animtype = medium
fall.animtype = medium
priority = 1,Hit
damage = ceil(20*ifelse(palno=12,1.5,1)),2*ifelse(palno=12,5,1)
getpower = 0, 0
givepower = 7, 4
pausetime = 2, 10
guard.pausetime = 2, 10
sparkno = -1
guard.sparkno = -1
sparkxy = 0, 0
hitsound = Sifelse(hitcount%2 = 0,0,99),ifelse(random <=499,0,1)
guardsound = S3, 7
ground.type = High
air.type = High
ground.hittime = 15
ground.slidetime = 15
guard.hittime = ifelse(enemynear(0),statetype != A,17,19)
guard.slidetime = ifelse(enemynear(0),statetype != A,17,19)
air.hittime = ceil(25*var(26)*0.01) + ifelse(palno=12,ceil(40*var(26)*0.01),0)
;guard.ctrltime = 0
;airguard.ctrltime = 0
yaccel = 0.2
ground.velocity = 0, 0
guard.velocity = -1
air.velocity = 0, 0
airguard.velocity = -0.5, -1
ground.cornerpush.veloff = 0
air.cornerpush.veloff = 0
down.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
air.juggle = 0
air.fall = 1
fall.recovertime = ceil(25*var(26)*0.01) + ifelse(palno=12,ceil(40*var(26)*0.01),0)
down.velocity = -3, 0
down.hittime = 15
down.bounce = 0
id = 8000
hitonce = 0
kill = 1
numhits = 1
guard.dist = 300
nochainID = ifelse(hitcount <= 16,8001,8000)
p2facing = 1

[State 8000, 1];ヒットスパーク（線）
type = helper
triggerall = enemynear(0),stateno != [120,155]
triggerall = movehit
trigger1 = AnimElemTime(29) >= 1
trigger1 = animelemtime(56) <= 1
trigger1 = Numhelper(6040) <= 8
helpertype = normal
name = "hitspark"
ID = 6040
pos = 0,-60
postype = p2
stateno = 6040
keyctrl = 0
ownpal = 1
facing = 1
size.xscale = 0.5
size.yscale = 0.5
supermovetime = 0
pausemovetime = 0
sprpriority = 5
ignorehitpause=1
persistent = 5

[State 8000, 2];ヒットスパーク（草）
type = Explod
triggerall = enemynear(0),stateno != [120,155]
trigger1 = AnimElemTime(29) >= 1
trigger1 = animelemtime(56) <= 1
trigger1 = movehit
trigger1 = NumExplod(6041) <= 8
anim = 6041
ID = 6041
pos = -5+random%10,-60+random%5
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 5

[State 8000, 2];ヒットスパーク（草）
type = Explod
triggerall = enemynear(0),stateno != [120,155]
trigger1 = AnimElemTime(29) >= 1
trigger1 = animelemtime(56) <= 1
trigger1 = movehit
trigger1 = NumExplod(6044) <= 8
anim = 6044
ID = 6044
pos = -5+random%10,-60+random%5
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 5

[State 8000, 2];ガードスパーク
type = Explod
triggerall = enemynear(0),stateno != [5000,5999]
trigger1 = moveguarded
trigger1 = AnimElemTime(29) >= 1
trigger1 = animelemtime(56) <= 1
trigger1 = NumExplod(6050) <= 8
anim = 6050
ID = 6050
pos = 10,-55
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 10



[State 8002, 1]
type = HitDef
trigger1 = animelemtime(56) = [0,1]
attr = S,HP
hitflag = MAF
guardflag = MA
affectteam = E
animtype = diagup
air.animtype = diagup
fall.animtype = diagup
priority = 1,Hit
damage = ceil(20*ifelse(palno=12,1.5,1)),2*ifelse(palno=12,5,1)
getpower = 0, 0
givepower = 7, 4
pausetime = 20, 20
guard.pausetime = 20, 20
sparkno = -1
guard.sparkno = -1
sparkxy = 0, 0
hitsound = S0,ifelse(random <= 499,4,5)
guardsound = S3, 7
ground.type = High
air.type = High
ground.hittime = 20
ground.slidetime = 20
guard.hittime = ifelse(enemynear(0),statetype != A,26,31)
guard.slidetime = ifelse(enemynear(0),statetype != A,26,31)
air.hittime = ceil(66*var(26)*0.01) + ifelse(palno=12,ceil(40*var(26)*0.01),0)
;guard.ctrltime = 0
;airguard.ctrltime = 0
yaccel = 0.2
ground.velocity = -1,-13
guard.velocity = -1
air.velocity = -1,-13
airguard.velocity = -1,-13
ground.cornerpush.veloff = 0
air.cornerpush.veloff = 0
down.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
air.juggle = 0
fall = 1
fall.recovertime = ceil(66*var(26)*0.01) + ifelse(palno=12,ceil(40*var(26)*0.01),0)
down.velocity = -3, 0
down.hittime = 20
down.bounce = 0
id = 8002
hitonce = 0
kill = 1
numhits = 1
persistent = 0
envshake.time = 10
envshake.ampl = 3
p2facing = 1

[State -2, 聖杖・真十鏡（乗算）]
type = varset
trigger1 = palno <= 11
trigger1 = movehit
;trigger1 = animelemtime(28) >= 0
fv = 5
value = ifelse(fvar(5) = 1, ceil(fvar(5)*91)*0.01, ceil(fvar(5)*91)*0.01)
ignorehitpause = 1

[State -2, 聖杖・真十鏡（12P）]
type = varset
trigger1 = palno = 12
trigger1 = movehit
;trigger1 = animelemtime(28) >= 0
fv = 5
value = ifelse(fvar(5) = 1, ceil(fvar(5)*91)*0.01, ceil(fvar(5)*100)*0.01)
ignorehitpause = 1

[State 8000, 4]
type = MoveHitReset
trigger1 = movehit
ignorehitpause = 1

[State 8000, 4]
type = changestate
trigger1 = animtime = 0
value = 0
ctrl = 1







;------------------------------------------------------------------------------------------
;聖杖・真十鏡（空中）
;------------------------------------------------------------------------------------------
[Statedef 8100]
type = A
movetype = A
physics = N
velset = 0,0
anim = 8100
sprpriority = 1
ctrl = 0

[State 8100, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S3,8
channel = 1
volume = var(21)
persistent = 0

[State 8100, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S9,3
channel = 0
volume = var(21)
persistent = 0

[State 8100, PlaySnd]
type = PlaySnd
trigger1 = animelemno(0) = 26
value = S9,4
channel = 0
volume = var(21)
persistent = 0


;衝撃波
[State -2, 1]
type = helper
trigger1 = time = 0
trigger1 = Numhelper(7002) = 0
helpertype = normal
name = "syougekiha_masokagami_air"
ID = 7002
pos = 0,0
postype = p1
stateno = 7002
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 9999
pausemovetime = 9999
persistent = 0

[State 8100, 2];カットインエフェクト
type = Explod
trigger1 = time = 0
anim = 6103
ID = 6103
pos = 0,-72
postype = p1
facing = 1
bindtime = -1
removetime = -2
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
;ignorehitpause = 1
persistent = 0

[State 8100, 2];背景1
type = Explod
trigger1 = time = 0
anim = 6101
ID = 6101
pos = 0,240
postype = back
facing = 1
bindtime = -1
removetime = 70
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = -2
ownpal = 1
removeongethit = 1
;ignorehitpause = 1
persistent = 0

[State 8100, 2];背景2
type = Explod
trigger1 = time = 0
anim = 6102
ID = 6102
pos = 0,240
postype = back
facing = 1
bindtime = -1
removetime = 70
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = -2
ownpal = 1
removeongethit = 1
;ignorehitpause = 1
persistent = 0

;カットインはヘルパー

[State 8100, 3]
type = SuperPause
trigger1 = time = 0
time = 45
anim = -1
;sound = S100,1
pos = 0,0
movetime = 45
darken = 0
p2defmul = 1
poweradd = -1000
unhittable = 1
persistent = 0

[State 8100, 3]
type = velset
trigger1 = animelemtime(33) >= 0
trigger1 = animelemtime(59) <= 1
y = 0.3

[State 8100, 3]
type = velset
trigger1 = animelemtime(60) >= 0
trigger1 = animelemtime(81) <= 1
y = 0

[State 8100, 3]
type = velset
trigger1 = animelemtime(82) >= 1
y = 0.5



[State 8100, 1]
type = HitDef
trigger1 = animelemtime(10) >= 1
trigger1 = animelemtime(20) <= 1
attr = A,HP
hitflag = MAF
guardflag = MA
affectteam = E
animtype = medium
air.animtype = medium
fall.animtype = medium
priority = 1,Hit
damage = ceil(40*ifelse(palno=12,1.5,1)),4*ifelse(palno=12,5,1)
getpower = 0, 0
givepower = 33, 17
pausetime = 0, 10
guard.pausetime = 0, 10
sparkno = -1
guard.sparkno = -1
sparkxy = 0, 0
hitsound = S0,ifelse(random <= 499,2,3)
guardsound = S3, 7
ground.type = High
air.type = High
ground.hittime = 20
ground.slidetime = 20
guard.hittime = ifelse(enemynear(0),statetype != A,24,28)
guard.slidetime = ifelse(enemynear(0),statetype != A,24,28)
air.hittime = ceil(40*var(26)*0.01) + ifelse(palno=12,ceil(40*var(26)*0.01),0)
;guard.ctrltime = 0
;airguard.ctrltime = 0
yaccel = 0.2
ground.velocity = -7.5, -4
guard.velocity = -1
air.velocity = -7.5, -4
airguard.velocity = -0.5, -1
ground.cornerpush.veloff = 0
air.cornerpush.veloff = 0
down.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
air.juggle = 0
fall = 1
fall.recovertime = ceil(40*var(26)*0.01) + ifelse(palno=12,ceil(40*var(26)*0.01),0)
down.velocity = -3, 0
down.hittime = 20
down.bounce = 0
id = 8100
hitonce = 0
kill = 1
numhits = 1
persistent = 0
guard.dist = 300
p2facing = 1

[State 8100, 1];ヒットスパーク（線）
type = helper
triggerall = enemynear(0),stateno != [120,155]
triggerall = movehit
trigger1 = animelemtime(10) >= 1
trigger1 = animelemtime(20) <= 1
helpertype = normal
name = "hitspark"
ID = 6040
pos = 0,-60
postype = p2
stateno = 6040
keyctrl = 0
ownpal = 1
facing = 1
size.xscale = 0.5
size.yscale = 0.5
supermovetime = 0
pausemovetime = 0
sprpriority = 5
ignorehitpause=1
persistent = 0

[State 8100, 2];ヒットスパーク（草）
type = Explod
triggerall = enemynear(0),stateno != [120,155]
trigger1 = animelemtime(10) >= 1
trigger1 = animelemtime(20) <= 1
trigger1 = movehit
anim = 6041
ID = 6041
pos = -5+random%10,-60+random%5
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8100, 2];ヒットスパーク（草）
type = Explod
triggerall = enemynear(0),stateno != [120,155]
trigger1 = animelemtime(10) >= 1
trigger1 = animelemtime(20) <= 1
trigger1 = movehit
anim = 6044
ID = 6044
pos = -5+random%10,-60+random%5
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8100, 2];ガードスパーク
type = Explod
triggerall = enemynear(0),stateno != [5000,5999]
trigger1 = animelemtime(10) >= 1
trigger1 = animelemtime(20) <= 1
trigger1 = moveguarded
anim = 6050
ID = 6050
pos = 10,-55
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0




[State 8100, PlaySnd]
type = PlaySnd
trigger1 = enemynear(0),stateno != [5000,5999]
trigger1 = AnimElemTime(30) >= 0
trigger1 = animelemtime(57) <= 1
value = S3,3
channel = 2
volume = var(21)
persistent = 5
ignorehitpause = 1



[State 8100, 1]
type = HitDef
trigger1 = AnimElemTime(30) >= 1
trigger1 = animelemtime(56) <= 1
attr = A,HP
hitflag = MAF
guardflag = MA
affectteam = E
animtype = medium
air.animtype = medium
fall.animtype = medium
priority = 1,Hit
damage = ceil(20*ifelse(palno=12,1.5,1)),2*ifelse(palno=12,5,1)
getpower = 0, 0
givepower = 7, 4
pausetime = 2, 10
guard.pausetime = 2, 10
sparkno = -1
guard.sparkno = -1
sparkxy = 0, 0
hitsound = Sifelse(hitcount%2 = 0,0,99),ifelse(random <=499,0,1)
guardsound = S3, 7
ground.type = High
air.type = High
ground.hittime = 15
ground.slidetime = 15
guard.hittime = ifelse(enemynear(0),statetype != A,17,19)
guard.slidetime = ifelse(enemynear(0),statetype != A,17,19)
air.hittime = ceil(25*var(26)*0.01) + ifelse(palno=12,ceil(40*var(26)*0.01),0)
;guard.ctrltime = 0
;airguard.ctrltime = 0
yaccel = 0.2
ground.velocity = 0, 0
guard.velocity = -1
air.velocity = 0, 0
airguard.velocity = -0.5, -1
ground.cornerpush.veloff = 0
air.cornerpush.veloff = 0
down.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
air.juggle = 0
air.fall = 1
fall.recovertime = ceil(25*var(26)*0.01) + ifelse(palno=12,ceil(40*var(26)*0.01),0)
down.velocity = -3, 0
down.hittime = 15
down.bounce = 0
id = 8100
hitonce = 0
kill = 1
numhits = 1
guard.dist = 300
nochainID = ifelse(hitcount <= 16,8101,8100)
p2facing = 1

[State 8100, 1];ヒットスパーク（線）
type = helper
triggerall = enemynear(0),stateno != [120,155]
triggerall = movehit
trigger1 = AnimElemTime(30) >= 1
trigger1 = animelemtime(56) <= 1
trigger1 = Numhelper(6040) <= 8
helpertype = normal
name = "hitspark"
ID = 6040
pos = 0,-60
postype = p2
stateno = 6040
keyctrl = 0
ownpal = 1
facing = 1
size.xscale = 0.5
size.yscale = 0.5
supermovetime = 0
pausemovetime = 0
sprpriority = 5
ignorehitpause=1
persistent = 5

[State 8000, 2];ヒットスパーク（草）
type = Explod
triggerall = enemynear(0),stateno != [120,155]
trigger1 = AnimElemTime(30) >= 1
trigger1 = animelemtime(56) <= 1
trigger1 = movehit
trigger1 = NumExplod(6041) <= 8
anim = 6041
ID = 6041
pos = -5+random%10,-60+random%5
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 5

[State 8000, 2];ヒットスパーク（草）
type = Explod
triggerall = enemynear(0),stateno != [120,155]
trigger1 = AnimElemTime(30) >= 1
trigger1 = animelemtime(56) <= 1
trigger1 = movehit
trigger1 = NumExplod(6044) <= 8
anim = 6044
ID = 6044
pos = -5+random%10,-60+random%5
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 5

[State 8000, 2];ガードスパーク
type = Explod
triggerall = enemynear(0),stateno != [5000,5999]
trigger1 = moveguarded
trigger1 = AnimElemTime(30) >= 1
trigger1 = animelemtime(56) <= 1
trigger1 = NumExplod(6050) <= 8
anim = 6050
ID = 6050
pos = 10,-55
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 10



[State 8100, 1]
type = HitDef
trigger1 = animelemtime(57) = [0,1]
attr = A,HP
hitflag = MAF
guardflag = MA
affectteam = E
animtype = hard
air.animtype = hard
fall.animtype = hard
priority = 1,Hit
damage = ceil(20*ifelse(palno=12,1.5,1)),2*ifelse(palno=12,5,1)
getpower = 0, 0
givepower = 7, 4
pausetime = 26, 26
guard.pausetime = 26, 26
sparkno = -1
guard.sparkno = -1
sparkxy = 0, 0
hitsound = S0,ifelse(random <= 499,4,5)
guardsound = S3, 7
ground.type = High
air.type = High
ground.hittime = 20
ground.slidetime = 20
guard.hittime = ifelse(enemynear(0),statetype != A,26,31)
guard.slidetime = ifelse(enemynear(0),statetype != A,26,31)
air.hittime = ceil(66*var(26)*0.01) + ifelse(palno=12,ceil(40*var(26)*0.01),0)
;guard.ctrltime = 0
;airguard.ctrltime = 0
;yaccel = 0
ground.velocity = 0, 0
guard.velocity = 0
air.velocity = 0, 0
airguard.velocity = -1, -4
ground.cornerpush.veloff = 0
air.cornerpush.veloff = 0
down.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
air.juggle = 0
fall = 1
fall.recover = 0
;fall.recovertime = ceil(66*var(26)*0.01) + ifelse(palno=12,ceil(40*var(26)*0.01),0)
down.velocity = -3, 0
down.hittime = 15
down.bounce = 0
id = 8102
hitonce = 0
kill = 1
numhits = 1
persistent = 0
envshake.time = 10
envshake.ampl = 3
p2facing = 1

[State 8100, 1];ヒットスパーク（線）
type = helper
triggerall = enemynear(0),stateno != [120,155]
triggerall = movehit
trigger1 = animelemtime(57) = [0,1]
helpertype = normal
name = "hitspark"
ID = 6040
pos = 0,-60
postype = p2
stateno = 6040
keyctrl = 0
ownpal = 1
facing = 1
size.xscale = 0.5
size.yscale = 0.5
supermovetime = 0
pausemovetime = 0
sprpriority = 5
ignorehitpause=1
persistent = 0

[State 8000, 2];ヒットスパーク（草）
type = Explod
triggerall = enemynear(0),stateno != [120,155]
trigger1 = animelemtime(57) = [0,1]
trigger1 = movehit
anim = 6041
ID = 6041
pos = -5+random%10,-60+random%5
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8000, 2];ヒットスパーク（草）
type = Explod
triggerall = enemynear(0),stateno != [120,155]
trigger1 = animelemtime(57) = [0,1]
trigger1 = movehit
anim = 6044
ID = 6044
pos = -5+random%10,-60+random%5
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8000, 2];ガードスパーク
type = Explod
triggerall = enemynear(0),stateno != [5000,5999]
trigger1 = moveguarded
trigger1 = animelemtime(57) = [0,1]
anim = 6050
ID = 6050
pos = 10,-55
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0



[State 8100, 3]
type = targetstate
trigger1 = NumTarget(8102) >= 1
trigger1 = Target(8102),ishelper = 0
trigger1 = movehit
value = 1630
ID = 8102
persistent = 0

[State 8100, 3]
type = targetvelset
trigger1 = NumTarget(8102) >= 1
trigger1 = Target(8102),ishelper = 0
trigger1 = movehit
x = -1
y = 13
ID = 8102
persistent = 0


[State -2, 聖杖・真十鏡（乗算）]
type = varset
triggerall = palno <= 11
trigger1 = movehit
trigger1 = Numtarget(8102) = 0
fv = 5
value = ifelse(fvar(5) = 1, ceil(fvar(5)*91)*0.01, ceil(fvar(5)*91)*0.01)
ignorehitpause = 1

[State -2, 聖杖・真十鏡（乗算）]
type = varset
triggerall = palno <= 11
trigger1 = movehit
trigger1 = Numtarget(8102) >= 1
fv = 5
value = ifelse(fvar(5) = 1, ceil(fvar(5)*91)*0.01, ceil(fvar(5)*91)*0.01)
persistent = 0
ignorehitpause = 1

[State -2, 聖杖・真十鏡（12P）]
type = varset
triggerall = palno = 12
trigger1 = movehit
fv = 5
value = ifelse(fvar(5) = 1, ceil(fvar(5)*91)*0.01, ceil(fvar(5)*100)*0.01)
ignorehitpause = 1

[State 8100, 4]
type = MoveHitReset
trigger1 = movehit
trigger1 = Numtarget(8102) = 0
ignorehitpause = 1

[State 8100, 4]
type = changestate
trigger1 = animtime = 0
value = 51
ctrl = 1


;空投げ敵
[Statedef 8130]
type = A
movetype= H
physics = N
ctrl = 0
sprpriority = 1

[State 8130, 1]
type = changeanim2
trigger1 = time = 0
value = 1630
persistent = 0

[State 8130, 1]
type = PlayerPush
trigger1 = 1
value = 0

[State 8130, 1]
type = changestate
trigger1 = pos y >= 0
value = 8131

[State 8130, 2]
type = posset
trigger1 = time >= 100
y = 0
[State 8130, 2]
type = velset
trigger1 = time >= 100
x = 0
y = 0
[State 8130, 2]
type = selfstate
trigger1 = time >= 100
value = 5100
ctrl = 0


[Statedef 8131]
movetype= H
ctrl = 0
sprpriority = 1
velset = 0,0
anim = 5100

[State 8131, 1]
type = PosFreeze
trigger1 = anim = 5100
value = 1

[State 8131, 2]
type = EnvShake
trigger1 = time = 0
time = 10
ampl = 4
persistent = 0

[State 8131, 3]
type = changeanim2
trigger1 = time >= 10
value = 1630
persistent = 0

[State 8131, 3]
type = velset
trigger1 = anim = 1630
x = -0.5
y = -7
persistent = 0

[State 8131, 3]
type = veladd
trigger1 = anim = 1630
y = 0.3

[State 8131, 4]
type = selfstate
trigger1 = time >= 30 + ifelse(enemynear(0),palno=12,40,0)
value = 5040




;------------------------------------------------------------------------------------------
;解放・射干玉
;------------------------------------------------------------------------------------------
[Statedef 8200]
type = S
movetype = I
physics = S
velset = 0,0
anim = 8200
sprpriority = 1
ctrl = 0

[State 8200, 1]
type = varset
trigger1 = time = 0
v = 20
value = 3
persistent = 0

[State 8200, 1]
type = varset
triggerall = animelemtime(1) <= 40
triggerall = command = "a" && command != "b" && command != "c"
trigger1 = Numhelper(8210) >= 1
trigger1 = helper(8210),stateno != 3910
trigger2 = Numhelper(8211) >= 1
trigger2 = helper(8211),stateno != 3910
trigger3 = Numhelper(8212) >= 1
trigger3 = helper(8212),stateno != 3910
trigger4 = Numhelper(8213) >= 1
trigger4 = helper(8213),stateno != 3910
trigger5 = Numhelper(8214) >= 1
trigger5 = helper(8214),stateno != 3910
trigger6 = Numhelper(8215) >= 1
trigger6 = helper(8215),stateno != 3910
trigger7 = Numhelper(8210)+Numhelper(8211)+Numhelper(8212)+Numhelper(8213)+Numhelper(8214)+Numhelper(8215) = 0
v = 20
value = 1

[State 8200, 1]
type = varset
triggerall = animelemtime(1) <= 40
triggerall = command = "b" && command != "a" && command != "c"
trigger1 = Numhelper(8210) >= 1
trigger1 = helper(8210),stateno != 4010
trigger2 = Numhelper(8211) >= 1
trigger2 = helper(8211),stateno != 4010
trigger3 = Numhelper(8212) >= 1
trigger3 = helper(8212),stateno != 4010
trigger4 = Numhelper(8213) >= 1
trigger4 = helper(8213),stateno != 4010
trigger5 = Numhelper(8214) >= 1
trigger5 = helper(8214),stateno != 4010
trigger6 = Numhelper(8215) >= 1
trigger6 = helper(8215),stateno != 4010
trigger7 = Numhelper(8210)+Numhelper(8211)+Numhelper(8212)+Numhelper(8213)+Numhelper(8214)+Numhelper(8215) = 0
v = 20
value = 2

[State 8200, 1]
type = varset
triggerall = animelemtime(1) <= 40
triggerall = command = "c" && command != "a" && command != "b"
trigger1 = Numhelper(8210) >= 1
trigger1 = helper(8210),stateno != 4110
trigger2 = Numhelper(8211) >= 1
trigger2 = helper(8211),stateno != 4110
trigger3 = Numhelper(8212) >= 1
trigger3 = helper(8212),stateno != 4110
trigger4 = Numhelper(8213) >= 1
trigger4 = helper(8213),stateno != 4110
trigger5 = Numhelper(8214) >= 1
trigger5 = helper(8214),stateno != 4110
trigger6 = Numhelper(8215) >= 1
trigger6 = helper(8215),stateno != 4110
trigger7 = Numhelper(8210)+Numhelper(8211)+Numhelper(8212)+Numhelper(8213)+Numhelper(8214)+Numhelper(8215) = 0
v = 20
value = 3


[State 8200, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S3,8
channel = 1
volume = var(21)
persistent = 0

[State 8200, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S9,5
channel = 0
volume = var(21)
persistent = 0

[State 8200, PlaySnd]
type = PlaySnd
trigger1 = animelemtime(8) = 1
value = S2,6
channel = 4
volume = var(21)
persistent = 0

[State 8200, 2];カットインエフェクト
type = Explod
trigger1 = time = 0
anim = 6103
ID = 6103
pos = 0,-72
postype = p1
facing = 1
bindtime = -1
removetime = -2
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
;ignorehitpause = 1
persistent = 0

[State 8200, 2];背景1
type = Explod
trigger1 = time = 0
anim = 6101
ID = 6101
pos = 0,240
postype = back
facing = 1
bindtime = -1
removetime = 70
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = -2
ownpal = 1
removeongethit = 1
;ignorehitpause = 1
persistent = 0

[State 8200, 2];背景2
type = Explod
trigger1 = time = 0
anim = 6102
ID = 6102
pos = 0,240
postype = back
facing = 1
bindtime = -1
removetime = 70
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = -2
ownpal = 1
removeongethit = 1
;ignorehitpause = 1
persistent = 0

;カットインはヘルパー

[State 8200, 3]
type = SuperPause
trigger1 = time = 0
time = 40
anim = -1
;sound = S100,1
pos = 0,0
movetime = 40
darken = 0
p2defmul = 1
poweradd = -1000
unhittable = 1
persistent = 0

[State 8200, 4]
type = helper
trigger1 = palno <= 11
trigger1 = animelemtime(8) = 1
trigger1 = Numhelper(8210) = 0
helpertype = normal
name = "tyou_big0"
ID = 8210
pos = 2,-85
postype = p1
stateno = 8210
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 9999
pausemovetime = 9999
persistent = 0

[State 8200, 4]
type = helper
trigger1 = palno <= 11
trigger1 = animelemtime(8) = 1
helpertype = normal
name = "tyou_big1"
ID = 8211
pos = 2,-85
postype = p1
stateno = 8210
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 9999
pausemovetime = 9999
persistent = 0

[State 8200, 4]
type = helper
trigger1 = palno <= 11
trigger1 = animelemtime(8) = 1
helpertype = normal
name = "tyou_big2"
ID = 8212
pos = 2,-85
postype = p1
stateno = 8210
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 9999
pausemovetime = 9999
persistent = 0

[State 8200, 4]
type = helper
trigger1 = palno <= 11
trigger1 = animelemtime(8) = 1
helpertype = normal
name = "tyou_big3"
ID = 8213
pos = 2,-85
postype = p1
stateno = 8210
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 9999
pausemovetime = 9999
persistent = 0

[State 8200, 4]
type = helper
trigger1 = palno <= 11
trigger1 = animelemtime(8) = 1
helpertype = normal
name = "tyou_big4"
ID = 8214
pos = 2,-85
postype = p1
stateno = 8210
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 9999
pausemovetime = 9999
persistent = 0

[State 8200, 4]
type = helper
trigger1 = palno <= 11
trigger1 = animelemtime(8) = 1
helpertype = normal
name = "tyou_big5"
ID = 8215
pos = 2,-85
postype = p1
stateno = 8210
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 9999
pausemovetime = 9999
persistent = 0

[State 8200, 5]
type = changestate
trigger1 = animtime = 0
value = 0
ctrl = 1



;大きい蝶
[Statedef 8210]
type = A
movetype = I
physics = N
velset = 0,0
anim = 8210
sprpriority = 5
ctrl = 0

[State 8210, 1]
type = AssertSpecial
trigger1 = !Ishelper(8210)
flag = noshadow
flag2 = Invisible

[State 8210, 5]
type = BindToParent
trigger1 = time = 0
pos = 2,-85
persistent = 0

[State 8210, 1]
type = varset
trigger1 = time = 0
v = 0
value = parent,var(20)
persistent = 0

[State 8210, 2]
type = velset
trigger1 = 1
x = 0.4
y = -0.5*sin(time*0.05) ;横方向に長く

[State 8210, 3]
type = PalFX
trigger1 = time = 0 ; 出現が始まる時間
time = 5 ; 完全に出るまでの時間*1
add = -255,-255,-255
sinadd = 256,256,256,104
;ignorehitpause = 1

[State 8210, 5]
type = changestate
trigger1 = time >= 128
value = ifelse(root,palno = 12,8230,8211)

[State 8210, 6]
type = destroyself
trigger1 = root,palno <= 11
trigger1 = var(0) = [1,2]
trigger1 = Ishelper(8214) || Ishelper(8215)
trigger2 = root,palno = 12
trigger2 = var(0) = 1
trigger2 = Ishelper(8213) || Ishelper(8214) || Ishelper(8215)
trigger3 = root,palno = 12
trigger3 = var(0) = 2
trigger3 = Ishelper(8212) || Ishelper(8213) || Ishelper(8214) || Ishelper(8215)

;小さい蝶
[Statedef 8211]
type = A
movetype = I
physics = N
velset = 0,0
anim = 8211
sprpriority = 5
ctrl = 0

[State 8211, 2]
type = velset
trigger1 = time = 0
trigger1 = var(0) = [1,2]
x = 0.05*(1+random%10)
y = 0.06*(3+random%20)
persistent = 0

[State 8211, 2]
type = velset
trigger1 = var(0) = [1,2]
trigger1 = pos y >= 0
x = 0
y = 0

[State 8211, 2]
type = posset
trigger1 = var(0) = [1,2]
trigger1 = pos y >= 0
y = 0

[State 8211, 3]
type = changeanim
trigger1 = var(0) = [1,2]
trigger1 = pos y >= 0
value = 8212
persistent = 0

[State 8211, 4]
type = changestate
trigger1 = var(0) = [1,2]
trigger1 = anim = 8212
trigger1 = animtime = 0
value = ifelse(var(0) = 1,3910,4010)


[State 8211, 2]
type = varrandom
trigger1 = var(0) = 3
v = 1
range = 0,24
persistent = 0

[State 8211, 2]
type = velset
trigger1 = time = 0
trigger1 = var(0) = 3
x = 0.1*(2+random%9)
y = -0.1*(1+random%10)
persistent = 0

[State 8211, 3]
type = velset
trigger1 = var(0) = 3
trigger1 = time = 28 + var(1)
x = 0
y = 0

[State 8211, 3]
type = changeanim
trigger1 = var(0) = 3
trigger1 = time = 28 + var(1)
value = 8212

[State 8211, 4]
type = changestate
trigger1 = var(0) = 3
trigger1 = anim = 8212
trigger1 = animtime = 0
value = 4110

[State 8211, 5]
type = destroyself
trigger1 = root,stateno = 20007




;小さい蝶(12P)
[Statedef 8230]
type = A
movetype = I
physics = N
velset = 0,0
anim = 8211
sprpriority = 5
ctrl = 0

[State 8211, 2]
type = velset
trigger1 = time = 0
trigger1 = var(0) = 1
x = ifelse(Ishelper(8210),0,ifelse(ishelper(8211),0.1,-0.1))
y = 0.6
persistent = 0

[State 8211, 2]
type = velset
trigger1 = var(0) = 1
trigger1 = pos y >= 0
x = 0
y = 0

[State 8211, 2]
type = posset
trigger1 = var(0) = 1
trigger1 = pos y >= 0
y = 0

[State 8211, 3]
type = changeanim
trigger1 = var(0) = 1
trigger1 = pos y >= 0
value = 8212
persistent = 0

[State 8211, 4]
type = changestate
trigger1 = var(0) = 1
trigger1 = anim = 8212
trigger1 = animtime = 0
value = 3910



[State 8211, 2]
type = velset
trigger1 = time = 0
trigger1 = var(0) = 2
x = 0
y = ifelse(Ishelper(8210),0.6,-0.9)
persistent = 0

[State 8211, 2]
type = velset
triggerall = var(0) = 2
trigger1 = pos y >= 0
trigger1 = Ishelper(8210)
trigger2 = screenpos y <= 0
trigger1 = Ishelper(8211)
x = 0
y = 0

[State 8211, 2]
type = posset
trigger1 = var(0) = 2
trigger1 = Ishelper(8210)
trigger1 = pos y >= 0
y = 0

[State 8211, 2]
type = posset
trigger1 = var(0) = 2
trigger1 = Ishelper(8211)
trigger1 = screenpos y <= 0
trigger1 = Numhelper(7000) = 1
y = -1*ceil(helper(7000),screenpos y)

[State 8211, 3]
type = changeanim
triggerall = var(0) = 2
trigger1 = pos y >= 0
trigger1 = Ishelper(8210)
trigger2 = screenpos y <= 0
trigger2 = Ishelper(8211)
trigger3 = time >= 600
value = 8212
persistent = 0

[State 8211, 4]
type = changestate
trigger1 = var(0) = 2
trigger1 = anim = 8212
trigger1 = animtime = 0
value = 4030





[State 8211, 2]
type = varrandom
trigger1 = var(0) = 3
v = 1
range = 0,24
persistent = 0

[State 8211, 2]
type = velset
trigger1 = time = 0
trigger1 = var(0) = 3
x = 0.1*(2+random%9)
y = -0.1*(1+random%10)
persistent = 0

[State 8211, 3]
type = velset
trigger1 = var(0) = 3
trigger1 = time = 28 + var(1)
x = 0
y = 0

[State 8211, 3]
type = changeanim
trigger1 = var(0) = 3
trigger1 = time = 28 + var(1)
value = 8212

[State 8211, 4]
type = changestate
trigger1 = var(0) = 3
trigger1 = anim = 8212
trigger1 = animtime = 0
value = 4110

[State 8211, 5]
type = destroyself
trigger1 = root,stateno = 20007



;------------------------------------------------------------------------------------------
;鳥獣・五百重波
;------------------------------------------------------------------------------------------
[Statedef 8300]
type = S
movetype = A
physics = S
velset = 0,0
anim = 8300
sprpriority = 1
ctrl = 0

[State 8300, 1]
type = NotHitBy
trigger1 = animelemtime(23) <= 2
value = SCA,AA,AT,AP
ignorehitpause = 1

[State 8300, 1]
type = width
trigger1 = 1
edge = 0,44

[State 8300, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S3,8
channel = 1
volume = var(21)
persistent = 0

[State 8300, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S9,6
channel = 0
volume = var(21)
persistent = 0

[State 8300, 2];カットインエフェクト
type = Explod
trigger1 = time = 0
anim = 6103
ID = 6103
pos = 0,-72
postype = p1
facing = 1
bindtime = -1
removetime = -2
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
;ignorehitpause = 1
persistent = 0

[State 8300, 2];背景1
type = Explod
trigger1 = time = 0
anim = 6101
ID = 6101
pos = 0,240
postype = back
facing = 1
bindtime = -1
removetime = 70
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = -2
ownpal = 1
removeongethit = 1
;ignorehitpause = 1
persistent = 0

[State 8300, 2];背景2
type = Explod
trigger1 = time = 0
anim = 6102
ID = 6102
pos = 0,240
postype = back
facing = 1
bindtime = -1
removetime = 70
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = -2
ownpal = 1
removeongethit = 1
;ignorehitpause = 1
persistent = 0

;カットインはヘルパー

[State 8300, 3]
type = SuperPause
trigger1 = time = 1
time = 45
anim = -1
;sound = S100,1
pos = 0,0
movetime = 45
darken = 0
p2defmul = 1
poweradd = -1000
unhittable = 1
persistent = 0

[State 8300, 4]
type = changestate
trigger1 = enemynear(0),movetype = H
trigger1 = enemynear(0),stateno = 8311 || enemynear(0),stateno = 8312
value = 8350
ctrl = 0

[State 8300, 4]
type = changestate
trigger1 = animtime = 0
value = 0
ctrl = 1


;-----------------------
;ふすみの動作（ロック前）
;-----------------------
[Statedef 8305]
type = A
movetype = A
physics = N
velset = 0,0
sprpriority = 2
anim = 7050

[State 8305, 1]
type = varset
trigger1 = time = 0
v = 0
value = 0

[State 8305, 1]
type = changestate
trigger1 = parent,movetype = H
value = 7050

;-19,-42

[State -2, 1]
type = attackmulset
trigger1 = 1
trigger1 = Numhelper(7000) >= 1
value = 1*root,fvar(5)*0.9*helper(7000),fvar(0)*helper(7000),fvar(2)*helper(7000),fvar(3)
ignorehitpause = 1

[State 8305, 1]
type = posadd
trigger1 = parent,anim = 8300
trigger1 = parent,animelemtime(3) <= 26
trigger1 = parentdist x > 19
x = ifelse(parentdist x < 24,1,5)

[State 8305, 1]
type = posadd
trigger1 = parent,anim = 8300
trigger1 = parent,animelemtime(3) <= 26
trigger1 = parentdist x < 19
x = ifelse(parentdist x > 14,-1,-5)

[State 8305, 1]
type = posadd
trigger1 = parent,anim = 8300
trigger1 = parent,animelemtime(3) <= 26
trigger1 = parentdist y > 42
y = ifelse(parentdist y < 47,1,5)

[State 8305, 1]
type = posadd
trigger1 = parent,anim = 8300
trigger1 = parent,animelemtime(3) <= 26
trigger1 = parentdist y < 42
y = ifelse(parentdist y > 37,-1,-5)

[State 8305, 1]
type = changeanim
trigger1 = parent,anim = 8300
trigger1 = parent,animelemtime(4) = 0
value = 8305
persistent = 0

[State 8305, 1]
type = BindToParent
trigger1 = parent,anim = 8300
trigger1 = parent,animelemtime(4) = 0
pos = -19,-42
persistent = 0

[State 8305, 1]
type = posadd
trigger1 = parent,anim = 8300
trigger1 = parent,animelemno(0) = 4
y = -1

[State 8305, 1]
type = BindToParent
trigger1 = parent,anim = 8300
trigger1 = parent,animelemtime(5) = 0
pos = -20,-48
persistent = 0

[State 8305, 1]
type = velset
trigger1 = parent,anim = 8300
trigger1 = parent,animelemtime(5) = 3
x = 10
persistent = 0

[State 8305, PlaySnd]
type = PlaySnd
trigger1 = parent,anim = 8300
trigger1 = parent,animelemtime(6) = 0
value = S1,8
channel = 4
volume = var(21)
persistent = 0

[State 8305, 3]
type = Explod
trigger1 = parent,anim = 8300
trigger1 = parent,animelemtime(5) >= 3
trigger1 = Numexplod(1717) = 0
anim = 1717
ID = 1717
pos = 0,0
postype = p1
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 0
;persistent = 0


[State 8305, 2];ヒットスパーク
type = Explod
triggerall = enemynear(0),stateno != [120,155]
trigger1 = movehit
anim = 6011+random%4
ID = 6011
pos = 0+random%5,-55+random%5
postype = p2
facing = 1
bindtime = 1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.4, 0.4
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8305, 1];ヒットスパーク（線）
type = helper
triggerall = enemynear(0),stateno != [120,155]
trigger1 = movehit
helpertype = normal
name = "hitspark"
ID = 6030
pos = 0,-55
postype = p2
stateno = 6030
keyctrl = 0
ownpal = 1
facing = 1
size.xscale = 0.5
size.yscale = 0.5
supermovetime = 0
pausemovetime = 0
sprpriority = 5
ignorehitpause=1
persistent = 0

[State 8305, 2]
type = HitDef
trigger1 = parent,movetype != H
trigger1 = animelemno(0) >= 3
attr = A,HP
hitflag = MAF
guardflag = MA
affectteam = E
animtype = hard
air.animtype = hard
fall.animtype = hard
priority = 3,Hit
damage = 20*ifelse(root,palno=12,2,1)
getpower = 0,0
givepower = ceil(root,fvar(5)*15), 7
pausetime = 20, 20
guard.pausetime = 20, 20
sparkno = -1
guard.sparkno = -1
;sparkxy = -5, -60
hitsound = S0 ,ifelse(random <=499,4,5)
guardsound = S3, 7
ground.type = low
air.type = low
ground.slidetime = 18
guard.slidetime = 18
ground.hittime = 18
guard.hittime = 18
air.hittime = 30
;guard.ctrltime = 0
yaccel = 0
ground.velocity = 0, 0;-4
guard.velocity = -8
air.velocity = 0, 0;-3.5
;airguard.velocity = -3, -6
;airguard.ctrltime = 11
air.juggle = 1
sprpriority = 1
p1facing = 1
p2facing = 1
forcestand = 0
fall = 1
fall.recovertime = 30
;down.velocity = -8, 0
;down.hittime = 10
;down.bounce = 0
envshake.time = 10
envshake.ampl = 3
id = 8305
hitonce = 0
kill = 0
numhits = 1
persistent = 0

[State 8305, 2]
type = targetstate
trigger1 = NumTarget(8305) >= 1
trigger1 = Target(8305),ishelper = 0
trigger1 = movehit
value = 8310
ID = 8305
persistent = 0

[State 8305, 2];ガードスパーク
type = Explod
triggerall = enemynear(0),stateno != [5000,5999]
trigger1 = moveguarded
anim = 6050
ID = 6050
pos = 10,-55
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8305, 1]
type = changestate
trigger1 = time >= 106
value = 7050



;敵のステート
[Statedef 8310]
type = A
movetype = H
physics = N
velset = 0,0
anim = 5030
sprpriority = 1

[State 8310, 1]
type = PlayerPush
trigger1 = 1
value = 0

[State 8310, 1]
type = posset
trigger1 = time = 0
y = -5
persistent = 0

[State 8310, 2]
type = velset
trigger1 = 1
x = -8

[State 8310, 3]
type = changeanim2
trigger1 = time = 0
value = 610
elem = 1
persistent = 0

[State 8310, 4]
type = changestate
trigger1 = backedgebodydist < 1
value = 8311
ctrl = 0

[Statedef 8311]
type = A
movetype = H
physics = N
velset = 0,0
sprpriority = 1

[State 8311,1]
type = EnvShake
trigger1 = time = 5
time = 10
ampl = -4
persistent = 0

[State 8311, 1]
type = changeanim2
trigger1 = time = 0
value = 611
persistent = 0

[State 8311, 1]
type = veladd
trigger1 = time = 15
x = 1
y = -6
persistent = 0

[State 8311, 1]
type = changestate
trigger1 = time = 15
value = 8312

[Statedef 8312]
type = A
movetype = H
physics = N
sprpriority = 1

[State 8312, 1]
type = veladd
trigger1 = 1
y = 0.38

[State 8312, 1]
type = null;turn
trigger1 = time = 0
persistent = 0

[State 8312, 1]
type = changeanim2
trigger1 = time = 0
value = 612
persistent = 0

[State 8312, 2]
type = selfstate
trigger1 = time >= 10
trigger1 = pos y > 0
value = 5100
ctrl = 0



;ヒット後の本体
[Statedef 8350]
type = S
movetype = I
physics = S
velset = 0,0
anim = 8350
sprpriority = 1
ctrl = 0

[State 8350, 1]
type = varset
trigger1 = time = 0
v = 20
value = 0
persistent = 0

[State 8350, 1]
type = PlaySnd
trigger1 = animelemtime(4) = 6
value = S6, 3
channel = 0
volume = var(21)
persistent = 0

[State 8350, 1]
type = PlaySnd
trigger1 = animelemtime(43) = 1
value = S9, 7
channel = 0
volume = var(21)
persistent = 0

[State 8350, 1]
type = LifeAdd
trigger1 = animelemtime(43) = 1
value = -4
kill = 0
absolute = 1
persistent = 0

[State 8350, 1]
type = width
trigger1 = 1
edge = 0,74

[State 8350, 3]
type = helper
trigger1 = Animelemtime(5) = 0
helpertype = normal
name = "hayata"
ID = 8360
pos = 0,0
postype = p1
stateno = 8360
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 0
pausemovetime = 0
persistent = 0

[State 8350, 4];ヒットスパーク
type = Explod
trigger1 = animelemtime(43) = 0
anim = 6001+random%4
ID = 6001
pos = -70,-31
postype = p1
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8350, 2]
type = changestate
trigger1 = Numhelper(8360) >= 1
trigger1 = helper(8360),animelemno(0) = 25
trigger1 = helper(8360),movehit
value = 8355

[State 8350, 2]
type = changestate
trigger1 = Numhelper(8370) >= 1
trigger1 = helper(8370),movehit >= 10
value = 0
ctrl = 1


[Statedef 8355]
type = S
movetype = I
physics = S
velset = 0,0
anim = 8355
sprpriority = 1
ctrl = 0

[State 8355, 1]
type = varset
trigger1 = time = 0
v = 20
value = 0
persistent = 0

[State 8355, 1]
type = varadd
trigger1 = 1
v = 20
value = 1

[State 8355, 1]
type = width
trigger1 = 1
edge = 0,74

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

[State 8355, 1]
type = AssertSpecial
trigger1 = var(20) >= 40
flag = invisible

[State 8355, 2];背景1
type = Explod
trigger1 = Numhelper(8360) >= 1
trigger1 = helper(8360),animelemtime(28) >= 18
anim = 8365
ID = 8365
pos = 0,240
postype = back
facing = 1
bindtime = -1
removetime = -2
supermovetime = 9999
pausemovetime = 9999
scale = 1, 1
sprpriority = 7
ownpal = 1
ontop = 1
removeongethit = 1
;ignorehitpause = 1
persistent = 0

[State 8355, 2];背景2
type = Explod
trigger1 = Numhelper(8360) >= 1
trigger1 = helper(8360),animelemtime(28) >= 18
anim = 8366
ID = 8366
pos = 0,240
postype = back
facing = 1
bindtime = -1
removetime = -1
supermovetime = 9999
pausemovetime = 9999
scale = 1, 1
sprpriority = -3
ownpal = 1
removeongethit = 1
;ignorehitpause = 1
persistent = 0


[State 8355, 3]
type = helper
trigger1 = var(20) = 70
helpertype = normal
name = "husumi_nise1"
ID = 8371
pos = 40,0
postype = back
stateno = 8371
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 0
pausemovetime = 0
persistent = 0

[State 8355, 3]
type = helper
trigger1 = var(20) = 80
helpertype = normal
name = "husumi_nise2"
ID = 8372
pos = 320,-220
postype = back
stateno = 8371
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 0
pausemovetime = 0
persistent = 0

[State 8355, 3]
type = helper
trigger1 = var(20) = 90
helpertype = normal
name = "husumi_nise3"
ID = 8373
pos = 0,-90
postype = back
stateno = 8371
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 0
pausemovetime = 0
persistent = 0

[State 8355, 3]
type = helper
trigger1 = var(20) = 100
helpertype = normal
name = "husumi_nise4"
ID = 8374
pos = 320,-20
postype = back
stateno = 8371
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 0
pausemovetime = 0
persistent = 0

[State 8355, 3]
type = helper
trigger1 = var(20) = 110
helpertype = normal
name = "husumi_nise5"
ID = 8375
pos = 40,-240
postype = back
stateno = 8371
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 0
pausemovetime = 0
persistent = 0

[State 8355, 3]
type = helper
trigger1 = var(20) = 120
helpertype = normal
name = "husumi_nise6"
ID = 8376
pos = 320,-130
postype = back
stateno = 8371
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 0
pausemovetime = 0
persistent = 0

[State 8355, 3]
type = helper
trigger1 = var(20) = 130
helpertype = normal
name = "husumi_nise7"
ID = 8377
pos = 200,0
postype = back
stateno = 8371
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 0
pausemovetime = 0
persistent = 0

[State 8355, 3]
type = helper
trigger1 = var(20) = 140
helpertype = normal
name = "husumi_nise8"
ID = 8378
pos = 170,-240
postype = back
stateno = 8371
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 0
pausemovetime = 0
persistent = 0



[State 8355, 3]
type = helper
trigger1 = var(20) = 180
helpertype = normal
name = "husumi_nise9"
ID = 8379
pos = 30,0
postype = back
stateno = 8371
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 0
pausemovetime = 0
persistent = 0

[State 8355, 3]
type = helper
trigger1 = var(20) = 180
helpertype = normal
name = "hayata_nise"
ID = 8370
pos = 320,60
postype = back
stateno = 8370
keyctrl = 0
ownpal = 1
facing = 1
;size.xscale = 1
;size.yscale = 1
supermovetime = 0
pausemovetime = 0
persistent = 0

[State -2, 1]
type = ReMoveExplod
trigger1 = var(20) >= 215
ID = 8366

[State 8355, 1]
type = changestate
trigger1 = var(20) >= 215
;trigger1 = Numhelper(8370) >= 1
;trigger1 = helper(8370),movehit = 10
value = 0
ctrl = 1



;はやた
[Statedef 8360]
type = A
movetype = A
physics = N
velset = 10,-0.4
sprpriority = 2
anim = 8360

[State 8360, 1]
type = PlayerPush
trigger1 = 1
value = 0

[State -2, 1]
type = attackmulset
trigger1 = 1
trigger1 = Numhelper(7000) >= 1
value = 1*root,fvar(5)*0.9*helper(7000),fvar(0)*helper(7000),fvar(2)*helper(7000),fvar(3)
ignorehitpause = 1

[State 8360, 1]
type = changeanim
trigger1 = animelemno(0) = 1
value = 8360
elem = 1

[State 8360, 2];ヒットスパーク
type = Explod
;triggerall = enemynear(0),stateno = [5000,5999]
trigger1 = movehit
trigger1 = animelemno(0) = 1
anim = 6011+random%4
ID = 6011
pos = 0+random%5,-55+random%5
postype = p2
facing = 1
bindtime = 1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.4, 0.4
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8360, 2];ヒットスパーク（線）
type = helper
;triggerall = enemynear(0),stateno = [5000,5999]
trigger1 = movehit
trigger1 = animelemno(0) = 1
helpertype = normal
name = "hitspark"
ID = 6030
pos = 0,-55
postype = p2
stateno = 6030
keyctrl = 0
ownpal = 1
facing = 1
size.xscale = 0.5
size.yscale = 0.5
supermovetime = 0
pausemovetime = 0
sprpriority = 5
ignorehitpause=1
persistent = 0

[State 8360, 2]
type = HitDef
trigger1 = animelemno(0) = 1
attr = A,HP
hitflag = MAFD
;guardflag = MA
affectteam = E
animtype = hard
air.animtype = hard
fall.animtype = hard
priority = 7,Hit
damage = 40*ifelse(root,palno=12,2,1)
getpower = 0,0
givepower = ceil(root,fvar(5)*15), 7
pausetime = 0, 20
guard.pausetime = 20, 20
sparkno = -1
guard.sparkno = -1
;sparkxy = -5, -60
hitsound = S0 ,6
guardsound = S3, 7
ground.type = low
air.type = low
ground.slidetime = 18
guard.slidetime = 18
ground.hittime = 18
guard.hittime = 18
air.hittime = 30
;guard.ctrltime = 0
yaccel = 0
ground.velocity = 0, 0;-4
guard.velocity = -8
air.velocity = 0, 0;-3.5
;airguard.velocity = -3, -6
;airguard.ctrltime = 11
air.juggle = 1
sprpriority = 1
p1facing = 1
p2facing = 1
forcestand = 0
fall = 1
fall.recovertime = 30
;down.velocity = -8, 0
;down.hittime = 10
;down.bounce = 0
envshake.time = 10
envshake.ampl = 3
id = 8360
hitonce = 0
kill = 0
numhits = 1
persistent = 0

[State 8360, 3]
type = targetstate
trigger1 = animelemno(0) = 1
trigger1 = NumTarget(8360) >= 1
;trigger1 = Target(8360),ishelper = 0
trigger1 = movehit
value = 8310
ID = 8360
persistent = 0

[State 8360, 3]
type = changeanim
trigger1 = animelemno(0) = 1
trigger1 = movehit
value = 8360
elem = 2

[State 8360, 4]
type = veladd
trigger1 = animelemtime(2) = 0
x = -3
y = -5
persistent = 0

[State 8360, 4]
type = velmul
trigger1 = animelemtime(2) >= 0
trigger1 = animelemtime(4) <= 4
x = -0.9

[State 8360, 4]
type = veladd
trigger1 = animelemtime(2) >= 0
trigger1 = animelemtime(4) <= 4
y = 0.4

[State 8360, 5]
type = changeanim
trigger1 = pos y < 0
trigger1 = animelemtime(4) = 4
value = 8360
elem = 3

[State 8360, 6]
type = changeanim
trigger1 = animelemno(0) = [3,4]
trigger1 = pos y >= 0
value = 8360
elem = 5

[State 8360, 7]
type = velset
trigger1 = animelemtime(5) = 1
x = 0
y = 0

[State 8360, 7]
type = posset
trigger1 = animelemtime(5) = 1
y = 0



[State 8360, 8];ヒットスパーク
type = Explod
;triggerall = enemynear(0),stateno = [5000,5999]
trigger1 = movehit
trigger1 = animelemno(0) = 13
anim = 6011+random%4
ID = 6011
pos = 0+random%5,-55+random%5
postype = p2
facing = 1
bindtime = 1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.4, 0.4
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8360, 8];ヒットスパーク（線）
type = helper
;triggerall = enemynear(0),stateno = [5000,5999]
trigger1 = movehit
trigger1 = animelemno(0) = 13
helpertype = normal
name = "hitspark"
ID = 6030
pos = 0,-55
postype = p2
stateno = 6030
keyctrl = 0
ownpal = 1
facing = 1
size.xscale = 0.5
size.yscale = 0.5
supermovetime = 0
pausemovetime = 0
sprpriority = 5
ignorehitpause=1
persistent = 0

[State 8360, 8]
type = HitDef
trigger1 = animelemno(0) = 13
attr = A,HP
hitflag = MAFD
;guardflag = MA
affectteam = E
animtype = hard
air.animtype = hard
fall.animtype = hard
priority = 7,Hit
damage = 40*ifelse(root,palno=12,2,1)
getpower = 0,0
givepower = ceil(root,fvar(5)*15), 7
pausetime = 0, 20
guard.pausetime = 20, 20
sparkno = -1
guard.sparkno = -1
;sparkxy = -5, -60
hitsound = S0 ,6
guardsound = S3, 7
ground.type = low
air.type = low
ground.slidetime = 18
guard.slidetime = 18
ground.hittime = 18
guard.hittime = 18
air.hittime = 30
;guard.ctrltime = 0
yaccel = 0
ground.velocity = 0, 0;-4
guard.velocity = -8
air.velocity = 0, 0;-3.5
;airguard.velocity = -3, -6
;airguard.ctrltime = 11
air.juggle = 1
sprpriority = 1
p1facing = 1
p2facing = 1
forcestand = 0
fall = 1
fall.recovertime = 30
;down.velocity = -8, 0
;down.hittime = 10
;down.bounce = 0
envshake.time = 10
envshake.ampl = 3
id = 8361
chainID = 8360
hitonce = 0
kill = 0
numhits = 1
persistent = 0

[State 8360, 8]
type = targetstate
trigger1 = animelemno(0) = 13
trigger1 = NumTarget(8361) >= 1
;trigger1 = Target(8361),ishelper = 0
trigger1 = movehit
value = 8310
ID = 8361
persistent = 0

[State 8360, 9]
type = null;veladd
trigger1 = animelemno(0) = 22
x = 1


[State 8360, 10];ヒットスパーク
type = Explod
;triggerall = enemynear(0),stateno = [5000,5999]
trigger1 = movehit
trigger1 = animelemno(0) = 25
anim = 6011+random%4
ID = 6011
pos = 0+random%5,-55+random%5
postype = p2
facing = 1
bindtime = 1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.4, 0.4
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8360, 10];ヒットスパーク（線）
type = helper
;triggerall = enemynear(0),stateno = [5000,5999]
trigger1 = movehit
trigger1 = animelemno(0) = 25
helpertype = normal
name = "hitspark"
ID = 6030
pos = 0,-55
postype = p2
stateno = 6030
keyctrl = 0
ownpal = 1
facing = 1
size.xscale = 0.5
size.yscale = 0.5
supermovetime = 0
pausemovetime = 0
sprpriority = 5
ignorehitpause=1
persistent = 0

[State 8360, 10]
type = HitDef
trigger1 = animelemno(0) = 25
attr = A,HP
hitflag = MAFD
;guardflag = MA
affectteam = E
animtype = diagup
air.animtype = diagup
fall.animtype = diagup
priority = 7,Hit
damage = 40*ifelse(root,palno=12,2,1)
getpower = 0,0
givepower = ceil(root,fvar(5)*15), 7
pausetime = 10, 20
guard.pausetime = 20, 20
sparkno = -1
guard.sparkno = -1
;sparkxy = -5, -60
hitsound = S0 ,7
guardsound = S3, 7
ground.type = low
air.type = low
ground.slidetime = 18
guard.slidetime = 18
ground.hittime = 18
guard.hittime = 18
air.hittime = 30
;guard.ctrltime = 0
;yaccel = 0
ground.velocity = 0, -4
guard.velocity = -8
air.velocity = 2.5, -13
;airguard.velocity = -3, -6
;airguard.ctrltime = 11
air.juggle = 1
sprpriority = 1
p1facing = 1
p2facing = 1
forcestand = 0
fall = 1
fall.recover = 0
;down.velocity = -8, 0
;down.hittime = 10
;down.bounce = 0
envshake.time = 10
envshake.ampl = 3
id = 8362
chainID = 8361
hitonce = 0
kill = 0
numhits = 1
persistent = 0

[State 8360, 10]
type = targetstate
trigger1 = animelemtime(28) >= 18
trigger1 = NumTarget(8362) >= 1
;trigger1 = Target(8361),ishelper = 0
;trigger1 = movehit = 10
value = 8380
ID = 8362
persistent = 0

[State 8360, 10]
type = AssertSpecial
trigger1 = NumTarget(8362) >= 1
trigger1 = target(8362),stateno = 8380
flag = invisible

[State 8360, 11]
type = destroyself
trigger1 = animtime = 0
trigger2 = animelemtime(28) = 29


;敵のステート
[Statedef 8380]
type = A
movetype = H
physics = N
velset = 0,0
sprpriority = 1

[State 8380, 1]
type = PlayerPush
trigger1 = 1
value = 0

[State 8380, 2]
type = changeanim2
trigger1 = time = 0
value = 8380
persistent = 0

[State 8380, 1]
type = AssertSpecial
trigger1 = screenpos y <= 159
trigger2 = screenpos y >= 161
trigger3 = screenpos x >= 161
trigger4 = screenpos x <= 159
flag = invisible

[State 8380, pos y]
type = posadd
trigger1 = screenpos y <= 159
trigger2 = screenpos y >= 161
y = ifelse(screenpos y > 160,ifelse(screenpos y >= 170, -10, -1),ifelse(screenpos y <= 150, 10, 1))

[State 8380, 3];160
type = posadd
trigger1 = screenpos x >= 161
trigger2 = screenpos x <= 159
x = ifelse(facing = 1, ifelse(screenpos x < 160, ifelse(screenpos x <= 153,7,1),ifelse(screenpos x >= 167,-7,-1)),ifelse(screenpos x < 160, ifelse(screenpos x <= 153,-7,-1),ifelse(screenpos x >= 167,7,1)))

[State 8380, 3]
type = selfstate
trigger1 = time >= 200
value = 5040


;偽ふすみ
[Statedef 8371]
type = A
movetype = A
physics = N
velset = 0,0
sprpriority = 2
anim = 8371

[State 8371, 1]
type = sprpriority
trigger1 = 1
value = 2

[State -2, 1]
type = attackmulset
trigger1 = 1
trigger1 = Numhelper(7000) >= 1
value = 1*root,fvar(5)*0.9*helper(7000),fvar(0)*helper(7000),fvar(2)*helper(7000),fvar(3)
ignorehitpause = 1

[State 8371, 2]
type = changeanim
triggerall = time = 0
trigger1 = Ishelper(8372) = 1
trigger2 = Ishelper(8375) = 1
value = 8372
persistent = 0

[State 8371, 2]
type = changeanim
triggerall = time = 0
trigger1 = Ishelper(8373) = 1
trigger2 = Ishelper(8376) = 1
value = 8373
persistent = 0

[State 8371, 2]
type = changeanim
triggerall = time = 0
trigger1 = Ishelper(8377) = 1
value = 8374
persistent = 0

[State 8371, 2]
type = changeanim
triggerall = time = 0
trigger1 = Ishelper(8378) = 1
value = 8375
persistent = 0

[State 8371, 2]
type = changeanim
triggerall = time = 0
trigger1 = Ishelper(8379) = 1
value = 8379
persistent = 0

[State 8371, 3]
type = turn
triggerall = time = 0
trigger1 = Ishelper(8372) = 1
trigger2 = Ishelper(8374) = 1
trigger3 = Ishelper(8376) = 1
persistent = 0

[State 8371, 4]
type = velset
trigger1 = Ishelper(8371) = 1
x = 28
y = -30

[State 8371, 4]
type = velset
trigger1 = Ishelper(8372) = 1
x = 30
y = 25

[State 8371, 4]
type = velset
trigger1 = Ishelper(8373) = 1
x = 30
y = -4

[State 8371, 4]
type = velset
trigger1 = Ishelper(8374) = 1
x = 30
y = -30

[State 8371, 4]
type = velset
trigger1 = Ishelper(8375) = 1
x = 30
y = 24

[State 8371, 4]
type = velset
trigger1 = Ishelper(8376) = 1
x = 30
y = -4

[State 8371, 4]
type = velset
trigger1 = Ishelper(8377) = 1
x = 0
y = -30

[State 8371, 4]
type = velset
trigger1 = Ishelper(8378) = 1
x = 0
y = 30

[State 8371, 4]
type = velset
trigger1 = Ishelper(8379) = 1
x = 23
y = -20

[State 8371, 4]
type = angledraw
trigger1 = Ishelper(8377) = 1
value = 90

[State 8371, 4]
type = angledraw
trigger1 = Ishelper(8378) = 1
value = -90

[State 8371, 5]
type = Explod
trigger1 = ishelper(8372) = 1
trigger1 = Ishelper(8375) = 1
anim = 1716
ID = 1716
pos = 0,0
postype = p1
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8371, 5]
type = Explod
trigger1 = ishelper(8373) = 1
trigger1 = ishelper(8376) = 1
anim = 1717
ID = 1717
pos = 0,0
postype = p1
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8371, 5]
type = Explod
trigger1 = ishelper(8371) = 1
trigger2 = ishelper(8374) = 1
anim = 1718
ID = 1718
pos = 0,0
postype = p1
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8371, 5]
type = Explod
trigger1 = ishelper(8379) = 1
trigger1 = NumExplod(1718) = 0
anim = 1718
ID = 1718
pos = 0,0
postype = p1
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1

[State 8371, 6];衝撃波
type = helper
triggerall = time = 0
trigger1 = Ishelper(8377) = 1
trigger2 = Ishelper(8378) = 1
helpertype = normal
name = "syougekiha"
ID = ifelse(Ishelper(8377) = 1,1719,1720)
pos = 0,0
postype = p1
stateno = 1719
keyctrl = 0
ownpal = 1
facing = 1
size.xscale = 0.5
size.yscale = 0.5
supermovetime = 0
pausemovetime = 0
sprpriority = 5
;ignorehitpause=1
persistent = 0


[State 8371, 6];ヒットスパーク（線）
type = helper
;triggerall = enemynear(0),stateno = [5000,5999]
trigger1 = movehit
helpertype = normal
name = "hitspark"
ID = 6030
pos = 0,-55
postype = p2
stateno = 6030
keyctrl = 0
ownpal = 1
facing = 1
size.xscale = 1
size.yscale = 1
supermovetime = 0
pausemovetime = 0
sprpriority = 5
ignorehitpause=1
persistent = 0

[State 8371, 6]
type = HitDef
trigger1 = 1
trigger1 = ishelper(8379) = 0
attr = A,HP
hitflag = MAFD
;guardflag = MA
affectteam = E
animtype = hard
air.animtype = hard
fall.animtype = hard
priority = 7,Hit
damage = 8*ifelse(root,palno=12,2,1)
getpower = 0,0
givepower = ceil(root,fvar(5)*15), 7
pausetime = 0, 20
guard.pausetime = 20, 20
sparkno = -1
guard.sparkno = -1
;sparkxy = -5, -60
hitsound = S0 ,8
guardsound = S3, 7
ground.type = low
air.type = low
ground.slidetime = 18
guard.slidetime = 18
ground.hittime = 18
guard.hittime = 18
air.hittime = 30
;guard.ctrltime = 0
;yaccel = 0
ground.velocity = 0, 0
guard.velocity = 0
air.velocity = 0, 0
;airguard.velocity = 0, 0
;airguard.ctrltime = 11
air.juggle = 1
sprpriority = 1
p1facing = 1
p2facing = 1
forcestand = 0
fall = 1
fall.recover = 0
;down.velocity = -8, 0
;down.hittime = 10
;down.bounce = 0
;envshake.time = 10
;envshake.ampl = 3
id = 8371
hitonce = 0
kill = 0
numhits = 1
persistent = 0

[State 8371, 6]
type = targetstate
trigger1 = movehit
trigger1 = ishelper(8379) = 0
value = 8380
ID = 8371
persistent = 0

[State 8371, 1]
type = AfterImage
trigger1 = ishelper(8379) = 1
trigger1 = time = 0
time = -1
length = 10
palcontrast = 120,120,120
paladd = 0,0,0
palmul = 1,1,1
timegap = 1
framegap = 1
trans = add1

[State 8371, 2]
type = null;AfterImagetime
trigger1 = ishelper(8379) = 1
time = 10

[State 8371, 7]
type = destroyself
trigger1 = animtime = 0
trigger1 = Ishelper(8379) = 0

[State 8371, 7]
type = destroyself
trigger1 = Ishelper(8379) = 1
trigger1 = parent,var(20) >= 212



;偽はやた
[Statedef 8370]
type = A
movetype = A
physics = N
velset = 0,0
sprpriority = 2
anim = 8370

[State 8370, 1]
type = sprpriority
trigger1 = 1
value = 3

[State -2, 1]
type = attackmulset
trigger1 = 1
trigger1 = Numhelper(7000) >= 1
value = 1*root,fvar(5)*0.9*helper(7000),fvar(0)*helper(7000),fvar(2)*helper(7000),fvar(3)
ignorehitpause = 1

[State 8370, 2]
type = turn
trigger1 = time = 0
persistent = 0

[State 8370, 3]
type = velset
trigger1 = time = 0
x = 23
y = -20

[State 8370, 4];ヒットスパーク（線）
type = helper
;triggerall = enemynear(0),stateno = [5000,5999]
trigger1 = movehit
helpertype = normal
name = "hitspark"
ID = 6030
pos = 0,-55
postype = p2
stateno = 6030
keyctrl = 0
ownpal = 1
facing = 1
size.xscale = 1
size.yscale = 1
supermovetime = 0
pausemovetime = 0
sprpriority = 5
ignorehitpause=1
persistent = 0

[State 8370, 4];ヒットスパーク（線）
type = helper
;triggerall = enemynear(0),stateno = [5000,5999]
trigger1 = movehit
helpertype = normal
name = "hitspark"
ID = 6030
pos = 0,-55
postype = p2
stateno = 6030
keyctrl = 0
ownpal = 1
facing = 1
size.xscale = 1
size.yscale = 1
supermovetime = 0
pausemovetime = 0
sprpriority = 5
ignorehitpause=1
persistent = 0

[State 8370, 5]
type = HitDef
trigger1 = 1
attr = A,HP
hitflag = MAF
;guardflag = M
affectteam = E
animtype = diagup
air.animtype = diagup
fall.animtype = diagup
priority = 7,Hit
damage = 68*ifelse(root,palno=12,2,1)
getpower = 0,0
givepower = ceil(root,fvar(5)*27), 13
pausetime = 0, 38
guard.pausetime = 24, 24
sparkno = -1
guard.sparkno = -1
;sparkxy = -5, -60
hitsound = S0 ,6
guardsound = S3, 7
ground.type = high
air.type = high
ground.slidetime = 100
guard.slidetime = 18
ground.hittime = 100
guard.hittime = 18
air.hittime = 100
;guard.ctrltime = 0
yaccel = 0.2
ground.velocity = -1, -13
guard.velocity = -1
air.velocity = -1, -13
airguard.velocity = -1, -2
;airguard.ctrltime = 11
air.juggle = 1
sprpriority = 1
p1facing = 1
p2facing = 1
forcestand = 0
fall = 1
fall.recovertime = 100
;down.velocity = -8, 0
;down.hittime = 10
;down.bounce = 0
envshake.time = 10
envshake.ampl = 3
id = 8370
hitonce = 0
kill = 1
numhits = 2
persistent = 0

[State 8370, 6]
type = AfterImage
trigger1 = time = 0
time = -1
length = 10
palcontrast = 120,120,120
paladd = 0,0,0
palmul = 1,1,1
timegap = 1
framegap = 1
trans = add1

[State 8370, 7]
type = destroyself
trigger1 = parent,var(20) >= 212









;******************************************************************************************
;クリティカルハート************************************************************************
;------------------------------------------------------------------------------------------
;封呪・鳴神
;------------------------------------------------------------------------------------------
[Statedef 8400]
type = S
movetype = A
physics = S
velset = 0,0
anim = 8400
sprpriority = 1
ctrl = 0

[State 8400, 1]
type = varset
trigger1 = time = 0
v = 20
value = 0

[State 8400, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S3,10
channel = 1
volume = var(21)
persistent = 0

[State 8400, PlaySnd]
type = PlaySnd
trigger1 = time = 0
value = S10,0
channel = 0
volume = var(21)
persistent = 0

[State 8400, 2];カットインエフェクト
type = Explod
trigger1 = time = 0
anim = 6103
ID = 8400
pos = 0,-72
postype = p1
facing = 1
bindtime = 1
removetime = -2
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
;ignorehitpause = 1
persistent = 0

[State 8400, 2];背景1
type = Explod
trigger1 = time = 0
anim = 6101
ID = 8400
pos = 0,240
postype = back
facing = 1
bindtime = -1
removetime = -1
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = -2
ownpal = 1
removeongethit = 1
;ignorehitpause = 1
persistent = 0

[State 8400, 2];背景2
type = Explod
trigger1 = time = 0
anim = 6102
ID = 8400
pos = 0,240
postype = back
facing = 1
bindtime = -1
removetime = -1
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = -2
ownpal = 1
removeongethit = 1
;ignorehitpause = 1
persistent = 0

;カットインはヘルパー

[State 8400, 3]
type = SuperPause
trigger1 = time = 0
time = 70
anim = -1
;sound = S100,1
pos = 0,0
movetime = 70
darken = 0
p2defmul = 1
poweradd = -3000
unhittable = 1
persistent = 0

[State 8400, 4]
type = StateTypeSet
trigger1 = Animelemtime(2) = 0
Statetype = A
Physics = N

[State 8400, 4]
type = velset
trigger1 = Animelemtime(2) = 0
x = 1.75
y = -4.4

[State 8400, 4]
type = veladd
trigger1 = Animelemtime(2) >= 0
trigger1 = animelemtime(10) <= 4
y = 0.16

[State 8400, 4]
type = StateTypeSet
trigger1 = Animelemtime(11) = 0
Statetype = S
Physics = S
[State 8400, 4]
type = velset
trigger1 = Animelemtime(11) = 0
x = 0
y = 0
[State 8400, 4]
type = posset
trigger1 = Animelemtime(11) = 0
y = 0

[State 8400, 1]
type = NotHitBy
trigger1 = animelemtime(9) <= 1
value = SCA

[State 8400, 1]
type = HitDef
trigger1 = animelemtime(9) = [0,1]
attr = A,HA
hitflag = MAF
guardflag = MA
affectteam = E
animtype = hard
air.animtype = hard
fall.animtype = hard
priority = 5,Hit
damage = 0
getpower = 0, 0
givepower = 33, 17
pausetime = 0, 0
guard.pausetime = 10, 10
sparkno = -1
guard.sparkno = -1
sparkxy = 0, 0
hitsound = S0,3
guardsound = S3, 7
ground.type = Low
air.type = Low
ground.hittime = 20
ground.slidetime = 20
guard.hittime = ifelse(enemynear(0),statetype != A,26,31)
guard.slidetime = ifelse(enemynear(0),statetype != A,26,31)
air.hittime = ceil(40*var(26)*0.01)
;guard.ctrltime = 0
;airguard.ctrltime = 0
yaccel = 0.2
ground.velocity = -3.5, -4
guard.velocity = -1
air.velocity = -3.5, -3.5
airguard.velocity = -0.5, -1
ground.cornerpush.veloff = 0
air.cornerpush.veloff = 0
down.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
air.juggle = 0
fall = 0
fall.recovertime = ceil(40*var(26)*0.01)
down.velocity = -3, 0
down.hittime = 20
down.bounce = 0
id = 8400
hitonce = 0
kill = 1
numhits = 1
persistent = 0
p2facing = 1

[State 8400, 2];ヒットスパーク
type = Explod
triggerall = enemynear(0),stateno != [120,155]
trigger1 = animelemtime(9) = [0,1]
trigger1 = movehit
anim = 6031 + random%4
ID = 6031
pos = -5+random%10,-60+random%5
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8400, 2];ガードスパーク
type = Explod
triggerall = enemynear(0),stateno != [5000,5999]
trigger1 = animelemtime(9) = [0,1]
trigger1 = moveguarded
anim = 6050
ID = 6050
pos = 10,-55
postype = p2
facing = 1
bindtime = -1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 5
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8400, 6]
type = TargetState
trigger1 = NumTarget(8400) >= 1
trigger1 = movehit
value = 8450
ID = 8400
persistent = 0

[State 8400, 6]
type = TargetBind
trigger1 = NumTarget(8400) >= 1
trigger1 = movehit
pos = 85,0
ID = 8400
persistent = 0

[State 8400, 7]
type = changestate
trigger1 = NumTarget(8400) >= 1
trigger1 = movehit
value = 8401

[State 8400, 7]
type = changestate
trigger1 = animtime = 0
value = 0
ctrl = 1


[Statedef 8450]
type = S
movetype = H
physics = S
velset = 0,0
sprpriority = 0

[State 8450, 1]
type = changeanim2
trigger1 = time = 0
value = 8450
persistent = 0

[State 8450, 2]
type = NotHitBy
trigger1 = (enemynear(0),stateno = [8400,8403]) || (enemynear(0),stateno = [21700,21703])
value = SCA

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

[State 8450, 4]
type = PalFX
trigger1 = 1
time = 1
mul = 128,128,256
ignorehitpause = 1

[State 8450, 4]
type = selfstate
trigger1 = (enemynear(0),stateno != [8400,8404]) && (enemynear(0),stateno != [21700,21704])
value = 5110





[Statedef 8401];開始
type = S
movetype = A
physics = S
velset = 0,0
anim = 8401
sprpriority = 1
ctrl = 0

[State 8401, 1]
type = posset
trigger1 = time = 0
y = 0

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

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

[State 8401, 1]
type = varadd
trigger1 = command = "back"
v = 20
value = 1
persistent = 10

[State 8401, 1]
type = varset
trigger1 = animtime = 0
trigger1 = var(20) = 0
trigger2 = command = "fwd" || command = "down" || command = "up"
v = 20
value = 11

[State 8401, 2]
type = changestate
trigger1 = animtime = 0
trigger1 = var(20) = 1
value = 8402

[State 8401, 2]
type = changestate
trigger1 = animtime = 0
trigger1 = var(20) = 11
value = 8404


[Statedef 8402];4
type = S
movetype = A
physics = S
velset = 0,0
anim = 8402
sprpriority = 1
ctrl = 0

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

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

[State 8402, 1]
type = Playsnd
trigger1 = time = 0
value = S10,var(20)
channel = 0
volume = var(21)
persistent = 0

[State 8402, 2]
type = Explod
trigger1 = time = 0
anim = 8421
ID = 8421
pos = ifelse(facing = 1,-1,1)*20, var(20)*15
postype = front
facing = ifelse(facing = 1,1,-1)
bindtime = 1
vel = ifelse(facing = 1,-20,20), 0
removetime = -2
supermovetime = 9999
pausemovetime = 9999
scale = 1.5, 0.5
sprpriority = 4
ownpal = 1
removeongethit = 1

[State 8402, 3]
type = varadd
trigger1 = command = "down"
trigger2 = var(20) = 9
trigger2 = command = "recovery"
v = 20
value = 1
persistent = 10

[State 8402, 3]
type = varset
trigger1 = animtime = 0
trigger1 = var(20) != 2 && var(20) != 4 && var(20) != 6 && var(20) != 8 && var(20) != 10
v = 20
value = 11

[State 8402, 4]
type = changestate
trigger1 = animtime = 0
trigger1 = var(20) = 2 || var(20) = 4 || var(20) = 6 || var(20) = 8
value = 8403

[State 8402, 4]
type = changestate
trigger1 = animtime = 0
trigger1 = var(20) = [10,11]
value = 8404



[Statedef 8403];2
type = S
movetype = A
physics = S
velset = 0,0
anim = 8403
sprpriority = 1
ctrl = 0

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

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

[State 8403, 1]
type = Playsnd
trigger1 = time = 0
value = S10,var(20)
channel = 0
volume = var(21)
persistent = 0

[State 8403, 2]
type = Explod
trigger1 = time = 0
anim = 8422
ID = 8422
pos = ifelse(facing = 1,-1,1)*var(20)*15,20
postype = front
facing = ifelse(facing = 1,1,-1)
bindtime = 1
vel = 0, 20
removetime = -2
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 1.5
sprpriority = 4
ownpal = 1
removeongethit = 1

[State 8403, 3]
type = varadd
trigger1 = command = "back"
v = 20
value = 1
persistent = 10

[State 8403, 3]
type = varset
trigger1 = animtime = 0
trigger1 = var(20) != 3 && var(20) != 5 && var(20) != 7 && var(20) != 9
v = 20
value = 11

[State 8403, 4]
type = changestate
trigger1 = animtime = 0
trigger1 = var(20) = 3 || var(20) = 5 || var(20) = 7 || var(20) = 9
value = 8402

[State 8403, 4]
type = changestate
trigger1 = animtime = 0
trigger1 = var(20) = 11
value = 8404



[Statedef 8404];攻撃開始
type = S
movetype = A
physics = S
velset = 0,0
anim = 8404
sprpriority = 1
ctrl = 0

[State 8404, 1]
type = Playsnd
trigger1 = time = 0
trigger1 = var(20) = 10
value = S10,10
channel = 0
volume = var(21)
persistent = 0

[State 8404, 1]
type = Playsnd
trigger1 = animelemtime(5) = 1
value = S10,11
channel = 1
volume = var(21)
persistent = 0

[State 8404, 2]
type = NotHitBy
trigger1 = var(20) = 10
value = SCA

[State 8404, 1];避雷針
type = Explod
trigger1 = animelemtime(5) = 1
trigger1 = var(20) = 10
anim = 8423
ID = 8423
pos = 0,0
postype = p1
facing = 1;ifelse(facing = 1,1,-1)
bindtime = -1
removetime = -2
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = 4
ownpal = 1
removeongethit = 1
ignorehitpause = 1
persistent = 0

[State 8404, 1];魔方陣3
type = Explod
trigger1 = animelemtime(5) = 1
anim = 8426
ID = 8426
pos = 120,0
postype = p1
facing = ifelse(facing = 1,1,-1)
bindtime = 1
removetime = -2
supermovetime = 9999
pausemovetime = 9999
scale = 1, 0.3
sprpriority = -1
ownpal = 1
removeongethit = 0
ignorehitpause = 1
persistent = 0

[State 8404, 1];魔方陣2
type = Explod
trigger1 = animelemtime(5) = 1
anim = 8425
ID = 8425
pos = 120,0
postype = p1
facing = ifelse(facing = 1,1,-1)
bindtime = 1
removetime = -2
supermovetime = 9999
pausemovetime = 9999
scale = 1, 0.3
sprpriority = -1
ownpal = 1
removeongethit = 0
ignorehitpause = 1
persistent = 0

[State 8404, 1];魔方陣1
type = Explod
trigger1 = animelemtime(5) = 1
anim = 8424
ID = 8424
pos = 120,0
postype = p1
facing = ifelse(facing = 1,1,-1)
bindtime = 1
removetime = -2
supermovetime = 9999
pausemovetime = 9999
scale = 1, 0.3
sprpriority = -1
ownpal = 1
removeongethit = 0
ignorehitpause = 1
persistent = 0

[State 8404, 1]
type = helper
trigger1 = Numhelper(8430) = 0
trigger1 = animelemtime(5) = 21
helpertype = normal
name = "narukami"
ID = 8430
pos = 120,0
postype = p1
stateno = 8430
keyctrl = 0
ownpal = 1
facing = 1
size.xscale = 0.5
size.yscale = 1
supermovetime = 9999
pausemovetime = 9999
persistent = 0

[State 8404, 1]
type = helper
trigger1 = Numhelper(8431) = 0
trigger1 = animelemtime(5) = 21
trigger1 = var(20) = 11
helpertype = normal
name = "narukami2"
ID = 8431
pos = 120,0
postype = p1
stateno = 8430
keyctrl = 0
ownpal = 1
facing = -1
size.xscale = 0.5
size.yscale = 1
supermovetime = 9999
pausemovetime = 9999
persistent = 0

[State 8404, 5]
type = NotHitBy
trigger1 = animtime = 0
trigger1 = var(20) = 10
value2 = ,SA,HA,ST,HT,SP,HP
time = 555

[State 8404, 5]
type = changestate
trigger1 = animtime = 0
value = 0
ctrl = 1


[Statedef 8430]
type = A
movetype = A
physics = N
velset = 0,0
sprpriority = 5
anim = 8430

[State 8430, 1]
type = sprpriority
trigger1 = 1
value = 5

[State 8430, 1];稲妻1
type = Explod
trigger1 = time = 0
trigger1 = ishelper(8430) = 1
anim = 8431
ID = 8431
pos = -90 + random%30,0
postype = p1
facing = ifelse(facing = 1,1,-1)
bindtime = 1
removetime = -2
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = 6
ownpal = 1
removeongethit = 0
ignorehitpause = 1
persistent = 0

[State 8430, 1];稲妻2
type = Explod
trigger1 = time = 0
trigger1 = ishelper(8430) = 1
anim = 8431
ID = 8431
pos = 90 - random%30,0
postype = p1
facing = ifelse(facing = 1,1,-1)
bindtime = 1
removetime = -2
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = 6
ownpal = 1
removeongethit = 0
ignorehitpause = 1
persistent = 0

[State 8430, 1];稲妻3
type = Explod
trigger1 = time = 0
trigger1 = ishelper(8430) = 1
anim = 8432
ID = 8432
pos = 0,-125
postype = p1
facing = ifelse(facing = 1,1,-1)
bindtime = 1
removetime = -2
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = 6
ownpal = 1
removeongethit = 0
ignorehitpause = 1
persistent = 0

[State 8430, 1];稲妻4
type = Explod
trigger1 = time = 0
trigger1 = ishelper(8430) = 1
anim = 8432
ID = 8432
pos = 0,-185
postype = p1
facing = ifelse(facing = 1,1,-1)
bindtime = 1
removetime = -2
supermovetime = 9999
pausemovetime = 9999
scale = 0.5, 0.5
sprpriority = 6
ownpal = 1
removeongethit = 0
ignorehitpause = 1
persistent = 0


[State 8430, 1]
type = AssertSpecial
trigger1 = ishelper(8431) = 1
flag = noshadow
flag2 = invisible

[State -2, 1]
type = attackmulset
trigger1 = 1
trigger1 = Numhelper(7000) >= 1
value = 1*root,fvar(5)*0.9*helper(7000),fvar(0)*helper(7000),fvar(2)*helper(7000),fvar(3)
ignorehitpause = 1

[State 8430, 1]
type = HitDef
trigger1 = animelemtime(1) <= 3
trigger1 = ishelper(8430) = 1
attr = A,HP
hitflag = MAF
;guardflag = MA
affectteam = E
animtype = back
air.animtype = back
fall.animtype = back
priority = 5,Hit
damage = ceil(ifelse(root,var(20) = 10,438,192)*ifelse(root,palno=12,1.5,1));288,192)
getpower = 0, 0
givepower = -99999999*ifelse(root,palno = 12,0,1), 17
pausetime = 0, 36
guard.pausetime = 0, 10
sparkno = -1
guard.sparkno = -1
sparkxy = 0, 0
hitsound = S0,9
guardsound = S3, 7
ground.type = High
air.type = highs
ground.hittime = 20
ground.slidetime = 20
guard.hittime = ifelse(enemynear(0),statetype != A,26,31)
guard.slidetime = ifelse(enemynear(0),statetype != A,26,31)
air.hittime = ceil(50*root,var(26)*0.01)
;guard.ctrltime = 0
;airguard.ctrltime = 0
yaccel = 0.2
ground.velocity = -6.5, -4
guard.velocity = -1
air.velocity = -6.5, -3.5
airguard.velocity = -0.5, -1
ground.cornerpush.veloff = 0
air.cornerpush.veloff = 0
down.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
air.juggle = 0
fall = 1
fall.recover = 0;time = ceil(50*root,var(26)*0.01)
down.velocity = -3, 0
down.hittime = 20
down.bounce = 0
id = 8430
hitonce = 0
kill = 1
numhits = 1
persistent = 0
p2facing = 1
envshake.time = 50
envshake.ampl = 3

[State 8430, 1]
type = HitDef
trigger1 = animelemtime(1) <= 3
trigger1 = ishelper(8431) = 1
attr = A,HP
hitflag = MAF
;guardflag = MA
affectteam = F
animtype = back
air.animtype = back
fall.animtype = back
priority = 5,Hit
damage = 96
getpower = 0, 0
givepower = 33, 17
pausetime = 0, 36
guard.pausetime = 0, 10
sparkno = -1
guard.sparkno = -1
sparkxy = 0, 0
hitsound = S0,9
guardsound = S3, 7
ground.type = High
air.type = highs
ground.hittime = 20
ground.slidetime = 20
guard.hittime = ifelse(enemynear(0),statetype != A,26,31)
guard.slidetime = ifelse(enemynear(0),statetype != A,26,31)
air.hittime = ceil(50*root,var(26)*0.01)
;guard.ctrltime = 0
;airguard.ctrltime = 0
yaccel = 0.2
ground.velocity = -6.5, -4
guard.velocity = -1
air.velocity = -6.5, -3.5
airguard.velocity = -0.5, -1
ground.cornerpush.veloff = 0
air.cornerpush.veloff = 0
down.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
air.juggle = 0
fall = 1
fall.recovertime = ceil(50*root,var(26)*0.01)
down.velocity = -3, 0
down.hittime = 20
down.bounce = 0
id = 8431
hitonce = 0
kill = 0
numhits = 1
persistent = 0
p2facing = 1


[State -3, 乗算補正]
type = ParentVarSet
trigger1 = ishelper(8430) = 1
trigger1 = movehit
fv = 5
value = ifelse(root,fvar(5) = 1, ceil(root,fvar(5)*50)*0.01, ceil(root,fvar(5)*50)*0.01)
ignorehitpause = 1
persistent = 0

[State -2, 1];ノックバック補正
type = ParentVarAdd
trigger1 = ishelper(8430) = 1
trigger1 = movehit
v = 24
value = 40
ignorehitpause = 1
persistent = 0

[State -2, 1];復帰不能補正
type = ParentVarAdd
trigger1 = ishelper(8430) = 1
trigger1 = movehit
v = 26
value = -20
ignorehitpause = 1
persistent = 0


[State 8430, 1]
type = destroyself
trigger1 = animtime = 0





;==========================================================================================
;霊力バースト
;==========================================================================================
[Statedef 8500]
type = A
movetype = A
physics = N
sprpriority = 5
ctrl = 0
velset = 0,0
anim = 8500

[State 8500, 1]
type = posset
trigger1 = time = 0
trigger1 = pos y = 0
y = -10
persistent = 0

[State 8500, 1]
type = PlaySnd
trigger1 = animelemtime(2) = 0
value = S3, 11
channel = 5
volume = var(21)
persistent = 0

[State 8500, 1]
type = PlaySnd
trigger1 = animelemtime(3) = 5
value = S12, 7
channel = 0
volume = var(21)
persistent = 0
ignorehitpause = 1

[State 8500, 3]
type = velset
trigger1 = animelemtime(2) = 1
y = -0.5
[State 8500, 3]
type = velset
trigger1 = animelemtime(3) = 5
y = 0
[State 8500, 3]
type = velset
trigger1 = animelemtime(3) = 16
y = 0.5

[State 8500, 3]
type = StateTypeSet
trigger1 = animelemtime(5) >= 1
trigger1 = animelemtime(6) <= 4
physics = A

[State 8500, 4];魔方陣
type = Explod
trigger1 = Animelemtime(2) = 1
anim = 8501
ID = 8501
pos = 0,-90
postype = p1
facing = ifelse(facing = 1,1,-1)
bindtime = 1
removetime = -2
supermovetime = 0
pausemovetime = 0
scale = 1, 1
sprpriority = 6
ownpal = 1
removeongethit = 1
persistent = 0

[State 8500, 4]
type = ModifyExplod
trigger1 = NumExplod(8501) = 1
ID = 8501
scale = 0.25+(time-18)*0.2, 0.25+(time-18)*0.2

[State 8500, 2]
type = NotHitBy
trigger1 = animelemtime(3) < 0
value = ,AA,AP

[State 8500, 5]
type = HitDef
trigger1 = 1
attr = A,HA
hitflag = MAF
guardflag = MA
affectteam = E
animtype = diagup
air.animtype = diagup
fall.animtype = diagup
priority = 7,Hit
damage = 0
getpower = 0,0
givepower = 0, 0
pausetime = 0, 6
guard.pausetime = 0, 6
sparkno = -1
guard.sparkno = -1
sparkxy = 0, 0
hitsound = S0,ifelse(random <= 499,4,5)
guardsound = S3, 7
ground.type = High
air.type = High
ground.hittime = 20
ground.slidetime = 20
guard.hittime = 0
guard.slidetime = 0
air.hittime = ceil(20*var(26)*0.01)
guard.ctrltime = 0
airguard.ctrltime = 0
yaccel = 0.2
ground.velocity = -10, -3.5
guard.velocity = -3
air.velocity = -10, -3.5
airguard.velocity = -3, -2
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
airguard.cornerpush.veloff = 0
down.cornerpush.veloff = 0
air.juggle = 0
fall = 1
fall.recovertime = ceil(20*var(26)*0.01)
down.velocity = -4, 0
down.hittime = 20
down.bounce = 0
id = 8500
hitonce = 0
kill = 0
numhits = 0
persistent = 0
p2facing = 1
ignorehitpause = 1

[State 8500, 3]
type = changestate
trigger1 = pos y > 0
value = 8510
ctrl = 0


[Statedef 8510]
type = C
movetype = I
physics = C
velset = 0,0
anim = 8510
sprpriority = 1

[State 8510, 1]
type = posset
trigger1 = time = 0
y = 0

[State 8510, 2]
type = changestate
trigger1 = animtime = 0
value = 0
ctrl = 1

