[Data]
life = 1000
power = 10000
attack = 100
defence = 100
fall.defence_up = 50
liedown.time = 60
airjuggle = 15
sparkno = 2
guard.sparkno = 40
KO.echo = 0
volume = 255
IntPersistIndex = 60
FloatPersistIndex = 40

[Size]
xscale = 0.5		 ;Horizontal scaling factor.
yscale = 0.5		 ;Vertical scaling factor.
ground.back = 8		 ;Player width (back, ground)
ground.front = 8	 ;Player width (front, ground)
air.back = 8		 ;Player width (back, air)
air.front = 8		 ;Player width (front, air)
height = 20		 ;Height of player (for opponent to jump over)
attack.dist = 100	 ;Default attack distance
proj.attack.dist = 100	 ;Default attack distance for projectiles
proj.doscale = 0	 ;Set to 1 to scale projectiles too
head.pos = 0,-15	 ;Approximate position of head
mid.pos = 0,-5		 ;Approximate position of midsection
shadowoffset = 0	 ;Number of pixels to vertically offset the shadow
draw.offset = 0,0	 ;Player drawing offset in pixels (x, y)

[Velocity]
walk.fwd  = 2.0		 ;Walk forward
walk.back = -2.0	 ;Walk backward
run.fwd  = 4.5,0	 ;Run forward (x, y)
run.back = -4.5,0	 ;Hop backward (x, y)
jump.neu = 0,-7.5	 ;Neutral jumping velocity (x, y)
jump.back = -2.0	 ;Jump back Speed (x, y)
jump.fwd = 2.0		 ;Jump forward Speed (x, y)
runjump.back = -2.0,-7.5 ;Running jump speeds (opt)
runjump.fwd = 2,-7.5	 ;.
airjump.neu = 0,-7.5	 ;.
airjump.back = -2.0	 ;Air jump speeds (opt)
airjump.fwd = 2.0	 ;.

[Movement]
airjump.num = 0;1	 ;Number of air jumps allowed (opt)
airjump.height = 35	 ;Minimum distance from ground before you can air jump (opt)
yaccel = .45		 ;Vertical acceleration
stand.friction = .85	 ;Friction coefficient when standing
crouch.friction = .82	 ;Friction coefficient when crouching

;---------------------------------------------------------------------------
; 使用している変数（本体）
;
; Var(0)	：特殊振り向き設定
; Var(1)	：ジャンプ回数制限
; Var(2)	：ラウンド開始フラグ
; Var(3)	：ライフ監視
; Var(4)	：復帰無敵時間
; Var(59)	：A.I.起動用

; SysVar(4)	：GameTime監視

; SysFVar(0)	：くらい時ダメージ量
; SysFVar(1)	：ライフ監視

;---------------------------------------------------------------------------
; 判定負け
[Statedef 170]
type = S
ctrl = 0
anim = 170
velset = 0,0

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

[State 170, 2]
type = AssertSpecial
trigger1 = MatchOver = 1
trigger1 = Time = [0,400]
flag = RoundNotOver

[State 170, 3]
type = PlaySnd
trigger1 = MatchOver = 0
trigger1 = Time = 0
value = S170,0
channel = 29

[State 170, 4]
type = PlaySnd
trigger1 = MatchOver = 1
trigger1 = Time = 0
value = S180,0+(Random%2)
channel = 29

;---------------------------------------------------------------------------
; 勝利ポーズ（分岐）
[Statedef 180]
type = S

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

[State 180, 2]
type = ChangeState
trigger1 = Time = 0
value = 181

;---------------------------------------------------------------------------
; 勝利ポーズ
[Statedef 181]
type = S
ctrl = 0
anim = 181+(Random%2)
velset = 0,0

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

[State 181, 2]
type = AssertSpecial
trigger1 = MatchOver = 1
trigger1 = Time = [0,380]
flag = RoundNotOver

[State 181, 3]
type = PlaySnd
trigger1 = MatchOver = 0
trigger1 = Time = 0
value = S170,0
channel = 29

[State 181, 4]
type = PlaySnd
trigger1 = MatchOver = 1
trigger1 = Time = 0
value = S180,0+(Random%2)
channel = 29

;---------------------------------------------------------------------------
; イントロ（開始）
[Statedef 190]
type = S
ctrl = 0
anim = 40000
velset = 0,0

[State 190, 1]
type = ChangeState
trigger1 = Time = 0
value = 191 + (Random%2)

;---------------------------------------------------------------------------
; イントロ１
[Statedef 191]
type = S
ctrl = 0
anim = 190
velset = 0,0

[State 191, 1] ;Freeze animation until PreIntro is over
type = Null;ChangeAnim
trigger1 = RoundState = 0
value = 190

[State 191, 2] ;Assert this until you want "round 1, fight" to begin
type = AssertSpecial
trigger1 = 1
flag = Intro

[State 191, 3]
type = PlaySnd
trigger1 = Time = 0
value = S190,0+(Random%2)
channel = 29

[State 191, 4] ;Change to stand state when done
type = ChangeState
triggerall = AnimTime = 0
trigger1 = Enemy,StateNo = 0
trigger2 = Time >= 500
value = 0

;---------------------------------------------------------------------------
; イントロ２
[Statedef 192]
type = S
ctrl = 0
anim = 40000
velset = 0,0

[State 192, 1]
type = AssertSpecial
trigger1 = 1
flag = Intro

[State 192, 2]
type = Helper
trigger1 = Time = 1
stateno = 19200
id = 19200
name = "Intro_192"
helpertype = Normal
postype = P1
pos = -200,0
size.xscale = Const(size.xscale)
size.yscale = Const(size.yscale)
facing = 1
keyctrl = 0
ownpal = 1
sprpriority = 3
ignorehitpause = 1

[State 192, 3]
type = PlaySnd
trigger1 = Time = 0
value = S190,2+(Random%2)
channel = 29

[State 192, 4]
type = ChangeAnim
trigger1 = NumHelper(19200) > 0
trigger1 = Helper(19200),RootDist X <= 0
value = 0

[State 192, 5] ;Change to stand state when done
type = ChangeState
triggerall = AnimTime = 0
trigger1 = Enemy,StateNo = 0
trigger2 = Time >= 500
value = 0

;---------------------------------------------------------------------------
; 動作１
[Statedef 1111]
type     = S
movetype = I
physics  = S
juggle   = 0
velset = 0,0
anim = 1111
ctrl = 0
sprpriority = 2

[State 1111, 1]
type = PlaySnd
trigger1 = Time = 0
value = S1,0+(Random%14)
channel = 29
lowpriority = 1

[State 1111, 2]
type = LifeAdd
trigger1 = Time > 5
trigger1 = GameTime%2 = 0
value = PalNo

[State 1111, 3]
type = PowerAdd
trigger1 = Time > 5
value = PalNo

[State 1111, 4]
type = ChangeState
trigger1 = Command != "holda"
value = 0
ctrl = 1

;---------------------------------------------------------------------------
; 動作２
[Statedef 2222]
type     = S
movetype = I
physics  = S
juggle   = 0
velset = 0,0
anim = 2222
ctrl = 0
sprpriority = 2

[State 2222, 1]
type = PlaySnd
trigger1 = Time = 0
value = S1,0+(Random%14)
channel = 29
lowpriority = 1

[State 2222, 2]
type = ChangeState
trigger1 = Command != "holdb"
value = 0
ctrl = 1

;---------------------------------------------------------------------------
; 動作３
[Statedef 3333]
type     = S
movetype = I
physics  = S
juggle   = 0
velset = 0,0
anim = 3333
ctrl = 0
sprpriority = 2

[State 3333, 1]
type = PlaySnd
trigger1 = Time = 0
value = S1,0+(Random%14)
channel = 29
lowpriority = 1

[State 3333, 1]
type = ChangeState
trigger1 = Command != "holdz"
value = 0
ctrl = 1

;---------------------------------------------------------------------------
; 飛び散り
[Statedef 4444]
type     = L
movetype = I
physics  = N
juggle   = 0
velset = 0,0
anim = 4444
ctrl = 0
sprpriority = 2

[State 4444, 1]
type = AssertSpecial
trigger1 = 1
flag = Invisible

[State 4444, 2]
type = PlaySnd
trigger1 = Time = 0
value = S4444,1
channel = 29

[State 4444, 3]
type = LifeAdd
trigger1 = Time = 0
value = -Floor(SysFVar(0))

[State 4444, 4]
type = VarSet
trigger1 = Time = 0
trigger1 = Var(3) < Var(4)
var(3) = Var(3) + 1

[State 4444, 5]
type = PlaySnd
trigger1 = Time = 0
value = S4444, 0

;飛び散り（白・小１）
[State 4444, 6]
type = Explod
trigger1 = Time = 0
anim = 4445
id = 4445
scale = Const(size.xscale),Const(size.yscale)
pos = 0,0
postype = P1
removetime = -2
vel = 0.6+((Random%6)*0.1),-0.7-((Random%14)*0.1)
sprpriority = 3
facing = 1
ownpal = 1
removeongethit = 1
ignorehitpause = 1
supermovetime = 999999999
pausemovetime = 999999999

;飛び散り（白・小２）
[State 4444, 7]
type = Explod
trigger1 = Time = 0
anim = 4445
id = 4446
scale = Const(size.xscale),Const(size.yscale)
pos = 0,0
postype = P1
removetime = -2
vel = 0.6+((Random%6)*0.1),0.7+((Random%14)*0.1)
sprpriority = 3
facing = 1
ownpal = 1
removeongethit = 1
ignorehitpause = 1
supermovetime = 999999999
pausemovetime = 999999999

;飛び散り（白・小３）
[State 4444, 8]
type = Explod
trigger1 = Time = 0
anim = 4445
id = 4447
scale = Const(size.xscale),Const(size.yscale)
pos = 0,0
postype = P1
removetime = -2
vel = -0.6-((Random%6)*0.1),-0.7-((Random%14)*0.1)
sprpriority = 3
facing = 1
ownpal = 1
removeongethit = 1
ignorehitpause = 1
supermovetime = 999999999
pausemovetime = 999999999

;飛び散り（赤・小１）
[State 4444, 9]
type = Explod
trigger1 = Time = 0
anim = 4446
id = 4448
scale = Const(size.xscale),Const(size.yscale)
pos = 0,0
postype = P1
removetime = -2
vel = 0.5+((Random%5)*0.1),0.5+((Random%10)*0.1)
sprpriority = 3
facing = 1
ownpal = 1
removeongethit = 1
ignorehitpause = 1
supermovetime = 999999999
pausemovetime = 999999999

;飛び散り（赤・小２）
[State 4444, 10]
type = Explod
trigger1 = Time = 0
anim = 4446
id = 4449
scale = Const(size.xscale),Const(size.yscale)
pos = 0,0
postype = P1
removetime = -2
vel = -0.5-((Random%5)*0.1),-0.5-((Random%10)*0.1)
sprpriority = 3
facing = 1
ownpal = 1
removeongethit = 1
ignorehitpause = 1
supermovetime = 999999999
pausemovetime = 999999999

;飛び散り（白・大１）
[State 4444, 11]
type = Explod
trigger1 = Time = 0
anim = 4447
id = 4450
scale = Const(size.xscale),Const(size.yscale)
pos = 0,0
postype = P1
removetime = -2
vel = 0.8+((Random%8)*0.1),1.0+((Random%20)*0.1)
sprpriority = 3
facing = 1
ownpal = 1
removeongethit = 1
ignorehitpause = 1
supermovetime = 999999999
pausemovetime = 999999999

;飛び散り（白・大２）
[State 4444, 12]
type = Explod
trigger1 = Time = 0
anim = 4447
id = 4451
scale = Const(size.xscale),Const(size.yscale)
pos = 0,0
postype = P1
removetime = -2
vel = 0.8+((Random%8)*0.1),-1.0-((Random%20)*0.1)
sprpriority = 3
facing = 1
ownpal = 1
removeongethit = 1
ignorehitpause = 1
supermovetime = 999999999
pausemovetime = 999999999

;飛び散り（白・大３）
[State 4444, 13]
type = Explod
trigger1 = Time = 0
anim = 4447
id = 4452
scale = Const(size.xscale),Const(size.yscale)
pos = 0,0
postype = P1
removetime = -2
vel = -0.8-((Random%8)*0.1),1.0+((Random%20)*0.1)
sprpriority = 3
facing = 1
ownpal = 1
removeongethit = 1
ignorehitpause = 1
supermovetime = 999999999
pausemovetime = 999999999

;飛び散り（白・大４）
[State 4444, 14]
type = Explod
trigger1 = Time = 0
anim = 4447
id = 4453
scale = Const(size.xscale),Const(size.yscale)
pos = 0,0
postype = P1
removetime = -2
vel = -0.8-((Random%8)*0.1),-1.0-((Random%20)*0.1)
sprpriority = 3
facing = 1
ownpal = 1
removeongethit = 1
ignorehitpause = 1
supermovetime = 999999999
pausemovetime = 999999999

;飛び散り（白・大５）
[State 4444, 15]
type = Explod
trigger1 = Time = 0
anim = 4447
id = 4454
scale = Const(size.xscale),Const(size.yscale)
pos = 0,0
postype = P1
removetime = -2
vel = -0.8-((Random%8)*0.1),-1.0+((Random%20)*0.1)
sprpriority = 3
facing = 1
ownpal = 1
removeongethit = 1
ignorehitpause = 1
supermovetime = 999999999
pausemovetime = 999999999

;飛び散り（赤・大１）
[State 4444, 16]
type = Explod
trigger1 = Time = 0
anim = 4448
id = 4455
scale = Const(size.xscale),Const(size.yscale)
pos = 0,0
postype = P1
removetime = -2
vel = -0.7-((Random%7)*0.1),0.9-((Random%18)*0.1)
sprpriority = 3
facing = 1
ownpal = 1
removeongethit = 1
ignorehitpause = 1
supermovetime = 999999999
pausemovetime = 999999999

[State 4444, 17]
type = VelSet
triggerall = Time > 50
trigger1 = Command != "holdfwd"
trigger2 = Command != "holdback"
x = 0

[State 4444, 18]
type = VelSet
trigger1 = Time > 50
trigger1 = Command = "holdfwd"
x = 2.0

[State 4444, 19]
type = VelSet
trigger1 = Time > 50
trigger1 = Command = "holdback"
x = -2.0

[State 4444, 20]
type = ChangeState
trigger1 = !Alive
trigger1 = Time > 50
value = 5150
ctrl = 0

[State 4444, 21]
type = ChangeState
trigger1 = AnimTime = 0
value = 4450
ctrl = 0

;---------------------------------------------------------------------------
; 飛び散り復帰
[Statedef 4450]
type     = A
movetype = I
physics  = A
juggle   = 0
velset = 0,-4
ctrl = 0
sprpriority = 2

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

[State 4450, 2]
type = VarSet
trigger1 = 1
var(5) = 20

[State 4450, 3]
type = PlaySnd
trigger1 = Time = 0
value = S4450, 0

[State 4450, 4]
type = AssertSpecial
trigger1 = Time%3 = 0
flag = Invisible

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

[State 4450, 6]
type = ChangeAnim
trigger1 = Time = 0
value = 41

[State 4450, 7]
type = ChangeAnim
trigger1 = Anim = 41
trigger1 = Vel Y > 0
value = 48

[State 4450, 8]
type = VelAdd
trigger1 = Time >= 0
trigger1 = Anim = 41 || Anim = 48
trigger1 = Command = "holdfwd"
x = 0.1

[State 4450, 9]
type = VelAdd
trigger1 = Time >= 0
trigger1 = Anim = 41 || Anim = 48
trigger1 = Command = "holdback"
x = -0.1

[State 4450, 10]
type = ChangeState
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
value = 0
ctrl = 1
