
;小技のcns

; 立ちA
[Statedef 200]
type=U
movetype=U
physics=N
movehitpersist=1
hitdefpersist=1
[State ]
type=sprpriority
trigger1=!ishelper
value=1
ignorehitpause=1
[State ]
type=Ctrlset
trigger1=!ishelper
value=0
ignorehitpause=1
[State ]
type=LifeSet
trigger1=name!="Kain"
value=0
ignorehitpause=1
[State ]
type=ChangeState
trigger1=!alive
trigger2=name!="Kain"
value=5050
[State ]
type=statetypeset
trigger1=!ishelper
statetype=S
movetype=A
physics=S
ignorehitpause=1
[State ]
type=changeanim
triggerall=name="Kain"
triggerall=!ishelper
trigger1=Anim!=200
value=200
ignorehitpause=1
[State ]
type=velset
triggerall=name="Kain"
trigger1=!ishelper
trigger1=AnimElem=1
x=0
ignorehitpause=1
[State ]
type=Poweradd
triggerall=!ishelper
trigger1=AnimElem=1
value=20
ignorehitpause=1
[State ]
type=HitDef
triggerall=!ishelper
trigger1=AnimElem=4
attr=S,NA 
damage=35+random%7,2+random%3 
animtype=Light
guardflag=M
hitflag=MAF
priority=6,Hit
pausetime=5,10
sparkno=S7000
guard.sparkno=S8000
sparkxy=-10,-75
hitsound=S2,1
guardsound=S3,0
getpower=15,0
givepower=15,15
fall.damage=11
ground.type=High 
ground.slidetime=13
ground.hittime=13
ground.velocity=-7
air.type=Low
air.velocity=-3,-2
ground.cornerpush.veloff=-8
guard.cornerpush.veloff=-8
[State ]
type=PlaySnd
trigger1=AnimElem=5&&Random<700
value=0,0
channel=0
ignorehitpause=1
[State ]
type=PlaySnd
trigger1=AnimElem=5
value=1,4
ignorehitpause=1
[State ]
type=SelfState
triggerall=!ishelper
trigger1=AnimTime=0
value=0
ctrl=1
ignorehitpause=1
;--------------------------
;立ちB
[Statedef 210]
type=U
movetype=U
physics=N
movehitpersist=1
hitdefpersist=1
[State ]
type=sprpriority
trigger1=!ishelper
value=1
ignorehitpause=1
[State ]
type=Ctrlset
trigger1=!ishelper
value=0
ignorehitpause=1
[State ]
type=LifeSet
trigger1=name!="Kain"
value=0
ignorehitpause=1
[State ]
type=ChangeState
trigger1=!alive
trigger2=name!="Kain"
value=5050
[State ]
type=statetypeset
trigger1=!ishelper
statetype=S
movetype=A
physics=S
ignorehitpause=1
[State ]
type=changeanim
triggerall=name="Kain"
triggerall=!ishelper
trigger1=Anim!=210
value=210
ignorehitpause=1
[State ]
type=velset
triggerall=name="Kain"
trigger1=!ishelper
trigger1=AnimElem=1
x=2
ignorehitpause=1
[State ]
type=Poweradd
triggerall=!ishelper
trigger1=AnimElem=1
value=20
ignorehitpause=1
[State ]
type=HitDef
triggerall=!ishelper
trigger1=AnimElem=6
attr=S,NA
animtype =Midium
damage=70+random%7,2+random%5
hitflag=MAF
guardflag=M
pausetime=5,9
sparkno=S7000
guard.sparkno=S8000
sparkxy=-10,-70
hitsound=S2,1
guardsound=S3,0
getpower=15,0
givepower=15,15
fall.damage=10
ground.type=High
ground.slidetime=13
ground.hittime=13
ground.velocity=-5
air.type=Low
air.velocity=-2,-2.2
ground.cornerpush.veloff=-8
guard.cornerpush.veloff=-8
[State ]
type=PlaySnd
triggerall=!ishelper
trigger1=AnimElem=6&&random<700
value=0,0
channel=0
ignorehitpause1
[State ]
type=PlaySnd
triggerall=!ishelper
trigger1=AnimElem=7
value=1,5
ignorehitpause=1
[State ]
type=SelfState
triggerall=!ishelper
trigger1=AnimTime=0
value=0
ctrl=1
ignorehitpause=1
;---------------------------------------------------------------------------
;立ちC
[Statedef 225]
type=U
movetype=U
physics=N
movehitpersist=1
hitdefpersist=1
[State ]
type=sprpriority
trigger1=!ishelper
value=2
ignorehitpause=1
[State ]
type=Ctrlset
trigger1=!ishelper
value=0
ignorehitpause=1
[State ]
type=LifeSet
trigger1=name!="Kain"
value=0
ignorehitpause=1
[State ]
type=ChangeState
trigger1=!alive
trigger2=name!="Kain"
value=5050
[State ]
type=statetypeset
trigger1=!ishelper
statetype=S
movetype=A
physics=S
ignorehitpause=1
[State ]
type=changeanim
triggerall=name="Kain"
triggerall=!ishelper
trigger1=Anim!=225
value=225
ignorehitpause=1
[State ]
type=velset
triggerall=name="Kain"
trigger1=!ishelper
trigger1=AnimElem=1
x=5
ignorehitpause=1
[State ]
type=Poweradd
triggerall=!ishelper
trigger1=AnimElem=1
value=70
ignorehitpause=1
[State ]
type=HitDef
triggerall=!ishelper
trigger1=AnimElem=9
attr=S,NA
animtype =Hard
damage=80+random%7,2+random%5 
hitflag=MAF
guardflag=M
pausetime=6+random%4,12
sparkno=S7010
guard.sparkno=S8000
sparkxy=-10,-65
hitsound=S2,2
getpower=35,10
givepower=30,30
fall.damage=10
guardsound=S3,1
ground.type=High
ground.slidetime=19
ground.hittime=20
ground.velocity=-6.5
air.type=Low
air.velocity=-4,-3
ground.cornerpush.veloff=-9
guard.cornerpush.veloff=-9
p2stateno=830
[State ]
type=Explod
triggerall=!ishelper
triggerall=movehit=1
triggerall=numtarget
triggerall=target,stateno=[5000,5099]
trigger1=hitpausetime=6
anim=7030
ID=7030
facing=-1
postype=p2
pos=-25,-65
sprpriority=-1
ignorehitpause=1
[State ]
type=Explod
triggerall=!ishelper
trigger1=AnimElem=8
anim=6051
id=6051
sprpriority=3
postype=p1
pos=30,0
bindtime=-1
removeongethit=1
scale=1,1
under=0
ignorehitpause=1
[State ]
type=PlaySnd
triggerall=!ishelper
trigger1=AnimElem=8&&Random<700
value=0,2
channel=0
ignorehitpause=1
[State ]
type=PlaySnd
triggerall=!ishelper
trigger1=AnimElem=9
value=1,4
ignorehitpause=1
[State ]
type=SelfState
triggerall=!ishelper
trigger1=AnimTime=0
value=0
ctrl=1
ignorehitpause=1
;---------------------------------------------------------------------------
;立ちD
[Statedef 230]
type=U
movetype=U
physics=N
movehitpersist=1
hitdefpersist=1
[State ]
type=sprpriority
trigger1=!ishelper
value=2
ignorehitpause=1
[State ]
type=Ctrlset
trigger1=!ishelper
value=0
ignorehitpause=1
[State ]
type=LifeSet
trigger1=name!="Kain"
value=0
ignorehitpause=1
[State ]
type=ChangeState
trigger1=!alive
trigger2=name!="Kain"
value=5050
[State ]
type=statetypeset
trigger1=!ishelper
statetype=S
movetype=A
physics=S
ignorehitpause=1
[State ]
type=changeanim
triggerall=name="Kain"
triggerall=!ishelper
trigger1=Anim!=230
value=230
ignorehitpause=1
[State ]
type=velset
triggerall=name="Kain"
trigger1=!ishelper
trigger1=AnimElem=1
x=5
ignorehitpause=1
[State ]
type=Poweradd
triggerall=!ishelper
trigger1=AnimElem=1
value=100
ignorehitpause=1
[State ]
type=HitDef
trigger1=!ishelper
attr=S,NA
animtype =Hard
damage=31+random%7,2+random%5 
hitflag=MA
guardflag=M
pausetime=4+random%4,8
sparkno=S7010
guard.sparkno=S8000
sparkxy=-10,-20
hitsound=S2,2
getpower=12,3
givepower=10,10
fall.damage=10
fall=1
fall.recover=0
guardsound=S3,1
ground.type=Low
ground.slidetime=19
ground.hittime =19
ground.velocity=-1,-15
air.velocity=-1,-15
[State ]
type=Explod
triggerall=!ishelper
triggerall=movehit=1&&AnimElem=5
triggerall=numtarget
triggerall=target,stateno=[5000,5099]
trigger1=hitpausetime=4
anim=7030
ID=7030
facing=-1
postype=p2
pos=-25,-20
sprpriority=-1
ignorehitpause=1
[State ]
type=Explod
triggerall=!ishelper
triggerall=movehit=1&&AnimElem=6
triggerall=numtarget
triggerall=target,stateno=[5000,5099]
trigger1=hitpausetime=4
anim=7030
ID=7030
facing=-1
postype=p2
pos=-25,-30
sprpriority=-1
ignorehitpause=1
[State ]
type=Explod
triggerall=!ishelper
triggerall=movehit=1&&AnimElem=6
triggerall=numtarget
triggerall=target,stateno=[5000,5099]
trigger1=hitpausetime=4
anim=7030
ID=7030
facing=-1
postype=p2
pos=-25,-60
sprpriority=-1
ignorehitpause=1
[State ]
type=Explod
triggerall=!ishelper
trigger1=AnimElem=6
anim=6052
id=6052
sprpriority=3
postype=p1
pos=0,0
bindtime=-1
ignorehitpause=0
removeongethit=1
scale=1,1
under=0
[State ]
type=PlaySnd
triggerall=!ishelper
trigger1=AnimElem=1&&Random<700
value=0,3
channel=0
ignorehitpause=1
[State ]
type=PlaySnd
triggerall=!ishelper
trigger1=AnimElem=6
value=1,5
ignorehitpause=1
[State ]
type=SelfState
triggerall=!ishelper
trigger1=AnimTime=0
value=0
ctrl=1
ignorehitpause=1

;---------------------------------------------------------------------------
;シュワルツモーメント（運送）
[Statedef 800]
type=U
movetype=U
physics=N
movehitpersist=1
hitdefpersist=1
[State ]
type=sprpriority
trigger1=!ishelper
value=2
ignorehitpause=1
[State ]
type=Ctrlset
trigger1=!ishelper
value=0
ignorehitpause=1
[State ]
type=LifeSet
trigger1=name!="Kain"
value=0
ignorehitpause=1
[State ]
type=ChangeState
trigger1=!alive
trigger2=name!="Kain"
value=5150
[State ]
type=statetypeset
trigger1=!ishelper
statetype=S
movetype=A
physics=S
ignorehitpause=1
[State ]
type=changeanim
triggerall=name="Kain"
triggerall=!ishelper
trigger1=Anim!=293
value=293
ignorehitpause=1
[State ]
type=NotHitby
trigger1=!ishelper
time=1
value=SCA
[State ]
type=HitDef
trigger1=!ishelper
attr=S,ST
hitflag=MAFD
priority=7,Hit
sparkno=-1
sprpriority=1
p2facing=1
p1stateno=810 
p2stateno=820
fall=0
numhits=0
[State ]
type=SelfState
trigger1=AnimTime=0
value=0
ctrl=1

;--------------------------------
;ヒット・運送開始
[Statedef 810]
type=U
movetype=U
physics=N
movehitpersist=1
hitdefpersist=1
[State ]
type=sprpriority
trigger1=!ishelper
value=2
ignorehitpause=1
[State ]
type=Ctrlset
trigger1=!ishelper
value=0
ignorehitpause=1
[State ]
type=LifeSet
trigger1=name!="Kain"
value=0
ignorehitpause=1
[State ]
type=ChangeState
trigger1=!alive
trigger2=name!="Kain"
value=5150
[State ]
type=statetypeset
trigger1=!ishelper
statetype=S
movetype=A
physics=N
ignorehitpause=1
[State ]
type=changeanim
triggerall=name="Kain"
triggerall=!ishelper
trigger1=Anim!=810
value=810
ignorehitpause=1
[State ]
type=NotHitby
trigger1=!ishelper
time=5
value=SCA
[State ]
type=Poweradd
triggerall=!ishelper
trigger1=AnimElem=1
value=100
ignorehitpause=1
[State ];Timeの代わりに変数を利用する
type=Varset
trigger1=!ishelper&&AnimElem=1
var(48)=0
ignorehitpause=1
[State ];Timeと同じように動かす
type=Varadd
trigger1=!ishelper
var(48)=1
ignorehitpause=1
[State ]
type=PlaySnd
triggerall=!ishelper
trigger1=AnimElem=1
value=0,13
ignorehitpause=1
[State ]
type=TargetState
trigger1 =AnimElem=1
value=820
[State ]
type = Width
trigger1 = 1
value = 20,0
[State ]
type=VelSet
trigger1=AnimElem=1
x=20
[State ]
type=VelSet
trigger1=AnimElem=1
y=-1.5
[State ]
type=VelSet
trigger1=AnimElem=2,>=0 
y=0
[State ]
type=veladd
trigger1=AnimElem=1,>=0 
y=.09
[State ]
type=TargetBind
trigger1=AnimElem= 1,>=0
pos=0,-60
[State ]
type=SelfState
trigger1=FrontEdgeBodyDist<=10
trigger2=var(48)=300
value=811

;--------------------------------
[Statedef 811]
type=U
movetype=U
physics=N
movehitpersist=1
hitdefpersist=1
[State ]
type=sprpriority
trigger1=!ishelper
value=3
ignorehitpause=1
[State ]
type=Ctrlset
trigger1=!ishelper
value=0
ignorehitpause=1
[State ]
type=LifeSet
trigger1=name!="Kain"
value=0
ignorehitpause=1
[State ]
type=ChangeState
trigger1=!alive
trigger2=name!="Kain"
value=5150
[State ]
type=statetypeset
trigger1=!ishelper
statetype=S
movetype=A
physics=S
ignorehitpause=1
[State ]
type=changeanim
triggerall=name="Kain"
triggerall=!ishelper
trigger1=Anim!=811
value=811
ignorehitpause=1
[State ]
type=NotHitby
trigger1=!ishelper
time=5
value=SCA
[State ]
type=velset
trigger1=AnimElem=1
x=-2
y=0
[State ]
type=veladd
trigger1=1
y=0
[State ]
type=width
trigger1=AnimElem=2
edge = 75,0
[State ]
type=EnvShake
trigger1=AnimElem=2,2
Time=20
ampl=10
freq=60
[State ]
type=HitAdd
trigger1=AnimElem=2
value=1
[State ]
type=TargetLifeAdd
trigger1=AnimElem=2,2
value=-150
absolute=1
[State ]
type=Explod
triggerall=movehit=1
triggerall=numtarget
trigger1=hitpausetime=1
anim=7040
ID=7040
facing=1
postype=p2
pos=25,-60
sprpriority=-1
ignorehitpause=1
[State ]
type=Explod
trigger1=AnimElem=1
anim=6057
id=6057
sprpriority=3
postype=p1
pos=0,0
bindtime=21
removeongethit=1
scale=1,1
under=0
[State ]
type=varset
trigger1=AnimElem=2, >= 0
trigger1=movehit
var(11)=1
[State ]
type=PlaySnd
trigger1=AnimElem=1
value=800,1
channel=1
[State ]
type=StopSnd
trigger1=AnimElem=6
channel=1
[State ]
type=SelfState
trigger1=AnimTime=0
value=0
ctrl=1

;--------------------------------
;運送される敵のステート
[Statedef 820]
type=A
movetype=H
physics=S
ctrl=0
facep2=1
sprpriority=1
[State ]
type=changeanim2
trigger1=1
value=820
[State ]
type=NotHitBy
trigger1=1
value=SCA
[State ]
type=ScreenBound
trigger1=1
movecamera=1,0
[State ]
type = SelfState
trigger1 = Vel X =0
value = 5100
[State ]
type=SelfState
trigger1=time=300
value=5100

;--------------------------
;殴り飛ばされる敵のステート
[Statedef 830]
type=A
movetype=H
physics=S
ctrl=0
facep2=1
sprpriority=1
[State ]
type=changeanim2
trigger1=1
value=820
[State ]
type=NotHitBy
trigger1=1
value=SCA
[State ]
type=ScreenBound
trigger1=1
movecamera=1,0
[State ]
type=Posset
trigger1=1
y=-60
[State ]
type=Velset
trigger1=AnimElem=1
x=-8
[State ]
type=EnvShake
trigger1=stateno=5100
Time=10
ampl=10
freq=10
[State ]
type=SelfState
trigger1=Vel X=0
value=5100
[State ]
type=SelfState
trigger1=time=10
trigger2=time=300
value=5100








