


;ココはコモンの管理場所です


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

; Stand
[Statedef 0]
type = U
movetype = U
physics = N
movehitpersist = 1
hitdefpersist = 1

[State 0, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 0, ステートタイプ変更]
type = Statetypeset
trigger1 = !ishelper
statetype = S
movetype = I
physics = S
ignorehitpause = 1

[State 0, アニメ変更]
type = Changeanim
triggerall = !ishelper
trigger1 = anim != 0
value = 0
ignorehitpause = 1

[State 0, スプライト表示優先度]
type = Sprpriority
trigger1 = !ishelper
value = 4
ignorehitpause = 1

[State 0, コントロールフラグ]
type = Varset
triggerall = !ishelper
trigger1 = ctrl
sysvar(2) = 1
ignorehitpause = 1

[State 0, コントロール可否]
type = Ctrlset
triggerall = !ishelper
trigger1 = sysvar(2)
trigger2 = roundstate > 2
value = 1
ignorehitpause = 1

[State 0, 振り向き]
type = Turn
triggerall = !ishelper
trigger1 = pos x < enemynear,pos x && facing = -1
trigger2 = enemynear,pos x < pos x && facing = 1
ignorehitpause = 1

[State 0, 準ステート固定]
type = Changestate
triggerall = !ishelper
trigger1 = name = "STGs420"
value = 120
ignorehitpause = 1

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

; Stand to Crouch

[Statedef 10]

[State 10, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 10, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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

; Crouching

[Statedef 11]

[State 45, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 11, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1


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

; Crouch to Stand

[Statedef 12]

[State 45, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 11, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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

; Walk

[Statedef 20]

[State 45, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 11, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1


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

; Jump Start

[Statedef 40]

[State 45, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 11, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1


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

; AirJump Start


[Statedef 45]

[State 45, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 11, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1


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

; Jump Up

[Statedef 50]

[State 50, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 50, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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


[Statedef 51]

[State 51, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 51, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1


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

; Jump Land
[Statedef 52]

[State 52, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 52, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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

; RUN_FWD
[Statedef 100]

[State 100, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 52, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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

; RUN_BACK
[Statedef 105]

[State 52, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 52, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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

; RUN_BACK2 (land)
[Statedef 106]

[State 52, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 52, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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

; RUN_UP
[Statedef 110]

[State 52, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 52, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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

; RUN_DOWN
[Statedef 115]

[State 52, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 52, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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


[Statedef 120]
type = U
movetype = U
physics = U
movehitpersist = 1
hitdefpersist = 1

[State 120, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 120]
type = Null
trigger1 = !ishelper
ignorehitpause = 1


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

; STAND GUARD (guarding)

[Statedef 130]

[State 130, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State ]
type = Selfstate
trigger1 = !ishelper
value = 40
ignorehitpause = 1

[State 130, ヘルパーアニメ変更]
type = Changeanim
trigger1 = ishelper(130)
value = 1001 ;被弾判定
ignorehitpause = 1

[State 130, ヘルパーステートタイプ変更]
type = Statetypeset
trigger1 = ishelper(130)
statetype = C
movetype = I
physics = N
ignorehitpause = 1

[State 130, ヘルパーコントロール不可]
type = Ctrlset
trigger1 = ishelper(130)
value = 0
ignorehitpause = 1

[State 130, ヘルパーライフ]
type = Lifeset
trigger1 = ishelper(130)
value = 9999999999999
ignorehitpause = 1

[State 130, ヘルパー透明化]
type = Assertspecial
trigger1 = ishelper(130)
flag = invisible
flag2 = noshadow
ignorehitpause = 1

[State 130, ヘルパーカメラ固定]
type = Screenbound
trigger1 = ishelper(130)
value = 0
ignorehitpause = 1

[state 130, ヘルパー押し戻し判定解除]
type = Playerpush
trigger1 = ishelper(130)
value = 0
ignorehitpause = 1

[State 130, ヘルパー本体追従]
type = Bindtoroot
trigger1 = ishelper(130)
ignorehitpause = 1

[State 130, 特定属性のみ命中]
type = Hitby
trigger1 = ishelper(130)
value = C, HP
ignorehitpause = 1

[State 130, ヘルパー消去]
type = Destroyself
trigger1 = !alive
trigger2 = !root,alive
ignorehitpause = 1


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

[Statedef 131]
movehitpersist = 1

[State 131, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State ]
type = Selfstate
trigger1 = !ishelper
value = 40
ignorehitpause = 1

[State 131, ヘルパーアニメ変更]
type = Changeanim
trigger1 = ishelper(131)
value = 1000 ; 攻撃判定
ignorehitpause = 1

[State 131, ヘルパーステートタイプ変更]
type = Statetypeset
trigger1 = ishelper(131)
statetype = S
movetype = A
physics = N
ignorehitpause = 1

[State 131, ヘルパーコントロール不可]
type = Ctrlset
trigger1 = ishelper(131)
value = 0
ignorehitpause = 1

[State 131, ヘルパーライフ]
type = Lifeset
trigger1 = ishelper(131)
value = 9999999999999
ignorehitpause = 1

[State 131, ヘルパー透明化]
type = Assertspecial
trigger1 = ishelper(131)
flag = invisible
flag2 = noshadow
ignorehitpause = 1

[State 131, ヘルパーカメラ固定]
type = Screenbound
trigger1 = ishelper(131)
value = 0
ignorehitpause = 1

[State 131, ヘルパー追従]
type = Bindtoroot
trigger1 = ishelper(131)
ignorehitpause = 1

[State 131, ステート習得用]
type = Hitdef
triggerall = ishelper(131)
trigger1 = !sysvar(1)
numhits = 0
attr = S, AA, AT, AP
hitflag = MAFD
ground.type = trip
damage = 1
priority = 7, hit
sparkno = -1
guard.sparkno = -1
yaccel = 999999999999999
fall = 1
fall.recover = 0
fall.damage = 9999999999999
sparkno = -1
guard.sparkno = -1
p2getp1state = 0
ground.hittime = 1
guard.ctrltime = 1

[State 131, 当身感知時]
type = Varset
triggerall = ishelper(131)
trigger1 = movereversed
sysvar(1) = 1
ignorehitpause = 1

[State 131, ヘルパー消去]
type = Destroyself
triggerall = ishelper(131)
trigger1 = !alive
trigger2 = !root,alive
trigger3 = roundstate != 2
trigger4 = numhelper(131) > 1
ignorehitpause = 1



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

; AIR GUARD (guarding)
[Statedef 132]

[State 132, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 132, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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

; LOSE (Time over)
[Statedef 170]
type = U
movetype = U
physics = N
movehitpersist = 1
hitdefpersist = 1

[State 170, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 170, アニメ変更]
type = Changeanim
triggerall = !ishelper
trigger1 = anim != 170
value = 170
ignorehitpause = 1

[State 170, ステートタイプ変更]
type = Statetypeset
trigger1 = !ishelper
statetype = S
movetype = I
physics = S
ignorehitpause = 1

[State 170, コントロール不可]
type = Ctrlset
trigger1 = !ishelper
value = 0
ignorehitpause = 1

[State 170, 準ステート固定]
type = Changestate
trigger1 = !ishelper
value = 120
ignorehitpause = 1

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

; DRAWGAME (Time over)
[Statedef 175]
type = U
movetype = U
physics = N
movehitpersist = 1
hitdefpersist = 1

[State 175, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 175, ステートタイプ変更]
type = Statetypeset
trigger1 = !ishelper
statetype = S
movetype = I
physics = S
ignorehitpause = 1

[State 175, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 170
ignorehitpause = 1

[State 175, 準ステート固定]
type = Changestate
trigger1 = !ishelper
value = 120
ignorehitpause = 1

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

[Statedef 180]
type = U
movetype = U
physics = N
movehitpersist = 1
hitdefpersist = 1

[State 180, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 180, ステートタイプ変更]
type = Statetypeset
trigger1 = !ishelper
statetype = S
movetype = I
physics = S
ignorehitpause = 1

[State 181, 2]
type = playsnd
trigger1 = animelem = 1
value = 0,14

[State 180, 1]
type = ChangeState
triggerall = !ishelper
trigger1 = win
value = 181
ignorehitpause = 1

[State 180, 準ステ固定]
type = Changestate
trigger1 = !ishelper
value = 120
ignorehitpause = 1

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

; WIN1
[Statedef 181]
type = U
movetype = U
physics = N
movehitpersist = 1
hitdefpersist = 1

[State 181, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 181, アニメ変更]
type = Changeanim
triggerall = !ishelper
trigger1 = anim != 181
value = 181
ignorehitpause = 1

[State 181, ステートタイプ変更]
type = Statetypeset
trigger1 = !ishelper
statetype = S
movetype = I
physics = S
ignorehitpause = 1

[State 181, コントロール可否]
type = Ctrlset
trigger1 = !ishelper
value = 0
ignorehitpause = 1

[State 181, 位置調整]
type = Velset
trigger1 = !ishelper
x = 0
y = 0
ignorehitpause = 1

[State 181, 2]
type = playsnd
trigger1 = animelem = 1
value = 0,14

[State 181, 準ステ固定]
type = Changestate
trigger1 = !ishelper
value = 120
ignorehitpause = 1

;---------------------------------------------------------------------------
; PREINTRO
[Statedef 190]

[State 190, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 190, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 170
ignorehitpause = 1

[State 190, 準ステ固定]
type = Changestate
trigger1 = !ishelper
value = 120
ignorehitpause = 1

;---------------------------------------------------------------------------
; INTRO (override this state to give character an intro)
[Statedef 191]

[State 191, 自キャラ以外だった場合]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 191, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 170
ignorehitpause = 1

[State 191, 準ステ固定]
type = Changestate
trigger1 = !ishelper
value = 120
ignorehitpause = 1

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









[Statedef 5000]

[State 5000, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5000, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1


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


[Statedef 5001]

[State 5000, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5000, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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


[Statedef 5010]

[State 5000, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5000, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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


[Statedef 5011]

[State 5000, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5000, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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


[Statedef 5020]

[State 5000, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5000, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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


[Statedef 5030]

[State 5000, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5000, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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


[Statedef 5035]

[State 5000, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5000, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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


[Statedef 5040]

[State 5000, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5000, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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


[Statedef 5050]

[State 5000, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5000, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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


[Statedef 5070]

[State 5000, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5000, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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

; HIT_TRIP2 (fall through air)
[Statedef 5071]

[State 5000, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5000, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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

; HITL_SHAKE
[Statedef 5080]

[State 5000, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5000, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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

[Statedef 5081]

[State 5000, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5000, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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


[Statedef 5100]

[State 5000, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5000, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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

[Statedef 5101]

[State 5000, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5000, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1


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

[Statedef 5110]

[State 5000, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5000, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1


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

; HIT_GETUP
[Statedef 5120]

[State 5000, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5000, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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


;死、死んでる…！こいつ死んでるぞ…！

[Statedef 5150]

[State 5150, ステートタイプ変更]
type = Statetypeset
trigger1 = !ishelper
statetype = L
movetype = H
physics = N
ignorehitpause = 1

[State 5150, アニメ変更]
type = Changeanim
triggerall = !ishelper
triggerall = name = "STGs420"
trigger1 = anim != 5150
value = 5150
ignorehitpause = 1

[State 5150, 死亡]
type = Lifeset
triggerall = !ishelper
trigger1 = name != "STGs420"
value = 0
ignorehitpause = 1

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

; HIT_FALLRECOVER (still falling)
[Statedef 5200]

[State 5200, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5200, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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

; HIT_FALLRECOVER (on the ground)
[Statedef 5201]

[State 5200, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5200, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1

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

; HIT_AIRFALLRECOVER
[Statedef 5210]

[State 5200, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5200, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1


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







; Continue?
[Statedef 5500]

[State 5200, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
value = 5150
ignorehitpause = 1

[State 5200, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 170
ignorehitpause = 1


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


; Initialize (at the start of the round)
[Statedef 5900]

[State 5200, 自キャラ以外だった場合ｏｒ死亡時]
type = Changestate
trigger1 = name != "STGs420"
trigger2 = !alive
value = 5150
ignorehitpause = 1

[State 5200, ステート変更]
type = Changestate
trigger1 = !ishelper
value = 0
ignorehitpause = 1






