; 仮面ライダーブレイド　ver.060122

; 基本設定
[Data]
  ;体力ゲージの初期値
life = 1000
  ;攻撃力（これ以上に設定すると強くなる）
attack = 100
  ;防御力（これ以上に設定すると強くなる）
defence = 100
  ;コンボをくらっている時にあがる防御力
fall.defence_up = 50
  ;倒れてから起上がるまでのフレーム数
liedown.time = 60
  ;空中でどれだけコンボが繋がるか（高くすると無限コンボになるので注意）
airjuggle = 15
  ;hitdefで設定していない時の基本ヒットスパークナンバー
sparkno = 2
  ;設定してない時のガードナンバー
guard.sparkno = 40
  ;KOした時に声にエコーをかけるか（１でＯＮ）
KO.echo = 0
 volume = 0
  IntPersistIndex = 60
FloatPersistIndex = 40

[Size]
xscale = 1           ;水平方向の縮尺（通常１）
yscale = 1           ;垂直方向の縮尺（通常１）
ground.back = 15     ;キャラの幅(後方,地上)
ground.front = 16    ;キャラの幅(前方,地上)
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,0    ;使用しない

[Velocity]
walk.fwd  = 2.4      ;前進の速度
walk.back = -2.2     ;後退の速度
run.fwd  = 4.6, 0    ;前ダッシュの速度（ホップする時はyを-にする）
run.back = -4.5,-3.8 ;後ダッシュの速度（ホップする時はyを-にする）
jump.neu = 0,-8.4    ;垂直ジャンプの速度
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 = 1      ;空中でジャンプする回数
airjump.height = 35  ;空中でジャンプする最低限の高さ
yaccel = .44         ;重力
stand.friction = .85  ;立ち状態の摩擦係数
crouch.friction = .82 ;屈み状態の摩擦係数

;---------------------------------------------------------------------------
; ステイトの解説
; [Statedef STATENO]
; type = ?      S/C/A/L  Ｓ：立ち/Ｃ：屈み/Ａ：空中/Ｌ：ダウン
; movetype = ?  I/A/H    Ｉ：通常状態/Ａ：攻撃状態/Ｈ：ダメージをくらってる状態
; physics = ?   S/C/A/N  Ｓ：立ち/Ｃ：屈み/Ａ：空中/Ｎ：無し
; juggle = ?             その攻撃に使うジャグル数
;

;---------------------------------------------------------------------------
; タイムオーバーで負けた時
[Statedef 170]
type = S
ctrl = 0
anim = 170
velset = 0,0

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

;---------------------------------------------------------------------------
; 勝った動作１
[Statedef 180]
type = S

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

;---------------------------------------------------------------------------
; 勝った動作２
[Statedef 181]
type = S
ctrl = 0
anim = 180
velset = 0,0

[State 181, 2] 
type = AssertSpecial
trigger1 = Time = [0,200]
flag = roundnotover

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

[State 181, 3]
type = PlaySnd
trigger1 = time = 0
value = 100, 1

[State 181, 3]
type = PlaySnd
trigger1 = AnimElem = 9
value = 100, 2

;---------------------------------------------------------------------------
; 開始前の動作
[Statedef 190]
type = S
ctrl = 0
anim = 190
velset = 0,0

[State 190, 1] 
type = ChangeAnim
trigger1 = RoundState = 0
value = 190

[State 191, Visual effect]
type = Explod
trigger1 = AnimElem = 9
anim = 195
pos = -3,3
sprpriority = 3
postype = p1
supermove = 1
bindtime = 1
ownpal = 1
scale = 1,1
shadow = 100,50,0

[State 190, 2] 
type = AssertSpecial
trigger1 = 1
flag = Intro

[State 190, 3]
type = PlaySnd
trigger1 = AnimElem = 5
value = 100, 0

[State 190, 3]
type = PlaySnd
trigger1 = Time = 120
value = 101, 0

[State 190, 4] 
type = ChangeState
trigger1 = AnimTime = 0
value = 0

;---------------------------------------------------------------------------
; 立ち弱斬り
[Statedef 200]
type    = S
movetype= A
physics = S
juggle  = 4
poweradd= 22
ctrl = 0
velset = 0,0
anim = 200
sprpriority = 2

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

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

[State 200, 2]
type = HitDef
trigger1 = Time = 0
attr = S, NA
animtype  = Light
damage    = 25
guardflag = MA
pausetime = 12,12
sparkno = S205
guard.sparkno = S207
sparkxy = 30,-85
hitsound   = 5,1
guardsound = 6,0
ground.type = High
ground.slidetime = 10
ground.hittime  = 12
ground.velocity = -5
air.velocity = -2.5,-3.5

[State 200, 3]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
; 立ちキック
[Statedef 210]
type    = S
movetype= A
physics = S
juggle  = 5
poweradd= 65
ctrl = 0
velset = 0,0
anim = 210
sprpriority = 2

[State 200, 1]
type = PlaySnd
trigger1 = Time = 1
value = 50, 2

[State 210, 1]
type = PlaySnd
trigger1 = Time = 2
value = 0, 1

[State 210, 2] 
type = HitDef
trigger1 = AnimElem = 2
attr = C, NA
damage    = 50
animtype  = Medium
hitflag = MAF
guardflag = MA
pausetime = 12,12
sparkno = S215
guard.sparkno = S217
sparkxy = -10,-83
hitsound   = 5,2
guardsound = 6,0
ground.type = High
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -7
air.velocity = -3,-4

[State 210, 3]
type = PosAdd
trigger1 = AnimElem = 7
x = 12

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

;---------------------------------------------------------------------------
; 立ち強斬り
[Statedef 220]
type    = S
movetype= A
physics = S
juggle  = 4
poweradd= 65
ctrl = 0
velset = 0,0
anim = 220
sprpriority = 1

[State 200, 1]
type = PlaySnd
trigger1 = Time = 1
value = 50, 3

[State 220, 1]
type = PlaySnd
trigger1 = Time = 2
value = 0, 4

[State 220, 2]
type = HitDef
trigger1 = AnimElem = 2
attr = S, NA
animtype  = Heavy
damage    = 75
guardflag = MA
pausetime = 12,12
sparkno = S225
guard.sparkno = S207
sparkxy = 40,-85
hitsound   = 5,2
guardsound = 6,0
ground.type = Low
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -5.5
air.velocity = -2.5,-4

[State 220, 5]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1


;---------------------------------------------------------------------------
;屈み弱斬り
[Statedef 400]
type    = C
movetype= A
physics = C
juggle  = 5
poweradd= 22
ctrl = 0
anim = 400
sprpriority = 2

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

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

[State 400, 2]
type = HitDef
trigger1 = Time = 0
attr = C, NA
damage    = 25
animtype  = Light
hitflag = MAFD
guardflag = L
pausetime = 12,12
sparkno = S205
guard.sparkno = S207
sparkxy = 20,-45
hitsound   = 5,1
guardsound = 6,0
ground.type = Low
ground.slidetime = 6
ground.hittime  = 12
ground.velocity = -5
air.velocity = -2,-3
down.velocity = -5,0
down.hittime = 20

[State 400, 3]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

;---------------------------------------------------------------------------
;屈みキック
[Statedef 410]
type    = C
movetype= A
physics = C
juggle  = 7
poweradd= 70
ctrl = 0
anim = 410
sprpriority = 2

[State 200, 1]
type = PlaySnd
trigger1 = Time = 1
value = 50, 2

[State 410, 1]
type = PlaySnd
trigger1 = Time = 2
value = 0, 2

[State 410, 2]
type = HitDef
trigger1 = Time = 0
attr = C, NA
damage    = 50
animtype  = Medium
hitflag = MAF
guardflag = L
pausetime = 12,12
sparkno = S215
guard.sparkno = S217
sparkxy = -10,-10
hitsound   = 5,2
guardsound = 6,0
ground.type = Low
ground.slidetime = 10
ground.hittime  = 15
ground.velocity = -4
air.velocity = -3,-4
guard.velocity = -5

[State 410, 3]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

;---------------------------------------------------------------------------
;屈み強斬り

[Statedef 420]
type    = C
movetype= A
physics = C
juggle  = 6
poweradd= 50
ctrl = 0
anim = 420
sprpriority = 2

[State 200, 1]
type = PlaySnd
trigger1 = Time = 1
value = 50, 3

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

[State 420, 2]
type = HitDef
trigger1 = AnimElem = 2
attr = S, NA
animtype  = Heavy
damage    = 75
guardflag = MA
pausetime = 12,12
sparkno = S226
guard.sparkno = S227
sparkxy = 25,-120
hitsound   = 5,2
guardsound = 6,0
ground.type = Trip
ground.slidetime = 12
ground.hittime  = 15
ground.velocity = -1.5,-2
air.velocity = -1.2,-3
fall = 1

[State 420, 3]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

;---------------------------------------------------------------------------
;空中弱斬り
[Statedef 600]
type    = A
movetype= A
physics = A
juggle  = 3
poweradd= 20
ctrl = 0
anim = 600
sprpriority = 2

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

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

[State 600, 2]
type = HitDef
trigger1 = Time = 0
attr = A, NA
damage = 25
guardflag = HA
priority = 3
pausetime = 8,8
sparkno = S206
guard.sparkno = S207
sparkxy = 25,-100
hitsound   = 5,0
guardsound = 6,0
ground.type = High
ground.slidetime = 6
ground.hittime  = 6
ground.velocity = -4
air.velocity = -2,-3

;---------------------------------------------------------------------------
;空中キック
[Statedef 610]
type    = A
movetype= A
physics = A
juggle  = 4
poweradd= 65
ctrl = 0
anim = 610
sprpriority = 2

[State 200, 1]
type = PlaySnd
trigger1 = Time = 1
value = 50, 2

[State 610, 1]
type = PlaySnd
trigger1 = Time = 2
value = 0, 1

[State 610, 2]
type = HitDef
trigger1 = Time = 0
attr = A, NA
damage    = 50
guardflag = HA
priority = 4
pausetime = 12,12
sparkno = S215
guard.sparkno = S217
sparkxy = 0,-95
hitsound   = 5,3
guardsound = 6,0
animtype = Med
ground.type = High
ground.slidetime = 17
ground.hittime  = 17
ground.velocity = -5
air.velocity = -3,-4

;---------------------------------------------------------------------------
;空中強斬り
[Statedef 620]
type    = A
movetype= A
physics = A
juggle  = 4
poweradd= 65
ctrl = 0
anim = 620
sprpriority = 2

[State 200, 1]
type = PlaySnd
trigger1 = Time = 1
value = 50, 3

[State 620,１ ]
type = PlaySnd
trigger1 = Time = 2
value = 0, 1

[State 620, 2]
type = HitDef
trigger1 = AnimElem = 2
attr = A, NA
damage = 75
guardflag = HA
priority = 4
pausetime = 12,12
sparkno = S226
guard.sparkno = S207
sparkxy = 25,-115
hitsound   = 5,3
guardsound = 6,0
animtype = Med
ground.type = High
ground.slidetime = 17
ground.hittime  = 17
ground.velocity = -5
air.velocity = -3,-4


[Statedef 800]
type = S
MoveType = A
physics = S
juggle  = 0
velset = 0,0
anim = 800
ctrl = 0

[State 750 , 1]
type = TargetBind
trigger1 = Time = 0
Pos = 32, 0

[State 750 , 4]
type = HitDef
Trigger1 = Time = 0
trigger1 = P2StateType = S
attr = S, NT
getpower  = 0
givepower = 40
hitflag = M-
priority = 2, Miss    ;Throw has low priority, should be miss or dodge type.
sparkno = -1
sprpriority = 1      ;Draw behind p2
p2facing = 1
p2stateno = 815

[State 750 , 5]
type = ChangeState
trigger1 = animtime = 0
value = 805
ctrl = 1

[Statedef 805]
type = S
MoveType = A
physics = S
juggle  = 0
velset = 0,0
anim = 805
ctrl = 0

[State 752 , 1]
type = Hitdef
Trigger1 = AnimElem = 1
Trigger1 = var(4) > 0
attr = S, NA
getpower  = 0
givepower = 40
hitflag = MAF
numhits = 0
Damage = 85
sparkxy = -10,-96
sprpriority = -1      ;Draw behind p2
p2facing = 1
animtype = Heavy
sparkno = S216
pausetime = 20,20
sparkxy = -10,-70
hitsound   = S1000,1
guardsound = 6,0
ground.type = High
ground.slidetime = 9
ground.hittime  = 9
ground.velocity = -5,-4     
Down.Velocity = -5,-4
air.velocity = -4,-3
fall = 1
fall.recover = 0

[State 752 , 2]
type = Hitdef
Trigger1 = AnimElem = 1
trigger1 = Var(4) <= 0
attr = S, NA
getpower  = 0
givepower = 40
hitflag = MAF
numhits = 0
Damage = 85
sparkxy = -10,-96
sprpriority = -1      ;Draw behind p2
p2facing = 1
animtype = Heavy
sparkno = S216
pausetime = 20,20
sparkxy = -10,-70
hitsound   = S1000,1
guardsound = 6,0
ground.type = High
ground.slidetime = 9
ground.hittime  = 9
ground.velocity = -3,-4     
Down.Velocity = -3,-4
air.velocity = -3,-3
fall = 1
fall.recover = 0

[State 620,１ ]
type = PlaySnd
trigger1 = Time = 0
value = 6,0

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

[Statedef 815]
type = S
MoveType = H
physics = S
ctrl = 0

[State 755 , 1]
type = ChangeAnim2
trigger1 = time = 0
value = 815

;---------------------------------------------------------------------------
;ダッシュ       
[Statedef 100]          
type = A             
physics = A           
ctrl = 0
anim = 100
velset = 5, -5

[State 100, 1]
type = ChangeState
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
value = 101

;---------------------------------------------------------------------------
;ダッシュ2
[Statedef 101]
type    = S
physics = S
ctrl = 1

[State 101, 1]
type = VelSet
trigger1 = Time = 0
y = 0

[State 101, 2]
type = PosSet
trigger1 = Time = 0
y = 0

[State 101, 3]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

[State 101, 4]
type = MakeDust
trigger1 = Time = 1
pos = -25,3
spacing = 2

[State 101, 5]
type = MakeDust
trigger1 = time >= 8
trigger1 = time <= 25
pos = -15,3

;---------------------------------------------------------------------------
;サンダーＡ
[Statedef 1000]
type    = S
movetype= A
physics = S
juggle  = 15
poweradd= 80
velset = 0,0
anim = 1000
ctrl = 0

;[State 200, 1]
;type = PlaySnd
;trigger1 = Time = 1
;value = 55, 1

[State 9901, 1]
type = PlaySnd
trigger1 = AnimElem = 2
value = 1000,0

[State 1101, 5]
type = envshake
trigger1 = animelem = 2
time = 30

[State 9901, 2]
type = Projectile
trigger1 = AnimElem = 2
projanim = 1050
projremovetime = 2
projhitanim = 1011
projpriority = 1
projshadow = -1
offset = 75,-90
velocity = 0
attr = S, SP
damage   = 60,25
animtype = back
guardflag = MA
hitflag = MAFDP
pausetime = 0,0
;hitsound   = S8,0
sparkno = S1051
guard.sparkno = S207
sparkxy = 0,0
;guardsound = S4,7
ground.type = low
ground.slidetime = 25
ground.hittime  = 25
ground.velocity = -6
air.velocity = -3,-6
air.juggle = 3
air.fall = 1
fall = 1
palfx.time = 5
palfx.add = 220, 230,220

[State XXXX, End1]
type = ChangeState
trigger1 = AnimTime = 0
trigger1 = PalNo = [1, 6]
value = 0
ctrl = 1

[State XXXX, End2]
type = ChangeState
trigger1 = AnimTime = 0
trigger1 = PalNo = [7, 12]
trigger1 = P2BodyDist X <= 100
value = 0
ctrl = 1

[State XXXX, End3]
type = ChangeState
trigger1 = AnimTime = 0
trigger1 = PalNo = [7, 12]
trigger1 = P2BodyDist X > 100
value = 1

;---------------------------------------------------------------------------
;サンダーＢ
[Statedef 1001]
type    = S
movetype= A
physics = S
juggle  = 15
poweradd= 80
velset = 0,0
anim = 1000
ctrl = 0

;[State 200, 1]
;type = PlaySnd
;trigger1 = Time = 1
;value = 55, 1

[State 9901, 1]
type = PlaySnd
trigger1 = AnimElem = 2
value = 1000,0

[State 1101, 5]
type = envshake
trigger1 = animelem = 2
time = 30

[State 9901, 2]
type = Projectile
trigger1 = AnimElem = 2
projanim = 1050
projremovetime = 2
projhitanim = 1011
projpriority = 1
projshadow = -1
offset = 150,-90
velocity = 0
attr = S, SP
damage   = 60,25
animtype = back
guardflag = MA
hitflag = MAFDP
pausetime = 0,0
;hitsound   = S8,0
sparkno = S1051
guard.sparkno = S207
sparkxy = 0,0
;guardsound = S4,7
ground.type = low
ground.slidetime = 25
ground.hittime  = 25
ground.velocity = -6
air.velocity = -3,-6
air.juggle = 3
air.fall = 1
fall = 1
palfx.time = 5
palfx.add = 220, 230,220

[State XXXX, End1]
type = ChangeState
trigger1 = AnimTime = 0
trigger1 = PalNo = [1, 6]
value = 0
ctrl = 1

[State XXXX, End2]
type = ChangeState
trigger1 = AnimTime = 0
trigger1 = PalNo = [7, 12]
trigger1 = P2BodyDist X <= 100
value = 0
ctrl = 1

[State XXXX, End3]
type = ChangeState
trigger1 = AnimTime = 0
trigger1 = PalNo = [7, 12]
trigger1 = P2BodyDist X > 100
value = 1

;---------------------------------------------------------------------------
;サンダーＣ
[Statedef 1002]
type    = S
movetype= A
physics = S
juggle  = 15
poweradd= 80
velset = 0,0
anim = 1000
ctrl = 0

;[State 200, 1]
;type = PlaySnd
;trigger1 = Time = 1
;value = 55, 1

[State 9901, 1]
type = PlaySnd
trigger1 = AnimElem = 2
value = 1000,0

[State 1101, 5]
type = envshake
trigger1 = animelem = 2
time = 30

[State 9901, 2]
type = Projectile
trigger1 = AnimElem = 2
projanim = 1050
projremovetime = 2
projhitanim = 1011
projpriority = 1
projshadow = -1
offset = 255,-90
velocity = 0
attr = S, SP
damage   = 60,25
animtype = back
guardflag = MA
hitflag = MAFDP
pausetime = 0,0
;hitsound   = S8,0
sparkno = S1051
guard.sparkno = S207
sparkxy = 0,0
;guardsound = S4,7
ground.type = low
ground.slidetime = 25
ground.hittime  = 25
ground.velocity = -6
air.velocity = -3,-6
air.juggle = 3
air.fall = 1
fall = 1
palfx.time = 5
palfx.add = 220, 230,220

[State XXXX, End1]
type = ChangeState
trigger1 = AnimTime = 0
trigger1 = PalNo = [1, 6]
value = 0
ctrl = 1

[State XXXX, End2]
type = ChangeState
trigger1 = AnimTime = 0
trigger1 = PalNo = [7, 12]
trigger1 = P2BodyDist X <= 100
value = 0
ctrl = 1

[State XXXX, End3]
type = ChangeState
trigger1 = AnimTime = 0
trigger1 = PalNo = [7, 12]
trigger1 = P2BodyDist X > 100
value = 1
;---------------------------------------------------------------------------
;ビート
[Statedef 1100]
type    = A
movetype= A
physics = N
juggle  = 8
anim = 1100
velset = 0, 0

[State 9901, 1]
type = PlaySnd
trigger1 = time = 0
value = 1100,0

[State 1200, 1]
type = PlaySnd
trigger1 = Time = 1
value = 50, 2

[State 1021, 8]
type = HitDef
trigger1 = AnimElem= 2
attr = A, SA
animtype = Hard
damage = 100,25
guardflag = HA
hitflag = MAF
getpower  = 10,5
givepower = 50,25
pausetime = 20, 27
sparkno = S216
guard.sparkno = S217
sparkxy = 0,-95
hitsound   = S1100,1
guardsound = 6,0
ground.type = Low
guard.slidetime = 20
ground.velocity = -8,-7
guard.velocity = -7
air.velocity = -8,-7
airguard.velocity = -5, -4
fall = 1
p2stateno = 1105

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

;------------------
; 攻撃をくらった相手の状態
[Statedef 1105]
type    = A
movetype= H
physics = N
velset = 0,0

[State 1025, Anim] ;２Ｐのスプライトステートを変更しています
type = ChangeAnim2
trigger1 = 1
value = 1025

[State 1025, State]
type = ChangeState
trigger1 = HitShakeOver = 1
value = 1106

;------------------
; 飛んでいく相手のステート

[Statedef 1106]
type    = A
movetype= H
physics = N

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

[State 1026, Gravity]
type = VelAdd
trigger1 = 1
y = .45

[State 1026, No scroll]
type = ScreenBound
triggerall = Pos y < -15
trigger1 = BackEdgeBodyDist < 65
trigger2 = FrontEdgeBodyDist < 65
value = 1
movecamera = 0,1

[State 1026, Hit wall]
type = ChangeState
triggerall = Pos y < -15
trigger1 = BackEdgeBodyDist <= 20
trigger2 = FrontEdgeBodyDist <= 20
value = 1107

[State 1026, Hit ground]
type = SelfState
trigger1 = (Vel y > 0) && (Pos y >= 0)
value = 5100

;------------------
; 飛んでいった相手の壁に当たる状態のステート

[Statedef 1107]
type    = A
movetype= H
physics = N

[State 1027, Turn]
type = Turn
trigger1 = (Time = 0) && (FrontEdgeBodyDist <= 30)

[State 1027, Pos]
type = PosAdd
trigger1 = Time = 0
x = 15 - BackEdgeBodyDist

[State 1027, Stop moving]
type = PosFreeze
trigger1 = 1
x = 1
y = 1

[State 1027, No scroll]
type = ScreenBound
trigger1 = 1
value = 1
movecamera = 0,1

[State 1027, Spark]
type = Explod
trigger1 = Time = 0
anim = F72
pos = 0, floor (screenpos y) - 50
postype = back
sprpriority = 3

[State 1027, Anim]
type = ChangeAnim2
trigger1 = Time = 0
value = 1027

[State 1027, Sound]
type = PlaySnd
trigger1 = Time = 0
value = F7,0

[State 1027, State]
type = ChangeState
trigger1 = AnimTime = 0
value = 1108

;------------------
; 壁に当たった相手が落ちるステート

[Statedef 1108]
type    = A
movetype= H
physics = N

[State 1028, 1]
type = NotHitBy
trigger1 = 1
value = , NA, NP

[State 1028, Vel Y]
type = VelSet
trigger1 = Time = 0
y = -6

[State 1028, Vel X]
type = VelSet
trigger1 = Time = 0
x = 1.6

[State 1028, Turn]
type = Turn
trigger1 = (Time = 0) && (BackEdgeDist < 30)

[State 1028, Gravity]
type = VelAdd
trigger1 = 1
y = .35

[State 1028, Anim 5050] 
type = ChangeAnim
trigger1 = Time = 0
trigger1 = !SelfAnimExist(5052)
value = 5050

[State 1028, Anim 5052] 
type = ChangeAnim
trigger1 = Time = 0
trigger1 = SelfAnimExist(5052)
value = 5052

[State 1028, Anim 5060] 
type = ChangeAnim
trigger1 = Vel Y > -2
trigger1 = Anim = 5050
trigger1 = SelfAnimExist(5060)
persistent = 0
value = 5060

[State 1028, Anim 5062] 
type = ChangeAnim
trigger1 = Vel Y > -2
trigger1 = Anim = 5052
trigger1 = SelfAnimExist(5062)
persistent = 0
value = 5062

[State 1028, Hit ground]
type = SelfState
trigger1 = (Vel y > 0) && (Pos y >= 0)
value = 5100

;---------------------------------------------------------------------------
;キック開始
[Statedef 1200]
type    = A
movetype= A
physics = N
ctrl = 0
velset = 4.5, -5.5
anim = 1200
velset = 0, 0
PowerAdd = 30

[State 1200, 1]
type = PlaySnd
trigger1 = Time = 1
value = 55, 2

[State 1200, 1]
type = PlaySnd
trigger1 = AnimElem = 1
value = 1100, 0
channel = 1

[State 1200, 2]
type = ChangeState
trigger1 = AnimTime = 0
value = 1201


;---------------------------------------------------------------------------
;キック攻撃
[Statedef 1201]
type    = A
movetype= A
physics = N
juggle  = 8
anim = 1201
velset = 0, 0

[State 1201, 1]
type = HitDef
trigger1 = AnimElem= 1
attr = A, SA
animtype = Heavy
damage = 95, 32
guardflag = HA
hitflag = MAF
getpower  = 10,5
givepower = 50,25
pausetime = 20, 27
sparkno = S216
guard.sparkno = S217
sparkxy = 15, -55
hitsound   = S1100,1
guardsound = 6,0
ground.type = Trip
guard.slidetime = 3
ground.hittime  = 15
ground.velocity = -4
air.velocity = -4

[State 1201, 2]
type = VelSet
trigger1 = Time > 0
x = 7

[State 1201, 3]
type = VelSet
trigger1 = Time > 0
trigger1 = Time < 5
y = -7.5

[State 1201, 4]
type = VelSet
trigger1 = Time > 4   
trigger1 = Time < 15   ;←
y = 0

[State 1201, 5]
type = VelSet
trigger1 = Time > 15   ;←
trigger1 = Pos Y < -2
y = 7.5


[State 1201, 6]
type = VelSet
trigger1 = Time > 20   ;←
x = 0

[State 1201, 8]
type = ChangeState
trigger1 = Time > 20   ;←
trigger2 = Pos Y > -2 
value = 1202

;---------------------------------------------------------------------------
;キック着地
[Statedef 1202]
type    = C
movetype= A
physics = S
anim = 1202
velset = 0.25, 0

[State 1202, 1]
type = PosSet
trigger1 = Time = 0
y = 0

[State 1202, 2]
type = VelAdd
trigger1 = Vel X > 0.2
x = -0.05

[State 1202, 3]
type = VelSet
trigger1 = Vel X <= 0.2
x = 0

[State 1202, 10]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
;スラッシュ
[Statedef 1300]
type    = A
movetype= A
physics = N
juggle  = 8
anim = 1300
velset = 0, 0

[State 1300, 1]
type = Veladd
trigger1 = Time > 8
x = 3

[State 1300, 1]
type = Velset
trigger1 = Time > 12
x = 0
y = 0

[State 1200, 1]
type = PlaySnd
trigger1 = AnimElem = 2
value = 50, 1

[State 1200, 1]
type = PlaySnd
trigger1 = AnimElem = 5
value = 50, 3

[State 1200, 1]
type = PlaySnd
trigger1 = AnimElem = 2
value = 1100, 0
channel = 1

[State 1200, 1]
type = PlaySnd
trigger1 = AnimElem = 5
value = 1100, 0
channel = 1

[State 1021, 8]
type = HitDef
trigger1 = AnimElem = 2
attr = A, SA
animtype = High
damage = 60,15
guardflag = HA
hitflag = MAF
getpower  = 10,5
givepower = 50,25
pausetime = 5, 40
sparkno = S225
guard.sparkno = S207
sparkxy = 30,-90
hitsound   = 5,4
guardsound = 6,0
ground.type = High
guard.slidetime = 20

[State 1021, 8]
type = HitDef
trigger1 = AnimElem = 5
attr = A, SA
animtype = Hard
damage = 70,12
guardflag = HA
hitflag = MAF
getpower  = 10,5
givepower = 50,25
pausetime = 5, 25
sparkno = S225
guard.sparkno = S207
sparkxy = 30,-80
hitsound   = 5,4
guardsound = 6,0
ground.type = High
guard.slidetime = 20
p2stateno = 3005

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

;---------------------------------------------------------------------------
;ライトニングブラスト前動作
[Statedef 3000]
type    = A
movetype= A
physics = N
ctrl = 0
velset = 0, 0
anim = 3000
velset = 0, 0
PowerAdd = -1000

[State 3050, Super A]
type = SuperPause
trigger1 = AnimElem = 2
pos = 25, -100
movetime = 65
time = 65

[State 3050, 1]
type = PlaySnd
trigger1 = AnimElem = 1
value = 3100, 2
channel = 1

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

[State 1000, 2]
type = ChangeState
trigger1 = AnimTime = 0
value = 3001

;---------------------------------------------------------------------------
;ライトニングブラスト開始
[Statedef 3001]
type    = A
movetype= A
physics = N
ctrl = 0
velset = 4.5, -5.5
anim = 3001
velset = 0, 0
PowerAdd = -1000

[State 1200, 1]
type = PlaySnd
trigger1 = AnimElem = 1
value = 1100, 0
channel = 1

[State 1000, 2]
type = ChangeState
trigger1 = AnimTime = 0
value = 3002


;---------------------------------------------------------------------------
;ライトニングブラスト攻撃
[Statedef 3002]
type    = A
movetype= A
physics = N
juggle  = 8
anim = 3002
velset = 0, 0

[State 1001, 1]
type = HitDef
trigger1 = AnimElem= 1
attr = A, SA
animtype = Heavy
damage = 180, 45
guardflag = HA
hitflag = MAF
getpower  = 10,5
givepower = 50,25
pausetime = 20, 27
sparkno = S1051
sparkxy = 40, -15
hitsound   = S1100,1
guardsound = 6,0
ground.type = Trip
guard.slidetime = 3
ground.hittime  = 15
ground.velocity = -4
air.velocity = -4
palfx.time = 62
palfx.mul = 192,192,255
palfx.add = 96,96,124
p2stateno = 3005

[State 1052, 1]
type = Projectile
trigger1 = movehit = 1
projanim = 3050
projremovetime = 26
postype = p2
pos = 0, 80

[State 1001, 2]
type = VelSet
trigger1 = Time > 0
x = 7

[State 1001, 3]
type = VelSet
trigger1 = Time > 0
trigger1 = Time < 5
y = -7.5

[State 1001, 4]
type = VelSet
trigger1 = Time > 4   
trigger1 = Time < 15   ;←
y = 0

[State 1001, 5]
type = VelSet
trigger1 = Time > 15   ;←
trigger1 = Pos Y < -2
y = 7.5


[State 1001, 6]
type = VelSet
trigger1 = Time > 20   ;←
x = 0

[State 1001, 8]
type = ChangeState
trigger1 = Time > 20   ;←
trigger2 = Pos Y > -2 
value = 3003

;---------------------------------------------------------------------------
;ライトニングブラスト着地
[Statedef 3003]
type    = C
movetype= A
physics = S
anim = 3003
velset = 0.25, 0

[State 1002, 1]
type = PosSet
trigger1 = Time = 0
y = 0

[State 1002, 2]
type = VelAdd
trigger1 = Vel X > 0.2
x = -0.05

[State 1002, 3]
type = VelSet
trigger1 = Vel X <= 0.2
x = 0

[State 1002, 10]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1
;---------------------
;ライトニングブラスト ヒット時相手動作１
;---------------------
[Statedef 3005]
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 = 3006

;---------------------
;ライトニングブラスト ヒット時相手動作２
;---------------------
[Statedef 3006]
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
;---------------------------------------------------------------------------
; Dash Forward        
[Statedef 100]          
type = A             
physics = A           
ctrl = 0
anim = 100
velset = 5, -5

[State 100, 4]
type = ChangeState
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
value = 101

;---------------------------------------------------------------------------
; Dash forward (land)
[Statedef 101]
type    = S
physics = S
ctrl = 1
anim = 101

[State 106, 3]
type = VelSet
trigger1 = Time = 0
y = 0

[State 106, 3]
type = PosSet
trigger1 = Time = 0
y = 0

[State 106, 5]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

[State 100, 6]
type = MakeDust
trigger1 = Time = 1
pos = -25,3
spacing = 2

[State 100, 6]
type = MakeDust
trigger1 = time >= 8
trigger1 = time <= 25
pos = -15,3

;---------------------------------------------------------------------------

;---------------------------------------------------------------------------
;---------------------------------------------------------------------------
; ここから下に新しいステートを書くと分かりやすくていいと思います
;---------------------------------------------------------------------------

;---------------------------------------------------------------------------
; ここは-2のステートを書いてください、ヘルパー関係です
;---------------------------------------------------------------------------

;---------------------------------------------------------------------------
; ここから下は-3のステートを書いてください、ここに書いたものはゲーム中
; に条件が成立すればいつでも開始するステートです。
;---------------------------------------------------------------------------

[Statedef -3]

;ゲーム中に常にいつでも開始したいステート、ここでは「着地音」に使用しています
;下の条件は「52か106のステートに移動して１フレーム目に」と言う事です。
;52と106はバックステップとジャンプの着地のステートです。
[State -3, Landing Sound]
type = PlaySnd
triggerall = Time = 1
trigger1 = stateno = 52 
trigger2 = stateno = 106 
value = 40, 0
