;********************************************
; 超必杀技设置
;********************************************

;---[圣盾术]---
[statedef 3000]
type = S
movetype= I
physics = S
anim = 3000
velset = 0,0
ctrl = 0
sprpriority = 3

[State 3000, SuperPause]
type = SuperPause
trigger1 = time = 0
time = 20
movetime = 0
anim = -1

[State 3000, NotHitBy]
type = NotHitBy
trigger1 = numhelper(3001) = 0
value = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
;value2 = S,NA
time = 2
;ignorehitpause =
;persistent =

[State -2, PlaySnd]
type = PlaySnd
trigger1 = animelem = 7
value = 3000,0
volume = 200
;channel = 0
;lowpriority = -1
freqmul = 1
;loop = 0
;pan = 0
;abspan =
;ignorehitpause =
;persistent =

[state 3000,圣盾]
type = helper
trigger1 = animelem = 8
trigger1 = numhelper(3001) = 0
postype = P1
pos = 0 , -80
stateno = 3001
ID = 3001
ownpal = 1

[state 0,varset]
type = varset
trigger1 = time = 0
v = 12    ;fv = 10
value = 1

[State 3000,end]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;---[圣盾术-效果持续]---
[statedef 3001]
type = S
movetype = I
physics = S
anim = 23000
velset = 0,0
ctrl = 0
sprpriority = 10

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

[State 0, PosSet]
type = PosSet
trigger1 = parent,statetype != A
x = parent,pos x
y = -80 + parent,pos y
;ignorehitpause =
;persistent =

[State 0, PosSet]
type = PosSet
trigger1 = parent,statetype = A
x = parent,pos x
y = -105 + parent,pos y
;ignorehitpause =
;persistent =

[State 0, DestroySelf]
type = DestroySelf
trigger1 = time = 300
;ignorehitpause =
;persistent =

;---[圣盾术]---
[statedef 3010]
type = A
movetype= I
physics = A
anim = 2000
ctrl = 0
sprpriority = 3

[State 3000, SuperPause]
type = SuperPause
trigger1 = time = 0
time = 20
movetime = 0
anim = -1

[State 3000, NotHitBy]
type = NotHitBy
trigger1 = numhelper(3001) = 0
value = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
;value2 = S,NA
time = 2
;ignorehitpause =
;persistent =

[state 3000,圣盾]
type = helper
trigger1 = animelem = 2
trigger1 = numhelper(3001) = 0
postype = P1
pos = 0 , -80
stateno = 3001
ID = 3001
ownpal = 1

[state 0,varset]
type = varset
trigger1 = time = 0
v = 12    ;fv = 10
value = 1

;---[制裁之锤]---
[statedef 3100]
type = S
movetype= A
physics = S
anim = 3100
velset = 0,0
ctrl = 0
sprpriority = 3

[State 0, 惩戒能量消耗]
type = VarAdd
trigger1 = time = 0
v = 22
value = -3
;ignorehitpause =
;persistent =

[State 0, 惩戒能量消耗]
type = VarAdd
trigger1 = time = 0
v = 20
value = -3
;ignorehitpause =
;persistent =

;[State 3100, PowerAdd]
;type = PowerAdd
;trigger1 = time = 0
;value = -2000
;;ignorehitpause =
;;persistent =

[State 3100, SuperPause]
type = SuperPause
trigger1 = time = 0
time = 20
movetime = 0
anim = -1

[State -2, PlaySnd]
type = PlaySnd
trigger1 = animelem = 8
value = 3100,0
volume = 200
;channel = 0
;lowpriority = -1
freqmul = 1
;loop = 0
;pan = 0
;abspan =
;ignorehitpause =
;persistent =

[State 0, Explod]
type = Explod
trigger1 = animelem = 10
trigger1 = numexplod(23100) = 0
anim = 23100
ID = 23100
pos = 30,-80
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = -1
removetime = -2
scale = .5,.5
sprpriority = 9
ontop = 0
shadow = 0,0,0
ownpal = 1
removeongethit = 1
;ignorehitpause =
;persistent =

[state 3100,命中火花]
type = helper
trigger1 = animelem = 10
trigger1 = numhelper(3101) = 0
postype = P1
pos = ifelse(p2bodydist x > 100,100,p2bodydist x), -60
stateno = 3101
ID = 3101
ownpal = 1

[State 3100, 超杀背景]
type = Explod
trigger1 = time = 0
trigger1 = numexplod(24000) = 0
anim = 24000
sprpriority = -6
bindtime = -1
ignorehitpause = 1
pos = 0,0
scale = .6,.6
postype = left
Id = 24000
removetime = -1
removeongethit = 1
ownpal = 1

[State 3100, RemoveExplod]
type = RemoveExplod
trigger1 = animtime = 0
id = 24000
;ignorehitpause =
;persistent =

[State 3100,end]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;---[制裁之锤1]---
[statedef 3101]
type = S
movetype = A
physics = S
anim = 23101
velset = 0,0
ctrl = 0
sprpriority = 10

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

[State 800, 1]
type = HitDef
trigger1 = time = 0
trigger1 = p2statetype != A
attr = S, ST
hitflag = MAF
priority = 3, miss
sparkno = -1
hitonce = 1
numhits = 0
p2stateno = 13110

[State 0, DestroySelf]
type = DestroySelf
trigger1 = time = 30
;ignorehitpause =
;persistent =

;---[制裁之锤2]---
[statedef 3102]
type = S
movetype = A
physics = S
anim = 23102
velset = 0,0
ctrl = 0
sprpriority = 10

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

[State 800, 1]
type = HitDef
trigger1 = time = 0
attr = S, ST
hitflag = MAF
priority = 3, miss
sparkno = -1
hitonce = 1
numhits = 0
p2stateno = 13110

[State 0, DestroySelf]
type = DestroySelf
trigger1 = time = 2
;ignorehitpause =
;persistent =

;---[制裁之锤3]---
[statedef 3103]
type = S
movetype = A
physics = S
anim = 23102
velset = 0,0
ctrl = 0
sprpriority = 10

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

[State 800, 1]
type = HitDef
trigger1 = time = 0
attr = S, HT
hitflag = MAF
priority = 3, miss
sparkno = -1
hitonce = 1
numhits = 0
p2stateno = 13130

[State 0, DestroySelf]
type = DestroySelf
trigger1 = time = 2
;ignorehitpause =
;persistent =


;---[制裁之锤-挨打状态1]---
[statedef 13110]
type = S
movetype = H
physics = S
velset = 0,0
ctrl = 0
sprpriority = 3

[State 0, PosSet]
type = PosSet
trigger1 = time = 0
y = 0
;ignorehitpause =
;persistent =

[State 0, ChangeAnim]
type = ChangeAnim2
trigger1 = anim !=3110
value = 3110
;elem = 1
;ignorehitpause =
;persistent =

[State 0, HitOverride]
type = HitOverride
trigger1 = 1
attr = SCA,NA,SA,HA,NP,SP,HP,NT,ST;,HT
slot = 0
stateno = 13120
time = 1
forceair = 0
;ignorehitpause =
;persistent =

[State 3150, VelSet]
type = VelSet
trigger1 = Life = 0
x = GetHitVar(xvel)
y = GetHitVar(yvel)

[State 3150, End]
type = SelfState
trigger1 = Life = 0
value = 5050
;anim =
;ctrl =
;ignorehitpause = 0
;persistent = 1

;---[制裁之锤-挨打状态2]---
[Statedef 13120]
type = U
movetype = U
physics = U

[State 4810, PalFX]
type = PalFX
trigger1 = Life > 0
trigger1 = Time = 0
time = 2
add = 0,-200,-200
mul = 256,256,256
ignorehitpause = 1

[State 4810, PosFreeze]
type = PosFreeze
trigger1 = Life > 0
trigger1 = 1
ignorehitpause
value = 1

[State 3150, HITSHAKE] ;Freeze anim
type = ChangeAnim
trigger1 = 1
value = Anim
elem  = AnimElemNo(0)

[State 3150, VelSet]
type = VelSet
trigger1 = Life = 0
x = GetHitVar(xvel)
y = GetHitVar(yvel)

[State 3150, End]
type = SelfState
trigger1 = Life = 0
value = 5050

;---[制裁之锤-挨打状态3]---
[statedef 13130]
type = U
movetype = U
physics = U
ctrl = 0
sprpriority = 3

[State 3150, VelSet]
type = VelSet
trigger1 = time = 0
x = GetHitVar(xvel)
y = GetHitVar(yvel)

[State 3150, End]
type = SelfState
trigger1 = time = 0
value = 5050
;anim =
;ctrl =
;ignorehitpause = 0
;persistent = 1
