;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]棫偪
;--------------------------------------------------
[StateDef 0]
Type = S
Physics = S
SprPriority = 0

[State 0]
type = statetypeset
trigger1 = name !="ONI-MIKO-REIMU"
statetype = S
movetype = H
physics = N

[state a]
type = velset
triggerall = name !="ONI-MIKO-REIMU"
trigger1 = time = 0
x = 0
y = 0

[State 9997, 1]
type = varset
trigger1 = ishelper
trigger1 = root,name !="ONI-MIKO-REIMU"
var(44) = prevstateno

[State 9997, 1]
type = varset
trigger1 = ishelper
trigger1 = root,name !="ONI-MIKO-REIMU"
var(4) = anim

[State 1706]
Type = AssertSpecial
triggerall = name !="ONI-MIKO-REIMU"
trigger1=1
flag=unguardable

[State 9997, 1];夋柺撪偄偲偗
type = posset
triggerall = name !="ONI-MIKO-REIMU"
triggerall = !ishelper
trigger1 = pos y != [-1000,100]
y = 0

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[State 310 , blink]
type = PalFX
triggerall = name !="ONI-MIKO-REIMU"
trigger1 = time%3 = 0
time = 90
add = 100,-180,-180
sinadd = -80,-80,-80,10
color = 0 
invertall = 1
persistent = 30

[State a]
type = AssertSpecial
trigger1 = ishelper
trigger1 = root,name !="ONI-MIKO-REIMU"
flag = invisible
ignorehitpause = 1

[State a]
type = PosSet
triggerall = ishelper
triggerall = root,name !="ONI-MIKO-REIMU"
trigger1 = 1
x = 0
y = 2500
ignorehitpause = 1

[State proj] 
type = Projectile
triggerall = ishelper
trigger1 = root,name !="ONI-MIKO-REIMU"
trigger1 = root,alive
trigger1 = time < 60
projID = 1709
projanim = var(4)
projremovetime = 600
projhits = 999
projheightbound = -2000000000, 2000000000
ProjEdgeBound = 2000000000
ProjStageBound = 2000000000
postype = p1
supermovetime = 999000
pausemovetime = 999000
attr = C,ST
hitflag = MAFPD
givepower = 0,0
getpower = 0,0
pausetime = 0,0
persistent = 0
p1stateno = var(44)
ignorehitpause = 1

[State proj] 
type = Projectile
triggerall = ishelper
trigger1 = root,name !="ONI-MIKO-REIMU"
trigger1 = root,alive = 0
projID = 1710
projanim = var(4)
projremovetime = 600
projhits = 999
projheightbound = -2000000000, 2000000000
ProjEdgeBound = 2000000000
ProjStageBound = 2000000000
postype = p1
supermovetime = 999000
pausemovetime = 999000
attr = C,ST
hitflag = MAFPD
givepower = 0,0
getpower = 0,0
pausetime = 0,0
persistent = 0
p1stateno = 5150
ignorehitpause = 1

[State proj] 
type = Projectile
triggerall = ishelper
trigger1 = root,name !="ONI-MIKO-REIMU"
trigger1 = time = 0
projID = gametime
projanim = anim
projhits = 999
projremovetime = 600
projheightbound = -2000000000, 2000000000
ProjEdgeBound = 2000000000
ProjStageBound = 2000000000
postype = p1
offset = 1000,199997500
supermovetime = 999000
pausemovetime = 999000
attr = C,ST
hitflag = MAFPD
affectteam = B
givepower = 0,0
getpower = 0,0
pausetime = 0,0
persistent = 0
p1stateno = 50
ignorehitpause = 1

[state destoryhelper] 
type = destroyself 
triggerall = ishelper
triggerall = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
trigger1 = Time >= 3
trigger2 = root,name ="ONI-MIKO-REIMU"
ignorehitpause = 1

[state destoryhelper] 
type = destroyself 
triggerall = ishelper(6904) && roundstate >= 3
trigger1 = root,name = "ONI-MIKO-REIMU"
trigger1 = root,stateno = 0 && root,time > 10
ignorehitpause = 1

[State 60]
type = changestate
triggerall = !ishelper
trigger1 = name !="ONI-MIKO-REIMU"
trigger1 = !alive
value = 5150
ignorehitpause = 1

[State 9997, 1]
type = SelfState
triggerall = name !="ONI-MIKO-REIMU"
triggerall = !ishelper
trigger1 = Time >= 3
value = 5050
ignorehitpause = 1

[State 1000]
type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = numhelper(8901061) < 5 && name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
ID = 8901061
name = "batsu"
stateno = 8901061
pos = 0,999999999
postype = p1
facing = 1
helpertype = player
keyctrl = 0
ownpal = 1
ignorehitpause = 1

[State 1000]
type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = numhelper(8901061) < 5 && name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
ID = 8901061
name = "batsu"
stateno = 8901061
pos = 0,999999999
postype = p1
facing = 1
helpertype = player
keyctrl = 0
ownpal = 1
ignorehitpause = 1

[State 1000]
type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = numhelper(8901061) < 5 && name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
ID = 8901061
name = "batsu"
stateno = 8901061
pos = 0,999999999
postype = p1
facing = 1
helpertype = player
keyctrl = 0
ownpal = 1
ignorehitpause = 1

[State 1000]
type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = numhelper(8901061) < 5 && name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
ID = 8901061
name = "batsu"
stateno = 8901061
pos = 0,999999999
postype = p1
facing = 1
helpertype = player
keyctrl = 0
ownpal = 1
ignorehitpause = 1

[State 1000]
type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = numhelper(8901061) < 5 && name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
ID = 8901061
name = "batsu"
stateno = 8901061
pos = 0,999999999
postype = p1
facing = 1
helpertype = player
keyctrl = 0
ownpal = 1
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State -2, Helper]
Type = Helper
triggerall = !ishelper && roundstate <= 2
triggerall = name ="ONI-MIKO-REIMU" && palno = 12
trigger1=((enemy,name ="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))||(p2name="kaioh"||p4name="kaioh")
OwnPal = 1
PosType = P1
Pos = 999, 999
ID = 8901066
StateNo = 8901066
Name = " "
ignorehitpause = 1

[State 1060, PlaySnd]
Type = PlaySnd
triggerall = name ="ONI-MIKO-REIMU" && !ishelper && roundstate = 1 && time = 80
trigger1 = (palno = 12 || palno = 6)&&((enemy,name="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))
Value = S890, 0
Channel = 6

[State 20]
type = ctrlset
triggerall = name ="ONI-MIKO-REIMU" && !ishelper && roundstate <= 2
triggerall = palno = 12
trigger1 = (palno = 12 || palno = 6)&&((enemy,name="F1")&&(enemy,numpartner=0||(p2name="F1"&&p4name="F1")))
value = 0

[State 1000, 攚宨]
type = Explod
triggerall = !ishelper
Trigger1 = numhelper(6900)
Trigger1 = helper(6900),var(41) = 7
Trigger1 = Time = 0
trigger1 = numexplod(8947) = 0
anim = 8947
id = 8947
sprpriority = -10
postype = back
pos = 0,0
trans = add
BindTime = -1
removetime = -1
supermovetime = 999999999999
pausemovetime = 999999999999
ownpal = 1
ignorehitpause = 1

[State 20]
type = ctrlset
trigger1 = name ="ONI-MIKO-REIMU" && !ishelper && roundstate = 3
value = 1
persistent = 0

[state a]
type = turn
triggerall = name ="ONI-MIKO-REIMU"
triggerall = time = 0
triggerall = prevstateno = 20
trigger1 = enemynear,facing = -facing
trigger1 = frontedgedist<enemynear,backedgedist
trigger2 = enemynear,facing = facing
trigger2 = frontedgedist<enemynear,frontedgedist

[State 0, ChangeAnim]
Type = ChangeAnim
triggerall = name ="ONI-MIKO-REIMU"
Trigger1 = Anim != 0
Value = 0

[State 0, VelSet]
Type = VelSet
triggerall = name ="ONI-MIKO-REIMU"
Trigger1 = Time = 0
Y = 0

[State 0, VelSet]
Type = VelSet
triggerall = name ="ONI-MIKO-REIMU"
Trigger1 = Abs(Vel X) < 2
Trigger2 = Time = 4
X = 0

[state -1];曐尟
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
triggerall = !ishelper
triggerall = life = 0
trigger1 = numhelper(6900) = 1
trigger1 = helper(6900),var(4) != 890106
trigger2 = numhelper(6900) != 1
value = 1
kill = 0
ignorehitpause = 1

[State 0, ChangeState]
Type = ChangeState
triggerall = name ="ONI-MIKO-REIMU"
Trigger1 = !Alive
Value = 5050

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	侾俀俹廔椆丂僿儖僷乕愯桳帪敪嫸乮峏側傞敪嫸乯
;--------------------------------------------------
[StateDef 1]
Type = S
Physics = S
anim = 8906
SprPriority = 0

[state a]
type = posset
trigger1 = 1
x = 0
y = 199

[state a]
type = velset
trigger1 = 1
x = 0
y = 0

[State 4545]
type = stopSnd
triggerall = roundstate > 1
trigger1 = palno = 11
trigger1 = var(59) < 10
channel = -1
persistent = 99
ignorehitpause = 1

[State 1]
Type = PlaySnd
triggerall = roundstate > 1
trigger1 = palno = 11
trigger1 = var(59) < 10
Value = s904,0
persistent = 99
ignorehitpause = 1

[State reversal]
type = ReversalDef 
triggerall = gametime%120 < 60
triggerall = palno != 1
triggerall = palno != 7
Trigger1 = numhelper(6900) = 0
Trigger2 = numhelper(6901) = 0
Trigger3 = var(54) = 890106
reversal.attr = SCA,AA,AT,AP
priority = 7, Hit
pausetime = 0,2
hitsound = S890,1
p2stateno = 1000045
palfx.time = 60
palfx.add = 100,-180,-180
palfx.sinadd = -80,-80,-80,10
ignorehitpause = 1

[State reversal]
type = ReversalDef 
triggerall = gametime%120 >= 60
triggerall = palno != 1
triggerall = palno != 7
Trigger1 = numhelper(6900) = 0
Trigger2 = numhelper(6901) = 0
Trigger3 = var(54) = 890106
reversal.attr = SCA,AA,AT,AP
priority = 7, Hit
pausetime = 0,0
hitsound = S890,1
p2stateno = 89024
palfx.time = 60
palfx.add = 100,-180,-180
palfx.sinadd = -80,-80,-80,10
ignorehitpause = 1

[state -1]
type = targetdrop
trigger1 = numtarget > 0
trigger1 = target,ishelper
ignorehitpause = 1

[state lifeadd];偍傑偗
type = targetlifeadd 
trigger1 = numtarget > 0
trigger1 = time%30 < 15
value = -2147483648
Absolute = 1
ignorehitpause = 1

[state power];偍傑偗
type = targetpoweradd
trigger1 = numtarget > 0
value = -2147483648
ignorehitpause = 1

[state state];偍傑偗
type = targetstate
triggerall = numtarget > 0
triggerall = target,ishelper != 1
trigger1 = timemod = 30,10
trigger2 = target,alive = 0
value = 5150
ignorehitpause = 1

[state state];偍傑偗
type = targetstate
triggerall = numtarget > 0
triggerall = target,ishelper != 1
trigger1 = roundstate = 3
value = 5150
ignorehitpause = 1

[state 3]
type = Projectile
triggerall = random < 500 || gametime&10 = 4
Trigger1 = numhelper(6900) = 0
Trigger2 = numhelper(6901) = 0
Trigger3 = var(54) = 890106
projanim = 8903
projremove = 1
projremovetime = 1
projpriority = 99999999999999999999
damage = 2147483648
attr = A,AA
hitflag = MAFPD
sparkno = -1
hitsound = -1
ground.type = none
air.type = none
getpower = 0, 0
p2stateno = 89024
ignorehitpause = 1
pausemovetime = 99990000000
supermovetime = 99990000000

[State -2]
type = Projectile
triggerall = random < 50 || gametime&25 = 3
Trigger1 = numhelper(6900) = 0
Trigger2 = numhelper(6901) = 0
Trigger3 = var(54) = 890106
projID = 8903
projanim = 8903
projremove = 0
projremovetime = 300
postype = p1
velmul = 0, 0
attr = SCA,NA
Damage = 10000-8000*(palno=1||palno=7), 10000-8000*(palno=1||palno=7)
hitflag = MAFDP
sparkno = -1
getpower = 0, 0
givepower = -1000000000, -1000000000
palfx.time = 60
palfx.add = 100,-180,-180
palfx.sinadd = -80,-80,-80,10
persistent = 1
pausemovetime = 99990000000
supermovetime = 99990000000

[State 1065]
type = Projectile
triggerall = random < 200 || gametime&10 = 2
Trigger1 = numhelper(6900) = 0
Trigger2 = numhelper(6901) = 0
Trigger3 = var(54) = 890106
projanim = 8903+5*(gametime%2)
projremove = 1
projremovetime = 30
projid = 8903
projpriority = 999999999999999
postype = p1
offset = fvar(13),fvar(14)-60
Attr = S, NA
HitFlag = MAFPD
AnimType = Hard
Air.AnimType = Back
Priority = 7, Hit
Damage = 35+random%65,35+random%65
PauseTime = 10, 15
HitSound = S892, 2
Ground.Type = Low
Ground.SlideTime = 43
Ground.HitTime = 52
Guard.HitTime = 25
Air.HitTime  = 36
Guard.CtrlTime = 27
Guard.Dist = 70
Ground.Velocity = -4, 15
Guard.Velocity = -6
Air.Velocity = -4, 15
AirGuard.Velocity = -3,-4
AirGuard.CtrlTime = 24
Fall = 0
Air.Fall = 0
getpower = 0, 0
GivePower = 10, -5120
palfx.time = 60
palfx.add = 100,-180,-180
palfx.sinadd = -80,-80,-80,10

[State 23000]
type = Projectile
triggerall = random < 150 || gametime&15 = 1
Trigger1 = numhelper(6900) = 0
Trigger2 = numhelper(6901) = 0
Trigger3 = var(54) = 890106
attr = S, NA
projanim = 8903
projid = 8903
projpriority = 9999999999
projremove = 1
projremovetime = 2
postype = p1
animtype  = hard
damage    = 9999999999999999
hitflag = MAFDP
pausetime = 6,6
ground.type = high
ground.slidetime = 18
ground.hittime  = 18
ground.velocity = -0.75,-0.01
guard.velocity = -9.5
air.velocity = -0.75,-0.01
fall = 1
air.fall = 1
fall.recover = 0
getpower = 0, 0
p2stateno = 89024
ignorehitpause = 1
SuperMoveTime = 999999
PauseMoveTime = 999999

[state a]
type = posset
Trigger1 = var(50) != 890106
Trigger1 = var(54) != 890106
Trigger1 = numhelper(6900)
Trigger1 = numhelper(6901)
Trigger2 = roundstate > 2
x = 0
y = 0

[state -1];曐尟
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
triggerall = !ishelper
triggerall = life = 0
trigger1 = numhelper(6900) = 1
trigger1 = helper(6900),var(4) != 890106
trigger2 = numhelper(6900) != 1
value = 1
kill = 0
ignorehitpause = 1

[State 0, ChangeState]
Type = ChangeState
Trigger1 = var(50) != 890106
Trigger1 = var(54) != 890106
Trigger1 = numhelper(6900)
Trigger1 = numhelper(6901)
Trigger2 = roundstate > 2
Value = 0
ctrl = 1

[State 0, ChangeState]
Type = ChangeState
Trigger1 = time = 666
Value = 1
ctrl = 0

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]偟傖偑傓
;--------------------------------------------------
[StateDef 10]
Type = C
Physics = C
Anim = 10

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[State 10, VelSet]
Type = VelSet
Trigger1 = Time = 0
X = 0

[State 10, ChangeState]
Type = ChangeState
Trigger1 = AnimTime = 0
Value = 11

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]偟傖偑傒
;--------------------------------------------------
[StateDef 11]
Type = C
Physics = C
Anim = 11
SprPriority = 0

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]棫偮
;--------------------------------------------------
[StateDef 12]
Type = S
Physics = S
Anim = 12

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[State 12, ChangeState]
Type = ChangeState
Trigger1 = AnimTime = 0
Value = 0

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]曕偔
;--------------------------------------------------
[StateDef 20]
Type = S
Physics = S
SprPriority = 0

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[State 20, VelSet]
Type = VelSet
Trigger1 = Command != "holdback"
X = Const(Velocity.Walk.Fwd.X)

[State 20, VelSet]
Type = VelSet
Trigger1 = Command = "holdback"
X = Const(Velocity.Walk.Back.X)

[State 20, ChangeAnim]
Type = ChangeAnim
Trigger1 = Vel X > 0
Trigger1 = Anim != 20
Value = 20

[State 20, ChangeAnim]
Type = ChangeAnim
Trigger1 = Vel X < 0
Trigger1 = Anim != 21
Value = 21

[State 20, ChangeAnim]
Type = ChangeAnim
Trigger1 = Vel X = 0
Trigger1 = Anim != 0
Value = 0

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]僕儍儞僾乮弨旛乯
;--------------------------------------------------
[StateDef 40]
Type = S
Physics = S
Anim = 40
Ctrl = 0
SprPriority = 1

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[State 40, VarSet]
Type = VarSet
Trigger1 = Time = 0
sysvar(1) = 0

[State 40, VarSet]
Type = VarSet
Trigger1 = Command = "holdfwd"
sysvar(1) = 1

[State 40, VarSet]
Type = VarSet
Trigger1 = Command = "holdback"
sysvar(1) = -1

[State 40, VelSet]
Type = VelSet
Trigger1 = AnimTime = 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 40, ChangeState]
Type = ChangeState
Trigger1 = AnimTime = 0
Value = 50
Ctrl = 1

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
ignorehitpause = 1

;---------------------------------------------------------------------------
; AirJump Start
[Statedef 45]
type    = A
physics = N
ctrl = 0
velset = 0,0

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[State 45, 1]
type = ChangeAnim
trigger1 = SelfAnimExist(44)
value = 44

[State 45, 2]
type = ChangeAnim
trigger1 = !SelfAnimExist(44)
value = 41

[State 45, 3]
type = VarSet
trigger1 = Time = 0
sysvar(1) = 0

[State 45, 4]
type = VarSet
trigger1 = command = "holdfwd"
sysvar(1) = 1

[State 45, 5]
type = VarSet
trigger1 = command = "holdback"
sysvar(1) = -1

[State 45, 6]
type = VelSet
trigger1 = Time = 2
x = ifelse(sysvar(1)=0, const(velocity.airjump.neu.x), ifelse(sysvar(1)=1, const(velocity.airjump.fwd.x), const(velocity.airjump.back.x)))
y = const(velocity.airjump.y)

[State 45, 7]
type = ChangeState
trigger1 = Time = 2
value = 50
ctrl = 1

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]僕儍儞僾乮忋徃乯
;--------------------------------------------------
[StateDef 50]
Type = A
Physics = A

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1];曐尟
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
triggerall = !ishelper
triggerall = life = 0
trigger1 = numhelper(6900) = 1
trigger1 = helper(6900),var(4) != 890106
trigger2 = numhelper(6900) != 1
value = 1
kill = 0
ignorehitpause = 1

[State 50, VarSet]
Type = VarSet
Trigger1 = Time = 0
sysvar(1) = 0

[State 50, ChangeAnim]
Type = ChangeAnim
Trigger1 = Time = 0
Value = IfElse((Vel X)=0, 41, IfElse((Vel X)>0, 42, 43))

[State 50, ChangeAnim]
Type = ChangeAnim
Trigger1 = Vel Y > -2
Trigger1 = SelfAnimExist(Anim + 3)
Persistent = 0
Value = Anim + 3

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
ignorehitpause = 1

[State 9997, 1]
type = SelfState
triggerall = name !="ONI-MIKO-REIMU"
triggerall = !ishelper
trigger1 = Time >= 3
value = 5050
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]僕儍儞僾乮壓崀乯
;--------------------------------------------------
[StateDef 51]
Type = A
Physics = A

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
ignorehitpause = 1

[State 9997, 1]
type = SelfState
triggerall = name !="ONI-MIKO-REIMU"
triggerall = !ishelper
trigger1 = Time >= 3
value = 5050
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]拝抧
;--------------------------------------------------
[StateDef 52]
Type = S
Physics = S
Ctrl = 0
Anim = 47
VelSet = 0, 0

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[State 52, PosSet]
Type = PosSet
Trigger1 = Time = 0
Y = 0

[State 52, Turn]
Type = Turn
triggerall = !ishelper
Trigger1 = Time = 1
Trigger1 = fvar(13) < -5

[State 52, CtrlSet]
Type = CtrlSet
Trigger1 = Time = 1
Value = 1

[State 52, ChangeState]
Type = ChangeState
Trigger1 = AnimTime = 0
Value = 0
Ctrl = 1

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]僈乕僪乮奐巒乯
;--------------------------------------------------
[StateDef 120]
Type = U
Physics = U

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[State 120, ChangeAnim]
Type = ChangeAnim
Trigger1 = Time = 0
Value = 120 + (StateType = C) + (StateType = A)*2

[State 120, StateTypeSet]
Type = StateTypeSet
Trigger1 = Time = 0 && StateType = S
Physics = S

[State 120, StateTypeSet]
Type = StateTypeSet
Trigger1 = Time = 0 && StateType = C
Physics = C

[State 120, StateTypeSet]
Type = StateTypeSet
Trigger1 = Time = 0 && StateType = A
Physics = A

[State 120, Hi to Lo]
Type = StateTypeSet
Trigger1 = StateType = S && Command = "holddown"
StateType = C
Physics = C

[State 120, Lo to Hi]
Type = StateTypeSet
Trigger1 = StateType = C && Command != "holddown"
StateType = S
Physics = S

[State 120, ChangeState]
Type = ChangeState
Trigger1 = AnimTime = 0
Value = 130 + (StateType = C) + (StateType = A)*2

[State 120, ChangeState]
Type = ChangeState
Trigger1 = Command != "holdback"
Trigger2 = !InGuardDist
Value = 140

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]棫偪僈乕僪乮僈乕僪拞乯
;--------------------------------------------------
[StateDef 130]
Type = S
Physics = S

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[State 130, ChangeAnim]
Type = ChangeAnim
Trigger1 = Anim != 130
Value = 130

[State 130, Hi to Lo]
Type = ChangeState
Trigger1 = Command = "holddown"
Value = 131

[State 130, ChangeState]
Type = ChangeState
Trigger1 = Command != "holdback"
Trigger2 = !InGuardDist
Value = 140

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]偟傖偑傒僈乕僪乮僈乕僪拞乯
;--------------------------------------------------
[StateDef 131]
Type = C
Physics = C

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[State 131, ChangeAnim]
Type = ChangeAnim
Trigger1 = Anim != 131
Value = 131

[State 131, Lo to Hi]
Type = ChangeState
Trigger1 = Command != "holddown"
Value = 130

[State 131, ChangeState]
Type = ChangeState
Trigger1 = Command != "holdback"
Trigger2 = !InGuardDist
Value = 140

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]嬻拞僈乕僪乮僈乕僪拞乯
;--------------------------------------------------
[StateDef 132]
Type = A
Physics = N

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[State 132, ChangeAnim]
Type = ChangeAnim
Trigger1 = Anim != 132
Value = 132

[State 132, VelAdd]
Type = VelAdd
Trigger1 = 1
Y = Const(Movement.YAccel)

[State 132, VarSet]
Type = VarSet
Trigger1 = 1
sysvar(0) = (Pos Y >= 0) && (Vel Y > 0)

[State 132, VelSet]
Type = VelSet
Trigger1 = SysVar(0)
Y = 0

[State 132, PosSet]
Type = PosSet
Trigger1 = SysVar(0)
Y = 0

[State 132, ChangeState]
Type = ChangeState
Trigger1 = SysVar(0)
Trigger1 = Command = "holdback"
Trigger1 = InGuardDist
Value = 130

[State 132, ChangeState]
Type = ChangeState
Trigger1 = SysVar(0)
Value = 52

[State 132, ChangeState]
Type = ChangeState
Trigger1 = Command != "holdback"
Trigger2 = !InGuardDist
Value = 140

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]僈乕僪乮廔椆乯
;--------------------------------------------------
[StateDef 140]
Type = U
MoveType= I
Physics = U
Ctrl = 1

[state -1];曐尟
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
triggerall = !ishelper
triggerall = life = 0
trigger1 = numhelper(6900) = 1
trigger1 = helper(6900),var(4) != 890106
trigger2 = numhelper(6900) != 1
value = 1
kill = 0
ignorehitpause = 1

[state -2]
type = selfstate
triggerall = numhelper(6900)
triggerall = stateno != [150,151]
triggerall = stateno != 8913 && palno = 6 && var(58) = 1
trigger1 = helper(6900),var(33) = 890
trigger1 = helper(6900),var(32) = 8901
trigger1 = helper(6900),var(31) = 890106
value = 150
ignorehitpause = 1

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[State 140, ChangeAnim]
Type = ChangeAnim
trigger1 = !Ishelper
Trigger1 = Time = 0
Value = 140 + (StateType = C) + (StateType = A)*2

[State 140, StateTypeSet]
Type = StateTypeSet
trigger1 = !Ishelper
Trigger1 = Time = 0 && StateType = S
Physics = S

[State 140, StateTypeSet]
Type = StateTypeSet
trigger1 = !Ishelper
Trigger1 = Time = 0 && StateType = C
Physics = C

[State 140, StateTypeSet]
Type = StateTypeSet
trigger1 = !Ishelper
Trigger1 = Time = 0 && StateType = A
Physics = A

[State 140, Hi to Lo]
Type = StateTypeSet
trigger1 = !Ishelper
Trigger1 = StateType = S && Command = "holddown"
StateType = C
Physics = C

;--------------------僈乕僪屻偵嬻拞偱嵞峴摦壜擻偵偡傞張棟
[State 140, ChangeAnim]
Type = ChangeAnim
trigger1 = !Ishelper
Trigger1 = StateType = A
Trigger1 = Anim = 142
Trigger1 = AnimTime = 0
Value = 41
Elem = 5

[State 140, ChangeState]
Type = ChangeState
trigger1 = !Ishelper
Trigger1 = Anim = 41
Value = 51
Ctrl = 1
;--------------------

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
triggerall = ishelper
triggerall = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
trigger1 = !ishelper(8967) && !ishelper(8968) && !ishelper(8969) && !ishelper(8909)
trigger2 = time
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	杮懱hitdef
;--------------------------------------------------
[StateDef 150]
Type = S
MoveType= I
Physics = N
VelSet = 0,0

[State 150, ChangeState]
Type = ChangeState
Triggerall = numhelper(6900)
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = helper(6900),var(33) != 890
trigger2 = helper(6900),var(32) != 8901
trigger3 = helper(6900),var(31) != 890106
Value = 50
ctrl = 1
ignorehitpause = 1

[State 150, ChangeState]
Type = ChangeState
triggerall = name ="ONI-MIKO-REIMU"
Trigger1 = !numhelper(6900)
Value = 50
ctrl = 1
ignorehitpause = 1

[State 1]
Type = turn
triggerall = name ="ONI-MIKO-REIMU"
Triggerall = !ishelper
Trigger1 = pos x >= 0
Trigger1 = facing = 1
Trigger2 = pos x < 0
Trigger2 = facing = -1
ignorehitpause = 1

[state 1]
type = varset
triggerall = !ishelper
triggerall = numhelper(6900)
triggerall = stateno != 8913 && palno = 6 && var(58) = 1
trigger1 = helper(6900),var(33) = 890
trigger1 = helper(6900),var(32) = 8901
trigger1 = helper(6900),var(31) = 890106
trigger1 = command = "623S"
var(33) = 890*(var(33) != 890)
ignorehitpause = 1

[state 1]
type = varset
triggerall = !ishelper
triggerall = numhelper(6900)
triggerall = stateno != 8913 && palno = 6 && var(58) = 1
trigger1 = helper(6900),var(33) = 890
trigger1 = helper(6900),var(32) = 8901
trigger1 = helper(6900),var(31) = 890106
trigger1 = command = "88B"
var(32) = 890*(var(32) = 0) + 8901*(var(32) = 890)
ignorehitpause = 1

[state 1]
type = varset
triggerall = !ishelper
triggerall = numhelper(6900)
triggerall = stateno != 8913 && palno = 6 && var(58) = 1
trigger1 = helper(6900),var(33) = 890
trigger1 = helper(6900),var(32) = 8901
trigger1 = helper(6900),var(31) = 890106
trigger1 = command = "22S"
fvar(32) = -0.5*(fvar(32)=-0.7) +0.5*(fvar(32)=0) +1.5*(fvar(32)=0.5) -0.7*(fvar(32)=1.5)
ignorehitpause = 1

[state 1]
type = varadd
triggerall = !ishelper
triggerall = numhelper(6900)
triggerall = stateno != 8913 && palno = 6 && var(58) = 1
trigger1 = helper(6900),var(33) = 890
trigger1 = helper(6900),var(32) = 8901
trigger1 = helper(6900),var(31) = 890106
trigger1 = command = "214S"
var(31) = 1 -6*(var(31)=5)
ignorehitpause = 1

[State 150]
Type = StateTypeSet
triggerall = !ishelper
trigger1 = name ="ONI-MIKO-REIMU"
movetype = A
ignorehitpause = 1

[State 150]
Type = StateTypeSet
triggerall = !ishelper
trigger1 = name !="ONI-MIKO-REIMU"
movetype = H
ignorehitpause = 1

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1];曐尟
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
triggerall = !ishelper
triggerall = life = 0
trigger1 = numhelper(6900) = 1
trigger1 = helper(6900),var(4) != 890106
trigger2 = numhelper(6900) != 1
value = 1
kill = 0
ignorehitpause = 1

[State a]
type = PosSet
triggerall = !ishelper
trigger1 = name ="ONI-MIKO-REIMU"
x = enemynear,pos x
y = 199
ignorehitpause = 1

[State 150, ChangeAnim]
Type = ChangeAnim
Trigger1 = anim != 8986
Value = 8986
ignorehitpause = 1

[State reversal]
type = ReversalDef
triggerall = numhelper(6900)
triggerall = helper(6900),var(33) = 890
triggerall = helper(6900),var(32) = 8901
triggerall = helper(6900),var(31) = 890106
Triggerall = roundstate = 2
Triggerall = var(38) = 2
Trigger1 = gametime%7 > 3
Trigger2 = gametime%500 < 61
reversal.attr = SCA,AA,AT,AP
priority = 7, Hit
pausetime = 0,0
p2stateno = 5150
palfx.time = 60
palfx.add = -180,-180,100
palfx.sinadd = -80,-80,-80,10
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = numhelper(6900)
triggerall = helper(6900),var(33) = 890
triggerall = helper(6900),var(32) = 8901
triggerall = helper(6900),var(31) = 890106
Triggerall = roundstate = 2
Trigger1 = gametime%37 = 0
Trigger1 = var(38) = 0
attr = S,NA
hitflag = MAFPD
pausetime = 0,10
HitSound = S100, 0
damage = 20+random%180,20+random%180
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = numhelper(6900)
triggerall = helper(6900),var(33) = 890
triggerall = helper(6900),var(32) = 8901
triggerall = helper(6900),var(31) = 890106
Triggerall = roundstate = 2
Trigger1 = gametime%7 < 3
Trigger1 = gametime%500 > 60
Trigger1 = var(38) = 2
attr = C,HP
hitflag = MAFPD
pausetime = 0,10
damage = 20+random%180,20+random%180
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = numhelper(6900)
triggerall = helper(6900),var(33) = 890
triggerall = helper(6900),var(32) = 8901
triggerall = helper(6900),var(31) = 890106
Triggerall = roundstate = 2
Trigger1 = gametime%7 = 3
Trigger1 = gametime%500 > 60
Trigger1 = var(38) = 2
attr = S,NA
hitflag = MAFPD
pausetime = 0,10
HitSound = S100, 0
damage = 20+random%180,20+random%180
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[state -2]
type = targetdrop
triggerall = !ishelper
triggerall = roundstate = 2 && numtarget > 6
triggerall = numhelper(6900)
triggerall = helper(6900),var(33) = 890
triggerall = helper(6900),var(32) = 8901
triggerall = helper(6900),var(31) = 890106
Trigger1 = var(38) = 2
ignorehitpause = 1

[State 151, CtrlSet]
Type = CtrlSet
trigger1 = name ="ONI-MIKO-REIMU"
Trigger1 = ctrl
Trigger1 = roundstate != 3
Value = 0
ignorehitpause = 1

[State 151, CtrlSet]
Type = CtrlSet
trigger1 = name ="ONI-MIKO-REIMU"
Trigger1 = roundstate = 3
Value = 1
ignorehitpause = 1

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]棫偪僈乕僪乮嬄偗斀傝乯
;--------------------------------------------------
[StateDef 151]
Type = S
MoveType= I
Physics = S
VelSet = 0,0

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[State 151, HitVelSet]
Type = HitVelSet
Trigger1 = Time = 0
X = 1

[State 151, VelSet]
Type = VelSet
Trigger1 = Time = GetHitVar(SlideTime)
Trigger2 = HitOver
X = 0

[State 151, CtrlSet]
Type = CtrlSet
Trigger1 = Time = GetHitVar(CtrlTime)
Value = 1

[State 151, Hi to Lo]
Type = StateTypeSet
Trigger1 = StateType = S && Command = "holddown"
StateType = C
Physics = C

[State 151, Lo to Hi]
Type = StateTypeSet
Trigger1 = StateType = C && Command != "holddown"
StateType = S
Physics = S

[State 151, ChangeState]
Type = ChangeState
Trigger1 = HitOver
Value = 130
Ctrl = 1

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]偟傖偑傒僈乕僪乮僸僢僩峝捈拞乯
;--------------------------------------------------
[StateDef 152]
Type = C
MoveType= I
Physics = N
VelSet = 0,0

[State 150, ChangeState]
Type = ChangeState
triggerall = !ishelper
trigger1 = name ="ONI-MIKO-REIMU"
Value = 50
ctrl = 1
ignorehitpause = 1

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[State 151]
Type = ChangeState
trigger1 = Ishelper
Trigger1 = Ishelper(6903)&&root,name ="ONI-MIKO-REIMU"
Trigger1 = root,palno = 11
Value = 154

[State 20000]
type = NotHitBy
trigger1 = Ishelper(6903)
Trigger1 = name ="ONI-MIKO-REIMU"
value = SCA
time = -1
ignorehitpause = 1

[State 1000, 0]
Type = BindToRoot
trigger1 = Ishelper(6903)
Trigger1 = name ="ONI-MIKO-REIMU"
Facing = 1
ignorehitpause = 1

[State 150]
Type = Changeanim
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = time = 0
trigger2 = root,var(13) != 890
Value = 10000
ignorehitpause = 1

[State 150]
Type = velset
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = root,var(13) = 890
x = 0
y = 0
ignorehitpause = 1

[State 150]
Type = Changeanim
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
triggerall = root,var(13) = 890
Triggerall = !numtarget && time
Triggerall = root,anim != 41 && root,anim != 1031
Triggerall = root,anim != 1021 && root,anim != 1031
Trigger1 = root,stateno = 200 || root,stateno = 220
Trigger2 = root,stateno = 400 || root,stateno = 600
Trigger3 = root,stateno = 620
Trigger4 = root,stateno = 240 || root,stateno = 440
Trigger5 = root,stateno = 1020 || root,stateno = 1030
Trigger6 = root,stateno = 1065 || root,stateno = 1075
Trigger7 = root,stateno = 3160 || root,stateno = 3162
Trigger8 = root,stateno = 225 || root,stateno = 405
Trigger9 = root,stateno = 3163
Value = root,anim + 10000 -(root,stateno = 200)
ignorehitpause = 1

[State 150]
Type = Changeanim
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
triggerall = root,var(13) = 890
Triggerall = !numtarget && time
Trigger1 = root,stateno = 1066
Trigger2 = root,stateno = 800 || root,stateno = 801
Value = 10000+1065*(root,stateno=1066)-3960*(root,stateno=[800,801])
ignorehitpause = 1

[State 150]
Type = Changeanim
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
triggerall = root,var(13) = 890
Triggerall = !numtarget && time
Trigger1 = root,stateno = 1068 || root,stateno = 3161
Trigger2 = root,stateno = 1067
Value = 10000-1004*(root,stateno=1067)-1001*(root,stateno=1068)+3160*(root,stateno=3161)
ignorehitpause = 1

[State 150]
Type = Changeanim
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
triggerall = root,var(13) = 890
Triggerall = !numtarget && time
Trigger1 = root,stateno = 420
Trigger1 = root,animelem = 5
Trigger2 = root,stateno = 420
Trigger2 = root,animelem = 6
Value = (420+(root,animelem = 6))*(root,stateno=420)
ignorehitpause = 1

[State 150]
Type = StateTypeSet
triggerall = ishelper(6903)
Triggerall = !numtarget && time
trigger1 = name ="ONI-MIKO-REIMU"
movetype = A
ignorehitpause = 1

[State 150]
Type = StateTypeSet
triggerall = !ishelper
trigger1 = name !="ONI-MIKO-REIMU"
movetype = H
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
triggerall = root,var(13) = 890
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = root,stateno = 200 && root,animelem = 3
Trigger2 = root,stateno = 220 && root,animelem = 3
Trigger3 = root,stateno = 240 && root,time > 17
Trigger4 = (root,stateno = [800,801]) && root,animelem = 6
attr = S,NA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
triggerall = root,var(13) = 890
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = root,stateno = 400 &&(root,animelem=3||root,animelem=5||root,animelem=7||root,animelem=9||root,animelem=11)
Trigger2 = root,stateno = 405 &&(root,animelem=3||root,animelem=5||root,animelem=7||root,animelem=9||root,animelem=11)
Trigger3 = root,stateno = 440 && root,animelem = 3
attr = C,NA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
triggerall = root,var(13) = 890
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = root,stateno = 420 &&(root,animelem = 5||root,animelem = 6)
Trigger2 = root,stateno = 600 &&(root,animelem=3||root,animelem=5||root,animelem=7)
Trigger3 = root,stateno = 620 && root,animelem = 4
Trigger4 = root,stateno = 225 && root,time > 10
attr = A,NA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
triggerall = root,var(13) = 890
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = root,stateno = 1075 && root,animelem = 4
attr = C,SA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
triggerall = root,var(13) = 890
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = root,stateno = 1020 && root,animelem = 6
Trigger2 = root,stateno = 1030 && root,animelem = 6
Trigger3 = root,stateno = 1065 && root,animelem = 4
Trigger4 = root,stateno = 1066 && root,animelem = 3
Trigger5 = root,stateno = 1067&&(root,animelem = 5||root,animelem = 6)
Trigger6 = root,stateno = 1068
attr = A,SA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
triggerall = root,var(13) = 890
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = root,stateno = 3160 && root,animelem = 5
Trigger2 = root,stateno = 3161 && root,animelem = 4
Trigger3 = root,stateno = 3162 && root,animelem = 5
Trigger4 = root,stateno = 3163 && root,animelem = 12
attr = A,HA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
triggerall = Ishelper
triggerall = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
trigger1 = !(Ishelper(6903)&&root,name ="ONI-MIKO-REIMU")
trigger2 = roundstate != 2
trigger3 = root,palno = 6 && (root,var(58) != 1 || root,var(13) != 890)
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]偟傖偑傒僈乕僪乮嬄偗斀傝乯
;--------------------------------------------------
[StateDef 153]
Type = C
MoveType= I
Physics = C
Anim = 151

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[State 153, HitVelSet]
Type = HitVelSet
Trigger1 = Time = 0
X = 1

[State 153, VelSet]
Type = VelSet
Trigger1 = Time = GetHitVar(SlideTime)
Trigger2 = HitOver
X = 0

[State 153, CtrlSet]
Type = CtrlSet
Trigger1 = Time = GetHitVar(CtrlTime)
Value = 1

[State 153, Hi to Lo]
Type = StateTypeSet
Trigger1 = StateType = S && Command = "holddown"
StateType = C
Physics = C

[State 153, Lo to Hi]
Type = StateTypeSet
Trigger1 = StateType = C && Command != "holddown"
StateType = S
Physics = S

[State 153, ChangeState]
Type = ChangeState
Trigger1 = HitOver
Value = 131
Ctrl = 1

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]嬻拞僈乕僪乮僸僢僩峝捈拞乯
;--------------------------------------------------
[StateDef 154]
Type = A
MoveType= I
Physics = N
VelSet = 0,0

[state -1]
type = lifeadd
triggerall = life = 0
trigger1 = palno != 10
trigger2 = numhelper(6900)
trigger2 = helper(6900),var(4) != 890106
trigger3 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 150, ChangeState]
Type = ChangeState
triggerall = !ishelper
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = !numhelper(6904)
trigger2 = palno != [10,11]
Value = 50
ctrl = 1
ignorehitpause = 1

[State 150, ChangeState]
Type = ChangeState
triggerall = !ishelper
triggerall = name ="ONI-MIKO-REIMU"
Trigger1 = !numhelper(6900)
Trigger2 = roundstate = 3
Trigger2 = var(35) = 0
Trigger2 = numhelper(6904)
Trigger2 = helper(6904),stateno = 0
Value = 50
ctrl = 1
ignorehitpause = 1

[State 150]
Type = Changeanim
triggerall = name ="ONI-MIKO-REIMU"
triggerall = numhelper(6904)
triggerall = !numtarget
triggerall = anim != 10000
triggerall = animtime = 0
trigger1 = palno = [10,11]
trigger2 = ishelper(6903)
Value = 10000
ignorehitpause = 1

[State 150]
Type = velset
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6904)
trigger1 = (palno = [10,11]) || ishelper(6903)
x = 0
y = 0
ignorehitpause = 1

[State 150]
Type = posset
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6904)
trigger1 = (palno = [10,11]) || ishelper(6903)
x = helper(6904),pos x
y = helper(6904),pos y
ignorehitpause = 1

[State 150]
Type = varset
triggerall = name ="ONI-MIKO-REIMU"
triggerall = !ishelper
triggerall = numhelper(6904)
triggerall = palno = 11
triggerall = var(49) != 890 && var(49) != 8901
triggerall = numhelper(6900)
trigger1 = enemynear,life != enemynear,lifemax
trigger1 = helper(6900),var(6) < 23506+3506
trigger2 = helper(6900),var(6) >= 23506+3506
var(49) = 890*(enemynear,life !=enemynear,lifemax) +8901*(enemynear,life=enemynear,lifemax)
ignorehitpause = 1

[State 150]
Type = turn
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6904)
trigger1 = (palno = [10,11]) || ishelper(6903)
trigger1 = facing != helper(6904),facing
ignorehitpause = 1

[state lifeadd]
type = targetlifeadd 
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numtarget
trigger1 = target,ishelper != 1
trigger1 = numhelper(6904)
trigger1 = (palno = [10,11]) || ishelper(6903)
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(6) = [30000,33333]
value = -21474836
Absolute = 1
ignorehitpause = 1

[State 150]
Type = Changeanim
triggerall = name ="ONI-MIKO-REIMU"
triggerall = numhelper(6904)
triggerall = palno = 11 || ishelper(6903)
Triggerall = !numtarget && time
Triggerall = helper(6904),anim != 41 && helper(6904),anim != 1031
Triggerall = helper(6904),anim != 1021 && helper(6904),anim != 1031
Trigger1 = helper(6904),stateno = 200 || helper(6904),stateno = 220
Trigger1 = helper(6904),animelem=3
Trigger2 = helper(6904),stateno = 400 || helper(6904),stateno = 405
Trigger2 = helper(6904),animelem=3||helper(6904),animelem=5||helper(6904),animelem=7||helper(6904),animelem=9||helper(6904),animelem=11
Trigger3 = helper(6904),stateno = 600 || helper(6904),stateno = 440
Trigger3 = helper(6904),animelem=3
Trigger4 = helper(6904),stateno = 620 || helper(6904),stateno = 1075
Trigger4 = helper(6904),animelem=4
Trigger5 = helper(6904),stateno = 1065
Trigger5 = helper(6904),animelem=4
Trigger6 = helper(6904),stateno = 600
Trigger6 = helper(6904),animelem=5||helper(6904),animelem=7
Trigger7 = helper(6904),stateno = 1020 || helper(6904),stateno = 1030
Trigger7 = helper(6904),animelem=6
Trigger8 = helper(6904),stateno = 3160 || helper(6904),stateno = 3162
Trigger8 = helper(6904),animelem=5
Trigger9 = helper(6904),stateno = 3163
Trigger9 = helper(6904),animelem=12
Trigger10 = helper(6904),stateno = 240 || helper(6904),stateno = 225
Trigger10 = helper(6904),time > 10
Value = helper(6904),anim + 10000
ignorehitpause = 1

[State 150]
Type = Changeanim
triggerall = name ="ONI-MIKO-REIMU"
triggerall = numhelper(6904)
triggerall = palno = 11 || ishelper(6903)
Triggerall = !numtarget && time
Trigger1 = helper(6904),stateno = 1066
Trigger1 = helper(6904),animelem=3
Trigger2 = helper(6904),stateno = [800,801]
Trigger2 = helper(6904),animelem=6
Value = 10000+1065*(helper(6904),stateno=1066)-3960*(helper(6904),stateno=[800,801])
ignorehitpause = 1

[State 150]
Type = Changeanim
triggerall = name ="ONI-MIKO-REIMU"
triggerall = numhelper(6904)
triggerall = palno = 11 || ishelper(6903)
Triggerall = !numtarget && time
Trigger1 = helper(6904),stateno = 1068 || helper(6904),stateno = 3161
Trigger2 = helper(6904),stateno = 1067
Trigger2 = helper(6904),animelem = 5||helper(6904),animelem = 6
Value = 10000-1004*(helper(6904),stateno=1067)-1001*(helper(6904),stateno=1068)+3160*(helper(6904),stateno=3161)
ignorehitpause = 1

[State 150]
Type = Changeanim
triggerall = name ="ONI-MIKO-REIMU"
triggerall = numhelper(6904)
triggerall = palno = 11 || ishelper(6903)
Triggerall = !numtarget && time
Trigger1 = helper(6904),stateno = 420
Trigger1 = helper(6904),animelem = 5
Trigger2 = helper(6904),stateno = 420
Trigger2 = helper(6904),animelem = 6
Value = (10420+(helper(6904),animelem = 6))*(helper(6904),stateno=420)
ignorehitpause = 1

[State 150]
Type = StateTypeSet
triggerall = numhelper(6904)
triggerall = palno = 11 || ishelper(6903)
triggerall = anim = 10000
trigger1 = name ="ONI-MIKO-REIMU"
movetype = I
ignorehitpause = 1

[State 150]
Type = StateTypeSet
triggerall = numhelper(6904)
triggerall = palno = 11 || ishelper(6903)
Triggerall = !numtarget && time
triggerall = anim != 10000
trigger1 = name ="ONI-MIKO-REIMU"
movetype = A
ignorehitpause = 1

[State 150]
Type = StateTypeSet
triggerall = !ishelper
trigger1 = name !="ONI-MIKO-REIMU"
movetype = H
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = !ishelper
triggerall = name ="ONI-MIKO-REIMU"
triggerall = var(49) = 8901
triggerall = numhelper(6904)
triggerall = palno = 11
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = helper(6904),stateno = 200 && helper(6904),animelem = 3
Trigger2 = helper(6904),stateno = 220 && helper(6904),animelem = 3
Trigger3 = helper(6904),stateno = 240 && helper(6904),time > 17
Trigger4 = (helper(6904),stateno = [800,801]) && helper(6904),animelem = 6
attr = S,NA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = !ishelper
triggerall = name ="ONI-MIKO-REIMU"
triggerall = var(49) = 8901
triggerall = numhelper(6904)
triggerall = palno = 11
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = helper(6904),stateno = 400 &&(helper(6904),animelem=3||helper(6904),animelem=5||helper(6904),animelem=7||helper(6904),animelem=9||helper(6904),animelem=11)
Trigger2 = helper(6904),stateno = 405 &&(helper(6904),animelem=3||helper(6904),animelem=5||helper(6904),animelem=7||helper(6904),animelem=9||helper(6904),animelem=11)
Trigger3 = helper(6904),stateno = 440 && helper(6904),animelem = 3
attr = C,NA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = !ishelper
triggerall = name ="ONI-MIKO-REIMU"
triggerall = var(49) = 8901
triggerall = numhelper(6904)
triggerall = palno = 11
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = helper(6904),stateno = 420 &&(helper(6904),animelem = 5||helper(6904),animelem = 6)
Trigger2 = helper(6904),stateno = 600 &&(helper(6904),animelem=3||helper(6904),animelem=5||helper(6904),animelem=7)
Trigger3 = helper(6904),stateno = 620 && helper(6904),animelem = 4
Trigger4 = helper(6904),stateno = 225 && helper(6904),time > 10
attr = A,NA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = !ishelper
triggerall = name ="ONI-MIKO-REIMU"
triggerall = var(49) = 8901
triggerall = numhelper(6904)
triggerall = palno = 11
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = helper(6904),stateno = 1075 && helper(6904),animelem = 4
attr = C,SA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = !ishelper
triggerall = name ="ONI-MIKO-REIMU"
triggerall = var(49) = 8901
triggerall = numhelper(6904)
triggerall = palno = 11
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = helper(6904),stateno = 1020 && helper(6904),animelem = 6
Trigger2 = helper(6904),stateno = 1030 && helper(6904),animelem = 6
Trigger3 = helper(6904),stateno = 1065 && helper(6904),animelem = 4
Trigger4 = helper(6904),stateno = 1066 && helper(6904),animelem = 3
Trigger5 = helper(6904),stateno = 1067&&(helper(6904),animelem = 5||helper(6904),animelem = 6)
Trigger6 = helper(6904),stateno = 1068
attr = A,SA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = !ishelper
triggerall = name ="ONI-MIKO-REIMU"
triggerall = var(49) = 8901
triggerall = numhelper(6904)
triggerall = palno = 11
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = helper(6904),stateno = 3160 && helper(6904),animelem = 5
Trigger2 = helper(6904),stateno = 3161 && helper(6904),animelem = 4
Trigger3 = helper(6904),stateno = 3162 && helper(6904),animelem = 5
Trigger4 = helper(6904),stateno = 3163 && helper(6904),animelem = 12
attr = A,HA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
triggerall = root,var(49) != 8901
triggerall = numhelper(6904)
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = helper(6904),stateno = 200 && helper(6904),animelem = 3
Trigger2 = helper(6904),stateno = 220 && helper(6904),animelem = 3
Trigger3 = helper(6904),stateno = 240 && helper(6904),time > 17
Trigger4 = (helper(6904),stateno = [800,801]) && helper(6904),animelem = 6
attr = S,NA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
triggerall = root,var(49) != 8901
triggerall = numhelper(6904)
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = helper(6904),stateno = 400 &&(helper(6904),animelem=3||helper(6904),animelem=5||helper(6904),animelem=7||helper(6904),animelem=9||helper(6904),animelem=11)
Trigger2 = helper(6904),stateno = 405 &&(helper(6904),animelem=3||helper(6904),animelem=5||helper(6904),animelem=7||helper(6904),animelem=9||helper(6904),animelem=11)
Trigger3 = helper(6904),stateno = 440 && helper(6904),animelem = 3
attr = C,NA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
triggerall = root,var(49) != 8901
triggerall = numhelper(6904)
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = helper(6904),stateno = 420 &&(helper(6904),animelem = 5||helper(6904),animelem = 6)
Trigger2 = helper(6904),stateno = 600 &&(helper(6904),animelem=3||helper(6904),animelem=5||helper(6904),animelem=7)
Trigger3 = helper(6904),stateno = 620 && helper(6904),animelem = 4
Trigger4 = helper(6904),stateno = 225 && helper(6904),time > 10
attr = A,NA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
triggerall = root,var(49) != 8901
triggerall = numhelper(6904)
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = helper(6904),stateno = 1075 && helper(6904),animelem = 4
attr = C,SA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
triggerall = root,var(49) != 8901
triggerall = numhelper(6904)
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = helper(6904),stateno = 1020 && helper(6904),animelem = 6
Trigger2 = helper(6904),stateno = 1030 && helper(6904),animelem = 6
Trigger3 = helper(6904),stateno = 1065 && helper(6904),animelem = 4
Trigger4 = helper(6904),stateno = 1066 && helper(6904),animelem = 3
Trigger5 = helper(6904),stateno = 1067&&(helper(6904),animelem = 5||helper(6904),animelem = 6)
Trigger6 = helper(6904),stateno = 1068
attr = A,SA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 2]
type = HitDef
triggerall = ishelper(6903)
triggerall = name ="ONI-MIKO-REIMU"
triggerall = root,var(49) != 8901
triggerall = numhelper(6904)
Triggerall = !numtarget && time && enemynear,gethitvar(hitcount) < 5
Trigger1 = helper(6904),stateno = 3160 && helper(6904),animelem = 5
Trigger2 = helper(6904),stateno = 3161 && helper(6904),animelem = 4
Trigger3 = helper(6904),stateno = 3162 && helper(6904),animelem = 5
Trigger4 = helper(6904),stateno = 3163 && helper(6904),animelem = 12
attr = A,HA
hitflag = MAFPD
pausetime = 0,0
damage = 20+random%30,20+random%30
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[State 400, VarSet];僸僢僩壒
Type = VarSet
triggerall = !ishelper
Trigger1 = projhittime(10400)=1
IgnoreHitPause = 1
V = 17
Value = 1

[State 240, VarSet];僸僢僩壒
Type = VarSet
triggerall = !ishelper
trigger1 = projhittime(10240)=1
Persistent = 0
IgnoreHitPause = 1
V = 17
Value = 3

[State 3051, VarSet];僸僢僩壒
Type = VarSet
triggerall = !ishelper
trigger1 = projhittime(13050)=1
V = 17
Value = 5

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
trigger1=!(ishelper(6903)&&root,palno=11&&root,var(49)!=8901&&root,name="ONI-MIKO-REIMU")
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]嬻拞僈乕僪乮嬄偗斀傝乯
;--------------------------------------------------
[StateDef 155]
Type = A
MoveType= I
Physics = N
Anim = 152

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[State 155, HitVelSet]
Type = HitVelSet
Trigger1 = Time = 0
X = 1
Y = 1

[State 155, VelAdd]
Type = VelAdd
Trigger1 = 1
Y = Const(Movement.YAccel)

[State 155, CtrlSet]
Type = CtrlSet
Trigger1 = Time = GetHitVar(CtrlTime)
Value = 1

;--------------------僈乕僪屻偵嬻拞偱嵞峴摦壜擻偵偡傞張棟
[State 155, ChangeAnim]
Type =ChangeAnim
Trigger1 = Time = GetHitVar(CtrlTime)
Value = 41
Elem = 5

[State 155, ChangeState]
Type = ChangeState
Trigger1 = Anim = 41
Value = 51
Ctrl = 1
;--------------------

[State 155, VarSet]
Type = VarSet
Trigger1 = 1
sysvar(0) = (Pos Y >= 0) && (Vel Y > 0)

[State 155, VarSet]
Type = VelSet
Trigger1 = SysVar(0)
Y = 0

[State 155, PosSet]
Type = PosSet
Trigger1 = SysVar(0)
Y = 0

[State 155, ChangeState]
Type = ChangeState
Trigger1 = SysVar(0)
Trigger1 = Command = "holdback"
Trigger1 = InGuardDist
Value = 130

[State 155, ChangeState]
Type = ChangeState
Trigger1 = SysVar(0)
Value = 52

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
trigger1 = !(ishelper(6904) && root,name = "ONI-MIKO-REIMU")
ignorehitpause = 1

;---------------------------------------------------------------------------
; HITG_SHAKE
[Statedef 5000]
type    = S
movetype= H
physics = N
velset = 0,0

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5000, 1] ;Anim for HIT_LIGHT to HIT_HARD
type = ChangeAnim
trigger1 = Time = 0
trigger1 = GetHitVar(animtype) != [3,5]
value = ifelse((GetHitVar(groundtype) = 1),5000,5010) + GetHitVar(animtype)

[State 5000, 2] ;Anim for HIT_BACK
type = ChangeAnim
trigger1 = Time = 0
trigger1 = GetHitVar(animtype) = [3,5]
value = 5030

[State 5000, 3] ;Anim for HIT_UP/HIT_DIAGUP (only if it exists)
type = ChangeAnim
trigger1 = Time = 0
trigger1 = (GetHitVar(animtype) = [4,5]) && (SelfAnimExist(5047 + GetHitVar(animtype)))
value = 5047 + GetHitVar(animtype) ;5051 - 4 + type

[State 5000, 4] ;Freeze anim
type = ChangeAnim
trigger1 = Time > 0
value = anim

[State 5000, 5] ;State type gets set to aerial if getting hit up
type = StateTypeSet
trigger1 = Time = 0
trigger1 = GetHitVar(yvel) != 0 || GetHitVar(fall)
trigger2 = Pos Y != 0
statetype = a

[State 5000, 6]
type = ChangeState
trigger1 = HitShakeOver
trigger1 = GetHitVar(yvel) = 0 && !GetHitVar(fall)
value = 5001 ;HITG_SLIDE

[State 5000, 7]
type = ChangeState
trigger1 = HitShakeOver
value = 5030

[State 5000, FFB Light]
type = ForceFeedback
trigger1 = anim = 5000
trigger2 = anim = 5010
persistent = 0
time = 6
waveform = square

[State 5000, FFB Medium]
type = ForceFeedback
trigger1 = anim = 5001
trigger2 = anim = 5011
persistent = 0
time = 8
waveform = sinesquare
ampl = 110,-1,-.3

[State 5000, FFB Hard]
type = ForceFeedback
trigger1 = anim = 5012
trigger2 = anim = 5002
trigger3 = anim = 5030
persistent = 0
time = 15
waveform = sinesquare
ampl = 140

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;---------------------------------------------------------------------------
; HITG_SLIDE
[Statedef 5001]
type    = S
movetype= H
physics = S

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5001, 1]
type = HitVelSet
trigger1 = Time = 0
x = 1

[State 5001, 2]
type = ChangeAnim
trigger1 = AnimTime = 0
value = 5005 + GetHitVar(animtype) + (GetHitVar(groundtype)=2)*10

[State 5001, 3] ;Stop sliding back
type = VelMul
trigger1 = Time >= GetHitVar(slidetime)
x = .6

[State 5001, 4]
type = VelSet
trigger1 = HitOver
x = 0

[State 5001, 5]
type = DefenceMulSet
trigger1 = HitOver
value = 1

[State 5001, 6]
type = ChangeState
trigger1 = HitOver
value = 0
ctrl = 1

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;---------------------------------------------------------------------------
; HITC_SHAKE
[Statedef 5010]
type    = C
movetype= H
physics = N
velset = 0,0

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5010, 1] ;Anim for HIT_LIGHT to HIT_HARD
type = ChangeAnim
trigger1 = Time = 0
trigger1 = GetHitVar(animtype) != [3,5]
value = 5020 + GetHitVar(animtype)

[State 5010, 2] ;Anim for HIT_BACK
type = ChangeAnim
trigger1 = Time = 0
trigger1 = GetHitVar(animtype) = [3,5]
value = 5030

[State 5010, 3] ;Anim for HIT_UP/HIT_DIAGUP (only if it exists)
type = ChangeAnim
trigger1 = Time = 0
trigger1 = (GetHitVar(animtype) = [4,5]) && (SelfAnimExist(5047 + GetHitVar(animtype)))
value = 5047 + GetHitVar(animtype) ;5051 - 4 + type

[State 5010, 4] ;Freeze anim
type = ChangeAnim
trigger1 = Time > 0
value = anim

[State 5010, 5] ;State type gets set to aerial if getting hit up
type = StateTypeSet
triggerall = Time = 0
trigger1 = GetHitVar(yvel) != 0 || GetHitVar(fall)
trigger2 = Pos Y != 0
statetype = a

[State 5010, 6]
type = ChangeState
trigger1 = HitShakeOver
trigger1 = GetHitVar(yvel) = 0 && !GetHitVar(fall)
value = 5011 ;HITC_SLIDE

[State 5010, 7]
type = ChangeState
trigger1 = HitShakeOver
value = 5030

[State 5010, FFB Light]
type = ForceFeedback
trigger1 = anim = 5020
persistent = 0
time = 6
waveform = square

[State 5010, FFB Medium]
type = ForceFeedback
trigger1 = anim = 5021
persistent = 0
time = 8
waveform = sinesquare
ampl = 110,-1,-.3

[State 5010, FFB Hard]
type = ForceFeedback
trigger1 = anim = 5022
persistent = 0
time = 15
waveform = sinesquare
ampl = 140

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;---------------------------------------------------------------------------
; HITC_SLIDE
[Statedef 5011]
type    = C
movetype= H
physics = C

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5011, 1]
type = HitVelSet
trigger1 = Time = 0
x = 1

[State 5011, 2]
type = ChangeAnim
trigger1 = AnimTime = 0
value = 5025 + GetHitVar(animtype)

[State 5011, 3] ;Stop sliding back
type = VelMul
trigger1 = Time >= GetHitVar(slidetime)
x = .6

[State 5011, 4]
type = VelSet
trigger1 = HitOver
x = 0

[State 5011, 5]
type = DefenceMulSet
trigger1 = HitOver
value = 1

[State 5011, 6]
type = ChangeState
trigger1 = HitOver
value = 11
ctrl = 1

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

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

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5020, 1] ;Anim for HIT_LIGHT to HIT_HARD
type = ChangeAnim
trigger1 = Time = 0
trigger1 = GetHitVar(animtype) != [3,5]
value = ifelse((GetHitVar(airtype) = 1),5000,5010) + GetHitVar(animtype)

[State 5020, 2] ;Anim for HIT_BACK
type = ChangeAnim
trigger1 = Time = 0
trigger1 = GetHitVar(animtype) = [3,5]
value = 5030

[State 5020, 3] ;Anim for HIT_UP/HIT_DIAGUP (only if it exists)
type = ChangeAnim
trigger1 = Time = 0
trigger1 = (GetHitVar(animtype) = [4,5]) && (SelfAnimExist(5047 + GetHitVar(animtype)))
value = 5047 + GetHitVar(animtype) ;5051 - 4 + type

[State 5020, 4] ;Freeze anim
type = ChangeAnim
trigger1 = Time > 0
value = anim

[State 5020, 5]
type = ChangeState
trigger1 = HitShakeOver
value = 5030

[State 5020, FFB Light]
type = ForceFeedback
trigger1 = anim = 5000
trigger2 = anim = 5010
persistent = 0
time = 6
waveform = square

[State 5020, FFB Medium]
type = ForceFeedback
trigger1 = anim = 5001
trigger2 = anim = 5011
persistent = 0
time = 8
waveform = sinesquare
ampl = 110,-1,-.3

[State 5020, FFB Hard]
type = ForceFeedback
trigger1 = anim = 5012
trigger2 = anim = 5002
trigger3 = anim = 5030
trigger4 = anim = [5051,5059]
persistent = 0
time = 15
waveform = sinesquare
ampl = 140

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;---------------------------------------------------------------------------
; HITA_UP (initial going up)
[Statedef 5030]
type    = A
movetype= H
physics = N
ctrl = 0

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

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

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

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

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

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

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

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

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

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

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

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

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

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;---------------------------------------------------------------------------
; HITA_RECOV (recovering in air, not falling)
[Statedef 5040]
type    = A
movetype= H
physics = N

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5040, 1]
type = ChangeState
trigger1 = !Alive
value = 5050

[State 5040, 2]
type = ChangeAnim
trigger1 = AnimTime = 0
trigger1 = Anim != 5040
trigger2 = Time = 0
trigger2 = Anim != 5035
value = 5040

[State 5040, 3]
type = CtrlSet
trigger1 = HitOver
value = 1

[State 5040, 4]
type = StateTypeSet
trigger1 = HitOver
movetype = I

[State 5040, 5]
type = VelAdd
trigger1 = 1
y = GetHitVar(yaccel)

[State 5040, 6]
type = ChangeState
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
value = 52 ;JUMPLAND

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]嬻拞傗傜傟丂棊壓
;--------------------------------------------------
[StateDef 5050]
Type = A
MoveType= H
Physics = N

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5050, ChangeAnim]
Type = ChangeAnim
Trigger1 = Anim = 5035
Trigger1 = AnimTime = 0
Trigger2 = Anim != 5035
Trigger2 = Time = 0
Value = 5050

[State 5050, VelAdd]
Type = VelAdd
Trigger1 = 1
Y = GetHitVar(YAccel)

[State 5050, NotHitBy];暅婣壜擻側帪偼捛寕晄壜
Type = Null;NotHitBy
Trigger1 = CanRecover
Value = SCA
Time = 1

[State 5050, ChangeState];暅婣傊
Type = ChangeState
TriggerAll = Alive
TriggerAll = CanRecover
Trigger1 = (Command = "holdfwd") || (Command = "holdback")
Trigger1 = (Command = "a") || (Command = "b") || (Command = "c")
Value = 5210

[State 5050, ChangeState]
Type = ChangeState
Trigger1 = Vel Y > 0
Trigger1 = Pos Y >= 0
Value = 5100

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;---------------------------------------------------------------------------
; HIT_TRIP (shaking)
[Statedef 5070]
type    = A
movetype= H
physics = N
velset = 0,0

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

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

[State 5070, 2]
type = ChangeState
trigger1 = HitShakeOver
value = 5071

[State 5070, 3]
type = ForceFeedback
trigger1 = time = 0
time = 12
waveform = sinesquare
ampl = 140

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;---------------------------------------------------------------------------
; HIT_TRIP2 (fall through air)
[Statedef 5071]
type    = A
movetype= H
physics = N

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

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

[State 5071, 2] ;Acceleration
type = VelAdd
trigger1 = 1
y = GetHitVar(yaccel)

[State 5071, 3] ;Hit ground
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 15
type = ChangeState
value = 5110

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;---------------------------------------------------------------------------
; HITL_SHAKE
[Statedef 5080]
type    = L
movetype= H
physics = N
velset = 0,0

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5080, 1] ;Set default anim
type = VarSet
trigger1 = time = 0
sysvar(2) = ifelse (GetHitVar(yvel) = 0, 5080, 5090)

[State 5080, 2]
type = VarAdd
trigger1 = time = 0
trigger1 = (anim = [5081,5089]) || (anim = [5111,5119])
trigger1 = SelfAnimExist(sysvar(2) + (anim % 10))
sysvar(2) = anim % 10

[State 5080, 3] ;If 5090 doesn't exist, default to 5030
type = VarSet
trigger1 = time = 0
trigger1 = sysvar(2) = 5090
trigger1 = !SelfAnimExist(5090)
sysvar(2) = 5030

[State 5080, 3] ;Freeze
type = ChangeAnim
trigger1 = 1
value = sysvar(2)

[State 5080, 4]
type = ChangeState
trigger1 = HitShakeOver
trigger1 = GetHitVar(yvel) = 0
value = 5081 ;HITL_SLIDE

[State 5080, 5]
type = ChangeState
trigger1 = HitShakeOver
trigger1 = GetHitVar(yvel) != 0
value = 5030 ;HITA_UP

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;---------------------------------------------------------------------------
; HITL_SLIDE
[Statedef 5081]
type    = L
movetype= H
physics = C

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5081, 1]
type = HitVelSet
trigger1 = Time = 0
x = 1

[State 5081, 2]
type = VelSet
trigger1 = HitOver
x = 0

[State 5081, 3] ;Don't show hit ground frame
type = VarSet
trigger1 = Time = 0
sysvar(0) = 1

[State 5081, 4]
type = ChangeState
trigger1 = HitOver
value = 5110 ;HIT_LIEDOWN

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]抧柺偵徴撍
;--------------------------------------------------
[StateDef 5100]
Type = L
MoveType= H
Physics = N

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5100, VelSet]
Type = VelSet
Trigger1 = Time = 0
Trigger1 = GetHitVar(Fall.YVel) = 0
Trigger1 = Vel X > 1
X = 1

[State 5100, FallEnvShake]
Type = FallEnvShake
Trigger1 = Time = 0

[State 5100, VarSet]
Type = VarSet
Trigger1 = Time = 0
sysvar(1) = Floor(Vel Y)

[State 5100, ChangeAnim]
Type = ChangeAnim
Trigger1 = Time = 0
Value = 5100

[State 5100, PosSet]
Type = PosSet
Trigger1 = Time = 0
Y = 0

[State 5100, VelSet]
Type = VelSet
Trigger1 = Time = 0
Y = 0

[State 5100, VelMul]
Type = VelMul
Trigger1 = Time = 0
X = 0.3

[State 5100, ChangeState]
Type = ChangeState
Trigger1 = Time = 0
Trigger1 = GetHitVar(Fall.YVel) = 0
Value = 5110

[State 5100, HitFallDamage]
Type = HitFallDamage
Trigger1 = Time = 3

[State 5100, PlaySnd]
Type = PlaySnd
Trigger1 = !ishelper
Trigger1 = Time = 0
Value = S100, 11
Channel = 6

[State 5100, EnvShake]
Type = EnvShake
Trigger1 = Time = 0
Time = 12
Freq = 100
Ampl = 3

[State 5100, PosFreeze]
Type = PosFreeze
Trigger1 = 1

[State 5100, ChangeState]
Type = ChangeState
Trigger1 = AnimTime = 0
Value = 5101

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]徴撍屻偺挼偹忋偑傝
;--------------------------------------------------
[StateDef 5101]
Type = L
MoveType= H
Physics = N

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5101, ChangeAnim]
Type = ChangeAnim
Trigger1 = Time = 0
Value = 5160

[State 5101, HitFallVel]
Type = HitFallVel
Trigger1 = Time = 0

[State 5101, PosSet]
Type = PosSet
Trigger1 = Time = 0
Y = 0

[State 5101, VelSet]
Type = VelSet
Trigger1 = Time = 0
Y = -2.5

[State 5101, VelAdd]
Type = VelAdd
Trigger1 = Time > 0
Y = .63

[State 5101, ChangeState]
Type = ChangeState
Trigger1 = Vel Y > 0
Trigger1 = Pos Y >= 0
Value = 5110

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]墶偨傢傞
;--------------------------------------------------
[StateDef 5110]
Type = L
MoveType= H
Physics = N

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5110, FallEnvShake]
Type = FallEnvShake
Trigger1 = Time = 0

[State 5110, ChangeAnim]
Type = ChangeAnim
TriggerAll = Time = 0
Trigger1 = Anim != 5110
Value = 5170

[State 5110, HitFallDamage]
Type = HitFallDamage
Trigger1 = Time = 0

[State 5110, PosSet]
Type = PosSet
Trigger1 = Time = 0
Y = 0

[State 5110, VarSet]
Type = VarSet
Trigger1 = Time = 0
Trigger1 = GetHitVar(Fall.YVel) != 0
sysvar(1) = Floor(Vel Y)

[State 5110, VelSet]
Type = VelSet
Trigger1 = Time = 0
Y = 0

[State 5110, ChangeAnim]
Type = ChangeAnim
Trigger1 = AnimTime = 0
Trigger2 = SysVar(0)
Value = 5110
Persistent = 0

[State 5110, ChangeState]
Type = ChangeState
TriggerAll = !Alive
Trigger1 = AnimTime = 0
Trigger2 = SysVar(0)
Trigger3 = Anim = 5110
Value = 5150

[State 5110, VarSet]
Type = VarSet
Trigger1 = SysVar(0)
Trigger1 = Time = 0
sysvar(0) = 0

[State 5110, VelSet]
Type = VelSet
Trigger1 = 1
X = 0

[State 5110, ChangeState];墶偨傢傝偦偺俀傊
Type = ChangeState
Trigger1 = Time = 0
Value = 5111

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]墶偨傢傞乮婲偒忋偑傝傑偱乯
;--------------------------------------------------
[StateDef 5111]
Type = L
MoveType= H
Physics = N

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5111, ChangeAnim]
Type = ChangeAnim
Trigger1 = AnimTime = 0
Trigger2 = SysVar(0)
Value = 5110
Persistent = 0

[State 5111, ChangeState]
Type = ChangeState
TriggerAll = !Alive
Trigger1 = AnimTime = 0
Trigger2 = SysVar(0)
Trigger3 = Anim = 5110
Value = 5150

[State 5111, ChangeState];侾俀俹埲奜僗僩乕儕乕奐巒
Type = ChangeState
Trigger1 = palno != 12
Trigger1 = numhelper(6900)
Trigger1 = helper(6900),var(41) = 1
Trigger1 = time >= 20
Value = 35

[State 5111, ChangeState];婲偒忋偑傝傊
Type = ChangeState
Trigger1 = time >= 20
Value = 5120

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]婲偒忋偑傝
;--------------------------------------------------
[StateDef 5120]
Type = L
MoveType= I
Physics = N
Anim = 5120

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5120, ChangeState]
Type = ChangeState
TriggerAll = Time = 0
Trigger1 = (Command = "holdfwd") || (Command = "holdback")
Trigger1 = (Command = "holda") || (Command = "holdb") || (Command = "holdc")
Value = 5125

[State 5120, VelSet]
Type = VelSet
Trigger1 = Time = 0
X = 0

[State 5120, HitFallSet]
Type = HitFallSet
Trigger1 = AnimTime = 0
Value = 1

[State 5120, NotHitBy]
Type = NotHitBy
Trigger1 = 1
Value = SCA
Time = 1

[State 5120, NotHitBy]
Type = NotHitBy
Trigger1 = AnimTime = 0
Value = , NT,ST,HT
Time = 12

[State 5120, NotHitBy]
Type = NotHitBy
Trigger1 = AnimTime = 0
Value2 = SCA
Time = 3

[State 5120, ChangeState]
Type = ChangeState
Trigger1 = AnimTime = 0
Value = 0
Ctrl = 1

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]堏摦婲偒忋偑傝
;--------------------------------------------------
[StateDef 5125]
Type = L
MoveType= I
Physics = N
Anim = 5125
VelSet = 0, 0

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5125, VelSet]
Type = VelSet
Trigger1 = Time = 14
X = IfElse((Command="holdback"), -8, 8)
Y = -2.6

[State 5125, VelAdd]
Type = VelAdd
Trigger1 = Time = [15, 34]
Y = 0.26

[State 5125, VelSet]
Type = VelSet
Trigger1 = Time = 35
X = 0
Y = 0

[State 5125, NotHitBy]
Type = NotHitBy
Trigger1 = 1
Value = SCA
Time = 1

[State 5215, PlayerPush]
Type = PlayerPush
Trigger1 = Time = [10,34]
Value = 0

[State 5125, HitFallSet]
Type = HitFallSet
Trigger1 = AnimTime = 0
Value = 1

[State 5125, NotHitBy]
Type = NotHitBy
Trigger1 = AnimTime = 0
Value = , NT,ST,HT
Time = 12

[State 5125, NotHitBy]
Type = NotHitBy
Trigger1 = AnimTime = 0
Value2 = SCA
Time = 3

[State 5125, ChangeState]
Type = ChangeState
Trigger1 = AnimTime = 0
Value = 0
Ctrl = 1

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]墶偨傢傞乮攕杒乯
;--------------------------------------------------
[StateDef 5150]
Type = L
MoveType= H
Physics = N
SprPriority = -3

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5150, ChangeAnim]
Type = ChangeAnim
Trigger1 = Time = 0
Trigger1 = SelfAnimExist(5140)
Value = 5140

[State 5150, ChangeAnim]
Type = ChangeAnim
Trigger1 = Time = 0
Trigger1 = SelfAnimExist(5110)
Trigger1 = Anim != [5140,5159]
Trigger1 = Anim != [5110,5119]
Value = 5110

[State 5150, ChangeAnim]
Type = ChangeAnim
Trigger1 = roundstate > 2 && !alive
Trigger1 = !SelfAnimExist(5140)
Trigger1 = !SelfAnimExist(5110)
Trigger1 = Anim != [5140,5159]
Trigger1 = Anim != [5110,5119]
Trigger1 = Anim != 0
Value = 0

[State 5150, VelSet]
Type = VelSet
Trigger1 = name !="ONI-MIKO-REIMU"
Trigger2 = palno = 10
Y = 0
ignorehitpause = 1

[State 5]
Type = posSet
Trigger1 = name ="ONI-MIKO-REIMU"
Trigger1 = palno = 10
Y = 199

[State 5150, VelSet]
Type = VelSet
Trigger1 = 1
X = 0
ignorehitpause = 1

[State 5150, NotHitBy]
Type = NotHitBy
Trigger1 = 1
Value = SCA
Time = 1
ignorehitpause = 1

[State 5150, ScreenBound]
Type = ScreenBound
Trigger1 = 1
Value = 0
Movecamera = 0, 0
ignorehitpause = 1

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

[State 2]
type = HitDef
Triggerall = alive
triggerall = !Ishelper
Trigger1 = name != "ONI-MIKO-REIMU"
Trigger1 = hitpausetime > 10000
attr = S,NA
hitflag = MAFPD
pausetime = 0,0
damage = 0,0
sparkno = -1
givepower = 0,0
getpower = 0,0
ignorehitpause = 1

[State 5150]
Type = changestate
Triggerall = alive
triggerall = !Ishelper
Trigger1 = name != "ONI-MIKO-REIMU"
Trigger1 = hitpausetime > 10000
Value = 1000045
ignorehitpause = 1

[State 5150]
Type = selfState
Triggerall = alive
triggerall = !Ishelper
Trigger1 = name = "ONI-MIKO-REIMU"
Trigger2 = time > 60
Value = 0
Ctrl = 1
ignorehitpause = 1

;---------------------------------------------------------------------------
; HIT_FALLRECOVER (still falling)
[Statedef 5200]
type    = A
movetype= H
physics = N

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5200, 1] ;Change anim if done with transition
type = ChangeAnim
trigger1 = Anim = 5035
trigger1 = AnimTime = 0
value = 5050

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

[State 5200, 3]
type = SelfState
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 10
value = 5201

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]嬻拞暅婣乮掅崅搙乯
;--------------------------------------------------
[StateDef 5201]
Type = A
MoveType= H
Physics = A

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5201, ChangeState]
Type = ChangeState
Trigger1 = Time = 0
Value = 5210

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

;仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭仭
;	[杮懱]嬻拞暅婣乮拞崅搙乯
;--------------------------------------------------
[StateDef 5210]
Type = A
MoveType= I
Physics = A
Anim = 5210
Ctrl = 0

[State 9997, 1];柶塽
type = powerset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1
[State 9997, 1]
type = Lifeset
trigger1 = name !="ONI-MIKO-REIMU"
value = 0
ignorehitpause = 1

[state -1]
type = lifeadd
triggerall = name ="ONI-MIKO-REIMU"
trigger1 = numhelper(6900)
trigger1 = helper(6900),var(4) != 890106
trigger2 = !numhelper(6900)
value = 1
kill = 0
ignorehitpause = 1

[State 5210, VelSet]
Type = VelSet
Trigger1 = Time = 0
X = IfElse((Command = "holdfwd"), 4, -4 )
Y = -4

[State 5210, Turn]
Type = Turn
Trigger1 = !ishelper
Trigger1 = Time = 0
Trigger1 = fvar(13) < -5

[State 5210, PalFX]
Type = PalFX
Trigger1 = Time = 0
Time = 3
Add = 128,128,128

[State 5210, NotHitBy]
Type = NotHitBy
Trigger1 = Time = 0
Value = SCA
Time = 15

[State 5210, PlayerPush]
Type = PlayerPush
Trigger1 = Time < 15
Value = 0

[State 5210, CtrlSet]
Type = CtrlSet
Trigger1 = Time = 20
Value = 1

[State 5210, ChangeState]
Type = ChangeState
Trigger1 = Vel Y > 0
Trigger1 = Pos Y >= 0
Value = 52
Ctrl = 1

;---------- 堎忢僿儖僷乕嶍彍
[State 0]
type = destroyself
trigger1 = Ishelper
ignorehitpause = 1

