;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;			婎杮僨乕僞
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Data]
life		= 1000		;儔僀僼乮懱椡僎乕僕乯嵟戝抣
power		= 3000		;僷儚乕僎乕僕嵟戝抣乮僆僾僔儑儞丒僨僼僅儖僩偼3000=Lv.3乯
attack		= 100		;峌寕椡乮僨僼僅儖僩偼侾侽侽亾乯
defence		= 100		;杊屼椡乮僨僼僅儖僩偼侾侽侽亾乯
fall.defence_up	= 50		;墶偵搢傟偰偄傞帪偵堦帪揑偵壛偊傞杊屼椡乮亾乯
liedown.time	= 60		;墶偵搢傟偰偄傞帪娫乮僼儗乕儉乯
airjuggle	= 15		;僕儍僌儖億僀儞僩尷奅抣乮乽彫僱僞.txt乿嶲徠乯
sparkno		= 2		;僨僼僅儖僩偺僸僢僩僗僷乕僋乮fightfx偐傜乯
guard.sparkno	= 40		;僨僼僅儖僩偺僈乕僪僗僷乕僋乮fightfx偐傜乯
KO.echo		= 0		;俲俷帪偺壒惡乮11,0乯偵僄僐乕傪妡偗傞偐斲偐乮0=妡偗側偄,1=妡偗傞乯
volume		= 0		;僉儍儔偺昗弨偺壒検乮嵟彫-255丒嵟戝255乯
IntPersistIndex		= 30	;師偺儔僂儞僪傊帩偪墇偣傞乽Var乿偺傾僪儗僗偺斖埻
FloatPersistIndex	= 40	;師偺儔僂儞僪傊帩偪墇偣傞乽FVar乿偺傾僪儗僗偺斖埻


;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;			丂僒僀僘
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Size]
xscale		= 1		;悈暯曽岦偺弅広乮捠忢侾乯
yscale		= 1		;悅捈曽岦偺弅広乮捠忢侾乯
ground.back	= 25		;僉儍儔偺暆(屻曽,抧忋)
ground.front	= 25		;僉儍儔偺暆(慜曽,抧忋)
air.back	= 12		;僉儍儔偺暆(屻曽,嬻拞)
air.front	= 12		;僉儍儔偺暆(慜曽,嬻拞)
height		= 60		;僉儍儔偺崅偝
attack.dist	= 160		;峌寕傪偟偨帪憡庤偑僈乕僪懱惂偵擖傞嵟掅嫍棧
proj.attack.dist= 90		;峌寕傪偟偨帪憡庤偑僈乕僪懱惂偵擖傞嵟掅嫍棧乮旘傃摴嬶乯
proj.doscale	= 0		;忋偱愝掕偟偨弅広傪旘傃摴嬶偵傕揔梡偡傞偐乮侾偱俷俶乯   
head.pos	= -5, -90	;摢偺戝懱偺嵗昗
mid.pos		= -5, -60	;懱偺拞怱偺戝懱偺嵗昗
shadowoffset	= 0		;塭偺悅捈曽岦偺僆僼僙僢僩
draw.offset	= 0,4		;巊梡偟側偄

[Velocity]
walk.fwd	= 2.4		;慜恑偺懍搙
walk.back	= -2.2		;屻戅偺懍搙
run.fwd		= 6.6, 0	;慜僟僢僔儏偺懍搙乮儂僢僾偡傞帪偼y傪-偵偡傞乯
run.back	= -4.5,-3.8	;屻僟僢僔儏偺懍搙乮儂僢僾偡傞帪偼y傪-偵偡傞乯
jump.neu	= 0,-9	;悅捈僕儍儞僾偺懍搙
jump.back	= -2.55		;屻僕儍儞僾偺懍搙
jump.fwd	= 2.5		;慜僕儍儞僾偺懍搙
runjump.back	= -2.55,-8.1	;屻僟僢僔儏偟側偑傜偺僕儍儞僾懍搙(僆僾僔儑儞)
runjump.fwd	= 4,-8.1	;慜僟僢僔儏偟側偑傜偺僕儍儞僾懍搙(僆僾僔儑儞)
airjump.neu	= 0,-8.1	;俀抜僕儍儞僾埲崀偺悅捈僕儍儞僾偺懍搙(僆僾僔儑儞)
airjump.back	= -2.55		;俀抜僕儍儞僾埲崀偺屻僕儍儞僾偺懍搙(僆僾僔儑儞)
airjump.fwd	= 2.5		;俀抜僕儍儞僾埲崀偺慜僕儍儞僾偺懍搙

[Movement]
airjump.num	= 0		;嬻拞偱僕儍儞僾偡傞夞悢
airjump.height	= 35		;嬻拞偱僕儍儞僾偡傞嵟掅尷偺崅偝
yaccel		= .44		;廳椡
stand.friction	= .85		;棫偪忬懺偺杸嶤學悢
crouch.friction	= .82		;孅傒忬懺偺杸嶤學悢

;---------------------------------------------------------------------------
; Stand
[Statedef 0]
type = S
physics = S
sprpriority = ifelse(numprojid(56789),99999,0)

[State 0, 1]
type = ChangeAnim
triggerall=numprojid(56789)
trigger1 = Anim != 23302
value = 23302

[State 0, 1]
type = ChangeAnim
triggerall=numprojid(246810)
trigger1 = Anim != 23001
value = 23001

[State 0, 1]
type = ChangeAnim
triggerall=!numprojid(246810)
triggerall=!numprojid(56789)
trigger1 = Anim != 0 && Anim != 5
trigger2 = Anim = 5 && AnimTime = 0 ;Turn anim over
value = 0

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

[State 0, 3] ;Stop moving if low velocity or 4 ticks pass
type = VelSet
trigger1 = abs(vel x) < 2
trigger2 = Time = 4
x = 0

[State 0, 4] ;Are you dead?
type = ChangeState
trigger1 = !alive
value = 5050

;---------------------------------------------------------------------------
; RUN_BACK
[Statedef 105]
type    = A
physics = A
ctrl = 0
anim = 105
sprpriority = 1

[State 0, PlaySnd]
type = PlaySnd
trigger1 = !time 
value = S10105,0
ignorehitpause = 1

[State -2, Common Effect]
type = Explod
trigger1 = !time
anim = 10105
facing = -1
pos = 0,5
scale = .55,.55
sprpriority = 0
bindtime=1
ownpal = 1
Supermovetime = -1

[State 105, 1]
type = VelSet
trigger1 = Time = 0
x = const(velocity.run.back.x)
y = const(velocity.run.back.y)

[State 105, 2]
type = CtrlSet
trigger1 = Time = 2
value = 1

[State 105, 3]
type = ChangeState
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
value = 106


;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;杺朄恮徚幐
[Statedef 99999]
type	= S
velset	= 0,0
ctrl	= 0
sprpriority=ifelse(prevstateno=11000,3,999999)

[State 0, SprPriority]
type = SprPriority
trigger1 = prevstateno=13101
value = -3
ignorehitpause = 1

[State 0, PalFXWiz]
type = PalFX
trigger1 =prevstateno!=13303
time = 1
add = 7,-200,-200
mul = 256,256,256
sinadd = 30,30,0,10
invertall = 0
color = 0
invertall = 0
color = 256

[State 181]
type = trans
trigger1=1
trans = addalpha
alpha = 256-((var(59))*10), 256
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = 1
var(59) = 1
ignorehitpause = 1

[State 0, DestroySelf]
type = DestroySelf
trigger1 = var(59)>=25
ignorehitpause = 1 

[State 0, DisplayToClipboard]
type = DisplayToClipboard
trigger1 = 1
text = "fvar(1) = %f"
params = fvar(1)
ignorehitpause = 1
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;			CommonState娭楢婰弎
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;AI嶌摦拞偵彑庤偵曕峴偟偨傝丄僕儍儞僾偟側偄傛偆偵惂尷偡傞偨傔偵
;婎杮摦嶌傪曄悢傪巊偭偰惂尷偟偰偍偒傑偡丅


[Statedef 20, 曕峴]
type    = S
physics = S
sprpriority = 0

[State 40, AI]
Type = ChangeState
triggerAll = Var(59) = 1;忦審傪壛偊偢偵昁偢栠傞傛偆偵偡傞丅
trigger1 = Time = 0
Value = 0
Ctrl = 1
IgnoreHitPause = 1

[State 20, 堏摦懍搙] ;慜恑偡傞懍搙
type = VelSet
trigger1 = var(59) = 0 ; AI僼儔僌偑OFF(恖憖嶌帪)
trigger1 = command = "holdfwd"
x = const(velocity.walk.fwd.x) ;掕悢偱愝掕偟偨懍搙

[State 20, 堏摦懍搙] ;屻戅偡傞懍搙
type = VelSet
trigger1 = var(59) = 0 ; AI僼儔僌偑OFF(恖憖嶌帪)
trigger1 = command = "holdback" ; 屻傠僉乕偑墴偝傟偰傞偲偒
x = const(velocity.walk.back.x) ;掕悢偱愝掕偟偨懍搙

[State 20, 傾僯儊曄峏] ;慜恑偡傞傾僯儊偵曄峏
type = ChangeAnim
triggerall = vel x > 0
trigger1 = Anim != 20 && Anim != 5
trigger2 = Anim = 5 && AnimTime = 0
value = 20

[State 20, 傾僯儊曄峏] ;屻戅偡傞傾僯儊偵曄峏
type = ChangeAnim
triggerall = vel x < 0
trigger1 = Anim != 21 && Anim != 5
trigger2 = Anim = 5 && AnimTime = 0
value = 21



[Statedef 40, 僕儍儞僾]
type    = S
physics = S
anim = 40
ctrl = 0
sprpriority = 1


[State 40, AI]
Type = ChangeState
triggerAll = Var(59) = 1;忦審傪壛偊偢偵昁偢栠傞傛偆偵偡傞丅
trigger1 = Time = 0
Value = 0
Ctrl = 1
IgnoreHitPause = 1


;--------------------伀僕儍儞僾偡傞曽岦傪惂屼偡傞曄悢

[State 40, 曄悢傪愝掕] ;僕儍儞僾奐巒帪偵曄悢乽sysvar(1)乿傪0偵僙僢僩
type = VarSet
trigger1 = time = 0
sysvar(1) = 0

[State 40, 曄悢傪愝掕] ;僐儅儞僪"holdfwd"偺応崌乽sysvar(1)乿傪1偵僙僢僩
type = VarSet
trigger1 = var(59) <= 0
trigger1 = command = "holdfwd"
sysvar(1) = 1

[state 40, AI]
type = varset
triggerall = var(59) > 0
trigger1 = P2BodyDist X > 145
trigger1 = Random = [0,100]
sysvar(1) = 1


[State 40, 曄悢傪愝掕] ;僐儅儞僪"holdback"偺応崌乽sysvar(1)乿傪-1偵僙僢僩
type = VarSet
trigger1 = var(59) <= 0
trigger1 = command = "holdback"
sysvar(1) = -1

[state 40, AI]
type = varset
triggerall = var(59) > 0
trigger1 = P2BodyDist X < 60
trigger1 = Random = [101,200]
sysvar(1) = -1

;--------------------仾僕儍儞僾偡傞曽岦傪惂屼偡傞曄悢

[State 40, 堏摦懍搙] ;僕儍儞僾奐巒帪偺懍搙惂屼
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)
;仾偺曄悢偐傜僕儍儞僾偡傞曽岦傪敾暿偟丄掕悢偺[Velocity]傛傝曽岦偛偲偺悢抣傪堷梡丅
;僕儍儞僾偟偰偄傞娫偼忢偵偙偺悢抣偑揔梡偝傟傑偡丅

[State 40, 堏摦懍搙] ;僟僢僔儏僕儍儞僾帪偺懍搙惂屼
type = VelSet
trigger1 = animtime = 0
trigger1 = prevStateNo = 100 ;僟僢僔儏
trigger1 = sysvar(1) = 1
x = const(velocity.runjump.fwd.x)

[State 40, 壒傪柭傜偡]
type = PlaySnd
trigger1 = Time = 1
value = 3,3

[State 40, 壒傪柭傜偡]
type = PlaySnd
trigger1 = !animtime
value = 10000,(prevstateno=100)

[State 3100, AfterImage]
type = AfterImage
triggerall = !animtime
trigger1 = prevstateno=100
time = 20
length = 9
TimeGap  = 2
FrameGap = 3
palbright = 0,0,0
palcontrast = 100,100,100
palpostbright = 0,0,0
paladd = -30,-30,-30
palmul = .75,.75,.75
trans = add1

[State -2, 傾乕儅乕僿儖僷乕屇傃弌偟]
type = Helper
trigger1 = !animtime
name = "Armor"
stateno = 10040
ID = 10040
size.xscale = 1
size.yscale = 1
postype = p1
pos = 0,0
ownpal = 1
supermovetime = 99999
pausemovetime = 99999

[State 40, 僗僥乕僩曄峏] ;僕儍儞僾拞僗僥乕僩傊堏峴
type = ChangeState
trigger1 = animtime = 0
value = 50
ctrl = 1

;------------------------
[Statedef 10040]
type = A
movetype = I
physics = N
ctrl = 0
anim = 20000
velset = 0,0

[State 1000, 0]
type = BindToRoot
trigger1 = time > 0
pos = 0,0

[State 4110, Explod]
type = Explod
trigger1 = time = 0 || time = 2 || time = 6
anim = 10040
pos = 0,0
postype = P1
scale = .5,.5
sprpriority = 5
supermove=1
ownpal = 0

[State 4110, DestroySelf]
type = DestroySelf
trigger1 = time >= 20

;------------------------------------------------------------------------------------
;   AI梡婎杮峴摦僗僥乕僩
;------------------------------------------------------------------------------------
;僾儗僀儎乕憖嶌偲偼暿偵AI梡偺僗僥乕僩傪暿偵嶌偭偰偍偒傑偡丅
;偦偆偡傞帠偱帺暘偺寛傔偨忦審偱曕峴傗僕儍儞僾傪惂屼偱偒傑偡丅


[Statedef 21]
type	= S
physics	= S
anim	= 20
sprpriority = 0
ctrl	= 0


[State 21, Turn]
type	= Turn
trigger1= P2dist X < 0

[State 21, VelSet]
type	= VelSet
trigger1= 1
x = const(velocity.walk.fwd.x)

[State 21, ChangeAnim]
type	= ChangeAnim
triggerAll = Vel X > 0
trigger1= Anim != 20 && Anim != 5
trigger2= Anim = 5 && AnimTime = 0
value	= 20

[State 21, ChangeAnim]
type	= ChangeAnim
triggerAll = Vel X < 0
trigger1= Anim != 21 && Anim != 5
trigger2= Anim = 5 && AnimTime = 0
value	= 21

[State 21, ChangeState]
type	= ChangeState
trigger1= RoundState != 2
trigger2= P2BodyDist X <= 5
trigger3= InGuardDist
value	= 0
ctrl	= 1

;屻戅
[Statedef 22]
type	= S
physics	= S
anim	= 21
sprpriority = 0
ctrl	= 0

[State 22, Turn]
type	= Turn
trigger1= P2dist X < 0

[State 22, VelSet]
type	= VelSet
trigger1= 1
x = const(velocity.walk.back.x)

[State 22, ChangeAnim]
type	= ChangeAnim
triggerAll = Vel X > 0
trigger1= Anim != 20 && Anim != 5
trigger2= Anim = 5 && AnimTime = 0
value	= 20

[State 22, ChangeAnim]
type	= ChangeAnim
triggerAll = Vel X < 0
trigger1= Anim != 21 && Anim != 5
trigger2= Anim = 5 && AnimTime = 0
value	= 21

[State 22, ChangeState]
type	= ChangeState
trigger1= RoundState != 2
trigger2= P2BodyDist X >= 80 && random <= 100
trigger3= InGuardDist
value	= 0
ctrl	= 1

;僕儍儞僾
[Statedef 39]
type	= S
physics	= S
anim	= 40
ctrl	= 0
velset	= 0,0
sprpriority = 1
facep2	= 1

[State 39, 1]
type	= NotHitBy
trigger1= 1
value	= SC,AT

[State 39, VarSet]
type	= VarSet
triggerAll = time = 0
trigger1 = P2BodyDist X >= 100
trigger2 = P2BodyDist X <= 50
trigger2 = BackEdgeBodyDist <= 30
sysvar(1) = 1

[State 39, VarSet]
type	= VarSet
triggerAll = time = 0
trigger1= P2BodyDist X <= 50
trigger1 = BackEdgeBodyDist >= 30
sysvar(1) = -1


[State 40, 堏摦懍搙] ;僕儍儞僾奐巒帪偺懍搙惂屼
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, 堏摦懍搙] ;僟僢僔儏僕儍儞僾帪偺懍搙惂屼
type = VelSet
trigger1 = animtime = 0
trigger1 = prevStateNo = 100 ;僟僢僔儏
trigger1 = sysvar(1) = 1
x = const(velocity.runjump.fwd.x)


[State 40, 僗僥乕僩曄峏] ;僕儍儞僾拞僗僥乕僩傊堏峴
type = ChangeState
trigger1 = animtime = 0
value = 50
ctrl = 1


[State 39, ChangeState]
type	= ChangeState
trigger1= AnimTime = 0
value	= 50
ctrl	= 1



;---------------------------------------------------------------------------
;僟僢僔儏
[Statedef 100]
type    = S
physics = S
anim = 100
sprpriority = 1

[State 100, 1]
type = VelSet
trigger1 = 1
x = const(velocity.run.fwd.x)

[State 100, 1]
type = PlaySnd
trigger1 = AnimElem = 1
value = 40, 2

[State 0, Explod]
type = Explod
trigger1 =!time 
anim = 10100
ID = 10100
pos = -2,-60
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
scale=.5,.5
bindtime = 1
removeongethit = 0
ignorehitpause =1

[State 100, 2] ;Prevent run from canceling into walk
type = AssertSpecial
trigger1 = 1
flag = NoWalk

[State 100, 3] ;Prevent from turning
type = AssertSpecial
trigger1 = 1
flag = NoAutoTurn

;AI僗僀僢僠ON帪丆僐儞僩儘乕儖傪扗偆
[state 100,AI]
type = ctrlset
trigger1 = var(59) = 1
value = 0

;AI僗僀僢僠OFF帪丆僟僢僔儏掆巭傊堏峴
[State 100, 4]
type = ChangeState
trigger1 = var(59) = 0
trigger1 = command != "holdfwd"
value = 0

;AI僗僀僢僠ON帪丆僟僢僔儏掆巭傊堏峴
[State 100, AI]
type = ChangeState
triggerall = var(59) = 1
trigger1 = time >= 120
trigger2 = p2bodydist x < 71
trigger3 = EnemyNear,MoveType = A
trigger4 = inguarddist
trigger5 = roundstate != 2
value = 0
ctrl = 1

;-------------------------------------------------------------------------------
[Statedef 110]
type	= A	;啦踢:S 棫偪,C 偟傖偑傒,A 嬻拞 , L liedown
movetype= I	;堏摦僞僀僾:A 峌寕,I 晛捠,H 偔傜偄
physics	= A	;杸嶤(廳椡):S 棫偪,C 偟傖偑傒,A 嬻拞
VelSet  = 6,-6
ctrl	= 0 	;僐儞僩儘乕儖壜擻
anim	= 110 	;傾僯儊乕僔儑儞斣崋
sprpriority = 2	;儗僀儎乕桪愭搙 

[State 110, 壒]
type	= PlaySnd	;壒傪柭傜偡
trigger1= Time = 0	;僞僀儉偑0偺偲偒
value	= 110, 0		;壒斣崋

[State 110, add]
type = varadd
trigger1 = Time = 0
var(11) = 1

[State 110, 廔傢傝]
type 	= ChangeState 	;廔傢傞偲偒偼偙傟偵偡傞
trigger1= AnimTime = 0 	;逼覐I椆偟偰偐傜0宱夁偟偨偲偒
value 	= 51 		;僗僥乕僩51(僕儍儞僾壓崀)傊
ctrl 	= 1		;僐儞僩儘乕儖壜

;-------------------------------------------------------------------------------
;僴僀僕儍儞僾
[Statedef 199]
type = S
physics = S
anim = 40
ctrl = 0
sprpriority = 1

[State 199, 僕儍儞僾椡偺愝掕]
type = VelSet
trigger1 = AnimTime = 0
x = ifelse(command = "holdfwd",const(velocity.jump.fwd.x)*1.4,ifelse(command = "holdback",const(velocity.jump.back.x)*1.2,0))
y = const(velocity.jump.y)*1.2

[State 100, 儔儞僟儉壒惡]
type = PlaySnd
trigger1 = Time = 0
value = S200,Random%9

[State 100, 儔儞僟儉壒惡]
type = PlaySnd
trigger1 = !animtime
value = 10000,1

[State -2, 傾乕儅乕僿儖僷乕屇傃弌偟]
type = Helper
trigger1 = !animtime
name = "Armor"
stateno = 10040
ID = 10040
size.xscale = 1
size.yscale = 1
postype = p1
pos = 0,0
ownpal = 1
supermovetime = 99999
pausemovetime = 99999

[State 199, 巆憸]
type = afterimage
trigger1 = AnimTime = 0
time = 300
TimeGap = 1
length = 12
palcolor = 200
palContrast = 250,25,0
palBright = 50, 50,50
palAdd = 0,0,0
palMul = 1, 1, 1
trans = none

[State 199, 僗僥乕僩曄峏]
type = ChangeState
trigger1 = AnimTime = 0
value = 50
ctrl = 1

;---------------------------------------------------------------------------
; GUARD (start)
[Statedef 120]
type = U    ;Leave state type unchanged
physics = U ;Leave physics unchanged

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

[State 120, 2]
type = StateTypeSet
trigger1 = Time = 0 && statetype = S
physics = S

[State 120, 3]
type = StateTypeSet
trigger1 = Time = 0 && statetype = C
physics = C

[State 120, 4]
type = StateTypeSet
trigger1 = Time = 0 && statetype = A
physics = A

[State 120, Hi to Lo]
type = StateTypeSet
TriggerAll = StateType = S
Trigger1 = Command = "holddown" && !Var(59)
Trigger2 = EnemyNear,StateType = C && Random < 500 && Var(59)
Trigger3 = Random < 100 && Var(59)
statetype = C
physics = C

[State 120, Lo to Hi]
type = StateTypeSet
TriggerAll = StateType = C
Trigger1 = Command != "holddown" && !Var(59)
Trigger2 = EnemyNear,StateType != C && Random < 500 && Var(59)
Trigger3 = Random < 100 && Var(59)
statetype = S
physics = S

[State 120, 5]
type = ChangeState
triggerall = var(59) = 1
trigger1 = AnimTime = 0
value = 130 + (EnemyNear,statetype = C) + (statetype = A)*2

[State 120, 5]
type = ChangeState
triggerall = var(59) != 1
trigger1 = AnimTime = 0
value = 130 + (statetype = C) + (statetype = A)*2

[State 130, Stop Guarding]
type = ChangeState
triggerall = var(59) = 1
trigger1 = !inguarddist
value = 140

[State 130, Stop Guarding]
type = ChangeState
triggerall = var(59) != 1
trigger1 = command != "holdback"
trigger2 = !inguarddist
value = 140

;---------------------------------------------------------------------------
; Stand guard (guarding)
[Statedef 130]
type    = S
physics = S

[State 130, 1]
type = ChangeAnim
trigger1 = Anim != 130
value = 130

[State 130, Hi to Lo]
type = ChangeState
trigger1 = !var(59)
trigger1 = command = "holddown"
trigger2 = EnemyNear,StateType = C && Random < 500 && Var(59)
value = 131

[State 130, Stop Guarding]
type = ChangeState
triggerall = var(59) = 1
trigger1 = !inguarddist
value = 140

[State 130, Stop Guarding]
type = ChangeState
triggerall = var(59) != 1
trigger1 = command != "holdback"
trigger2 = !inguarddist
value = 140

;---------------------------------------------------------------------------
; Crouch guard (guarding)
[Statedef 131]
type    = C
physics = C

[State 131, 1]
type = ChangeAnim
trigger1 = Anim != 131
value = 131

[State 130, Hi to Lo]
type = ChangeState
trigger1 = !var(59)
trigger1 = command != "holddown"
trigger2 = EnemyNear,StateType != C && Random < 500 && Var(59)
value = 130

[State 130, Stop Guarding]
type = ChangeState
triggerall = var(59) = 1
trigger1 = !inguarddist
value = 140

[State 130, Stop Guarding]
type = ChangeState
triggerall = var(59) != 1
trigger1 = command != "holdback"
trigger2 = !inguarddist
value = 140

;---------------------------------------------------------------------------
; Air guard (guarding)
[Statedef 132]
type    = A
physics = N

[State 132, 1]
type = ChangeAnim
trigger1 = Anim != 132
value = 132

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

[State 132, 3]
type = VarSet
trigger1 = 1
sysvar(0) = (pos y >= 0) && (vel y > 0)

[State 132, 4]
type = VelSet
trigger1 = sysvar(0)
y = 0

[State 132, 5]
type = PosSet
trigger1 = sysvar(0)
y = 0

[State 132, 6]
type = ChangeState
triggerall = sysvar(0)
triggerall = inguarddist
trigger1 = !var(59) && command = "holdback"
trigger2 = var(59)
value = 130

[State 132, 7]
type = ChangeState
trigger1 = sysvar(0)
value = 52

[State 130, Stop Guarding]
type = ChangeState
triggerall = var(59) = 1
trigger1 = !inguarddist
value = 140

[State 130, Stop Guarding]
type = ChangeState
triggerall = var(59) != 1
trigger1 = command != "holdback"
trigger2 = !inguarddist
value = 140

;---------------------------------------------------------------------------
; GUARD (end)
[Statedef 140]
type = U    ;Leave state type unchanged
physics = U ;Leave physics unchanged
ctrl = 1

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

[State 140, 2]
type = StateTypeSet
trigger1 = Time = 0 && statetype = S
physics = S

[State 140, 3]
type = StateTypeSet
trigger1 = Time = 0 && statetype = C
physics = C

[State 140, 4]
type = StateTypeSet
trigger1 = Time = 0 && statetype = A
physics = A

[State 140, Hi to Lo]
type = StateTypeSet
TriggerAll = StateType = S
Trigger1 = Command = "holddown" && !Var(59)
Trigger2 = EnemyNear,StateType = C && Random < 500 && Var(59)
Trigger3 = Random < 100 && Var(59)
statetype = C
physics = C

[State 140, Lo to Hi]
type = StateTypeSet
TriggerAll = StateType = C
Trigger1 = Command != "holddown" && !Var(59)
Trigger2 = EnemyNear,StateType != C && Random < 500 && Var(59)
Trigger3 = Random < 100 && Var(59)
statetype = S
physics = S

;[State 140, 5] ;Implemented within engine
;type = ChangeState
;trigger1 = AnimTime = 0
;value = (statetype = C)*11 + (statetype = A)*51

;---------------------------------------------------------------------------
; SGUARDHIT (shaking)
[Statedef 150]
type    = S
movetype= H
physics = N
velset = 0,0

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

[State 150, 2]
type = ChangeState
trigger1 = HitShakeOver
value = 151 + 2*(command = "holddown"&&!Var(59)||Random<100&&EnemyNear,StateType=C&&Var(59))

[State 150, Hi to Lo]
type = StateTypeSet
TriggerAll = StateType = S
Trigger1 = Command = "holddown" && !Var(59)
Trigger2 = EnemyNear,StateType = C && Random < 500 && Var(59)
Trigger3 = Random < 100 && Var(59)
statetype = C
physics = C

[State 150, Lo to Hi]
type = StateTypeSet
TriggerAll = StateType = C
Trigger1 = Command != "holddown" && !Var(59)
Trigger2 = EnemyNear,StateType != C && Random < 500 && Var(59)
Trigger3 = Random < 100 && Var(59)
statetype = S
physics = S

[State 150, 3]
type = ForceFeedback
trigger1 = time = 0
waveform = square
time = 3

;---------------------------------------------------------------------------
; SGUARDHIT2 (knocked back)
[Statedef 151]
type    = S
movetype= H
physics = S
anim = 150

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

[State 151, 2]
type = VelSet
trigger1 = Time = GetHitVar(slidetime)
trigger2 = HitOver
x = 0

[State 151, 3]
type = CtrlSet
trigger1 = Time = GetHitVar(ctrltime)
value = 1

[State 151, Hi to Lo]
type = StateTypeSet
TriggerAll = StateType = S
Trigger1 = Command = "holddown" && !Var(59)
Trigger2 = EnemyNear,StateType = C && Random < 500 && Var(59)
Trigger3 = Random < 100 && Var(59)
statetype = C
physics = C

[State 151, Lo to Hi]
type = StateTypeSet
TriggerAll = StateType = C
Trigger1 = Command != "holddown" && !Var(59)
Trigger2 = EnemyNear,StateType != C && Random < 500 && Var(59)
Trigger3 = Random < 100 && Var(59)
statetype = S
physics = S

[State 151, 4]
type = ChangeState
trigger1 = HitOver
value = 130
ctrl = 1

;---------------------------------------------------------------------------
; CGUARDHIT (shaking)
[Statedef 152]
type    = C
movetype= H
physics = N
velset = 0,0

[State 152, 1]
type = ChangeAnim
trigger1 = 1
value = 151

[State 152, 3]
type = ChangeState
trigger1 = HitShakeOver
value = 151 + 2*(command = "holddown"&&!Var(59)||Random<100&&EnemyNear,StateType=C&&Var(59))

[State 152, Hi to Lo]
type = StateTypeSet
TriggerAll = StateType = S
Trigger1 = Command = "holddown" && !Var(59)
Trigger2 = EnemyNear,StateType = C && Random < 500 && Var(59)
Trigger3 = Random < 100 && Var(59)
statetype = C
physics = C

[State 152, Lo to Hi]
type = StateTypeSet
TriggerAll = StateType = C
Trigger1 = Command != "holddown" && !Var(59)
Trigger2 = EnemyNear,StateType != C && Random < 500 && Var(59)
Trigger3 = Random < 100 && Var(59)
statetype = S
physics = S

[State 152, 4]
type = ForceFeedback
trigger1 = time = 0
waveform = square
time = 4

;---------------------------------------------------------------------------
; CGUARDHIT2 (knocked back)
[Statedef 153]
type    = C
movetype= H
physics = C
anim = 151

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

[State 153, 2]
type = VelSet
trigger1 = Time = GetHitVar(slidetime)
trigger2 = HitOver
x = 0

[State 153, 3]
type = CtrlSet
trigger1 = Time = GetHitVar(ctrltime)
value = 1

[State 153, Hi to Lo]
type = StateTypeSet
TriggerAll = StateType = S
Trigger1 = Command = "holddown" && !Var(59)
Trigger2 = EnemyNear,StateType = C && Random < 500 && Var(59)
Trigger3 = Random < 100 && Var(59)
statetype = C
physics = C

[State 153, Lo to Hi]
type = StateTypeSet
TriggerAll = StateType = C
Trigger1 = Command != "holddown" && !Var(59)
Trigger2 = EnemyNear,StateType != C && Random < 500 && Var(59)
Trigger3 = Random < 100 && Var(59)
statetype = S
physics = S

[State 153, 4]
type = ChangeState
trigger1 = HitOver
value = 131
ctrl = 1

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

[State 154, 1]
type = ChangeAnim
trigger1 = 1
value = 152

[State 154, 2]
type = ChangeState
trigger1 = HitShakeOver
value = 155 ;AGUARDHIT2

[State 154, 3]
type = ForceFeedback
trigger1 = time = 0
waveform = square
time = 4

;---------------------------------------------------------------------------
; AGUARDHIT2 (knocked away)
[Statedef 155]
type    = A
movetype= H
physics = N
anim = 152

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

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

[State 155, 3]
type = CtrlSet
trigger1 = Time = GetHitVar(ctrltime)
value = 1

[State 155, 4]
type = VarSet
trigger1 = 1
sysvar(0) = (pos y >= 0) && (vel y > 0)

[State 155, 5]
type = VelSet
trigger1 = sysvar(0)
y = 0

[State 155, 6]
type = PosSet
trigger1 = sysvar(0)
y = 0

[State 132, 6]
type = ChangeState
triggerall = sysvar(0)
triggerall = inguarddist
trigger1 = !var(59) && command = "holdback"
trigger2 = var(59)
value = 130

[State 155, 7]
type = ChangeState
trigger1 = sysvar(0)
value = 52

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	HIT_BOUNCE (hit ground)
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 5100]
type    = L
movetype= H
physics = N






[State 5100, Explod_Fall-Crash]
type	= Explod
trigger1= time = 0
anim	= 7070
ID	= 7070
bindtime= 1
scale	= .7,.7
ontop	= 0
shadow	= 0,0,0
ownpal	= 1
removetime	= -2
sprpriority	= -3
postype=p1



;劒劒劒劒劒劒劒[埲壓偼Common偺婰弎僐僺儁乮壛昅売強側偟]
[State 5100, 1]
type = VelSet
trigger1 = Time = 0
trigger1 = GetHitVar(fall.yvel) = 0
trigger1 = vel x > 1
x = 1

[State 5100, EnvShake]
type = FallEnvShake
trigger1 = Time = 0




[State 5100, Var] ;Save fall velocity
type = VarSet
trigger1 = Time = 0
sysvar(1) = floor(vel y)

[State 5100, 2] ;Hit ground anim (normal)
type = ChangeAnim
triggerall = time = 0
trigger1 = (anim != [5051,5059]) && (anim != [5061,5069])
trigger2 = !SelfAnimExist(5100 + (anim % 10))
value = 5100

[State 5100, 3] ;Hit ground anim (for hit up)
type = ChangeAnim
trigger1 = time = 0
trigger1 = (anim = [5051,5059]) || (anim = [5061,5069])
trigger1 = SelfAnimExist(5100 + (anim % 10))
value = 5100 + (anim % 10)

[State 5100, 4]
type = PosSet
trigger1 = Time = 0
y = 0

[State 5100, 5]
type = VelSet
trigger1 = Time = 0
y = 0

[State 5100, 6] ;Reduce speed
type = VelMul
trigger1 = Time = 0
x = 0.75

[State 5100, 7]
type = ChangeState
trigger1 = Time = 0
trigger1 = GetHitVar(fall.yvel) = 0
value = 5110 ;HIT_LIEDOWN

[State 5100, 8]
type = null;GameMakeAnim		;慜尵揚夞丄偙傟偩偗柍岠壔偟偰傑偡丅
trigger1 = Time = 1
value = 60 + (sysvar(1) > 5) + (sysvar(1) > 14)
pos = 0, 0
under = sysvar(1) <= 14

[State 5100, 9]
type = HitFallDamage
trigger1 = Time = 3

[State 5100, 10]
type = PlaySnd
trigger1 = Time = 1
value = F7, (sysvar(1) > 5) + (sysvar(1) > 14)

[State 5100, 11]
type = PosFreeze
trigger1 = 1

[State 5100, 12]
type = ChangeState
trigger1 = AnimTime = 0
value = 5101

[State 5100, 13]
type = ForceFeedback
trigger1 = Time = 0
waveform = sinesquare
ampl = 128,-3,-.2,.005
time = 20



;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	HIT_LIEDOWN
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 5110]
type    = L
movetype= H
physics = N





[State 5110, Explod_Fall-Crash]
type	= Explod
trigger1= time = 0
trigger1= Vel Y != 0
anim	= 7070
ID	= 7070
bindtime= 1
scale	= .9,.9
ontop	= 0
shadow	= 0,0,0
ownpal	= 1
removetime	= -2
sprpriority	= -3
postype=p1



;劒劒劒劒劒劒劒劒劒劒劒[埲壓偼Common偺婰弎僐僺儁乮壛昅売強側偟]
[State 5110, EnvShake]
type = FallEnvShake
trigger1 = Time = 0

[State 5110, 1] ;For hit up/up-diag type (from state 5081)
type = ChangeAnim
persistent = 0
trigger1 = SelfAnimExist(5110 + (anim % 10))
trigger1 = anim = [5081,5089]
value = 5110 + (anim % 10)

[State 5110, 2] ;Hit ground anim (normal)
type = ChangeAnim
triggerall = time = 0
triggerall = anim != [5110,5119] ;Not already changed anim
trigger1 = anim != [5161,5169]
trigger2 = !SelfAnimExist(5170 + (anim % 10))
value = 5170

[State 5110, 3] ;Hit ground anim (for hit up)
type = ChangeAnim
triggerall = time = 0
triggerall = anim != [5110,5119] ;Not already changed anim
trigger1 = anim = [5161,5169]
trigger1 = SelfAnimExist(5170 + (anim % 10))
value = 5170 + (anim % 10)

[State 5110, 4]
type = HitFallDamage
trigger1 = Time = 0

[State 5110, 5]
type = PosSet
trigger1 = Time = 0
y = 0

[State 5110, Var] ;Get fall velocity
type = VarSet
trigger1 = Time = 0
trigger1 = GetHitVar(fall.yvel) != 0
sysvar(1) = floor(vel y)

[State 5110, 6]
type = PlaySnd
trigger1 = Time = 0
trigger1 = !SysVar(0)
value = F7, (sysvar(1) > 5) + (sysvar(1) > 14)

[State 5110, 7]
type = null;GameMakeAnim		;慜尵揚夞丄偙傟偩偗柍岠壔偟偰傑偡丅
trigger1 = Time = 0
trigger1 = !SysVar(0)
value = 60 + (sysvar(1) > 5) + (sysvar(1) > 14)
pos = 0, 0
under = sysvar(1) <= 14

[State 5110, 8]
type = VelSet
trigger1 = Time = 0
y = 0

[State 5110, 9] ;For hit up type
type = ChangeAnim
persistent = 0
triggerall = anim = [5171,5179]
triggerall = SelfAnimExist(5110 + (anim % 10))
trigger1 = AnimTime = 0
trigger2 = SysVar(0) ;SysVar(0) = 1 avoids hit ground anim
value = 5110 + (anim % 10)

[State 5110, 10] ;For normal
type = ChangeAnim
persistent = 0
triggerall = Anim != [5111,5119]
trigger1 = AnimTime = 0
trigger2 = SysVar(0) ;SysVar(0) = 1 avoids hit ground frame
value = 5110

[State 5110, 11] ;If just died
type = ChangeState
triggerall = !alive
trigger1 = AnimTime = 0
trigger2 = SysVar(0) ;SysVar(0) = 1 avoids hit ground frame
trigger3 = Anim = [5110,5119]
value = 5150

[State 5110, 12]
type = VarSet
trigger1 = SysVar(0)
trigger1 = Time = 0
sysvar(0) = 0

[State 5110, 13] ;Friction
type = VelMul
trigger1 = 1
x = 0.85

[State 5110, 14]
type = ForceFeedback
trigger1 = alive
trigger1 = Time = 0
time = 8
ampl = 240
waveform = sine

[State 5110, 15]
type = ForceFeedback
trigger1 = !alive
trigger1 = Time = 0
ampl = 200, 7, -.467
time = 30
waveform = sine





;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	LOSE (Time over)
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 170]
type = S
ctrl = 0
anim = 170
velset = 0,0

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



;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	彑棙億乕僘暘婒乮common1.cns偵偼柍偄偗偳丄偙傟傕僐儌儞僗僥乕僩乯
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 180]
type = S
sprpriority=ifelse(numprojid(56789),99999,0)

[State 180,暘婒捠忢彑棙]
type = ChangeState
trigger1 = numprojid(56789)
trigger1 = Time = 0
value = 10181
[State 180,暘婒捠忢彑棙]
type = ChangeState
trigger1 = numprojid(246810)
trigger1 = Time = 0
value = 20181

[State 180,暘婒捠忢彑棙]
type = ChangeState
trigger1 = MatchOver != 1
trigger1 = Time = 0
value = 181

[State 180,暘婒帋崌廔椆]
type = ChangeState
trigger1 = MatchOver = 1
trigger1 = Time = 0
value = 181


;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	彑棙億乕僘	/	儔僂儞僪彑棙
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 181]
type = S
ctrl = 0
anim = 181
velset = 0,0

[State 0, VarRandom]
type = VarRandom
trigger1 = !time
v = 21
range = 0,2
ignorehitpause = 1

[State 180, 墘弌帪娫] 
type = AssertSpecial
triggerall=!var(21)
trigger1 = Time = [0,90]
flag = roundnotover
[State 180, 墘弌帪娫] 
type = AssertSpecial
triggerall=var(21)=[1,2]
trigger1 = Time = [0,220]
flag = roundnotover

[State 181,埿奷惡]
type = PlaySnd
trigger1 = AnimElem = 1
value = 180,var(21)
volume=255

[State 181, 柍揋愝掕]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	彑棙億乕僘	/	儔僂儞僪彑棙
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 10181]
type = S
ctrl = 0
anim = 23302
velset = 0,0

[State 180, 墘弌帪娫] 
type = AssertSpecial
trigger1 = Time = [0,180]
flag = roundnotover

[State 181,埿奷惡]
type = PlaySnd
trigger1 = !time
value = 3300, 8
volume=255

[State 181, 柍揋愝掕]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	彑棙億乕僘	/	儔僂儞僪彑棙
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 20181]
type = S
ctrl = 0
anim = 23001
velset = 0,0

[State 180, 墘弌帪娫] 
type = AssertSpecial
trigger1 = Time = [0,90]
flag = roundnotover

[State 181, 柍揋愝掕]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1


;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	彑棙億乕僘	/	儔僂儞僪彑棙
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 99181]
type = S
ctrl = 0
anim = 181
velset = 0,0

[State 180, 墘弌帪娫] 
type = AssertSpecial
trigger1 = Time = [0,150]
flag = roundnotover

[State 181,埿奷惡]
type = PlaySnd
trigger1 = AnimElem = 3
value = 180, 0

[State 181, 柍揋愝掕]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1


;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	彑棙億乕僘	/	偦偺俀
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 182]
type = S
ctrl = 0
anim = 182
velset = 0,0

[State 182, 墘弌帪娫] 
type = AssertSpecial
trigger1 = Time = [0,240]
flag = roundnotover

[State 182, 夝彍壒]
type = PlaySnd
trigger1 = AnimElem = 3
value = 180, 1
channel = 1

[State 182, 夝彍]
type = explod
trigger1 = AnimElem = 7
anim = 8603
pos = 0,0
bindtime = 50
postype=p1
vel = 0,0
sprpriority = 1

[State 182, 偳偆傗傜愗傝嶥偼]
type = PlaySnd
trigger1 = AnimElem = 10
value = 180, 2

[State 182, 柍揋愝掕]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1


;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	彑棙億乕僘	/	寛拝彑棙
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 183]
type = S
ctrl = 0
anim = 183
velset = 0,0

[State 182, 墘弌帪娫] 
type = AssertSpecial
trigger1 = Time = [0,500]
flag = roundnotover

[State 182, 夝彍]
type = PlaySnd
trigger1 = AnimElem = 3
value = 180, 5
channel = 1

[State 182,徚幐]
type = explod
trigger1 = AnimElem = 5
anim = 185
pos = 0,-50
postype = p1
bindtime = 50
vel = 0,0
sprpriority = 1

[State 182, 巒傑傝偺彈]
type = explod
trigger1 = AnimElem = 7
anim = 184
pos = 100,0
postype = p1
bindtime = 50
vel = 0,0
sprpriority = 1

[State 182, 峢懢乧]
type = PlaySnd
trigger1 = AnimElem = 7,30
value = 180, 3
channel = 2

[State 182, 寎偊偵峴偔傛]
type = PlaySnd
trigger1 = AnimElem = 9
value = 180, 4
channel = 1

[State 182, 柍揋愝掕]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1



;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;		僀儞僩儘暘婒(PREINTRO/CommonState)
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 190]
type	= S
ctrl	= 0
velset	= 0,0

[State 190];僟乕僋儔僀僟乕梡僀儞僩儘暘婒
type	= ChangeState
triggerAll = Time = 0
trigger1= P2Name = "Go Badaa Ba" || P4Name = "Go Badaa Ba"
trigger2= P2Name = "Another Agito" || P4Name = "Another Agito"
trigger3= P2Name = "KamenRider Ouja" || P4Name = "KamenRider Ouja"
trigger4= P2Name = "壖柺儔僀僟乕儕儏僂僈" || P4Name = "壖柺儔僀僟乕儕儏僂僈"
trigger5= P2Name = "kamen rider kaixa" || P4Name = "kamen rider kaixa"
trigger6= P2Name = "junichi" || P4Name = "junichi"
trigger7= P2Name = "抧崠孼掜" || P4Name = "抧崠孼掜"
trigger8= P2Name = "壖柺儔僀僟乕僇僽僩" || P4Name = "壖柺儔僀僟乕僇僽僩"
trigger9= P2Name = "Akemi-Homura" || P4Name = "Akemi-Homura"
trigger10= P2Name = "Homura & Friends" || P4Name = "Homura & Friends"
trigger11= P2Name = "Kyoko_Sakura" || P4Name = "Kyoko_Sakura"
value	= 191

[State 190];KAITO梡僀儞僩儘暘婒
type	= ChangeState
triggerAll = Time = 0
trigger1= P2Name = "Kaito" || P4Name = "kaito"
value	= 191


[State 190, 曄恎傊]
type = ChangeState
trigger1 = Var(40) = 0
value = 191


;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	曄恎両両
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 191]
type	= S
anim	= 191
velset	= 0,0
ctrl	= 0

[State 191, 摿庩岠壥] 
type	= AssertSpecial
trigger1= 1
flag	= Intro

[State 191, 傾僯儊屌掕乮儔僂儞僪奐巒偺埫揮拞偵傾僯儊偑恑傑側偄傛偆偵偡傞乯]
type	= ChangeAnim
trigger1= RoundState = 0
value	= 191

[State 0, VarSet]
type = VarSet
trigger1 = AnimElem = 1,10
var(20) = 1
ignorehitpause = 1

[State 191, 僗僀僢僠]
type	= PlaySnd
trigger1= AnimElem = 1,10
value	= 10190, 0
channel	= 8
loop=1
ignorehitpause=1

[State 191, 曄恎]
type	= PlaySnd
trigger1= AnimElem = 2
value	= 10190, 1
volume=255

[State 191, 曄恎]
type	= PlaySnd
trigger1= AnimElem = 6
value	= 10190, 2
volume=255

[state 2000, 1]
type = PlaySnd
trigger1 = AnimElem = 11
value = 3000,4

[State 0, VarSet]
type = VarSet
trigger1 = AnimElem = 11
var(20) = 0
ignorehitpause = 1

[State 0, StopSnd]
type = StopSnd
trigger1= AnimElem = 11
channel = 8
ignorehitpause = 1

[State 191, 曄恎]
type	= PlaySnd
trigger1= AnimElem = 11
value	= 10190, 3

[State 191, 曄恎]
type	= PlaySnd
trigger1= AnimElem = 13
value	= 190, 1
channel	= 2

[State -2, 傾乕儅乕僿儖僷乕屇傃弌偟]
type = Helper
trigger1= AnimElem = 13
name = "Magic Square"
stateno = 10191
ID = 10191
size.xscale = 0.5
size.yscale = 0.5
postype = p1
pos = 80,-60
sprpriority = 9999999
ownpal = 1

[State 0, PalFXWiz]
type = PalFX
trigger1 = numhelper(10191)
trigger1 = helper(10191),rootdist x=[-20,0]
time = 1
add = 256,0,0
mul = 256,256,256
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 191,僎乕僩]
type = Explod
trigger1= AnimElem = 11
id=20190
anim = 10194
pos = 2, -66
sprpriority = 4
ownpal = 1
postype=p1
bindtime = 1
removetime=43
scale=0.001,0.001

[State 0, ModifyExplod]
type = ModifyExplod
trigger1 = numexplod(20190)
ID =20190
scale=fvar(21),fvar(21)
ignorehitpause = 1
trans = addalpha
alpha=256-((floor(fvar(22)))*15), 256

[State 0, VarAdd]
type = VarSet
trigger1 = !roundstate
fvar(21) = 0
ignorehitpause = 1
[State 0, VarAdd]
type = VarSet
trigger1 = !roundstate
fvar(22) = 0
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
triggerall=fvar(21)<=0.25
trigger1 = numexplod(20190)
fvar(21) = 0.05
ignorehitpause = 1
[State 0, VarAdd]
type = VarAdd
triggerall=fvar(21)>0.125
trigger1 = numexplod(20190)
fvar(21) = -0.001
ignorehitpause = 1
[State 0, VarAdd]
type = VarAdd
trigger1 = numexplod(20190)
fvar(22) = 1
ignorehitpause = 1

[State 191, 僗僥乕僩曄峏] 
type	= ChangeState
trigger1= AnimTime = 0
value	= 0

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒[僄僼僃僋僩丂/丂Explod]

[State 191,僎乕僩]
type = Explod
trigger1= AnimElem = 13
anim = 8191
pos = 0, 0
postype=p1
sprpriority = 4
ownpal = 1
bindtime = 1
supermove = 1

[State 191,曻幩]
type = Explod
trigger1= AnimElem = 28
anim = 8195
pos = 0, 0
postype=p1
sprpriority = 1
ownpal = 1
bindtime = 1
supermove = 1

[State 191,3]
type = Explod
trigger1= AnimElem = 20,60
anim = 8192
postype = p1
pos = 70, -60
sprpriority = 3
postype=p1
ownpal = 1
bindtime = 1
supermove = 1
facing = ifelse(facing=1, 1, -1)
vfacing = 1


[State 191,2]
type = Explod
trigger1= AnimElem = 20,120
anim = 8193
postype = p2
pos = 0, -60
sprpriority = 3
ownpal = 1
postype=p1
bindtime = 1
supermove = 1
facing = ifelse(facing=1, 1, -1)
vfacing = 1


[State 191,1]
type = Explod
trigger1= AnimElem = 20,180
anim = 8194
postype = p1
pos = 0, -60
sprpriority = 3
postype=p1
ownpal = 1
bindtime = 1
supermove = 1
facing = ifelse(facing=1, 1, -1)
vfacing = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 10191]
type	= S
anim	= 10191
velset	= 0,0
ctrl	= 0
sprpriority=999999

[State 0, ChangeAnim]
type = ChangeAnim
trigger1 = anim=10191
trigger1 = !animtime
value = 10192
ignorehitpause = 1

[State 191, 墝]
type	= Explod
trigger1= var(1)=20
anim	= 10193
id=10193
pos	= 60, 0
sprpriority =999998
ownpal	= 1
postype=p1
removetime=-1
bindtime= -1
scale=0.5,0.5
supermove = 1

[State 0, PalFXWiz]
type = PalFX
trigger1 =1 
time = 1
add = 7,-200,-200
mul = 256,256,256
sinadd = 30,30,0,10
invertall = 0
color = 0
invertall = 0
color = 256

[State 181]
type = trans
trigger1=rootdist x>=43
trans = addalpha
alpha = 256-((var(2))*12), 256
ignorehitpause = 1

[State 0, ModifyExplod]
type = ModifyExplod
triggerall=numexplod(10193)
trigger1=rootdist x>=8
ID = 10193
trans=addalpha
alpha = 256-((var(3))*12), 256
bindtime=3
ignorehitpause =1

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

[State 0, VelAdd]
type = VelSet
trigger1 = rootdist x<43
trigger1 = var(1)>=20
x = -1.25
ignorehitpause =1

[State 0, VelAdd]
type = VelSet
triggerall=vel x<0
trigger1 = rootdist x>=43
trigger1 = var(1)>=20
x = 0
ignorehitpause =1

[State 0, VelAdd]
type = Velset
trigger1=vel x>=0
x = 0
ignorehitpause =1

[State 0, VarAdd]
type = VarAdd
trigger1 = anim=10192
var(1) = 1
ignorehitpause = 1
[State 0, VarAdd]
type = VarAdd
trigger1 = rootdist x>=43
var(2) = 1
ignorehitpause = 1
[State 0, VarAdd]
type = VarAdd
trigger1 = rootdist x>=8
var(3) = 1
ignorehitpause = 1

[State 0, RemoveExplod]
type = RemoveExplod
triggerall=numexplod(10193)
trigger1 = var(2)>=43
id = 10193
ignorehitpause = 1

[State 0, DestroySelf]
type = DestroySelf
trigger1 = var(2)>=43
ignorehitpause = 1
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;			捠忢峌寕
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	棫偪c
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 220]
type    = S
MoveType= A
physics = S
juggle  = 5
ctrl = 0
velset = 0,0
anim = 220
sprpriority = 2

[State 100, 儔儞僟儉壒惡]
type = PlaySnd
trigger1 = Time = 0
value = S200,Random%5

[State 400, 岠壥壒]
type = PlaySnd
trigger1 = AnimElem = 2
value = S0, 1

[State 220, 僸僢僩掕媊] 
type = HitDef
trigger1 = AnimElem = 2
attr = S, NA
damage    = 87
animtype  = Medium
hitflag = MAF
guardflag = MA
pausetime = 14,14
sparkno = S8001
guard.sparkno = S8005
hitsound   = S1,4 
guardsound = S6, 0 
sparkxy = -10,-70
ground.type = High
ground.slidetime = 8
ground.hittime  = 15
ground.velocity = -3
air.velocity = -3,-4
getpower	= 70,10
givepower = 36,24

[State 200];忔嶼曗惓
type = Varset
triggerall = fvar(1) > 0
trigger1 = movehit
fv = 1
value = fVar(1)*0.78
persistent = 0
ignorehitpause = 1

[State 220, 僗僥乕僩曄峏]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	棫偪b
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 210]
type    = S
MoveType= A
physics = S
juggle  = 5
ctrl = 0
velset = 0,0
anim = 210
sprpriority = 2

[State 100, 儔儞僟儉壒惡]
type = PlaySnd
trigger1 = Time = 0
value = S200,Random%5

[State 210, 岠壥壒]
type = PlaySnd
trigger1 = Time = 2
value = S0, 1

[State 210, 僸僢僩掕媊] 
type = HitDef
trigger1 = AnimElem = 2
attr = S, NA
damage    = 60
animtype  = Medium
hitflag = MAF
guardflag = MA
pausetime = 14,14
sparkno = S8001
guard.sparkno = S8005
hitsound   = S1, 4 
guardsound = S6, 0 
sparkxy = -10,-60
ground.type = High
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -6
air.velocity = -3,-4
getpower	= 80,30
givepower = 12,8

[State 210, 堏摦]
type = null;Velset
trigger1 = AnimElem = 3
x = 4

[State 200];忔嶼曗惓
type = Varset
triggerall = fvar(1) > 0
trigger1 = movehit
fv = 1
value = fVar(1)*0.78
persistent = 0
ignorehitpause = 1

[State 210, 僗僥乕僩曄峏]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	棫偪a
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 200]
type    = S
MoveType= A
physics = S
juggle  = 1
ctrl = 0
velset = 0,0
anim = 200
poweradd = 0 
sprpriority = 2

[State 100, 儔儞僟儉壒惡]
type = PlaySnd
trigger1 = Time = 0
value = S200,Random%5

[State 200, 岠壥壒]
type = PlaySnd
trigger1 = Time = 2
value = S0, 0

[State 210, 僸僢僩掕媊] 
type = HitDef
trigger1 = AnimElem = 2
attr = S, NA
damage    = 30
animtype  = Medium
hitflag = MAF
guardflag = MA
pausetime = 12,12
sparkno = S8001
guard.sparkno = S8005
hitsound   = S1, 1 
guardsound = S6, 0 
sparkxy = -10,-90
ground.type = High
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -6
air.velocity = -3,-4
getpower	= 85,20
givepower = 5,5

[State 200];忔嶼曗惓
type = Varset
triggerall = fvar(1) > 0
trigger1 = movehit
fv = 1
value = fVar(1)*0.83
persistent = 0
ignorehitpause = 1

[State 200, 僗僥乕僩曄峏]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	偟傖偑傒b
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 410]
type    = C
movetype= A
physics = C
juggle  = 6
ctrl = 0
anim = 410
sprpriority = 2

[State 400, 岠壥壒]
type = PlaySnd
trigger1 = AnimElem = 2
value = S0, 1

[State 100, 儔儞僟儉壒惡]
type = PlaySnd
trigger1 = Time = 0
value = S200,Random%5

[State 400, 僸僢僩掕媊]
type = HitDef
trigger1 = AnimElem = 2
attr = C, NA
damage    = 23
animtype  = Light
hitflag = MAFD
guardflag = L
pausetime = 12,12
sparkno = S8001
guard.sparkno = S8005
sparkno = 1
guard.sparkno = 40
hitsound   = S1, 1
guardsound = S6, 0 
sparkxy = 10,-25
ground.slidetime = 12
ground.hittime  = 12
ground.velocity = -1.5,0
air.velocity = -1.2,0
fall = 0
getpower	= 50,25
givepower       = 20,12

[State 400, 岠壥壒]
type = PlaySnd
trigger1 = AnimElem = 3
value = S2, 0

[State 200];忔嶼曗惓
type = Varset
triggerall = fvar(1) > 0
trigger1 = movehit
fv = 1
value = fVar(1)*0.74
persistent = 0
ignorehitpause = 1

[State 400, 僗僥乕僩曄峏]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	偟傖偑傒a
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 400]
type    = C
MoveType= A
physics = C
juggle  = 5
ctrl = 0
anim = 400
sprpriority = 2

[State 100, 儔儞僟儉壒惡]
type = PlaySnd
trigger1 = Time = 0
value = S200,Random%5

[State 400, 岠壥壒]
type = PlaySnd
trigger1 = Time = 1
value = S0, 0

[State 400, 僸僢僩掕媊]
type = HitDef
trigger1 = animelem = 2
attr = C, NA
damage    = 10
animtype  = Light
hitflag = MAFD
guardflag = L
pausetime = 12,12
sparkno = S8000
guard.sparkno = S8005
hitsound   = S1, 1 
guardsound = S6, 0 
sparkxy = -10,-50
ground.type = Low
ground.slidetime = 6
ground.hittime  = 12
ground.velocity = -5
air.velocity = -2,-3
down.velocity = -5,0
down.hittime = 20
getpower	= 50,20
givepower = 10,5

[State 200];忔嶼曗惓
type = Varset
triggerall = fvar(1) > 0
trigger1 = movehit
fv = 1
value = fVar(1)*0.99
persistent = 0
ignorehitpause = 1

[State 400, 僗僥乕僩曄峏]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	偟傖偑傒C
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 420]
type    = C
MoveType= A
physics = C
juggle  = 6
ctrl = 0
anim = 420
sprpriority = 2

[State 100, 儔儞僟儉壒惡]
type = PlaySnd
trigger1 = Time = 0
value = S200,Random%5

[State 4300, 岠壥壒]
type = PlaySnd
trigger1 = AnimElem = 3
value = S0, 1

[State 430, 僸僢僩掕媊]
type = HitDef
trigger1 = AnimElem = 4
attr = C, NA
damage    = 85
animtype  = Heavy
hitflag = MAFD
guardflag = L
pausetime = 12,12
sparkno = S8001
guard.sparkno = S8005
hitsound   = S1, 6
guardsound = S6, 0 
sparkxy = 10,-25
ground.type = Trip
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -1.5,-2
air.velocity = -1.2,-3
fall = 1
getpower	= 90,20
givepower = 36,24

[State 200];忔嶼曗惓
type = Varset
triggerall = fvar(1) > 0
trigger1 = movehit
fv = 1
value = fVar(1)*0.87
persistent = 0
ignorehitpause = 1

[State 420, 僗僥乕僩曄峏]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僕儍儞僾b
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 610]
type    = A
MoveType= A
physics = A
juggle  = 3
ctrl = 0
anim = 610
sprpriority = 2

[State 100, 儔儞僟儉壒惡]
type = PlaySnd
trigger1 = Time = 0
value = S200,Random%5

[State 600, 岠壥壒]
type = PlaySnd
trigger1 = Time = 1
value = S0, 0

[State 600, 僸僢僩掕媊]
type = HitDef
trigger1 = AnimElem = 4
attr = A, NA
damage = 27
guardflag = HA
priority = 3
pausetime = 7,7
sparkxy = -5,-60
sparkno = S8000
guard.sparkno = S8005
hitsound   = S1, 1 
guardsound = S6, 0 
ground.type = High
ground.slidetime = 6
ground.hittime  = 6
ground.velocity = -4
air.velocity = -2,-3
getpower	= 30,10
givepower = 0,0

[State 200];忔嶼曗惓
type = Varset
triggerall = fvar(1) > 0
trigger1 = movehit
fv = 1
value = fVar(1)*0.74
persistent = 0
ignorehitpause = 1

;[State 640, 僐儞僩儘乕儖]
;type = CtrlSet
;trigger1 = (Time > 6)
;value = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僕儍儞僾a
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 600]
type    = A
MoveType= A
physics = A
juggle  = 3
ctrl = 0
anim = 600
sprpriority = 2

[State 100, 儔儞僟儉壒惡]
type = PlaySnd
trigger1 = Time = 0
value = S200,Random%5

[State 600, 岠壥壒]
type = PlaySnd
trigger1 = Time = 1
value = S0, 0

[State 600, 僸僢僩掕媊]
type = HitDef
trigger1 = AnimElem = 2
attr = A, NA
damage = 14
guardflag = HA
priority = 3
pausetime = 8,8
sparkxy = -5,-60
sparkno = S8000
guard.sparkno = S8005
hitsound   = S1, 1 
guardsound = S6, 0 
ground.type = High
ground.slidetime = 6
ground.hittime  = 6
ground.velocity = -4
air.velocity = -2,-3
getpower	= 30,10
givepower = 0,0

[State 200];忔嶼曗惓
type = Varset
triggerall = fvar(1) > 0
trigger1 = movehit
fv = 1
value = fVar(1)*0.81
persistent = 0
ignorehitpause = 1

[State 640, 僐儞僩儘乕儖]
type = CtrlSet
trigger1 = (Time > 14)
value = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僕儍儞僾C
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 620]
type    = A
MoveType= A
physics = A
juggle  = 4
ctrl = 0
anim = 620
sprpriority = 2

[State 100, 儔儞僟儉壒惡]
type = PlaySnd
trigger1 = Time = 0
value = S200,Random%5

[State 620, 岠壥壒]
type = PlaySnd
trigger1 = AnimElem = 3
value = S0, 1

[State 620, 僸僢僩掕媊]
type = HitDef
trigger1 = AnimElem = 3
attr = A, NA
damage = 80, 0
guardflag = HA
priority = 4
pausetime = 12,12
sparkxy = -10,-20
sparkno = S8000
guard.sparkno = S8005
hitsound   = S1, 6
guardsound = S6, 0 
animtype = Med
ground.type = High
ground.slidetime = 17
ground.hittime  = 17
ground.velocity = -5
air.velocity = -3,-4
getpower	= 50,25
givepower = 5,5

[State 200];忔嶼曗惓
type = Varset
triggerall = fvar(1) > 0
trigger1 = movehit
fv = 1
value = fVar(1)*0.78
persistent = 0
ignorehitpause = 1

;[State 640, 僐儞僩儘乕儖]
;type = CtrlSet
;trigger1 = (Time > 12)
;value = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僕儍儞僾嫮僉僢僋
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 630]
type    = A
MoveType= A
physics = A
juggle  = 4
ctrl = 0
anim = 630
sprpriority = 2

[State 100, 儔儞僟儉壒惡]
type = PlaySnd
trigger1 = Time = 0
value = S200,Random%5

[State 630, 岠壥壒]
type = PlaySnd
trigger1 = AnimElem = 2
value = S0, 1

[State 630, 僸僢僩掕媊]
type = HitDef
trigger1 = AnimElem = 3
attr = A, NA
damage = 85
guardflag = HA
priority = 4
pausetime = 12,12
sparkxy = -10,-75
sparkno = S8001
guard.sparkno = S8005
hitsound   = S1, 2
guardsound = S6, 0 
animtype = Med
ground.type = High
ground.slidetime = 17
ground.hittime  = 17
ground.velocity = -5
air.velocity = -3,-4
getpower	= 50,15
givepower = 5,5

[State 200];忔嶼曗惓
type = Varset
triggerall = fvar(1) > 0
trigger1 = movehit
fv = 1
value = fVar(1)*0.68
persistent = 0
ignorehitpause = 1

[State 640, 僐儞僩儘乕儖]
type = CtrlSet
trigger1 = (Time > 20)
value = 1



;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;			摿庩媄仌僒僽僔僗僥儉
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	嬞媫夞旔
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 700]
type	= S
movetype= A
physics	= S
velset	= 0,0
anim	= 700
ctrl	= 0
sprpriority=-2

[State 0, PowerAdd]
type = PowerAdd
triggerall=!time
trigger1 = prevstateno=150||prevstateno=152
value = -1000
ignorehitpause = 1

[State 0, VelSet]
type = VelSet
trigger1 = 1 
x = 5
ignorehitpause = 1

[State 0, PlaySnd]
type = PlaySnd
trigger1 = !time
value = S200,0

[State 100]
Type           = Afterimage
Trigger1       = Time = 0
Trans          = Add
TimeGap        = 2
FrameGap       = 3
Time           = 15
PalBright      = 0, 0, 0
PalContrast    = 70, 70, 70
PalAdd         = 0, 0, 0
PalMul         = 1, 1, 1

[State 0, Turn]
type = Turn
triggerall=!animtime
trigger1 = P2dist X <0
ignorehitpause = 1

[State 0, ChangeState]
type = ChangeState
trigger1 = !animtime
value = 0
ctrl = 1
ignorehitpause = 1

;	搳偘
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 800]
type	= S
movetype= A
physics	= S
velset	= 0,0
anim	= 800
ctrl	= 0


[State 800, 僸僢僩掕媊乮搳偘梡乯]
type		= HitDef
trigger1	= AnimElemTime(2) = 0
attr		= S, NT		;峌寕懏惈: 偙傟偼 Standing, Normal Throw乮棫偪捠忢搳偘乯
hitflag		= M-		;憡庤偑傗傜傟忬懺偱偼側偄抧忋偺帪偱偟偐捦傓帠偑弌棃傑偣傫
priority	= 1, Miss	;搳偘側偺偱桪愭搙傪掅偔丄偐偮miss偐dodge偺懏惈偱側偗傟偽側傝傑偣傫
sparkno		= -1		;-1偵偡傟偽僸僢僩僗僷乕僋偑昞帵偟側偔側傝傑偡
sprpriority	= 1		;峌寕偑摉偨偭偨帪偵夋憸昞帵桪愭搙傪1偵弌棃傑偡
numhits		= 0
p1facing	= 1;ifelse(command = "holdfwd", 0, 0)		;峌寕偑摉偨偭偨帪偺帺暘偺岦偒 仛俇
p2facing	= 1;0		;峌寕偑摉偨偭偨帪偺憡庤偺岦偒
p1StateNo	= 801		;帺暘偺僗僥乕僩曄峏
p2StateNo	= 802		;憡庤傪惂屼偡傞僗僥乕僩偵峴偐偣傞
guard.dist	= 0		;憡庤偑僈乕僪忬懺偵堏峴弌棃傞嫍棧乮尰嵼偼0側偺偱僈乕僪晄壜乯
fall	= 1			;1偵偡傟偽憡庤偑僟僂儞忬懺偵側傞


[State 800, 僗僥乕僩曄峏]
type	= ChangeState
trigger1= AnimTime = 0
value	= 0
ctrl	= 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	搳偘惉岟儌乕僔儑儞
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 801]
type    = S
MoveType= A
physics = N
anim = 801
sprpriority = 4
poweradd = 65

;劒劒劒劒劒劒劒劒劒劒劒劒劒[僄僼僃僋僩丂/丂Explod]
[State 801, 僄僼僃僋僩昞帵]
type = Explod
trigger1 = AnimElem = 2
trigger2 = AnimElem = 4
trigger3 = AnimElem = 6
anim = 8011
sprpriority = 5
pos = 60,-82
postype=p1
bindtime = 1

[State 801, HitAdd]
type	= HitAdd
trigger1 = AnimElem = 2
trigger2 = AnimElem = 4
trigger3 = AnimElem = 6
value	= 1

;劒劒劒劒劒劒劒劒劒[岠壥壒丂/丂SoundEffect]

[State 801, 岠壥壒]
type	= PlaySnd
trigger1 = AnimElem = 2
trigger2 = AnimElem = 4
trigger3 = AnimElem = 6
value	 = S1,1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒[搳偘張棟偁傟偙傟]
[State 801, 暔棟揑側僉儍儔偺暆]
type	= Width
trigger1= AnimElemTime(1) >= 0 && AnimElemTime(8) < 0
edge	= 60,0		;慜曽偺夋柺抂傪墴偡暆偺傒傪曄偊偰偄傑偡

[State 801, 捦傫偩憡庤偺埵抲]
type	= TargetBind
trigger1= time >= 0 && time <= 22
pos = 45, 0


[State 801, 憡庤偺懱椡僎乕僕偺憹尭]
type	= TargetLifeAdd
trigger1 = AnimElem = 2
trigger2 = AnimElem = 4
value	= -28
kill = 0

[State 801, 憡庤偺懱椡僎乕僕偺憹尭]
type	= TargetLifeAdd
trigger1 = AnimElem = 6
value	= -30

[State 200];忔嶼曗惓
type = Varset
triggerall = fvar(1) > 0
trigger1= AnimElem = 6
fv = 1
value = fVar(1)*0.74
persistent = 0
ignorehitpause = 1

[State 801, 僗僥乕僩曄峏]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1


;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	憡庤懁偺搳偘傜傟儌乕僔儑儞侾
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 802]
type    = A
MoveType= H
physics = N
ctrl = 0
velset = 0,0

[State 802, 憡庤偺傾僯儊曄峏]
type = ChangeAnim2
trigger1 = Time = 0
value = 802

[State 802, 夋柺屌掕]
type = ScreenBound
trigger1 = Time >= 0
value = 0

[State 800, 僗僥乕僩曄峏]
type = ChangeState
trigger1 = AnimElem = 8
value = 803

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	憡庤懁偺搳偘傜傟儌乕僔儑儞2
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 803]
type    = A
MoveType= H
physics = N
velset = -5,-6
poweradd = 40

[State 803, 懍搙壛嶼] ;廳椡
type = VelAdd
trigger1 = 1
y = .4

[State 803, 僗僥乕僩曄峏]
type = ChangeState
triggerall = Vel Y > 0
triggerall = Pos Y >= -20
triggerall = alive
triggerall = CanRecover
trigger1 = Command = "recovery"
value = 5200 ;common1.cns嶲徠

[State 803, 惂屼夝彍偟偰憡庤偺僗僥乕僩偵栠偡]
type = SelfState
triggerall = Vel Y > 0
triggerall = alive
triggerall = CanRecover
trigger1 = Command = "recovery"
value = 5210 ;common1.cns嶲徠

[State 803, 惂屼夝彍偟偰憡庤偺僗僥乕僩偵栠偡]
type = SelfState
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
value = 5100 ;common1.cns嶲徠


;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僷儚乕棴傔乮摿庩峴摦乯
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 905]
type     = S
MoveType = I
physics  = S
velset   = 0,0
anim     = 905
ctrl     = 0



[State 700, 墴偟敾掕]
type	= PlayerPush
trigger1= 1
value	= 0 ;憡庤傪墴偝偢丄偡傝敳偗傞帠偑弌棃傞丅

[state 3000, 儃僀僗]
type = PlaySnd
trigger1 = Time = 0
value = 1000,4
channel = 1


[State 780, PowerAdd]
type	= PowerAdd
trigger1= time <= 9
value	= 3

[State 780, PowerAdd]
type	= PowerAdd
trigger1= time > 9
trigger1= 1
value	= 1*((time+12)/12)

[State 780, Shake]
type	= EnvShake
trigger1= Anim = 905 && !(time%4)
time	= 4
freq	= 60
ampl	= 2



[State 700, 僄僼僃僋僩];乽僥儞僾儗乕僩.txt乿嶲徠
type	= Explod
trigger1= NumExplod(10005) = 0
anim	= 10005
ID	= 10005
pos	= 0,0
postype	= p1
facing	= -1
ownpal	= 1
sprpriority	= 3
removetime	= -1
removeongethit	= 1


[State 700, 僗僥乕僩曄峏]
type = ChangeState
trigger1 = Var(59) = 0
trigger1 = (Command != "holdb" || Command != "holdy")
trigger2 = Power = 3000
;埲壓偼AI梡僩儕僈乕愝掕偱偛偞傫偡丅
trigger3 = var(59) = 1
trigger3= P2MoveType = A || inguarddist || (p2bodydist X <=100&&p2MoveType!=H)
trigger4= RoundState >= 3
value = 0
ctrl = 1
persistent = 0


;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	偔傜偄敳偗
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 910,抧忋斉]
Type=S
MoveType=H
physics=N
velset=0,0
Ctrl=0
faceP2=1
Anim= 910
sprPriority=2

[State 750, 僎乕僕尭]
type = PowerAdd
trigger1 = Time = 0
value = -2000

[State 750, ]
type = NotHitBy
value = SCA
trigger1 = anim = 910


[State 750, 儃僀僗]
type = PlaySnd
trigger1 = time = 0
trigger1 = anim = 910
value = 1000,4
channel=0

[State 750, SE傪柭傜偡]
Type= PlaySnd
trigger1 = anim = 910
trigger1 = AnimElemtime(1) = 0
value= 4,2
volume= 255
channel =-1


[State 750,Hitdef]
Type=HitDef
trigger1=!MoveContAct
trigger1=!MoveReversed
trigger1=AnimElemTime(1)>=0
trigger1=AnimElemTime(1)<9
attr = S, NA
ID=915
damage = 50,25                       ;僟儊乕僕検乮嵍偑摉偨偭偨帪丄塃偼僈乕僪偟偨帪乯
animtype = Light                 ;摉偰偨帪偺憡庤偺億乕僘乮light/midium/hard/back乯偐傜慖戰
guardflag =                      ;僈乕僪偱偒傞忬懺乮倣a偼慡偰偺忬懺偱僈乕僪壜擻乯
hitflag = MAF                     ;摉偰傞帠偺偱偒傞忦審
priority = 3, Hit                ;峌寕偺桪愭尃乮0庛偄丂4捠忢丂7嫮偄
pausetime = 2, 2                 ;峌寕偑摉偨偭偨帪偺峝捈帪娫乮嵍偑帺暘丄塃偑憡庤乯
sparkno = -1                     ;僸僢僩僄僼僃僋僩偺僗僾儔僀僩僗僥乕僩乮柍偗傟偽0乯
sparkxy = -10, -56               ;僸僢僩僄僼僃僋僩傪昞帵偡傞応強乮憡庤偺嵗昗偱乯
hitsound =  -1                   ;僸僢僩偟偨帪偺壒乮倱*,*偵偡傞偲帺暘偺壒傪巊偆乯
ground.type = Low                ;憡庤偺偔傜偭偨応強乮High丗摢丄懱, Low丗懌, Trip丗懌暐偄乯
ground.slidetime = 5             ;憡庤偑屻偵偡傋傞帪娫
ground.hittime  = 12             ;僐儞儃偑宷偑傞帪娫乮崅偔偟偡偓側偄帠乯
ground.velocity = -18.4,-5       ;抧忋偱峌寕傪偔傜偭偨応崌偺憡庤偺堏摦忬嫷乮倶偲倷偱彫悢揰壜乯
airguard.velocity = -18.9,-.8    ;嬻拞偱峌寕傪偔傜偭偨応崌偺憡庤偺堏摦忬嫷乮倶偲倷偱彫悢揰壜乯
air.type = High                  ;嬻拞偱憡庤偑偔傜偭偨応強乮忋偲摨偠乯
air.velocity = -18.4,-4          ;嬻拞偱峌寕傪偔傜偭偨応崌偺憡庤偺堏摦忬嫷乮倶偲倷偱彫悢揰壜乯
air.hittime = 12                 ;嬻拞偱僐儞儃偑宷偑傞帪娫
fall=1
fall.recover=0
kill = 0
getpower =0
givepower =0
ground.cornerpush.veloff = 0


[State 750, 岦偒捈偟]
type = TargetFacing
trigger1 = moveHit = 1
value = -1


[State 750, 僄僼僃僋僩]
type = Explod
trigger1 = AnimElemtime(1) = 0
anim = 10000
ID = 10000
pos = 0, 0
postype = p1
bindtime = -1
supermovetime = 9999
pausemovetime = 9999
scale = 1, 1
sprpriority = 3
ownpal = 1
removeongethit = 1
removetime = 26


[State 750, 僠僃儞僕僗僥乕僩]
Type=ChangeState
trigger1 = anim = 910
trigger1= animTime = 0
value = 0
Ctrl = 1



;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	偔傜偄敳偗丄嬻拞斉
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 915, 嬻拞斉]
Type=A
MoveType = H
physics = N
velset = 0,0
Ctrl = 0
faceP2 = 1
Anim = 915
sprPriority = 2

[State 755, 僎乕僕尭]
type = PowerAdd
trigger1 = Time = 0
value = -2000


[State 755, ]
type = NotHitBy
value = SCA
trigger1 = Animelem = 1 


[State 755, 儃僀僗]
type = PlaySnd
trigger1 = time = 0
value = 1000,4
channel=0

[State 755, SE傪柭傜偡]
Type= PlaySnd
trigger1 = AnimElemtime(1) = 0
value= 4,2
volume= 255
channel =-1


[State 755,Hitdef]
Type=HitDef
trigger1=!MoveContAct
trigger1=!MoveReversed
trigger1=AnimElemTime(1)>=0
trigger1=AnimElemTime(1)<10
attr = S, NA
ID=915
damage = 50,25                       ;僟儊乕僕検乮嵍偑摉偨偭偨帪丄塃偼僈乕僪偟偨帪乯
animtype = Light                 ;摉偰偨帪偺憡庤偺億乕僘乮light/midium/hard/back乯偐傜慖戰
guardflag =                      ;僈乕僪偱偒傞忬懺乮倣a偼慡偰偺忬懺偱僈乕僪壜擻乯
hitflag = MAF                    ;摉偰傞帠偺偱偒傞忦審
priority = 3, Hit                ;峌寕偺桪愭尃乮0庛偄丂4捠忢丂7嫮偄
pausetime = 0, 0                 ;峌寕偑摉偨偭偨帪偺峝捈帪娫乮嵍偑帺暘丄塃偑憡庤乯
sparkno = -1                     ;僸僢僩僄僼僃僋僩偺僗僾儔僀僩僗僥乕僩乮柍偗傟偽0乯
sparkxy = -10, -56               ;僸僢僩僄僼僃僋僩傪昞帵偡傞応強乮憡庤偺嵗昗偱乯
hitsound =  -1                   ;僸僢僩偟偨帪偺壒乮倱*,*偵偡傞偲帺暘偺壒傪巊偆乯
ground.type = High               ;憡庤偺偔傜偭偨応強乮High丗摢丄懱, Low丗懌, Trip丗懌暐偄乯
ground.slidetime = 5             ;憡庤偑屻偵偡傋傞帪娫
ground.hittime  = 12             ;僐儞儃偑宷偑傞帪娫乮崅偔偟偡偓側偄帠乯
ground.velocity = -18.4,-5       ;抧忋偱峌寕傪偔傜偭偨応崌偺憡庤偺堏摦忬嫷乮倶偲倷偱彫悢揰壜乯
airguard.velocity = -18.9,-.8    ;嬻拞偱峌寕傪偔傜偭偨応崌偺憡庤偺堏摦忬嫷乮倶偲倷偱彫悢揰壜乯
air.type = High                  ;嬻拞偱憡庤偑偔傜偭偨応強乮忋偲摨偠乯
air.velocity = -18.4,-4          ;嬻拞偱峌寕傪偔傜偭偨応崌偺憡庤偺堏摦忬嫷乮倶偲倷偱彫悢揰壜乯
air.hittime = 12                 ;嬻拞偱僐儞儃偑宷偑傞帪娫
fall=1
fall.recover=0
kill = 0
getpower =0
givepower =0
ground.cornerpush.veloff =0


[State 755,岦偒捈偟]
type = TargetFacing
trigger1 = moveHit = 1
value = -1


[State 755, 僄僼僃僋僩]
type = Explod
trigger1 = AnimElemtime(1) = 0
anim = 10000
ID = 10000
pos = 0, 0
postype = p1
bindtime = -1
supermovetime = 9999
pausemovetime = 9999
scale = 1, 1
sprpriority = 3
ownpal = 1
removeongethit = 1
removetime = 26


[State 755,End]
Type=ChangeState
trigger1 = anim = 915
trigger1 = Time = 20
value = 50

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;			昁嶦媄
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	價僢僌
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 1000]
type    = S
movetype= A
physics = S
juggle  = 0
poweradd= 0
ctrl = 0
velset = 0,0
anim = 1000
sprpriority = 1

[State 1000, 岠壥壒]
type = PlaySnd
trigger1 = animelem = 1
value = 800, 0
channel=0

[State 1000, 岠壥壒]
type = PlaySnd
trigger1 = animelem = 1
value = 1000, 0
channel=1

[State 1000, 岠壥壒]
type = PlaySnd
trigger1 = animelem = 2
value = 1100, 0

[state 1000, ude]
type = helper
trigger1 = !time
Size.XScale =.4
Size.YScale =.4
id = 11000
name = "magic sphere"
pos = 45, -80
postype = p1
stateno = 11000
helpertype = normal
keyctrl = 1
ownpal = 1

[state 1000, ude]
type = helper
trigger1 = animelem = 2
Size.XScale =1
Size.YScale =1
id = 1000
name = "ude"
pos = 110, -80
postype = p1
stateno = 1050
helpertype = normal
pausemovetime = 0
keyctrl = 1
ownpal = 1


[State 1000,僗僥乕僩曄峏]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 11000]
type	= S
anim	= 11000
velset	= 0,0
ctrl	= 0
sprpriority=3

[State 0, PalFXWiz]
type = PalFX
trigger1 =1 
time = 1
add = 7,-200,-200
mul = 256,256,256
sinadd = 30,30,0,10
invertall = 0
color = 0
invertall = 0
color = 256

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

[State 0, VarAdd]
type = VarSet
trigger1 = !time
fvar(1) = 5
ignorehitpause = 1

[State 0, AngleDraw]
type = AngleDraw
trigger1 = 1
scale = fvar(1),fvar(1)
ignorehitpause = 1 

[State 0, VarAdd]
type = VarSet
trigger1 = fvar(1)<1
fvar(1) = 1
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = fvar(1)>1
fvar(1) = -0.5
ignorehitpause = 1

[State 181]
type = trans
trigger1=1
trans = addalpha
alpha = (var(1)*22), 256
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = 1
var(1) = 1
ignorehitpause = 1

[State 0, ChangeState]
type = ChangeState
trigger1 = time>=42
value =99999
ignorehitpause = 1 

;仸仸仸仸仸仸仸仸仸仸仸仸仸仸仸仸仸仸仸仸

[Statedef 1050]
type    = S
movetype= A
physics = N
juggle  = 0
poweradd= 0
ctrl = 0
velset = 0,0
anim = 1050
sprpriority = 5

[State 170, 柍揋]
type = NotHitBy
trigger1 = time = 0
value = SCA, NT, ST, HT, NA, SA, HA,NP,SP,HP
time = -1

[State 170, 柍揋]
type = HitBy
trigger1 = time = 0
value = SCA, NA, SA, HA,NP,SP,HP
time = -1

[State 1000,1]
type = HitOverride
trigger1 = Time = 0
attr = SCA, NT, ST, HT, NA, SA, HA,NP,SP,HP
stateno = 1050
time = -1

[State 35000]
type  = Explod 
trigger1 = time = 0
anim = 1051
postype = p1
ID = 1051
sprpriority = 5
pos = 0,0
scale = 1,1
bindtime = 1
facing = 1
removetime=50
ownpal = 1
ignorehitpause = 1

[State 35000]
type  = Explod 
trigger1 = time = 0
anim = 11001
postype = p1
ID = 11001
sprpriority = 999
pos = 90,-20
scale = 1.5,1.5
bindtime = -1
removetime=-2
ownpal = 1
ignorehitpause = 1

[State 240, 2]
type = HitDef
trigger1 = animelem = 1
attr = S, SP
animtype  = Medium
damage = Ceil(75*root,fvar(1)),15
guardflag = LHA
pausetime = 0,6
sparkno = S8011
guard.sparkno = S8006
sparkxy = -10,-20
hitsound   = S1000,3
guardsound = S6,0
ground.type = high
ground.slidetime = 6
ground.hittime = 18
ground.velocity = -6,-2
air.velocity = -2.5,-5
getpower	= 90,45
givepower = 50,50
fall = 1
fall.recover = 0
air.hittime = 40
fall.recovertime =40
envshake.time = 15
envshake.ampl = 7
envshake.freq = 176

[State 0, ModifyExplod]
type = ModifyExplod
trigger1 = time>=30
id=1051
trans = addalpha
alpha = 256-(var(1)),var(1)
ignorehitpause = 1

[State 200];忔嶼曗惓
type = null;parentVarset
trigger1 = movehit
fv = 1
value =  root,fVar(1)*0.86
persistent = 0
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = time>=30
var(1) = 10
ignorehitpause = 1

[State 230, 3]
type = destroyself
trigger1 = animtime = 0


;仸仸仸仸仸仸仸仸仸仸仸仸仸仸仸仸仸仸仸仸

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僶僀儞僪
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 1100]
type    = S
MoveType= A
physics = S
juggle  = 4
ctrl = 0
velset = 0,0
anim = 1100
sprpriority = 1

[State 230, 岠壥壒]
type = PlaySnd
trigger1 = Time = 0
value = S1000, 1

[State 230, 岠壥壒]
type = PlaySnd
trigger1 = Animelem=4
value = S11000, 0

[State -2, 杺朄恮僿儖僷乕屇傃弌偟]
type = Helper
trigger1= AnimElem = 4
name = "Magic Square"
stateno = 11150
ID = 11150
postype = p2
pos = 50,0
size.xscale =0.23 
size.yscale =0.23
sprpriority = 9999999
ownpal = 1

[State 1100, 嵔1]
type = Projectile
trigger1 = AnimElem = 4,10
attr = S, SP
projanim = 1151
ProjHitAnim = 1152
ProjRemAnim = 1152 
projid = 1151
Projremove = 1
ProjRemoveTime =60
projpriority = 1
projsprpriority = 5
projedgebound = 200
projstagebound = 200
postype = p2
offset = -50,0
velocity = 0,0
accel = 0,0
damage = 0,0
animtype = medium
guardflag = LHA
pausetime = 0,12
sparkxy = 50,-80
sparkno = S8010
guard.sparkno = S8006
hitsound   = S1, 1 
guardsound = S6, 0 
ground.type = high
ground.slidetime = 14
ground.hittime = 16
getpower	= 30,10
givepower = 2,2
p2StateNo	= 1158

[State -2, 杺朄恮僿儖僷乕屇傃弌偟]
type = Helper
trigger1= AnimElem = 4,12
name = "Magic Square"
stateno = 11150
ID = 11150
postype = p2
pos = -50,0
size.xscale =0.23 
size.yscale =0.23
sprpriority = 9999999
ownpal = 1

[State 1100, 嵔2]
type = Projectile
trigger1 = AnimElem = 4,12
attr = S, SP
projanim = 1153
ProjHitAnim = 1154
ProjRemAnim = 1154 
projid = 1151
Projremove = 1
ProjRemoveTime =60
projpriority = 1
projsprpriority = 5
projedgebound = 200
projstagebound = 200
postype = p2
offset = 50,0
velocity = 0,0
accel = 0,0
damage = 0,0
animtype = medium
guardflag = LHA
pausetime = 0,12
sparkxy = -50,-80
sparkno = S8010
guard.sparkno = S8006
hitsound   = S1, 1 
guardsound = S6, 0 
ground.type = high
ground.slidetime = 14
ground.hittime = 16
getpower	= 30,10
givepower = 2,2
p2StateNo	= 1158

[State -2, 杺朄恮僿儖僷乕屇傃弌偟]
type = Helper
trigger1= AnimElem = 4,14
name = "Magic Square"
stateno = 11150
ID = 11150
postype = p2
pos = 15,15
size.xscale =0.23 
size.yscale =0.23
sprpriority = 9999999
ownpal = 1

[State 1100, 嵔3]
type = Projectile
trigger1 = AnimElem = 4,14
attr = S, SP
projanim = 1151
ProjHitAnim = 1152
ProjRemAnim = 1152 
projid = 1151
Projremove = 1
ProjRemoveTime =60
projpriority = 1
projsprpriority = 5
projedgebound = 200
projstagebound = 200
postype = p2
offset = -15,25
velocity = 0,0
accel = 0,0
damage = 0,0
animtype = medium
guardflag = LHA
pausetime = 0,12
sparkxy = 50,-80
sparkno = S8010
guard.sparkno = S8006
hitsound   = S1, 1 
guardsound = S6, 0 
ground.type = high
ground.slidetime = 14
ground.hittime = 16
getpower	= 30,10
givepower = 2,2
p2StateNo	= 1158

[State -2, 杺朄恮僿儖僷乕屇傃弌偟]
type = Helper
trigger1= AnimElem = 4,16
name = "Magic Square"
stateno = 11150
ID = 11150
postype = p2
pos = -15,-15
size.xscale =0.23 
size.yscale =0.23
sprpriority = 9999999
ownpal = 1


[State 1100, 嵔4]
type = Projectile
trigger1 = AnimElem = 4,16
attr = S, SP
projanim = 1153
ProjHitAnim = 1154
ProjRemAnim = 1154 
projid = 1151
Projremove = 1
ProjRemoveTime =60
projpriority = -5
projsprpriority = -5
projedgebound = 200
projstagebound = 200
postype = p2
offset = 15,-15
velocity = 0,0
accel = 0,0
damage = 0,0
animtype = medium
guardflag = LHA
pausetime = 0,12
sparkxy = -50,-80
sparkno = S8010
guard.sparkno = S8006
hitsound   = S1, 1 
guardsound = S6, 0 
ground.type = high
ground.slidetime = 14
ground.hittime = 16
getpower	= 30,10
givepower = 2,2
p2StateNo	= 1158



[State 200];忔嶼曗惓
type = null;Varset
trigger1 = movehit
fv = 1
value = fVar(1)*0.84
persistent = 0
ignorehitpause = 1

[State 230, 僗僥乕僩曄峏]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 11150]
type	= S
anim	= 11150
velset	= 0,0
ctrl	= 0
sprpriority=999999

[State 0, PalFXWiz]
type = PalFX
trigger1 =1 
time = 1
add = 7,-200,-200
mul = 256,256,256
sinadd = 30,30,0,10
invertall = 0
color = 0
invertall = 0
color = 256

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

[State 0, VarAdd]
type = VarSet
trigger1 = !time
fvar(1) = 5
ignorehitpause = 1

[State 0, AngleDraw]
type = AngleDraw
trigger1 = 1
scale = fvar(1),fvar(1)
ignorehitpause = 1 

[State 0, VarAdd]
type = VarSet
trigger1 = fvar(1)<1
fvar(1) = 1
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = fvar(1)>1
fvar(1) = -0.5
ignorehitpause = 1

[State 181]
type = trans
trigger1=1
trans = addalpha
alpha = (var(1)*25), 256
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = 1
var(1) = 1
ignorehitpause = 1

[State 0, ChangeState]
type = ChangeState
trigger1 = time>=70
value =99999
ignorehitpause = 1 

[State 0, DisplayToClipboard]
type = DisplayToClipboard
trigger1 = 1
text = "fvar(1) = %f"
params = fvar(1)
ignorehitpause = 1


;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	憡庤敍傝
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒


[Statedef 1158]
type    = A
MoveType= H
physics = N
ctrl = 0
velset = 0,0

[State 802, 憡庤偺傾僯儊曄峏]
type = ChangeAnim2
trigger1 = anim!=32891158
value = 32891158

[State 802, 夋柺屌掕]
type = null;ScreenBound
trigger1 = Time >= 0
value = 0

[State 800, 僗僥乕僩曄峏]
type = ChangeState
trigger1 = AnimElem = 32
value = 1159

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	憡庤敍傝2
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

[Statedef 1159]
type    = A
MoveType= H
physics = N
velset = 0,-2
poweradd = 40

[State 803, 懍搙壛嶼] ;廳椡
type = VelAdd
trigger1 = 1
y = .4

[State 803, 僗僥乕僩曄峏]
type = ChangeState
triggerall = Vel Y > 0
triggerall = Pos Y >= -20
triggerall = alive
triggerall = CanRecover
trigger1 = Command = "recovery"
value = 5200 ;common1.cns嶲徠

[State 803, 惂屼夝彍偟偰憡庤偺僗僥乕僩偵栠偡]
type = SelfState
triggerall = Vel Y > 0
triggerall = alive
triggerall = CanRecover
trigger1 = Command = "recovery"
value = 5210 ;common1.cns嶲徠

[State 803, 惂屼夝彍偟偰憡庤偺僗僥乕僩偵栠偡]
type = SelfState
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
value = 5100 ;common1.cns嶲徠



;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僄僉僒僀僩
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 1200]
type    = S
MoveType= A
physics = S
juggle  = 4
ctrl = 0
velset = 0,0
anim = 1200
sprpriority = 1


[State 210, 僸僢僩掕媊] 
type = HitDef
trigger1 = AnimElem = 2
attr = S, NA
damage    = 85,20
animtype  = Medium
hitflag = MAF
guardflag = MA
pausetime = 12,12
sparkno = S8011
guard.sparkno = S8005
hitsound   = S1, 2 
guardsound = S6, 0 
sparkxy = -10,-60
ground.type = High
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -6,-3
air.velocity = -5,-4
getpower	= 40,20
givepower = 5,5
fall = 1
fall.recover = 0

[State 220, 岠壥壒]
type = PlaySnd
trigger1 = Time = 0
value = S1000, 2


[State 220, 僗僥乕僩曄峏]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僨傿僼僃儞僪
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 1300]
type    = S
movetype= A
physics = S
juggle  = 0
poweradd= 0
ctrl = 0
velset = 0,0
anim = 1300
sprpriority = 1

[State 1000, 岠壥壒]
type = PlaySnd
trigger1 = animelem = 1
value = 1200, 0
channel=1

[state 1000, ude]
type = helper
trigger1 = !time
Size.XScale =.4
Size.YScale =.4
id = 11300
name = "magic sphere"
pos = 45, -80
postype = p1
stateno = 11300
helpertype = normal
keyctrl = 1
ownpal = 1

[state 1000, ude]
type = helper
trigger1 =animelem=2
Size.XScale =.4
Size.YScale =.4
id = 1301
name = "defend"
pos = 65, -80
postype = p1
stateno = 1301
helpertype = normal
pausemovetime = 0
keyctrl = 1
ownpal = 1

[State 1000,僗僥乕僩曄峏]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 11300]
type	= S
anim	= 11000
velset	= 0,0
ctrl	= 0
sprpriority=3

[State 0, PalFXWiz]
type = PalFX
trigger1 =1 
time = 1
add = 7,-200,-200
mul = 256,256,256
sinadd = 30,30,0,10
invertall = 0
color = 0
invertall = 0
color = 256

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

[State 0, VarAdd]
type = VarSet
trigger1 = !time
fvar(1) = 5
ignorehitpause = 1

[State 0, AngleDraw]
type = AngleDraw
trigger1 = 1
scale = fvar(1),fvar(1)
ignorehitpause = 1 

[State 0, VarAdd]
type = VarSet
trigger1 = fvar(1)<1
fvar(1) = 1
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = fvar(1)>1
fvar(1) = -0.5
ignorehitpause = 1

[State 181]
type = trans
trigger1=1
trans = addalpha
alpha = (var(1)*22), 256
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = 1
var(1) = 1
ignorehitpause = 1

[State 0, ChangeState]
type = ChangeState
trigger1 = time>=42+12
trigger2 = root,stateno!=1300
value =99999
ignorehitpause = 1 
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 1301]
type    = S
movetype= A
physics = S
juggle  = 0
poweradd= 0
ctrl = 0
velset = 0,0
sprpriority = 99999

[State 0, ChangeAnim]
type = ChangeAnim
trigger1 = anim!=1301
value = 1301
ignorehitpause = 1
[State 0, PlayerPush]
type = PlayerPush
trigger1 = ishelper
value = 0
ignorehitpause =1 
[State 0, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = noshadow
ignorehitpause = 1

[State 0, HitOverride]
type = HitOverride
trigger1 = 1
attr = SCA,AA,AT,AP
stateno = stateno
time = -1
ignorehitpause = 1

[State 0, Explod]
type = Explod
trigger1 = gethitvar(damage)
anim = 1302
ID = 1302
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = 1
removetime = -2
scale = .4,.4
sprpriority = 9999
vel=-7,0

[State 430, 僸僢僩掕媊]
type = HitDef
trigger1 = !var(1)
trigger1 = time=0
attr = S, HP
damage    = 85
animtype  = Heavy
hitflag = MAF
guardflag = L
pausetime = 0,12
sparkno = S8007
guard.sparkno = S8005
hitsound   = S1, 11
guardsound = S6, 0 
sparkxy = 0,0
ground.type = Trip
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -1.5,-2
air.velocity = -1.2,-3
fall = 1
getpower	= 90,20
givepower = 36,24
palfx.time=12
palfx.add = 240,50,0
palfx.mul = 250,224,120
palfx.sinadd = 110,55,85,10
palfx.invertall = 1
sprpriority=99999

[State 10, VarSet]
type = VarSet
trigger1 = movehit
var(1) = 1
ignorehitpause = 1

[State 0, RemoveExplod]
type = RemoveExplod
triggerall=numexplod(1302)
trigger1 = root,movetype=h
id = 1302
ignorehitpause = 1

[State 0, DestroySelf]
type = DestroySelf
trigger1 = !animtime
trigger2 = root,stateno!=1300
ignorehitpause = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;			挻昁嶦媄
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僉僢僋僗僩儔僀僋 慜摦嶌
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

[Statedef 3000]
type = A
ctrl = 0
anim = 3000
velset = 0,0
movetype = A
physics = N
PowerAdd = -1000

[State -2, 杺朄恮僿儖僷乕屇傃弌偟]
type = Helper
trigger1= AnimElem = 6
name = "Magic Square"
stateno = 13000
ID = 13000
postype = p1
pos = 0,0
size.xscale =0.7 
size.yscale =0.7
sprpriority = 9999999
ownpal = 1
supermovetime=99999999
pausemovetime=99999999

[State 2000]
type = Explod
trigger1 = AnimElem = 5
anim = 8500
pos = 10, -75
sprpriority = 5
ownpal = 1
bindtime = 1
postype=p1
supermove = 1

[State 2000]
type = Explod
trigger1 = AnimElem = 11
anim = 13000
pos = 25, -50
sprpriority = 99999999
removetime=-2
ownpal = 1
bindtime = 1
postype=p1
scale=0.5,0.5
supermove = 1

[state 2000, 1]
type = PlaySnd
trigger1 = !time
value = 1000,1

[State 200, 1]
type = PlaySnd
trigger1 = Time = 0
value = 3000, 0
channel = 1
volume=255

[state 2000, 1]
type = PlaySnd
trigger1 = AnimElem = 5
value = 3000,1
channel = 2

[state 2000, 1]
type = PlaySnd
trigger1 = AnimElem = 5
value = 3000,4

[state 2000, 1]
type = PlaySnd
trigger1 = AnimElem = 6
value = 3000,2

[State 3050, Super A]
type = SuperPause
trigger1 = AnimElem = 1
movetime = 300
time = 300
anim = 30

[State 204, 3]
type     = EnvShake
trigger1 = time>=138
trigger1 = time%15=0
ampl     = -3
freq     = 90
phase    = 90
time     = 15

[State 3050, 3]
type = ChangeState
trigger1 = AnimTime = 0
value = 3001

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 13000]
type	= S
anim	= 11150
velset	= 0,0
ctrl	= 0
sprpriority=999999

[State 0, PalFXWiz]
type = PalFX
trigger1 =1 
time = 1
add = 7,-200,-200
mul = 256,256,256
sinadd = 30,30,0,10
invertall = 0
color = 0
invertall = 0
color = 256

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

[State 0, VarAdd]
type = VarSet
trigger1 = !time
fvar(1) = 5
ignorehitpause = 1

[State 0, AngleDraw]
type = AngleDraw
trigger1 = 1
scale = fvar(1),fvar(1)
ignorehitpause = 1 

[State 0, VarAdd]
type = VarSet
trigger1 = fvar(1)<1
fvar(1) = 1
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = fvar(1)>1
fvar(1) = -0.125
ignorehitpause = 1

[State 181]
type = trans
trigger1=1
trans = addalpha
alpha = (var(1)*10), 256
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = 1
var(1) = 1
ignorehitpause = 1

[State 0, ChangeState]
type = ChangeState
trigger1 = root,stateno!=3000
value =99999
ignorehitpause = 1 

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僉僢僋僗僩儔僀僋懁揮
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

[Statedef 3001]
type = A
ctrl = 0
anim = 3001
velset = 0,0
movetype = A
physics = N

[State 2000]
type = Explod
trigger1 = AnimElem = 1
anim = 13001
pos = -14,-3
sprpriority = 99999999
removetime=-2
ownpal = 1
postype=p1
bindtime = 1
scale=0.4,0.4
supermove = 1
[State 2000]
type = Explod
trigger1 = AnimElem = 2
anim = 13001
pos = -72,-56
sprpriority = 99999999
removetime=-2
ownpal = 1
postype=p1
bindtime = 1
scale=0.4,0.4
supermove = 1
[State 2000]
type = Explod
trigger1 = AnimElem = 3
anim = 13001
pos = 23,-142
sprpriority = 99999999
removetime=-2
ownpal = 1
postype=p1
bindtime = 1
scale=0.4,0.4
supermove = 1
[State 2000]
type = Explod
trigger1 = AnimElem = 4
anim = 13001
pos = 50,-87
sprpriority = 99999999
removetime=-2
ownpal = 1
postype=p1
bindtime = 1
scale=0.4,0.4
supermove = 1
[State 2000]
type = Explod
trigger1 = AnimElem = 5
anim = 13001
pos = 8,-5
sprpriority = 99999999
removetime=-2
ownpal = 1
postype=p1
bindtime = 1
scale=0.4,0.4
supermove = 1

[State 230, 1]
type = Velset
trigger1 = AnimElem = 1
x = 3

[State 230, 1]
type = Velset
trigger1 = AnimElem = 5
x = 0


[State 3050, 3]
type = ChangeState
trigger1 = AnimTime = 0
value = 3002



;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僉僢僋僗僩儔僀僋 忋徃
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 3002]
type    = A
movetype= A
physics = N
ctrl = 0
velset = 0, 0
anim = 3002
velset = 0, 0

[state 2000, 1]
type = PlaySnd
trigger1 = AnimElem = 2
value = 3000,3
volume=255

[state 2000, 1]
type = PlaySnd
trigger1 = !time
value = 10000,1
volume=255

[State 230, 1]
type = Velset
trigger1 = time = [0,16]
x = -3
y = -5

[State 230, 1]
type = Velset
trigger1 = time = [17,39]
x = -1
y = -1

;忋徃
[State 230, 1]
type = Velset
trigger1 = time = 40
x = 0
y = 0

[State 1101 , 3]
type = ChangeState
trigger1 = animtime = 0
value = 3003

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僉僢僋僗僩儔僀僋 峌寕
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 3003]
type    = A
movetype= A
physics = N
juggle  = 8
anim = 3003
velset = 0, 0

[State 190, hunsya]
type = explod
trigger1 = AnimElem = 1
anim = 3051
pos = -165,-125
postype = p1
bindtime = -1
vel = 0,0
sprpriority = 5
ownpal = 1
supermove = 1

[State 1000, 僄僼僃僋僩]
type = Explod
trigger1 = time = 0
anim = 3050
pos = 65, -35
postype = p1
bindtime = -1
supermovetime = 9999
pausemovetime = 9999
scale = 1, 1
sprpriority = 5

[State 0, VelAdd]
type = VelAdd
trigger1 = Time = [0,30]
x = 0.85
y = 0.35
ignorehitpause = 1

[State 2802, HitDef]
type = HitDef 
trigger1 = AnimElem = 1
attr = S, NA
animtype = Heavy
damage = 200,50
guardflag = MA
pausetime = 0,5
sparkxy = -5,-30
sparkno = S8011
guard.sparkno = S8006
hitsound   = S3000,10
guardsound = S6,0
ground.type = High
ground.slidetime = 10
ground.hittime  = 12
ground.velocity = -5
air.velocity = -2.5,-3.5
numhits = 2
envshake.time = 25
envshake.ampl = 7
envshake.freq = 176
p2stateno = 3010
palfx.time=45
palfx.add = 240,50,0
palfx.mul = 250,224,120
palfx.sinadd = 110,55,85,10
palfx.invertall = 1

[State 0, EnvColor]
type = EnvColor
trigger1 = movehit
value = 255,255,255
time = 2
persistent=0
ignorehitpause = 1

[State -2, 墛僿儖僷乕屇傃弌偟]
type = Helper
triggerall=enemy,animexist(89482892)
trigger1= movehit
name = "Flame"
stateno = 13001
ID = 13001
postype = p1
pos = 0,0
size.xscale =0.7 
size.yscale =0.7
sprpriority = 9999999
ownpal = 1
persistent=0
supermovetime=99999999
pausemovetime=99999999

[State -2, 墛僿儖僷乕屇傃弌偟]
type = Helper
triggerall=numenemy=2
triggerall=enemy(1),animexist(89482892)
trigger1= movehit
name = "Flame"
stateno = 13001
ID = 13002
postype = p1
pos = 0,0
size.xscale =0.7 
size.yscale =0.7
sprpriority = 9999999
ownpal = 1
persistent=0
supermovetime=99999999
pausemovetime=99999999

[State 2802, NotHitBY]
type = NotHitBy
trigger1 = 1
value = SCA,AP
time = 1

[State 4000, 1080]
type = varset
trigger1 = movehit = 1
var(10) = 1

[State 2802, ChangeState]
type	= ChangeState
trigger1 = Vel Y > 0 && Pos Y >= 0
value	= 3009

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 13001]
type    = A
movetype= I
physics = N
juggle  = 8
anim = 20000
velset = 0, 0

[State 0, PosSet]
type = PosSet
trigger1 = 1 
x = 0
y = 0
ignorehitpause = 1

[State 0, Turn]
type = Turn
triggerall=ishelper(13001)
trigger1 = enemy,facing=1
trigger1 = !time
ignorehitpause = 1

[State 0, Explod]
type = Explod
triggerall=ishelper(13001)
trigger1 = time%3=0
anim = 13001
ID = 13001
pos = floor(enemy,pos x),floor((enemy,pos y-40))
postype = p1
facing = 1
vfacing = 1
bindtime = 1
ownpal=1
vel = 0,-2
accel = 0,-0.1
random = 40,30
removetime = 30
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 99999
ignorehitpause = 1

[State 0, Turn]
type = Turn
triggerall=ishelper(13002)
trigger1 = enemy(1),facing=1
trigger1 = !time
ignorehitpause = 1

[State 0, Explod]
type = Explod
triggerall=ishelper(13002)
trigger1 = time%3=0
anim = 13001
ID = 13001
pos = floor(enemy(1),pos x),floor((enemy(1),pos y-40))
postype = p1
facing = 1
vfacing = 1
bindtime = 1
vel = 0,-2
ownpal=1
accel = 0,-0.1
random = 40,30
removetime = 30
pausemovetime = 0
scale = 0.5, 0.5
sprpriority = 99999
ignorehitpause = 1

[State 0, DestroySelf]
type = DestroySelf
trigger1 = time=45
trigger2 = root,stateno=23000
ignorehitpause = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僉僢僋僗僩儔僀僋拝抧
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 3009]
type    = A
movetype= A
physics = N
ctrl	= 0
anim	= 3009
velset	= 0,0

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

[State 0, ChangeState]
type = ChangeState
trigger1 =winko 
value =23000
ctrl = 0
ignorehitpause = 1

[State 4000, 1080]
type = varset
trigger1 = time = 0
var(10) = 0

[State 1100,4]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僉僢僋僗僩儔僀僋寛拝
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 23000]
type    = S
movetype= A
physics = N
ctrl	= 0
anim	= 23000
velset	= 0,0

[State 0, TargetState]
type = TargetState
triggerall = NumTarget;()
trigger1 =!time
value =23002
ignorehitpause = 1

[State 0, VelSet]
type = VelSet
trigger1 = !time
x = 12
ignorehitpause = 1

[State 0, VelSet]
type = VelAdd
trigger1 = vel x!=0
x = -1
ignorehitpause = 1

[state 1000, ude]
type = helper
trigger1 = animelem=3
Size.XScale =.4
Size.YScale =.4
id = 23001
name = "magic sphere"
pos = 5, -80
postype = p2
stateno = 23001
facing=-1
helpertype = normal
keyctrl = 1
ownpal = 1

[State 0, PlaySnd]
type = PlaySnd
trigger1 = animelem=3
value = 23000,0

[State 204, 3]
type     = EnvShake
trigger1 = time<132+15
trigger1 = time%15=0
ampl     = -3
freq     = 90
phase    = 90
time     = 15

[State 0, Explod]
type = Explod
trigger1 = time=132+15
anim = 11500
pos = -1,-65
postype = p2
bindtime = 1
removetime = -2
pausemovetime = 0
scale = 1,1
sprpriority = 999

[State 0, PlaySnd]
type = PlaySnd
trigger1 = time=132+15
value = 11500,0
ignorehitpause = 1

[State 0, EnvShake]
type = EnvShake
trigger1 = time=132+15
time = 17
time = 20
freq = 80
ampl = -40
ignorehitpause = 1

[State 0, TargetState]
type = TargetState
triggerall = NumTarget;()
trigger1 =time=132+15
value =3105
ignorehitpause = 1

[State 0, EnvColor]
type = EnvColor
trigger1 = time=132+15
value = 255,255,255
time = 2
ignorehitpause = 1

[State 10000]
type = Projectile
triggerall=numprojid(246810)=0
trigger1 =roundstate>=3
projid=246810
projanim = 20000
projremove = 0
projremovetime = -1
ignorehitpause=1

[State 0, ChangeState]
type = ChangeState
trigger1 =time=132+15+40
value = 0
ctrl = 1
ignorehitpause = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 23001]
type	= S
anim	= 11000
velset	= 0,0
ctrl	= 0
sprpriority=3

[State 0, Explod]
type = Explod
trigger1 = !time
anim = 23002
id=40000
pos = -1,-65
postype = p2
bindtime = 1
removetime = 132
pausemovetime = 0
scale = .5,.5
ownpal=1
sprpriority = 999

[State 0, PalFXWiz]
type = PalFX
trigger1 =1 
time = 1
add = 7,-200,-200
mul = 256,256,256
sinadd = 30,30,0,10
invertall = 0
color = 0
invertall = 0
color = 256

[State 0, Explod]
type = ModifyExplod
trigger1 = numexplod(40000)
ID = 40000
trans=addalpha
alpha = (var(1)*7), 256
ignorehitpause=1

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

[State 0, VarAdd]
type = VarSet
trigger1 = !time
fvar(1) = 5
ignorehitpause = 1

[State 0, AngleDraw]
type = AngleDraw
trigger1 = 1
scale = fvar(1),fvar(1)
ignorehitpause = 1 

[State 0, VarAdd]
type = VarSet
trigger1 = fvar(1)<1
fvar(1) = 1
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = fvar(1)>1
fvar(1) = -0.25
ignorehitpause = 1

[State 181]
type = trans
trigger1=1
trans = addalpha
alpha = (var(1)*7), 256
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = 1
var(1) = 1
ignorehitpause = 1

[State 0, ChangeState]
type = ChangeState
trigger1 = time>=132
value =99999
ignorehitpause = 1 

[Statedef 23002]
type    = S
movetype= H
physics = N
velset=0,0

[State 0, ChangeAnim2]
type = ChangeAnim2
trigger1 = !time
value = 23301
ignorehitpause = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	儔僀僟乕儘働僢僩僪儕儖僉僢僋憡庤摦嶌
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 3010]
type = A
movetype = H
physics = N

[State 1010, 1]
type = VelSet
trigger1 = Time = 0
x = 0
y = 0
z = 0

[State 3005, 2]
type = ChangeAnim2
Trigger1 = Time >= 0
value = 3010

[State 3005, 9]
type = ChangeState
trigger1 = HitShakeOver = 1
value = 3011

;---------------------
;儔僀僟乕僉僢僋 僸僢僩帪憡庤摦嶌俀
;---------------------
[Statedef 3011]
type = A
movetype = H
physics = N
velset = -2.2,-15.3

[State 3006, 1]
type = VelAdd
trigger1 = Time > 0
y = .6

[State 3006, 2]
type = EnvShake
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
time = 16
ampl = 10
freq = 90
phase = 90
ignorehitpause = 1

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


;===========================================================================
;儅僔儞僂傿儞僈乕
;敪摦
[Statedef 1500]
type = S
movetype = A
physics = S
juggle = 0
poweradd = -1000
ctrl = 0
velset = 0,0
anim = 1503
sprpriority = 3

[State 780, PowerAdd]
type	= VarAdd
trigger1 = time = 0
fVar(35) = 500
pausemovetime = 99999999999999
supermovetime = 99999999999999

[State 3000,挻昁僄僼僃僋僩]
type = Explod
trigger1 = time = 1
anim = 8500
pos = 1, -55
sprpriority = 5
ownpal = 1
bindtime = 1
supermove = 1



[State 1500, SE]
type	= PlaySnd
trigger1= animelemtime(1) = 0 
value	= 200,2


[State 1500, PosSet]
type	= PosSet
trigger1= animelemtime(2) = 0 
y = 0


[State 1500, NotHitBy]
type	= NotHitBy
trigger1= 1
value	= SCA


[State 1500, image]
type = AfterImage
trigger1 = Time = 0
time = 10
FrameGap = 3
length = 8
PalBright   =   0,  0,  0
PalContrast = 192,192,192
PalAdd      =   0,  0,  0
PalMul      =  1,1,1
Trans = Add1

[State 1500, ScreenBound]
type	= ScreenBound
trigger1 = 1
value	= 0

[State 1500, VelSet]
type	= VelSet
trigger1 = Animelem = 3
x = -25
y = -15

[State 1500, VelSet]
type	= VelSet
trigger1 = Animelem = 4
x = -25
y = -8

[State 1500, VelSet]
type	= VelSet
trigger1 = Animelem = 5
x = -25
y = -2

[State 1500, VelSet]
type	= VelSet
trigger1 = Animelem = 6
x = -25
y = 0

[State 1500, VelSet]
type	= VelSet
trigger1 = AnimTime = 7
x = -25
y = 6


[State 1500, end]
type	= ChangeState
trigger1= AnimTime = 0
value	= 1510
ctrl	= 0


;僶僀僋鐎偒
[Statedef 1510]
type	= S
movetype= A
physics	= N
anim	= 1500
ctrl	= 0

[State 0, PlaySnd]
type = PlaySnd
trigger1 = !time
value = 11500,1
pan=160
ignorehitpause = 1

;[State 3000,挻昁僄僼僃僋僩]
;type	= Explod
;trigger1=!time
;anim	= 1510
;pos	= 0, 0
;postype	= back
;scale	= 0.6,0.6
;sprpriority = -5
;ownpal	= 1
;bindtime= 1
;supermove = 1

;[State 3000,挻昁僄僼僃僋僩]
;type	= Explod
;trigger1=!time
;anim	= 1520
;pos	= 0, 0
;postype	= back
;scale	= 0.6,0.6
;sprpriority = 5
;ownpal	= 1
;bindtime= 1
;supermove = 1

[State 1500, SE]
type	= PlaySnd
trigger1= animelemtime(1) = 0 
value	= 3440,0

[State 1510, NotHitBy]
type	= NotHitBy
trigger1= 1
value	= SCA

[State 1510, ScreenBound]
type	= ScreenBound
trigger1= 1
value	= 0

[State 1510, PosSet]
type	= PosSet
trigger1= time >= 0
y = 0

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

;-------------------[峌寕敾掕]
[State 1510, HitDef]
type		= HitDef
trigger1	= time = 0
attr		= S, HA
hitflag		= MAFD
guardflag	= MA
priority	= 7, Hit
damage = 0,70
pausetime	= 4, 5
guard.pausetime	= 1, 1
sparkno		= s8002
guard.sparkno	= s8006
sparkxy		= 40,-50
hitsound	= -1
guardsound	= s6,0
ground.type	= Low
ground.slidetime= 16
ground.hittime	= 16
ground.velocity	= 6,-10
fall = 1
fall.recover = 0
ground.cornerpush.veloff = 0
guard.velocity	= 0
air.type	= Low
yaccel	= 0.5
kill = 1
getpower	= 0, 0
givepower	= 36,36
forcestand	= 1
envshake.time = 15
envshake.freq = 150
envshake.ampl = 8
p1stateno=1511
p2stateno=1512
numhits=0

[State 1510, image]
type = AfterImage
trigger1 = Time = 1
time = 40
FrameGap = 3
length = 8
PalBright   =   0,  0,  0
PalContrast = 192,222,255
PalAdd      =   0,  0,  0
PalMul      =  1,1,1
Trans = Add1

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

[State 1510, push]
type = PlayerPush
trigger1 = 1
value = 0

[state 1510, changestate]
type = changestate
trigger1 = FrontEdgeDist < 10
value = 1520

;僶僀僋鐎偒
[Statedef 1511]
type	= S
movetype= I
physics	= N
ctrl	= 0

[State 0, Explod]
type = Explod
trigger1 = !time 
anim = 20001
ID = 20001
pos = 0,0
postype = back
removetime = 120
scale=1.01,1
bindtime=-1

[State 0, ModifyExplod]
type = ModifyExplod
trigger1 =time<=184 
trigger1 =numexplod(20001)
ID =20001
trans=addalpha
alpha=var(6),256-var(6)

[State 0, VarAdd]
type = VarAdd
trigger1 = 1
var(6) = 25

[State 0, VarSet]
type = VarSet
trigger1 = !time
var(5) = animelemno(0)

[State 0, ChangeAnim]
type = ChangeAnim
trigger1 = !time
value = 11502
elem = var(5)

[State 0, HitAdd]
type = HitAdd
trigger1 = !time
trigger2 = time%15=0
value = 1

[State 0, HitAdd]
type = TargetState
triggerall=hitcount<9
trigger1 = !time
trigger2 = time%15=0
value = 1512

[State 0, EnvShake]
type = EnvShake
triggerall=hitcount<9
trigger1 = !time
trigger2 = time%15=0
time = 25
freq = 176
ampl = 7

[State 0, PlaySnd]
type = PlaySnd
triggerall=hitcount<9
trigger1 = !time
trigger2 = time%15=0
value = 1,2

[State 0, Explod]
type = Explod
triggerall=hitcount<9
trigger1 = !time
trigger2 = time%15=0
anim = 8008
pos = 30,0
postype = p2
bindtime = 1
removetime = -2
pausemovetime = 0
scale = 1,1
sprpriority = 999

[State 0, AfterImageTime]
type = AfterImageTime
trigger1 = !time
time = 120

[State 0, TargetLifeAdd]
type = TargetLifeAdd
triggerall=hitcount<9
trigger1 = !time
trigger2 = time%15=0
value = -15
kill=0
ignorehitpause = 1
[State 0, VelSet]
type = VelSet
trigger1 = 1
x = 2.5
[State 0, VelSet]
type = TargetVelSet
trigger1 = 1
x = -vel x

[State 0, TargetState]
type = TargetState
trigger1 = hitcount>=9
value = 1513
[State 0, TargetLifeAdd]
type = TargetLifeAdd
trigger1 = hitcount>=9  
value = -35*floor(fvar(1))
ignorehitpause = 1
[State 200];忔嶼曗惓
type = Varset
triggerall = fvar(1) > 0
trigger1 = hitcount>=9
fv = 1
value = fVar(1)*0.88
persistent = 0
ignorehitpause = 1

[State 0, ChangeState]
type = ChangeState
trigger1 = hitcount>=9  
value =1520

[Statedef 1512]
type	= S
movetype= H
physics	= S

[State 0, ChangeAnim2]
type = ChangeAnim2
trigger1 =!time 
value = 11501
ignorehitpause = 1

[Statedef 1513]
type	= S
movetype= H
physics	= N
velset=-12,-7

[State 0, PalFXWiz]
type = PalFX
trigger1 = !time
time = 20
add = 240,50,0
mul = 250,224,120
sinadd = 110,55,85,10
invertall = 1
color = 0

[State 0, ChangeAnim]
type = ChangeAnim
trigger1 = !time
value = ifelse(selfanimexist(5070),5070,0)
ignorehitpause = 1

[State 0, Gravity]
type = Gravity
trigger1 = 1
ignorehitpause = 1

[State 0, SelfState]
type = SelfState
trigger1 = vel y>=1
trigger1 = pos y>=0
value = 5100
ignorehitpause = 1

;廔椆張棟
[Statedef 1520]
type	= S
movetype= I
physics	= S
velset	= 0,0
ctrl	= 0
anim	= 1504
sprpriority = 3

[State 0, Explod]
type = Explod
triggerall=prevstateno=1511
trigger1 = !time
anim = 11500
pos = 30,0
postype = p2
bindtime = 1
removetime = -2
pausemovetime = 0
scale = 1,1
sprpriority = 999

[State 0, PlaySnd]
type = PlaySnd
triggerall=prevstateno=1511
trigger1 = !time
value = 11500,0
ignorehitpause = 1

[State 0, EnvShake]
type = EnvShake
triggerall=prevstateno=1511
trigger1 = !time
time = 17
time = 20
freq = 80
ampl = -40
ignorehitpause = 1

[State 1500, VelSet]
type	= VelSet
trigger1=prevstateno=1511
x = -8
[State 1500, VelSet]
type	= VelSet
triggerall=!time
trigger1=prevstateno=1511
y = -5

[State 0, Gravity]
type = Gravity
trigger1 = prevstateno=1511
ignorehitpause =1 

[State 1500, VelSet]
type	= VelSet
triggerall=prevstateno!=1511
trigger1 = Animelem = 1
x = -4
y = -2

[State 1500, VelSet]
type	= VelSet
triggerall=prevstateno!=1511
trigger1 = Animelem = 2
x = -4
y = -0

[State 1500, VelSet]
type	= VelSet
triggerall=prevstateno!=1511
trigger1 = Animelem = 3
x = -4
y =  1

[State 1500, VelSet]
type	= VelSet
triggerall=prevstateno!=1511
trigger1 = Animelem = 4
x = -4
y = 2

[State 1520 ,僶僀僋]
type = Explod
trigger1 = AnimElem = 1
anim = 1501
pos = 0,0
sprpriority = 5
ownpal = 1
bindtime = 1
supermove = 1
vel = 14,0
removetime = 120

[State 1520, end]
type = ChangeState
triggerall=vel y>=1
trigger1 = pos Y > 0
value = 52
ctrl = 1


;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僪儔僑儞僽儗僗
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

[Statedef 3100]
type = A
ctrl = 0
anim = 3100
velset = 0,0
movetype = A
physics = N
PowerAdd = -1500
sprpriority=4

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

[State -2, 杺朄恮僿儖僷乕屇傃弌偟]
type = Helper
trigger1= !time
name = "Magic Square"
stateno = 13101
ID = 13101
postype = p1
pos = -30,-90
size.xscale =0.5
size.yscale =0.5
sprpriority = 9999999
ownpal = 1
supermovetime=9999999

[State 3100,挻昁僄僼僃僋僩]
type = Explod
trigger1 = time = 1
anim = 8500
pos = 1, -110
sprpriority = 5
ownpal = 1
bindtime = 1
supermove = 1

[State 200, 1]
type = PlaySnd
trigger1 = Time = 0
value = 3000, 0
channel = 1

[State 200, 1]
type = PlaySnd
trigger1 = Time = 0
value = 3000, 4

[state 2000, 1]
type = PlaySnd
trigger1 = AnimElem = 5
value = 3000,1
channel = 2

[State 3150, Super A]
type = SuperPause
trigger1 = AnimElem = 1
movetime = 60
time = 60
anim = 30

[State 3150, 3]
type = ChangeState
trigger1 = AnimTime = 0
value = 3101

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僪儔僑儞僽儗僗忋徃
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

[Statedef 3101]
type = A
ctrl = 0
anim = 3101
velset = 0,0
movetype = A
physics = N
sprpriority=4

[State 0, VarAdd]
type = VarSet
trigger1 = !time
fvar(21) = 0
ignorehitpause = 1
[State 0, VarAdd]
type = VarSet
trigger1 = !time
fvar(22) = 0
ignorehitpause = 1

[State 200, 1]
type = PlaySnd
trigger1 = Time = 0
value = 3100, 1
volume=255

[State 230 , 1]
type = Velset
trigger1 = AnimElem = 1
y = -1

[State 231 , 1]
type = Velset
trigger1 = Pos y = -15
y = 0

[State 232 , 1]
type = ChangeAnim
trigger1 = Pos y <= -15
value = 3102
elem = 1

[State 3050 , 3]
type = ChangeState
trigger1 = time = 30
value = 3102

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 13101]
type	= S
anim	= 11000
velset	= 0,0
ctrl	= 0
sprpriority=3

[State 0, BindToRoot]
type = BindToRoot
trigger1 = 1 
pos = -30,-100
ignorehitpause = 1

[State 0, PalFXWiz]
type = PalFX
trigger1 =1 
time = 1
add = 7,-200,-200
mul = 256,256,256
sinadd = 30,30,0,10
invertall = 0
color = 0
invertall = 0
color = 256

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

[State 0, VarAdd]
type = VarSet
trigger1 = !time
fvar(1) = 10
ignorehitpause = 1

[State 0, AngleDraw]
type = AngleDraw
trigger1 = 1
scale = fvar(1),fvar(1)
ignorehitpause = 1 

[State 0, VarAdd]
type = VarSet
trigger1 = fvar(1)<1
fvar(1) = 1
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = fvar(1)>1
fvar(1) = -0.25
ignorehitpause = 1

[State 181]
type = trans
trigger1=1
trans = addalpha
alpha = (var(1)*8), 256
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = 1
var(1) = 1
ignorehitpause = 1

[State 0, ChangeState]
type = ChangeState
trigger1 = root,stateno!=[3100,3103]
value =99999
ignorehitpause = 1 

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僪儔僑儞僽儗僗懸婡
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

[Statedef 3102]
type = A
ctrl = 0
anim = 3102
velset = 0,0
movetype = A
physics = N
sprpriority=4

[State 3102 , 1]
type = ChangeState
trigger1 = AnimTime = 0
value = 3103

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僪儔僑儞僽儗僗敪幩
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 3103]
type    = A
movetype= A
physics = N
ctrl	= 0
anim	= 3103
velset	= 0,0
sprpriority=4

[State 0, VarSet]
type = VarSet
trigger1 = !time 
var(5) = 0
ignorehitpause = 1
[State 0, VarSet]
type = VarSet
trigger1 = var(5)>256
var(5) = 256
ignorehitpause = 1

[State 23000]
type = EnvShake
triggerall=time<=185
trigger1 = floor(GameTime%4) = 1
time = 5
ampl = -5
freq = 95
phase = 95

[State 0, Explod]
type = Explod
trigger1 = !time 
anim = 20001
ID = 20001
pos = 0,0
postype = back
removetime = 185
bindtime=-1
scale=1.01,1
ignorehitpause = 1

[State 0, ModifyExplod]
type = ModifyExplod
trigger1 =time<=184 
trigger1 =numexplod(20001)
ID =20001
trans=addalpha
alpha=var(6),256-var(6)
ignorehitpause = 1

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

[State 0, ModifyExplod]
type = ModifyExplod
trigger1 =time>184 
trigger1 =numexplod(20001)
ID =20001
trans=addalpha
alpha=256-var(6),var(6)
ignorehitpause = 1

[State 0, VarSet]
type = VarAdd
trigger1 = 1
var(6) = 25
ignorehitpause = 1

[State 0, PlaySnd]
type = PlaySnd
trigger1 = !time
value = 3100,0
ignorehitpause = 1

[State 0, Projectile]
type = Projectile
triggerall=time<=185
trigger1 = time%3=0
ProjID = 13103
projanim = 13103
projscale = 1,1
projhits=1
offset=-13,-155
projremove = 0
projremovetime = 45
ProjPriority=10
ProjSprPriority=999999
velocity = 15,2-(RANDOM%2)
attr=A,HP
damage		= 4,2
animtype	= Medium
hitflag= MAF
guardflag	= MA
pausetime	= 0, 2
sparkno		= S8010+(random%8)
guard.sparkno	= S8019
sparkxy		= 45,40
hitsound	= -1
guardsound	= -1
ground.type	= high
ground.slidetime= 14
ground.hittime	= 16
ground.velocity = -8,-2
air.velocity	= -2.5,-0.5
palfx.time	= 30
palfx.mul	= 240,220,128
palfx.sinadd	= 32,128,190,16
palfx.add	= 190,180,84
fall	= 1
fall.recover	= 0
getpower        = 0,0
givepower       = 10,10
ignorehitpause=1

[State 0, PlaySnd]
type = PlaySnd
trigger1 = time=185
value = 11500,0
ignorehitpause = 1

[State 0, Projectile]
type = Projectile
trigger1=time=185
ProjID = 11500
projanim = 11500
projscale = 2,2
projhits=1
postype=p2
offset=0,-80
projremove = 0
projremovetime = 49
ProjPriority=10
ProjSprPriority=999999
velocity = 0,0
attr=A,HP
damage		= 50,25
animtype	= Medium
hitflag= MAF
guardflag	= MA
pausetime	= 0, 12
sparkno		= S8010+(random%8)
guard.sparkno	= S8019
sparkxy		= -5,0
hitsound	= -1
guardsound	= -1
ground.type	= high
ground.slidetime= 14
ground.hittime	= 16
ground.velocity = -8,-2
air.velocity	= -2.5,-0.5
palfx.time	= 30
palfx.mul	= 240,220,128
palfx.sinadd	= 32,128,190,16
palfx.add	= 190,180,84
fall	= 1
fall.recover	= 0
getpower        = 0,0
givepower       = 10,10
ignorehitpause=1

[State 0, TargetState]
type = TargetState
triggerall=time>=185
triggerall = NumTarget
trigger1 = winko
value =3105
ignorehitpause = 1

[State 191,僎乕僩]
type = Explod
trigger1= time=185
id=20190
anim = 10194
pos = 0,-80
sprpriority = 999999
ownpal = 1
postype=p2
bindtime = 1
removetime=43
scale=0.001,0.001

[State 0, ModifyExplod]
type = ModifyExplod
trigger1 = numexplod(20190)
ID =20190
scale=fvar(21),fvar(21)
ignorehitpause = 1
trans = addalpha
alpha=256-((floor(fvar(22)))*5), 256

[State 0, VarAdd]
type = VarAdd
trigger1 = numexplod(20190)
fvar(21) = 0.05
ignorehitpause = 1
[State 0, VarAdd]
type = VarAdd
trigger1 = numexplod(20190)
fvar(22) = 1
ignorehitpause = 1

[State 2010]
type = EnvShake
trigger1 = time = 185
time = 20
freq = 60
ampl = -15

[State 10, AllPalFX]
type = AllPalFX
trigger1 = time=185
time = 5
add = 256,256,256
mul = 256,256,256
[State 10, AllPalFX]
type = AllPalFX
trigger1 = time>=190
time = 1
add = 256-(var(5)),256-(var(5)),256-(var(5))
mul = 256,256,256

[State 0, VarSet]
type = VarAdd
trigger1 = time>=190
var(5) = 12
ignorehitpause = 1

[State 3103,1]
type = ChangeState
trigger1 = time = 220
value = 3104

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僪儔僑儞僽儗僗棊壓
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;[Statedef 3104]
;type    = A
;movetype= A
;physics = N
;ctrl	= 0
;anim	= 3104
;velset	= 0,0

[Statedef 3104, 棊壓僗僥乕僩]
Type = A
MoveType = I
physics = A
velset = 0,0
Ctrl = 0
faceP2 = 0
Anim = 3104
sprPriority = 4

[State 0, ModifyExplod]
type = ModifyExplod
trigger1 = numexplod(20190)
ID =20190
scale=fvar(21),fvar(21)
ignorehitpause = 1
trans = addalpha
alpha=256-((floor(fvar(22)))*5), 256

[State 0, VarAdd]
type = VarAdd
trigger1 = numexplod(20190)
fvar(21) = 0.05
ignorehitpause = 1
[State 0, VarAdd]
type = VarAdd
trigger1 = numexplod(20190)
fvar(22) = 1
ignorehitpause = 1

[State 3104, 廔椆]
type = ChangeState
trigger1 = Pos Y >= 0
value = 0
ctrl = 1

[Statedef 3105]
Type = S
MoveType = H
physics = S
velset = 0,0
sprPriority = 4

[State 0, DestroySelf]
type = DestroySelf
trigger1 = ishelper
ignorehitpause = 1

[State 0, ScreenBound]
type = ScreenBound
trigger1 = 1
value = 0
ignorehitpause = 1

[State 0, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = invisible
flag2 = noshadow
ignorehitpause = 1

[State 0, AfterImageTime]
type = AfterImageTime
trigger1 =1 
time = 0
ignorehitpause = 1

[State 0, ChangeState]
type = ChangeState
trigger1 = !alive
value = 5150
ignorehitpause = 1

;---------------------------------------------------------------------------
; HIT_LIEDEAD
[Statedef 5150]
type    = L
movetype= H
physics = N
sprpriority = -3

[State 0, ScreenBound]
type = ScreenBound
trigger1 = prevstateno=3105
value = 0
ignorehitpause = 1

[State 0, AssertSpecial]
type = AssertSpecial
trigger1 = prevstateno=3105
flag = invisible
flag2 = noshadow
ignorehitpause = 1

[State 0, AfterImageTime]
type = AfterImageTime
trigger1 =prevstateno=3105 
time = 0
ignorehitpause = 1

[State 5150, 1] ;Normal anim
type = ChangeAnim
triggerall = Time = 0
triggerall = SelfAnimExist(5140)
trigger1 = (anim != [5111,5119]) && (anim != [5171,5179])
trigger2 = !SelfAnimExist(5140 + (anim % 10))
value = 5140

[State 5150, 3] ;Hit up type anim
type = ChangeAnim
trigger1 = Time = 0
trigger1 = (anim = [5111,5119]) || (anim = [5171,5179])
trigger1 = SelfAnimExist(5140 + (anim % 10))
value = 5140 + (anim % 10)

[State 5150, 4] ;Match over anim
type = ChangeAnim
persistent = 0
;trigger1 = Time = 0
trigger1 = MatchOver = 1
trigger1 = Anim = [5140,5149]
trigger1 = SelfAnimExist(anim+10)
value = anim+10

[State 5150, 5] ;Switch to 5110 if liedead anim does not exist
type = ChangeAnim
trigger1 = Time = 0
trigger1 = Anim != [5140,5159]
trigger1 = Anim != [5110,5119]
value = 5110

[State 5150, 6] ;Friction
type = VelMul
trigger1 = 1
x = 0.85

[State 5150, 7] ;Friction
type = VelSet
trigger1 = Vel x < .05
persistent = 0
x = 0

[State 5150, 8]
type = NotHitBy
trigger1 = 1
value = SCA
time = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僴儕働乕儞僩儖僱乕僪(壖徧)
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

[Statedef 3200]
type = A
ctrl = 0
anim = 3200
velset = 0,0
movetype = A
physics = N
PowerAdd = -1000
sprpriority=4

[State 3100,挻昁僄僼僃僋僩]
type = Explod
trigger1 = time = 0
anim = 8500
pos = 4, -72
sprpriority = 5
ownpal = 1
bindtime = 1
supermove = 1

[State 200, 1]
type = PlaySnd
trigger1 = Time = 0
value = 3200, 0
[State 200, 1]
type = PlaySnd
trigger1 = Time = 2
value = 3200, 1
channel=7

[State 3150, Super A]
type = SuperPause
triggerall=anim=3200
trigger1 = AnimElem = 1
movetime = 1
time = 60
anim = 30

[State 0, VelSet]
type = VelSet
trigger1 = time=2
y = -12
ignorehitpause =1 

[State 0, Explod]
type = Explod
trigger1 =time=2 
anim = 3203
ID = 3203
pos = 0,60
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
removetime = -1
scale = 1.3,1.3
sprpriority = 999
ownpal=1
removeongethit = 1
ignorehitpause =1

[State 0, RemoveExplod]
type = RemoveExplod
triggerall=vel y>0
trigger1 = numexplod(3203)
id = 3203
ignorehitpause = 1

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

[State 0, Explod]
type = Explod
trigger1 =vel y>0 
anim = 3204
ID = 3204
pos = 0,60
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
removetime = -2
scale = 1.3,1.3
sprpriority = 999
ownpal=1
persistent=0
removeongethit = 1
ignorehitpause =1

[State 210, 僸僢僩掕媊] 
type = HitDef
triggerall=hitcount<=14
trigger1 = time%2=0
attr = S, NA
damage    = 4,2
animtype  = Up
hitflag = MAF
guardflag = MA
pausetime = 0,0
sparkno = S8010
guard.sparkno = S8005
hitsound   = S1,4
guardsound = S6, 0 
sparkxy = -10,-60
ground.type = High
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -0.25,-6
air.velocity = -0.25,-6
getpower	= 3,4
givepower = 12,8

[State 210, 僸僢僩掕媊] 
type = HitDef
trigger1=hitcount=15
attr = S, NA
damage    = 150,75
animtype  = Up
hitflag = MAF
guardflag = MA
pausetime = 25,25
sparkno = S3205
guard.sparkno = S8005
hitsound   = S1,8 
guardsound = S6, 0 
sparkxy = -10,-60
ground.type = High
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -7,-4
air.velocity = -7,-4
getpower	= 3,4
givepower = 12,8
envshake.time = 25
envshake.ampl = 7
envshake.freq = 176
fall=1

[State -2, 杺朄恮僿儖僷乕屇傃弌偟]
type = Helper
trigger1= movehit
trigger1= var(48)!=hitcount
name = "Magic Square"
stateno = 3202
ID = 3202
size.xscale = 0.25
size.yscale = 0.25
postype = p2
pos = 10,-100
sprpriority = 9999999
ownpal = 1

[State 0, VarSet]
type = VarSet
trigger1 = movehit
var(48) = hitcount
ignorehitpause = 1

[State 0, EnvColor]
type = EnvColor
triggerall=movehit
trigger1=hitcount=16
value = 255,255,255
time = 2
persistent=0
ignorehitpause = 1

[State 0, Gravity]
type = Gravity
trigger1 = time>=3

[State 0, ChangeAnim]
type = ChangeAnim
triggerall=anim=3200
triggerall=time>=3
trigger1 = !numexplod(3204)
trigger1 = !numexplod(3203)
trigger1 = animelem=5
value = 3201

[State 3150, 3]
type = ChangeState
trigger1 = vel y>0
trigger1 = pos y>=0
value = 3201
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僴儕働乕儞僩儖僱乕僪(壖徧)
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

[Statedef 3201]
type = A
ctrl = 0
anim = 3202
velset = 0,0
movetype = A
physics = N
sprpriority=4

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

[State 4110, Explod]
type = Explod
trigger1=!time
anim = 10047
pos = 0,0
postype = P1
scale = .5,.5
sprpriority = -1
supermove=1
ownpal = 1

[State 10, PlaySnd]
type = PlaySnd
trigger1 = !time
value = S40,0

[State 10, PlaySnd]
type = PlaySnd
trigger1 = time=13
value = 10190,3

[State 0, PalFXWiz]
type = PalFX
trigger1 = time=[13,29]
time = 1
add = 256,0,0
mul = 256,256,256
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 4110, Explod]
type = Explod
trigger1=time=13
anim = 20004
pos = 0,-62
postype = P1
scale = .5,.5
sprpriority = 100000
supermove=1
ownpal = 1

[State 3150, 3]
type = ChangeState
trigger1 = !animtime
value = 0
ctrl=1

[Statedef 3202]
type	= S
anim	= 11150
velset	= 0,0
ctrl	= 0
sprpriority=999999

[State 0, VarRandom]
type = VarRandom
trigger1 = !time
v = 2
range = 0,359
ignorehitpause = 1

[State 0, PalFXWiz]
type = PalFX
trigger1 = 1
time = 1
add = -200,0,-200
mul = 256,256,256
sinadd = 40,80,40,10
invertall = 0
color = 0

[State 181]
type = trans
trigger1=1
trans = addalpha
alpha = (var(1)*25), 256
ignorehitpause = 1

[State 0, AngleDraw]
type = AngleDraw
trigger1 = 1
value=var(2)
scale = sysfvar(1),sysfvar(1)
ignorehitpause = 1

[state 686868]
type=varadd
trigger1=1
sysfvar(1)=0.5
ignorehitpause=1

[state 686868]
type=varadd
trigger1=1
var(1)=1
ignorehitpause=1

[State 0, DestroySelf]
type = DestroySelf
trigger1 = time=10
ignorehitpause = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;	僔儍僀僯儞僌僗僩儔僀僋
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

[Statedef 3300]
type = A
ctrl = 0
anim = 3300
velset = 0,0
movetype = A
physics = N
PowerAdd = -3000
sprpriority=4

[State 0, VarSet]
type = VarSet
trigger1 = !time
var(5) = 0
ignorehitpause = 1
[State 0, VarSet]
type = VarSet
trigger1 = !time
var(6) = 0
ignorehitpause = 1

[State 3100,挻昁僄僼僃僋僩]
type = Explod
trigger1 = time = 0
anim = 8500
pos = 7, -58
sprpriority = 5
ownpal = 1
bindtime = 1
supermove = 1

[State 200, 1]
type = PlaySnd
trigger1 = Time = 0
value = 20000, 0

[State 200, 1]
type = PlaySnd
trigger1 = Time = 0
value = 3300, 10

[State 200, 1]
type = PlaySnd
trigger1 = AnimElem = 2
value = 10000, 1

[State 0, VelSet]
type = VelSet
trigger1 = animelem=2 
x = 9
y = -4
ignorehitpause = 1

[State -2, Common Effect]
type = Explod
trigger1 = time=2
anim = 10105
facing = 1
pos = 0,5
scale = .55,.55
sprpriority = 0
bindtime=1
ownpal = 1
Supermovetime = -1

[State 3150, Super A]
type = SuperPause
trigger1 = AnimElem = 1
movetime = 1
time = 60
anim = -1

[State 210, 僸僢僩掕媊] 
type = HitDef
trigger1 = time=0
attr = S, NA
damage    = 0,75
animtype  = Hard
hitflag = MAF
pausetime = 0,0
sparkno = S8010
guard.sparkno = S8005
hitsound   = S1000,3
guardsound = S6, 0 
sparkxy = -10,-60
ground.type = High
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -10,-5
air.velocity = -10,-5
getpower	= 3,4
givepower = 12,8
fall=1
envshake.time = 15
envshake.ampl = 7
envshake.freq = 176
p2stateno=3304
sprpriority=99999

[State 0, TargetLifeAdd]
type = TargetLifeAdd
trigger1 = movehit
value = -150
ID = -1
persistent=0
kill=0
ignorehitpause = 1

[State 0, VarSet]
type = VarSet
trigger1 = movehit
var(5) = 1
ignorehitpause = 1

[State 0, Explod]
type = Explod
trigger1 =!numexplod(20001)
trigger1 =var(5)
anim = 20001
ID = 20001
pos = 0,0
postype = back
sprpriority=99997
removetime = -1
ownpal=1
bindtime=-1
scale=1.01,1
ignorehitpause = 1

[State 0, ModifyExplod]
type = ModifyExplod
trigger1 =numexplod(20001)
ID =20001
trans=addalpha
alpha=var(6),256-var(6)
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = var(5)
var(6) = 25
ignorehitpause =1 

[State 0, Gravity]
type = Gravity
trigger1 = time>=3

[State -2]
type = AssertSpecial
trigger1 = var(5)
trigger1 = numexplod(1234567)
flag = nomusic
flag2=nobardisplay
ignorehitpause = 1
supermovetime = 99999999
pausemovetime = 99999999

[State -2, 壒傪柭傜偡]
type = PlaySnd
trigger1 = var(5)
trigger1 = numexplod(1234567)
value = 3300,6
channel = 6
lowpriority = 6
ignorehitpause=1

[State 3150, 3]
type = ChangeState
triggerall=!numexplod(1234567)
trigger1 = vel y>0
trigger1 = pos y>=0
value = ifelse(var(5),3301,52)
[State 3150, 3]
type = ChangeState
triggerall=numexplod(1234567)
trigger1 = vel y>0
trigger1 = pos y>=0
value = ifelse(var(5),13301,52)

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

[Statedef 3301]
type = A
ctrl = 0
anim = 3301
velset = 0,0
movetype = A
physics = S
sprpriority=99999

[State 0, PlaySnd]
type = PlaySnd
trigger1 =!time 
value = S40,0
ignorehitpause = 1

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

[State 4110, Explod]
type = Explod
trigger1=!time
anim = 10047
pos = 0,0
postype = P1
scale = .5,.5
sprpriority = 99998
supermove=1
ownpal = 1

[State 0, Explod]
type = Explod
trigger1 =!numexplod(20001)
trigger1 = !time 
anim = 20001
ID = 20001
pos = 0,0
postype = back
sprpriority=99997
removetime = -1
bindtime=-1
ownpal=1
scale=1.01,1
ignorehitpause = 1

[State 0, ModifyExplod]
type = ModifyExplod
trigger1 =numexplod(20001)
ID =20001
trans=addalpha
alpha=var(6),256-var(6)
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = 1
var(6) = 25
ignorehitpause =1 

[State 0, PlaySnd]
type = PlaySnd
trigger1 = animelem=3
value = S3300,0

[State 0, PlaySnd]
type = PlaySnd
trigger1 = animelem=5
value = S20000,1

[State 0, PalFXWiz]
type = PalFX
triggerall=time<=107
trigger1 = animelemtime(4)>=15
time = 1 
add = (animelemtime(4)*3)-15,(animelemtime(4)*3)-15,(animelemtime(4)*3)-15
mul = 256,256,256
sinadd = 0,0,0,1
invertall = 0
color = 256

[State 4110, Explod]
type = Explod
trigger1=animelem=5
anim = 3304
pos = 9,-82
postype = P1
scale = .5,.5
sprpriority = 100000
supermove=1
ownpal = 1

[State 0, ChangeState]
type = ChangeState
trigger1 = !animtime
value = 3302
ignorehitpause = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

[Statedef 3302]
type = A
ctrl = 0
anim = 3302
velset = 0,0
movetype = A
physics = N
sprpriority=99999

[State 0, TargetState]
type = TargetState
triggerall = NumTarget
trigger1 = !time
value =3305
ignorehitpause = 1

[State 0, ScreenBound]
type = ScreenBound
trigger1 = 1
value = 0
ignorehitpause = 1

[State 0, PosSet]
type = PosSet
trigger1 = !time
x = ifelse(facing=-1,250,-250)
y = -100
ignorehitpause =1 

[State 0, PlaySnd]
type = PlaySnd
trigger1 = !time
value = 3300,3
volumescale = 0
ignorehitpause = 1

[State 0, VelSet]
type = VelSet
trigger1=time>=90
x = 25
y = 15
ignorehitpause = 1

[State 0, EnvShake]
type = EnvShake
trigger1 = vel y>0
trigger1 = pos y>=0
time = 17
time = 20
freq = 80
ampl = -40
ignorehitpause = 1

[State 0, ModifyExplod]
type = RemoveExplod
trigger1 =numexplod(20001)
trigger1 = vel y>0
trigger1 = pos y>=0
ID =20001

[State 0, TargetLifeAdd]
type = TargetLifeAdd
triggerall = NumTarget
trigger1 = vel y>0
trigger1 = pos y>=0
value = -350
ID = -1
ignorehitpause = 1

[State 0, TargetState]
type = TargetState
triggerall = NumTarget
trigger1 = vel y>0
trigger1 = pos y>=0
value =3010
ignorehitpause = 1

[State 0, ChangeState]
type = ChangeState
trigger1 = vel y>0
trigger1 = pos y>=0
value = 3303
ignorehitpause = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

[Statedef 3303]
type = A
ctrl = 0
anim = 3303
velset = 0,0
movetype = A
physics = N
sprpriority=4

[State 0, PalFXWiz]
type = AllPalFX
trigger1 = time<=17
time = 1
add = 256-(time*15),256-(time*15),256-(time*15)
mul = 256,256,256
sinadd = 0,0,0,1
invertall = 0
color = 256

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

[State 0, StopSnd]
type = StopSnd
triggerall=prevstateno=13302
trigger1 = !time
channel = 6
ignorehitpause = 1

[State 0, PosSet]
type = PosSet
triggerall=facing=1
triggerall=prevstateno=13302
trigger1 = !time
x = -60
ignorehitpause = 1

[State 0, PosSet]
type = PosSet
triggerall=facing=-1
triggerall=prevstateno=13302
trigger1 = !time
x = 60
ignorehitpause = 1

[State 0, PlaySnd]
type = PlaySnd
trigger1 = !time
value = S11500,0
ignorehitpause = 1

[State 0, Explod]
type = Explod
trigger1 = !time
anim = 3305
ID = 3305
pos = 0,0
postype = back
bindtime = -1
removetime = -2
scale=.5,.5
sprpriority = 999999

[State 0, Explod]
type = Explod
trigger1 = !time
anim = 3307
ID = 3305
pos = 134,30
postype = p1
bindtime = -1
removetime = -2
sprpriority = 999998

[State 4110, Explod]
type = Explod
trigger1=!animtime
anim = 20004
pos = 9,-82
postype = P1
scale = .5,.5
sprpriority = 100000
supermove=1
ownpal = 1

[State 0, PosSet]
type = PosSet
trigger1=!animtime
y = -20
ignorehitpause = 1

[State 0, PlaySnd]
type = PlaySnd
trigger1=!animtime
value = S10190,3
ignorehitpause = 1

[State 0, ChangeState]
type = ChangeState
trigger1 = !animtime
value = 50
ignorehitpause = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 3304]
type    = A
MoveType= H
physics = N
ctrl = 0
velset = 0,0
sprpriority=99999

[State 0, VelSet]
type = VelSet
trigger1 = 1
x = -20
ignorehitpause = 1

[State 802, 憡庤偺傾僯儊曄峏]
type = ChangeAnim2
trigger1 = Time = 0
value = 3306

[State 802, 夋柺屌掕]
type = ScreenBound
trigger1 = 1
value = 0

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 3305]
type    = A
MoveType= H
physics = N
ctrl = 0
velset = 0,0
sprpriority=99999

[State 0, VelSet]
type = PosSet
trigger1 = 1
x = 0
ignorehitpause = 1

[State 802, 憡庤偺傾僯儊曄峏]
type = ChangeAnim2
trigger1 = Time = 0
value = 3306

[State 802, 夋柺屌掕]
type = ScreenBound
trigger1 = 1
value = 0

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

[Statedef 13301]
type = A
ctrl = 0
anim = 13301
velset = 0,0
movetype = A
physics = S
sprpriority=99999

[State -2]
type = AssertSpecial
trigger1 = 1
flag = nomusic
flag2=nobardisplay
ignorehitpause = 1
supermovetime = 99999999
pausemovetime = 99999999

[State 0, VelSet]
type = VelSet
trigger1 = time<581
x = -0.25
ignorehitpause = 1

[State 0, ScreenBound]
type = ScreenBound
trigger1 = 1
value = 0
ignorehitpause = 1

[State 0, AngleDraw]
type = AngleDraw
trigger1 = 1
scale = 2,2
ignorehitpause = 1

[State 0, PosSet]
type = PosSet
triggerall=facing=1
trigger1 = !time
x=60
y = 80
ignorehitpause = 1
[State 0, PosSet]
type = PosSet
triggerall=facing=-1
trigger1 = !time
x=-60
y = 80
ignorehitpause = 1

[State 0, PlaySnd]
type = PlaySnd
trigger1 =!time 
value = S40,0
ignorehitpause = 1

[State 4110, Explod]
type = Explod
trigger1=!time
anim = 10047
pos = 0,0
postype = P1
scale = .5,.5
sprpriority = 99998
supermove=1
ownpal = 1

[State 0, Explod]
type = Explod
trigger1 =!numexplod(20001)
trigger1 = !time 
anim = 20001
ID = 20001
pos = 0,0
postype = back
sprpriority=99997
removetime = -1
bindtime=-1
ownpal=1
scale=1.01,1
ignorehitpause = 1

[State 0, ModifyExplod]
type = ModifyExplod
trigger1 =numexplod(20001)
ID =20001
trans=addalpha
alpha=var(6),256-var(6)
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = 1
var(6) = 25
ignorehitpause =1 

[State 0, PalFXWiz]
type = PalFX
triggerall=time<=311
trigger1 = animelemtime(4)>=15
time = 1 
add = (animelemtime(4))-15,(animelemtime(4))-15,(animelemtime(4))-15
mul = 256,256,256
sinadd = 0,0,0,1
invertall = 0
color = 256

[State -2, 杺朄恮屇傃弌偟]
type = Helper
trigger1 = animelemtime(5)=90
name = "Wizar-D"
stateno = 13305
ID = 13305
size.xscale = 2
size.yscale = 2
facing=-1
postype = front
pos = 180,0
ownpal = 1

[State 0, PlaySnd]
type = PlaySnd
trigger1 = animelem=5
value = S20000,1
volume=255

[State 4110, Explod]
type = Explod
trigger1=animelem=5
anim = 3304
pos = 18,-162
postype = P1
bindtime=-1
sprpriority = 100000
supermove=1
ownpal = 1

[State 4110, Explod]
type = Explod
trigger1=animelem=6
anim = 3304
pos = -36,-202
postype = P1
bindtime=-1
sprpriority = 100000
supermove=1
ownpal = 1

[State 0, PlaySnd]
type = PlaySnd
trigger1 = animelem=3
value = S3300,1
volume=255

[State -2, 杺朄恮屇傃弌偟]
type = Helper
trigger1 = animelem=4
name = "Magic Square"
stateno = 13303
ID = 13303
size.xscale = 1
size.yscale = 1
postype = p1
pos = 10,0
ownpal = 1

[State 0, PlaySnd]
type = PlaySnd
trigger1 = animelem=6
value = S3300,2
volume=255
[State 0, PlaySnd]
type = PlaySnd
trigger1 = animelem=7
value = S3300,3
volume=255

[State 191,僎乕僩]
type = Explod
trigger1= AnimElem = 7
id=20190
anim = 3308
pos = -36,-202
sprpriority = 100000
ownpal = 1
postype=p1
bindtime = -1
removetime=43
scale=0.001,0.001

[State 0, ModifyExplod]
type = ModifyExplod
trigger1 = numexplod(20190)
ID =20190
scale=fvar(21),fvar(21)
ignorehitpause = 1
trans = addalpha
alpha=256-((floor(fvar(22)))*15), 256

[State 0, VarAdd]
type = VarSet
trigger1 = !time
fvar(21) = 0
ignorehitpause = 1
[State 0, VarAdd]
type = VarSet
trigger1 = !time
fvar(22) = 0
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
triggerall=fvar(21)<=0.25
trigger1 = numexplod(20190)
fvar(21) = 0.05
ignorehitpause = 1
[State 0, VarAdd]
type = VarAdd
triggerall=fvar(21)>0.125
trigger1 = numexplod(20190)
fvar(21) = -0.001
ignorehitpause = 1
[State 0, VarAdd]
type = VarAdd
trigger1 = numexplod(20190)
fvar(22) = 1
ignorehitpause = 1

[State 0, RemoveExplod]
type = RemoveExplod
trigger1 =numexplod(20001)
trigger1 = animelemtime(7)=30
id = 20001
ignorehitpause =1 

[State 0, Explod]
type = Explod
trigger1 = animelemtime(7)=30
anim = 20002
ID = 20001
pos = 0,0
postype = back
sprpriority=99997
removetime = -1
bindtime=-1
ownpal=1
scale=1.01,1
ignorehitpause = 1

[State 0, VelAdd]
type = VelAdd
trigger1 = animelemtime(7)>=30
x = -2
y = 1
ignorehitpause = 1

[State 0, ChangeState]
type = ChangeState
trigger1 = !animtime
value =13302
ignorehitpause = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

[Statedef 13302]
type = A
ctrl = 0
anim = 13302
velset = 0,0
movetype = A
physics = S
sprpriority=99999

[State 0, AssertSpecial]
type = AssertSpecial
trigger1 = !time
flag = invisible
ignorehitpause = 1

[State 0, VelSet]
type = PosSet
triggerall=facing=1
trigger1 = !time
x = -220
y = 170
ignorehitpause = 1
[State 0, VelSet]
type = PosSet
triggerall=facing=-1
trigger1 = !time
x = 220
y = 170
ignorehitpause = 1

[State -2]
type = AssertSpecial
trigger1 = 1
flag = nomusic
flag2=nobardisplay
ignorehitpause = 1
supermovetime = 99999999
pausemovetime = 99999999

[State 0, VelSet]
type = VelSet
trigger1 = time=[0,4]
x = 20
y=-7
ignorehitpause = 1
[State 10, VelAdd]
type = VelAdd
trigger1 = vel y<0
y = 0.6
ignorehitpause = 1
[State 0, VelAdd]
type = VelSet
trigger1 = vel x<=0.5
x = 0.5
ignorehitpause = 1
[State 0, VelAdd]
type = VelSet
trigger1 = vel y>=-0.2
y = -0.2
ignorehitpause = 1

[State 0, PlaySnd]
type = PlaySnd
trigger1 = !time
value = S3300,4
volume=255

[State 0, ScreenBound]
type = ScreenBound
trigger1 = 1
value = 0
ignorehitpause = 1

[State 0, AngleDraw]
type = AngleDraw
trigger1 = 1
scale = 2,2
ignorehitpause = 1

[State 0, PlaySnd]
type = PlaySnd
trigger1 = time=102
value = S3300,5
channel=5
[State 0, PlaySnd]
type = PlaySnd
trigger1 = time=102+148
value = S3000,3

[State 4110, Explod]
type = Explod
trigger1=time=102
anim = 13304
pos = 0,0
postype = back
sprpriority = 100000
removetime=180
ownpal = 1
[State 4110, Explod]
type = Explod
trigger1=time=102
anim = 13303
pos = 0,0
postype = back
scale = .5,.5
sprpriority = 100001
scale=1.01,1
ownpal = 1

[State 0, ModifyExplod]
type = RemoveExplod
trigger1 =numexplod(20001)
trigger1 = time=102+180
ID =20001

[State 10, VarSet]
type = VarSet
triggerall=numtarget
triggerall=target,const(data.defence)<100
trigger1 = !ishelper
var(50) = 350
ignorehitpause = 1
[State 10, VarSet]
type = VarSet
triggerall=numtarget
triggerall=target,const(data.defence)>=100
trigger1 = !ishelper
var(50) = 350-((target,const(data.defence)-100)*10)
ignorehitpause = 1
[State 10, VarSet]
type = VarSet
triggerall=numtarget
triggerall=target,const(data.defence)>=100
triggerall=!var(50)
trigger1 = !ishelper
var(50) = 1
ignorehitpause = 1

[State 0, ChangeState]
type = ChangeState
triggerall = time=102+180
triggerall=numenemy=1
trigger1 = target,life<=var(50)
value = 23300
ignorehitpause = 1
[State 0, ChangeState]
type = ChangeState
triggerall = time=102+180
triggerall=numenemy=2
trigger1=target,id=enemy(0),id
trigger1=enemy(1),alive=0
trigger1 =target,life<=var(50)
trigger2=target,id=enemy(1),id
trigger2=enemy(0),alive=0
trigger2 =target,life<=var(50)
value = 23300
ignorehitpause = 1

[State 0, TargetLifeAdd]
type = TargetLifeAdd
triggerall = NumTarget
trigger1 = time=102+180
value = -350
ID = -1
ignorehitpause = 1

[State 0, TargetState]
type = TargetState
triggerall = NumTarget
trigger1 = time=102+180
value =3010
ignorehitpause = 1

[State 0, ChangeState]
type = ChangeState
trigger1 = time=102+180
value = 3303
ignorehitpause = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 13303]
type	= S
anim	= 11150
velset	= 0,0
ctrl	= 0
sprpriority=999999

[State -2, 杺朄恮屇傃弌偟]
type = Helper
trigger1 = !time
name = "Wizar-D"
stateno = 13304
ID = 13304
size.xscale = 2
size.yscale = 2
postype = p1
pos = -20,120
ownpal = 1

[State 0, VelSet]
type = VelSet
trigger1 = 1
x = -0.25
ignorehitpause = 1

[State 181]
type = trans
trigger1=1
trans = addalpha
alpha = var(1)*10, 256
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = 1
var(1) = 1
ignorehitpause = 1

[State 0, AngleDraw]
type = AngleDraw
trigger1 = 1
scale = fvar(1),fvar(1)
ignorehitpause = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = fvar(1)<1
fvar(1) = 0.04
ignorehitpause = 1
[State 0, VarAdd]
type = VarSet
trigger1 = fvar(1)>=1
fvar(1) = 1
ignorehitpause = 1
[State 0, VarAdd]
type = VarAdd
trigger1 = fvar(1)=1
fvar(2) = 1
ignorehitpause = 1
[State 0, VelSet]
type = VelSet
trigger1 = fvar(2)>=30
y = -1.3
ignorehitpause = 1 

[State 0, ChangeState]
type = ChangeState
trigger1 = time=264
value =99999
ignorehitpause =1 
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 13304]
type	= S
anim	= 13305
velset	= 0,0
ctrl	= 0
sprpriority=999999

[State 23000]
type = EnvShake
trigger1 = floor(GameTime%4) = 1
time = 5
ampl = -5
freq = 95
phase = 95

[State 0, VelSet]
type = VelSet
trigger1 = 1
y = -13
ignorehitpause =1 

[State 100]
Type           = Afterimage
Trigger1       = Time = 0
Trans          = Add
TimeGap        = 2
FrameGap       = 3
Time           = 70
PalBright      = 0, 0, 0
PalContrast    = 70, 70, 70
PalAdd         = 0, 0, 0
PalMul         = 1, 1, 1

[State 0, PlaySnd]
type = PlaySnd
trigger1 = !time 
value = S3300,9
ignorehitpause = 1

[State 0, DestroySelf]
type = DestroySelf
trigger1 = time=70
ignorehitpause = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 13305]
type	= S
anim	= 13306
velset	= 0,0
ctrl	= 0
sprpriority=999999

[State 0, VelSet]
type = VelSet
trigger1 = 1
x = 13
ignorehitpause =1 

[State 100]
Type           = Afterimage
Trigger1       = Time = 0
Trans          = Add
TimeGap        = 2
FrameGap       = 3
Time           = 70
PalBright      = 0, 0, 0
PalContrast    = 70, 70, 70
PalAdd         = 0, 0, 0
PalMul         = 1, 1, 1

[State 0, PlaySnd]
type = PlaySnd
trigger1 = !time 
value = S3300,9
ignorehitpause = 1

[State 0, DestroySelf]
type = DestroySelf
trigger1 = rootdist x<=0
ignorehitpause = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

[Statedef 23300]
type = A
ctrl = 0
anim = 20000
velset = 0,0
movetype = A
physics = S
sprpriority=99999

[State 0, StopSnd]
type = StopSnd
trigger1 = !time
channel = 5
ignorehitpause = 1

[State 0, EnvShake]
type = EnvShake
trigger1 =!time
time = 25
freq = 176
ampl = 7
ignorehitpause = 1

[State -2]
type = AssertSpecial
trigger1 = 1
flag = nomusic
flag2=nobardisplay
ignorehitpause = 1
supermovetime = 99999999
pausemovetime = 99999999

[State 0, TargetState]
type = TargetState
triggerall = NumTarget;()
trigger1 = !time
value =23301
ignorehitpause = 1

[State 0, PlaySnd]
type = PlaySnd
trigger1 =!time 
value = S3300,7
ignorehitpause = 1

[State 4110, Explod]
type = Explod
trigger1=!time
anim = 23300
pos = 8,-111
postype = P2
facing=-1
scale=2,2
sprpriority = 100000
supermove=1
ownpal = 1

[State 0, Explod]
type = Explod
trigger1 = !time 
anim = 20003
ID = 20003
pos = 0,0
postype = back
sprpriority=99997
removetime = -1
bindtime=-1
ownpal=1
scale=1.01,1
ignorehitpause = 1

[State 0, TargetLifeAdd]
type = TargetLifeAdd
trigger1 = time=100
value = -350
ignorehitpause = 1

[State 4110, Explod]
type = Explod
trigger1=time=100
anim = 11500
id=11500
pos = 38,-172
postype = P2
sprpriority = 100000
supermove=1
ownpal = 1
[State 4110, Explod]
type = Explod
trigger1=time=122
anim = 11500
id=11500
pos = 36,-74
postype = P2
sprpriority = 100000
supermove=1
ownpal = 1

[state 3020, 1]
type = allpalfx
trigger1 = time=122
time = 48
add = 0,0,0
sinadd = 255,255,255,90
ignorehitpause=1

[State 0, EnvShake]
type = EnvShake
trigger1 = time=100
trigger2 = time=122
time = 25
freq = 176
ampl = 11
ignorehitpause = 1

[State 0, PlaySnd]
type = PlaySnd
trigger1 = time=100
trigger2 = time=122
value=11500,0

[State 0, TargetState]
type = TargetState
triggerall = NumTarget
trigger1 =time=122+24
value = 23303
ignorehitpause = 1

[State 0, ChangeState]
type = ChangeState
trigger1 = time=122+24
value =23302
ignorehitpause = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 23301]
type    = A
MoveType= H
physics = N
ctrl = 0
velset = 0,0
sprpriority=99999

[State 0, AngleDraw]
type = AngleDraw
trigger1 = 1
scale = 2,2
ignorehitpause = 1

[State 0, VelSet]
type = PosSet
trigger1 = !time
x = 0
y = 50
ignorehitpause = 1

[State 0, VelSet]
type = VelSet
trigger1 = 1
x = -0.2
y = -0.1
ignorehitpause = 1

[State 802, 憡庤偺傾僯儊曄峏]
type = ChangeAnim2
trigger1 = Time = 0
value = 23301

[State 802, 夋柺屌掕]
type = ScreenBound
trigger1 = 1
value = 0

[Statedef 23302]
type = A
ctrl = 0
anim = 23302
velset = 0,0
movetype = A
physics = S
sprpriority=99999

[State 0, StopSnd]
type = StopSnd
triggerall=roundstate<=2
trigger1 = !time
channel = 6
ignorehitpause = 1

[State -2]
type = AssertSpecial
trigger1 = roundstate>2
flag = nomusic
flag2=nobardisplay
ignorehitpause = 1
supermovetime = 99999999
pausemovetime = 99999999

[State 0, RemoveExplod]
type = RemoveExplod
trigger1 = numexplod(20003)
id = 20003
ignorehitpause = 1
[State 0, RemoveExplod]
type = RemoveExplod
trigger1 = numexplod(11500)
id = 11500
ignorehitpause = 1

[State 10000];敾掕
type = Projectile
triggerall=roundstate>=3
triggerall=numprojid(56789)=0
trigger1 =!ishelper
projid=56789
projanim = 20000
projremove = 0
projremovetime = -1
ignorehitpause=1

[State 0, Explod]
type = Explod
triggerall=roundstate>=3
trigger1 = !time 
anim = 20001
ID = 20001
pos = 0,0
postype = back
sprpriority=99997
removetime = -1
bindtime=-1
ownpal=1
scale=1.01,1
ignorehitpause = 1

[State 0, PosSet]
type = PosSet
trigger1 = !time
x = ifelse(facing=-1,60,-60)
y = 0
ignorehitpause =1 

[State 0, ChangeState]
type = ChangeState
trigger1 = time=60
value = 0
ctrl = 1
ignorehitpause = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
[Statedef 23303]
type    = A
MoveType= H
physics = N
ctrl = 0
velset = 0,0
sprpriority=99999

[State 0, ChangeState]
type = ChangeState
trigger1 = 1
value =ifelse(alive,3010,3105)
ignorehitpause = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;		僴僀僷乕傾乕儅乕梡僿儖僷乕
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

[Statedef 9000]; 傾乕儅乕敾掕僿儖僷乕
type = A
movetype = I
physics = N

[State 9000, 0]; 晄嬶崌懳嶔
type = ChangeState
trigger1 = !IsHelper
value = 0
ctrl = 1

[State 9000, 0]; 傾乕儅乕壔偟偨弖娫偵廳暋旐抏偟側偄偨傔偺柍揋
type = NotHitBy
trigger1 = Time = 0
value = SCA
time = 1

[State 9000, 0]; 搳偘柍揋
type = NotHitBy
trigger1 = Time >= 1
value = ,AT
time = 2

[State 9000, 0]; 摟柧亄塭徚偟
type = AssertSpecial
trigger1 = 1
flag = Invisible
flag2 = NoShadow

[State 9000, 0]; 杮懱偵捛廬
type = BindToParent
trigger1 = 1
time = 1
facing = 1
pos = 0,0

[State 9000, 0]; 敾掕傪懙偊傞
type = ChangeAnim
trigger1 = SelfAnimExist(Parent,Anim)
value = Parent,Anim
elem = Parent,AnimElemNo(0)

[State 9000, 0]; 懪寕乛旘傃摴嬶傪庴偗偨傜僗僥乕僩傪孞傝曉偡
type = HitOverRide
trigger1 = IsHelper(9000)
attr = SCA,AA,AP
stateno = 9000

[State 9000, 0]; 杮懱偑傾乕儅乕僷乕僩傪夁偓偨傜徚柵
type = DestroySelf
trigger1= Parent,StateNo !=[3501,3505]

;---------------------------------------------------------------------------
; RUN_BACK2 (land)
[Statedef 106]
type    = S
physics = S
ctrl = 0
anim = 47

[State 106, 1]
type = VelSet
trigger1 = Time = 0
y = 0

[State 106, 2]
type = PosSet
trigger1 = Time = 0
y = 0

[State 4110, Explod]
type = Explod
trigger1=time=2
anim = 10047
pos = -10,0
postype = P1
scale = .5,.5
sprpriority = -1
supermove=1
ownpal = 1

[State 106, 4]
type = ChangeState
trigger1 = Time = 7
value = 0
ctrl = 1

;---------------------------------------------------------------------------
; Jump Land
[Statedef 52]
type    = S
physics = S
ctrl = 0
anim = 47

[State 4110, Explod]
type = Explod
trigger1=time=1
anim = 10047
pos = 0,0
postype = P1
scale = .5,.5
sprpriority = -1
supermove=1
ownpal = 1

[State 52, 1]
type = VelSet
trigger1 = Time = 0
y = 0

[State 52, 2]
type = PosSet
trigger1 = Time = 0
y = 0

[State 52, 3]
type = CtrlSet
triggerall=roundstate<=2
trigger1 = Time = 3
value = 1

[State 52, 4]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;		忢帪娔帇僗僥乕僩乮Statedef -2)
;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

[Statedef -2]

[State 10, VarSet]
type = VarSet
triggerall=numtarget
triggerall=target,const(data.defence)<100
trigger1 = !ishelper
var(51) = 500
ignorehitpause = 1
[State 10, VarSet]
type = VarSet
triggerall=numtarget
triggerall=target,const(data.defence)>=100
trigger1 = !ishelper
var(51) = 500-((target,const(data.defence)-100)*10)
ignorehitpause = 1
[State 10, VarSet]
type = VarSet
triggerall=numtarget
triggerall=target,const(data.defence)>=100
triggerall=!var(51)
trigger1 = !ishelper
var(51) = 1
ignorehitpause = 1

[State 10, Explod];儘儞僌斉敾掕
type = Explod
triggerall=!ishelper
triggerall=!numexplod(1234567)
trigger1=var(52)=1
trigger2=var(52)>=2
trigger2=var(51)
trigger2=numenemy=1
trigger2=numtarget
trigger2=target,life<=var(51)
anim = 20000
id=1234567
pos = 0,0
ontop=1
postype = back  ;p2,front,back,left,right
bindtime = -1
removetime = -1
ignorehitpause =1
[State 10, Explod];儘儞僌斉敾掕
type = Explod
triggerall=var(51)
triggerall=!ishelper
triggerall=!numexplod(1234567)
triggerall=var(52)>=2
triggerall=numenemy=2
triggerall=numtarget
trigger1=target,id=enemy(0),id
trigger1=enemy(1),alive=0
trigger1 =target,life<=var(51)
trigger2=target,id=enemy(1),id
trigger2=enemy(0),alive=0
trigger2 =target,life<=var(51)
anim = 20000
id=1234567
pos = 0,0
ontop=1
postype = back  ;p2,front,back,left,right
bindtime = -1
removetime = -1
ignorehitpause =1

[State 0, RemoveExplod]
type = RemoveExplod
triggerall=var(52)>=2
triggerall=!ishelper
triggerall = numexplod(1234567)
triggerall=numenemy=1
triggerall=numtarget
trigger1=target,life>var(51)
id = 1234567
ignorehitpause = 1
[State 0, RemoveExplod]
type = RemoveExplod
triggerall=var(52)>=2
triggerall=!ishelper
triggerall = numexplod(1234567)
triggerall=numenemy=2
triggerall=numtarget
trigger1=target,id=enemy(0),id
trigger1=enemy(1),alive=0
trigger1 =target,life>var(51)
trigger2=target,id=enemy(1),id
trigger2=enemy(0),alive=0
trigger2 =target,life>var(51)
id = 1234567
ignorehitpause = 1

[State 0, DisplayToClipboard]
type = DisplayToClipboard
trigger1 = !ishelper
text = "p2dx = %f  p2dy = %f"
params = p2bodydist x,p2bodydist y
ignorehitpause = 1

[State 191, 僗僀僢僠]
type	= StopSnd
triggerall=!ishelper
triggerall=roundstate=2
trigger1= var(20)
channel	= 8
ignorehitpause=1

[State 0, VarSet]
type = VarSet
triggerall=!ishelper
triggerall=roundstate=2
trigger1= var(20)
var(20) = 0
ignorehitpause =1 

;劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒
;---------------------[僟儊乕僕曗惓]
[State -2];曗惓
type = AttackMulSet
trigger1 = 1
value = 1*fvar(1)
ignorehitpause = 1

[State -2];曗惓
type = Varset
trigger1 = fvar(1) < 0
fv = 1
value = 0
ignorehitpause = 1

;---------------------[曗惓抣偺弶婜壔]
 [State -2];曗惓
type = Varset
trigger1 = enemy,movetype != H
trigger2 = enemy,stateno = [120,155]
fv = 1
value = 1
ignorehitpause = 1

[State -2, 僄僼僃僋僩傪徚偡];僷儚乕棴傔僗僥乕僩梡
type = RemoveExplod
triggerall = NumExplod(10005) > 0
trigger1 = StateNo !=905
trigger2 = MoveType != I
ID = 10005



[State -2, Landing Sound]
type	= PlaySnd
triggerAll = time = 1
trigger1 = StateNo = 52 
trigger2 = StateNo = 106 
trigger3 = StateNo = 1102
trigger4 = StateNo = 1112
trigger5 = StateNo = 3015
value = 40, 0

;巆憸徚嫀
[State -2]
type = AfterImageTime
trigger1 = StateNo = 52 || StateNo = 154|| StateNo = 3419|| StateNo = 3009;擇抜僕儍儞僾偺僗僥乕僩側偳偑偁傟偽捛壛偟偰偔偩偝偄
trigger2 = MoveType = H
time = 0

[State -2]
type = RemoveExplod
trigger1 = NumProjID(1200) = 0
id = 1250

[State -2]
type = RemoveExplod
trigger1 = NumProjID(1201) = 0
id = 1259

;-------------------------------------------------------------------------
;僴僀僷乕傾乕儅乕張棟
;-------------------------------------------------------------------------

;僇僠僪僉傾乕儉僘幐攕帪偺儃僀僗僗僩僢僾
[State -2, stop僒僂儞僪]
type	= stopSnd
trigger1 = prevstateno = 3500
trigger1 = StateNo != [3500,3504]
channel = 10


[State -2, 傾乕儅乕僿儖僷乕屇傃弌偟]
type = Helper
triggerall = !NumHelper(9000) && MoveType != H
trigger1 = StateNo = 3501
name = "Armor"
stateno = 9000
ID = 9000
size.xscale = 1
size.yscale = 1
postype = p1
pos = 0,0
ownpal = 1
supermovetime = 99999
pausemovetime = 99999

[State -2, 傾乕儅乕拞偺搳偘埲奜柍揋]
type = NotHitBy
trigger1 = NumHelper(9000)
value2 = ,AA,AP
time = 2

[State -2, 傾乕儅乕拞偵旐抏偟偨帪偺柍揋帪娫墑挿乮俀廳旐抏梷惂張抲乯]
type = NotHitBy
trigger1 = NumHelper(9000)
trigger1 = Helper(9000),GetHitVar(damage)
value = SCA
time = Helper(9000),GetHitVar(hitshaketime)+5

[State -2, 傾乕儅乕庴偗偟偨帪偺揰柵]
type = PalFX
trigger1 = NumHelper(9000)
trigger1 = Helper(9000),GetHitVar(damage)
time = 5
add = 256,10,10

[State -2, 傾乕儅乕庴偗偟偨帪偺儔僀僼尭彮]
type = LifeAdd
trigger1 = NumHelper(9000)
trigger1 = Helper(9000),GetHitVar(damage)
value = -0.2*Helper(9000),GetHitVar(damage)
absolute = 1
ignorehitpause = 1

