;=====================<REPPUKEN>==========================
[StateDef 1000]
type = S
physics = S
moveType = A
anim = 1000
ctrl = 0
velset = 0,0
sprPriority = 1
poweradd = 84 * !var(20)
faceP2 = 1

[State 1000, Voice]
type = PlaySnd
trigger1 = AnimElem = 4
value = 1000,3
channel = 0

[State 1000, Reppuken Snd]
type = PlaySnd
trigger1 = AnimElem = 5
value = 1000, 4
channel = 2

[State 1000, Width: Player]
type = Width
trigger1 = AnimElemTime(7) < 0
player = 18,0

[State 1000, Hand FX]
type = Explod
trigger1 = AnimElem = 3
anim = 1005
ID = 1005
pos = 0, 28
postype = P1
sprpriority = 2
scale = 1,1
ignorehitpause = 1
bindtime = -1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1000, Projectile]
type = Helper
trigger1 = AnimElem = 6
helperType = Normal
stateNo = 1010
ID = 1010
name = "Reppuken"
posType = P1
pos = 45,2
size.xScale = 0.38
size.yScale = 0.35
keyctrl = 1
ownpal = 1
facing = 1
persistent = 0
ignorehitpause = 1

[State 1000, End]
type = ChangeState
trigger1 = !AnimTime
value = 0
ctrl = 1

;Med
[StateDef 1001]
type = S
physics = S
moveType = A
anim = 1001
ctrl = 0
velset = 0,0
sprPriority = 1
poweradd = 84 * !var(20)
faceP2 = 1

[State 1001, Voice]
type = PlaySnd
trigger1 = AnimElem = 4
value = 1000,3
channel = 0

[State 1001, Reppuken Snd]
type = PlaySnd
trigger1 = AnimElem = 5
value = 1000, 4
channel = 2

[State 1001, Width: Player]
type = Width
trigger1 = AnimElemTime(7) < 0
player = 18,0

[State 1001, Hand FX]
type = Explod
trigger1 = AnimElem = 3
anim = 1006
ID = 1006
pos = 3, 28
postype = P1
sprpriority = 2
scale = 1,1
ignorehitpause = 1
bindtime = -1
;pausemovetime = 65535
;supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1001, Projectile]
type = Helper
trigger1 = AnimElem = 6
helperType = Normal
stateNo = 1014
ID = 1010
name = "Reppuken"
posType = P1
pos = 45,2
size.xScale = 0.38
size.yScale = 0.35
keyctrl = 1
ownpal = 1
facing = 1
persistent = 0
ignorehitpause = 1

[State 1001, End]
type = ChangeState
trigger1 = !AnimTime
value = 0
ctrl = 1

;Strong
[StateDef 1002]
type = S
physics = S
moveType = A
anim = 1002
ctrl = 0
velset = 0,0
sprPriority = 1
poweradd = 84 * !var(20)
faceP2 = 1

[State 1002, Voice]
type = PlaySnd
trigger1 = AnimElem = 2
value = 1000,5
channel = 0

[State 1002, Reppuken Snd]
type = PlaySnd
trigger1 = AnimElem = 3 || AnimElem = 9
value = 1000, 4
channel = 2

[State 1002, Width: Player]
type = Width
trigger1 = AnimElemTime(12) < 0
player = 18,0

[State 1002, Hand FX 1]
type = Explod
trigger1 = AnimElem = 3
anim = 1007
ID = 1005
pos = 0, 28
postype = P1
sprpriority = 2
scale = 1,1
ignorehitpause = 1
bindtime = -1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1002, Hand FX 2]
type = Explod
trigger1 = AnimElem = 9
anim = 1008
ID = 1008
pos = 3, 28
postype = P1
sprpriority = 2
scale = 1,1
ignorehitpause = 1
bindtime = -1
;pausemovetime = 65535
;supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1002, Projectile 1]
type = Helper
trigger1 = AnimElem = 6
helperType = Normal
stateNo = 1015
ID = 1010
name = "Double Reppuken"
posType = P1
pos = 0,0
size.xScale = 0.475
size.yScale = 0.475
keyctrl = 1
ownpal = 1
facing = 1
persistent = 0
ignorehitpause = 1

[State 1002, Projectile 2]
type = Helper
trigger1 = AnimElem = 11
helperType = Normal
stateNo = 1016
ID = 1010
name = "Double Reppuken"
posType = P1
pos = 55,2
size.xScale = 0.475
size.yScale = 0.475
keyctrl = 1
ownpal = 1
facing = 1
persistent = 0
ignorehitpause = 1

[State 1002, End]
type = ChangeState
trigger1 = !AnimTime
value = 300
ctrl = 1

;=======================<EX REPPUKEN>=======================
[StateDef 1030]
type = S
physics = S
moveType = A
anim = 1030
ctrl = 0
velset = 0,0
sprPriority = 1
poweradd = ifelse(var(20) > 0, 0, -500)
faceP2 = 1

[State 1030, MAX Timer Drain]
type = VarAdd
trigger1 = !Time
trigger1 = var(20) > 0
var(20) = -335

[State 1030, EX Sound]
type = PlaySnd
trigger1 = !Time
value = 0, ifelse(!fvar(31), 1000, 1001)

[State 1030, EX Flash]
type = VarSet
trigger1 = !Time
var(25) = 60

[State 1030, EX FX(Phantom)]
type = Explod
triggerall = !fvar(31)
trigger1 = !Time
anim = 8210
sprPriority = 3
posType = p1
pos = -2, -74
scale = 0.5, 0.5
pauseMoveTime = -1
superMoveTime = -1
ownPal = 1

[State 1030, EX FX 1(Divine)]
type = Explod
triggerall = fvar(31)
trigger1 = !Time
anim = 8220
sprpriority = 4
postype = p1
pos = 0, 0
bindtime = 1
facing = -1
scale = 0.5, 0.5;based on char size
pauseMoveTime = -1
superMoveTime = -1
ownpal = 1

[State 1030, EX FX 2(Divine)]
type = Explod
triggerall = fvar(31)
trigger1 = !Time
anim = 8221
sprpriority = -1
postype = p1
pos = 0, 0
bindtime = 1
facing = 1
scale = 0.5, 0.5;based on char size
pauseMoveTime = -1
superMoveTime = -1
ownpal = 1

[State 1030, Voice]
type = PlaySnd
trigger1 = AnimElem = 2
value = 1000,5
channel = 0

[State 1030, Reppuken Snd]
type = PlaySnd
trigger1 = AnimElem = 3 || AnimElem = 9
value = 1000, 4
channel = 2

[State 1030, Width: Player]
type = Width
trigger1 = AnimElemTime(12) < 0
player = 18,0

[State 1030, Hand FX 1]
type = Explod
trigger1 = AnimElem = 3
anim = 1007
ID = 1005
pos = 0, 28
postype = P1
sprpriority = 2
scale = 1,1
ignorehitpause = 1
bindtime = -1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1030, Hand FX 2]
type = Explod
trigger1 = AnimElem = 9
anim = 1032
ID = 1032
pos = 3, 28
postype = P1
sprpriority = 2
scale = 1,1
ignorehitpause = 1
bindtime = -1
;pausemovetime = 65535
;supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1030, Projectile 1]
type = Helper
trigger1 = AnimElem = 6
helperType = Normal
stateNo = 1035
ID = 1010
name = "Double Reppuken"
posType = P1
pos = 45,2
size.xScale = 0.38
size.yScale = 0.35
keyctrl = 1
ownpal = 1
facing = 1
persistent = 0
ignorehitpause = 1

[State 1030, Projectile 2]
type = Helper
trigger1 = AnimElem = 11
helperType = Normal
stateNo = 1035
ID = 1010
name = "Double Reppuken"
posType = P1
pos = 45,2
size.xScale = 0.38
size.yScale = 0.35
keyctrl = 1
ownpal = 1
facing = 1
persistent = 0
ignorehitpause = 1

[State 1030, End]
type = ChangeState
trigger1 = !AnimTime
value = 300
ctrl = 1

;========================<HARD EDGE>=======================
[Statedef 1100]
type = S
movetype = A
physics = N
anim = 1100
ctrl = 0
velset = 0,0
poweradd = 70 * !var(20)
sprpriority = 2
facep2 = 1

[State 1100, Width]
type = Width
trigger1 = 1
edge = 20,0

[State 1100, Voice]
type = PlaySnd
trigger1 = AnimElem = 3
value = 1100,0
channel = 0

[State 1100, Fly Snd]
type = PlaySnd
trigger1 = AnimElem = 4
value = 1000,0
channel = 2

[State 1100, Land Snd]
type = PlaySnd
trigger1 = AnimElem = 10
value = 52, 0

[State 1100, Velocity]
type = VelSet
trigger1 = AnimElem = 4 
x = 10.5

[State 1100, Friction]
type = VelMul
trigger1 = vel x > 0
trigger1 = AnimElemTime(7) > 0 
x = .88

[State 1100, VelStop]
type = VelSet
trigger1 = AnimElem = 10 
x = 0

[State 1100, PosAdd]
type = PosAdd
trigger1 = AnimElem = 4
trigger2 = AnimElem = 5
trigger3 = AnimElem = 6
y = -2

[State 1100, PosSet]
type = PosSet
trigger1 = AnimElem = 7
y = 0

[State 1100, StateType: Air, No Phys]
type = StateTypeSet
trigger1 = AnimElem = 4
statetype = A
physics = N

[State 1100, StateType: Standing, No Phys]
type = StateTypeSet
trigger1 = AnimElem = 7
statetype = S
physics = N

[State 1100, FX 1]
type = Explod
trigger1 = AnimElem = 3
anim = 1101
ID = 1101
pos = 0, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1100, FX 2]
type = Explod
trigger1 = AnimElem = 4
anim = 1102
ID = 1102
pos = 0, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1100, FX 3]
type = Explod
triggerall = AnimElemTime(5) > 0
trigger1 = AnimElemTime(7) < 0
anim = 1103
ID = 1103
pos = -30, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1100, End FX 1]
type = Explod
trigger1 = AnimElem = 9
anim = 1102
ID = 1102
pos = 40, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1
facing = -1

[State 1100, End FX 2]
type = Explod
trigger1 = AnimElem = 10
anim = 1103
ID = 1103
pos = 45, 0
postype = P1
sprpriority = 3
scale = 0.8,0.8
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1100, End FX 3]
type = Explod
trigger1 = AnimElem = 10
anim = 1103
ID = 1103
pos = 52, 0
postype = P1
sprpriority = 3
scale = 0.6,0.6
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1100, End FX 4]
type = Explod
trigger1 = AnimElem = 10
anim = 1103
ID = 1103
pos = 57, 0
postype = P1
sprpriority = 3
scale = 0.5,0.5
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1100, Hit] 
type = HitDef
trigger1 = !var(16) && var(15) < 1
trigger1 = AnimElem = 5
attr = A, SA
damage = ceil(ifElse(fvar(11) * 84 < 7, 7, fvar(11) * 84)), 7
priority = 4, hit
animtype = Hard
getpower = 70 * !var(20), 30 * !var(20)
givepower = 35, 35
guardflag = MA
hitflag = MAF
hitsound = S2,2
guardsound = S130,0
pausetime = 12,12
guard.pausetime = 12,12
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 49), var(36) := -73
air.animtype = Back
fall.animtype = Back
ground.type = High
air.type = High
ground.slidetime = 18
ground.hittime  = 18
guard.hittime = 18
ground.velocity = -6, -4.5
air.velocity = -6, -4.5
guard.velocity = -8
airguard.velocity = -6.65, -1
airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .5
fall = 1
fall.recover = 0
forcestand = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1100, StateTypeSet: Idle]
type = StateTypeSet
trigger1 = AnimElemTime(7) >= 0
moveType = I

[State 1100, End]
type = ChangeState
trigger1 = !AnimTime
value = 301
ctrl = 1

;Alpha Counter version
[Statedef 1101]
type = S
movetype = A
physics = N
anim = 1100
ctrl = 0
velset = 0,0
poweradd = 0
sprpriority = 2
facep2 = 1

[State 1101, Width]
type = Width
trigger1 = 1
edge = 20,0

[State 1101, Voice]
type = PlaySnd
trigger1 = AnimElem = 3
value = 1100,0
channel = 0

[State 1101, Fly Snd]
type = PlaySnd
trigger1 = AnimElem = 4
value = 1000,0
channel = 2

[State 1101, Land Snd]
type = PlaySnd
trigger1 = AnimElem = 10
value = 52, 0

[State 1101, Velocity]
type = VelSet
trigger1 = AnimElem = 4 
x = 10.5

[State 1101, Friction]
type = VelMul
trigger1 = vel x > 0
trigger1 = AnimElemTime(7) > 0 
x = .88

[State 1101, VelStop]
type = VelSet
trigger1 = AnimElem = 10 
x = 0

[State 1101, PosAdd]
type = PosAdd
trigger1 = AnimElem = 4
trigger2 = AnimElem = 5
trigger3 = AnimElem = 6
y = -2

[State 1101, PosSet]
type = PosSet
trigger1 = AnimElem = 7
y = 0

[State 1101, StateType: Air, No Phys]
type = StateTypeSet
trigger1 = AnimElem = 4
statetype = A
physics = N

[State 1101, StateType: Standing, No Phys]
type = StateTypeSet
trigger1 = AnimElem = 7
statetype = S
physics = N

[State 1101, FX 1]
type = Explod
trigger1 = AnimElem = 3
anim = 1101
ID = 1101
pos = 0, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1101, FX 2]
type = Explod
trigger1 = AnimElem = 4
anim = 1102
ID = 1102
pos = 0, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1101, FX 3]
type = Explod
triggerall = AnimElemTime(5) > 0
trigger1 = AnimElemTime(7) < 0
anim = 1103
ID = 1103
pos = -30, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1101, End FX 1]
type = Explod
trigger1 = AnimElem = 9
anim = 1102
ID = 1102
pos = 40, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1
facing = -1

[State 1101, End FX 2]
type = Explod
trigger1 = AnimElem = 10
anim = 1103
ID = 1103
pos = 45, 0
postype = P1
sprpriority = 3
scale = 0.8,0.8
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1101, End FX 3]
type = Explod
trigger1 = AnimElem = 10
anim = 1103
ID = 1103
pos = 52, 0
postype = P1
sprpriority = 3
scale = 0.6,0.6
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1101, End FX 4]
type = Explod
trigger1 = AnimElem = 10
anim = 1103
ID = 1103
pos = 57, 0
postype = P1
sprpriority = 3
scale = 0.5,0.5
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1101, Muteki]
type = Nothitby
trigger1 = AnimElemTime(7)<0
time = 1
value = SCA

[State 1101, Hit] 
type = HitDef
trigger1 = !var(16) && var(15) < 1
trigger1 = AnimElem = 5
attr = A, SA
damage = ceil(ifElse(fvar(11) * 84 < 7, 7, fvar(11) * 84)), 7
priority = 6, hit
animtype = Diagup
getpower = 0, 0
givepower = 35, 35
guardflag = MA
hitflag = MAF
hitsound = S2,2
guardsound = S130,0
pausetime = 12,12
guard.pausetime = 12,12
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 49), var(36) := -73
air.animtype = Diagup
fall.animtype = Diagup
ground.type = High
air.type = High
ground.slidetime = 18
ground.hittime  = 18
guard.hittime = 18
ground.velocity = -8, -4.5
air.velocity = -8, -4.5
guard.velocity = -8
airguard.velocity = -6.65, -1
airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .58
fall = 1
fall.recover = 0
forcestand = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1101, StateTypeSet: Idle]
type = StateTypeSet
trigger1 = AnimElemTime(7) >= 0
moveType = I

[State 1101, End]
type = ChangeState
trigger1 = !AnimTime
value = 301
ctrl = 1

;Med
[Statedef 1110]
type = S
movetype = A
physics = N
anim = 1110
ctrl = 0
velset = 0,0
poweradd = 70 * !var(20)
sprpriority = 2
facep2 = 1

[State 1110, Width]
type = Width
trigger1 = 1
edge = 20,0

[State 1110, Voice]
type = PlaySnd
trigger1 = AnimElem = 3
value = 1100,0
channel = 0

[State 1110, Fly Snd]
type = PlaySnd
trigger1 = AnimElem = 4
value = 1000,0
channel = 2

[State 1110, Land Snd]
type = PlaySnd
trigger1 = AnimElem = 11
value = 52, 0

[State 1110, Velocity]
type = VelSet
trigger1 = AnimElem = 4 
x = 12

[State 1110, Friction]
type = VelMul
trigger1 = vel x > 0
trigger1 = AnimElemTime(8) > 0 
x = .88

[State 1110, VelStop]
type = VelSet
trigger1 = AnimElem = 11 
x = 0

[State 1110, PosAdd]
type = PosAdd
trigger1 = AnimElem = 4
y = -2

[State 1110, PosSet]
type = PosSet
trigger1 = AnimElem = 8
y = 0

[State 1110, StateType: Air, No Phys]
type = StateTypeSet
trigger1 = AnimElem = 4
statetype = A
physics = N

[State 1110, StateType: Standing, No Phys]
type = StateTypeSet
trigger1 = AnimElem = 8
statetype = S
physics = N

[State 1110, FX 1]
type = Explod
trigger1 = AnimElem = 3
anim = 1101
ID = 1101
pos = 0, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1110, FX 2]
type = Explod
trigger1 = AnimElem = 4
anim = 1102
ID = 1102
pos = 0, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1110, FX 3]
type = Explod
triggerall = AnimElemTime(5) > 0
trigger1 = AnimElemTime(8) < 0
anim = 1103
ID = 1103
pos = -30, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1110, End FX 1]
type = Explod
trigger1 = AnimElem = 10
anim = 1102
ID = 1102
pos = 40, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1
facing = -1

[State 1110, End FX 2]
type = Explod
trigger1 = AnimElem = 11
anim = 1103
ID = 1103
pos = 45, 0
postype = P1
sprpriority = 3
scale = 0.8,0.8
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1110, End FX 3]
type = Explod
trigger1 = AnimElem = 11
anim = 1103
ID = 1103
pos = 52, 0
postype = P1
sprpriority = 3
scale = 0.6,0.6
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1110, End FX 4]
type = Explod
trigger1 = AnimElem = 11
anim = 1103
ID = 1103
pos = 57, 0
postype = P1
sprpriority = 3
scale = 0.5,0.5
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1110, Hit] 
type = HitDef
trigger1 = !var(16) && var(15) < 1
trigger1 = AnimElem = 5
attr = A, SA
damage = ceil(ifElse(fvar(11) * 91 < 7, 7, fvar(11) * 91)), 7
priority = 4, hit
animtype = Hard
getpower = 70 * !var(20), 30 * !var(20)
givepower = 35, 35
guardflag = MA
hitflag = MAF
hitsound = S2,2
guardsound = S130,0
pausetime = 12,12
guard.pausetime = 12,12
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 49), var(36) := -73
air.animtype = Back
fall.animtype = Back
ground.type = High
air.type = High
ground.slidetime = 18
ground.hittime  = 18
guard.hittime = 18
ground.velocity = -6, -4.5
air.velocity = -6, -4.5
guard.velocity = -8
airguard.velocity = -6.65, -1
airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .5
fall = 1
fall.recover = 0
forcestand = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1110, StateTypeSet: Idle]
type = StateTypeSet
trigger1 = AnimElemTime(8) >= 0
moveType = I

[State 1110, End]
type = ChangeState
trigger1 = !AnimTime
value = 301
ctrl = 1

;Strong
[Statedef 1120]
type = S
movetype = A
physics = N
anim = 1120
ctrl = 0
velset = 0,0
poweradd = 70 * !var(20)
sprpriority = 2
facep2 = 1

[State 1120, Width]
type = Width
trigger1 = 1
edge = 20,0

[State 1120, Voice]
type = PlaySnd
trigger1 = AnimElem = 3
value = 1100,0
channel = 0

[State 1120, Fly Snd]
type = PlaySnd
trigger1 = AnimElem = 4
value = 1000,0
channel = 2

[State 1120, Land Snd]
type = PlaySnd
trigger1 = AnimElem = 12
value = 52, 0

[State 1120, Velocity]
type = VelSet
trigger1 = AnimElem = 4 
x = 14.95

[State 1120, Friction]
type = VelMul
trigger1 = vel x > 0
trigger1 = AnimElemTime(9) > 0 
x = .88

[State 1120, VelStop]
type = VelSet
trigger1 = AnimElem = 12 
x = 0

[State 1120, PosAdd]
type = PosAdd
trigger1 = AnimElem = 4
trigger2 = AnimElem = 5
trigger3 = AnimElem = 6
y = -2

[State 1120, PosSet]
type = PosSet
trigger1 = AnimElem = 9
y = 0

[State 1120, StateType: Air, No Phys]
type = StateTypeSet
trigger1 = AnimElem = 4
statetype = A
physics = N

[State 1120, StateType: Standing, No Phys]
type = StateTypeSet
trigger1 = AnimElem = 9
statetype = S
physics = N

[State 1120, FX 1]
type = Explod
trigger1 = AnimElem = 3
anim = 1101
ID = 1101
pos = 0, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1120, FX 2]
type = Explod
trigger1 = AnimElem = 4
anim = 1102
ID = 1102
pos = 0, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1120, FX 3]
type = Explod
triggerall = AnimElemTime(5) > 0
trigger1 = AnimElemTime(9) < 0
anim = 1103
ID = 1103
pos = -30, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1120, Hand Energy FX]
type = Explod
trigger1 = AnimElem = 5
anim = 1104
ID = 1104
pos = -16, -53
postype = P1
sprpriority = 3
scale = 0.5,0.5
ignorehitpause = 1
bindtime = -1
pausemovetime = 255
supermovetime = 255
ownpal = 1
removeongethit = 1

[State 1120, End FX 1]
type = Explod
trigger1 = AnimElem = 11
anim = 1102
ID = 1102
pos = 40, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1
facing = -1

[State 1120, End FX 2]
type = Explod
trigger1 = AnimElem = 12
anim = 1103
ID = 1103
pos = 45, 0
postype = P1
sprpriority = 3
scale = 0.8,0.8
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1120, End FX 3]
type = Explod
trigger1 = AnimElem = 12
anim = 1103
ID = 1103
pos = 52, 0
postype = P1
sprpriority = 3
scale = 0.6,0.6
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1120, End FX 4]
type = Explod
trigger1 = AnimElem = 12
anim = 1103
ID = 1103
pos = 57, 0
postype = P1
sprpriority = 3
scale = 0.5,0.5
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1120, Hit] 
type = HitDef
trigger1 = !var(16) && var(15) < 1
trigger1 = AnimElem = 5
attr = A, SA
damage = ceil(ifElse(fvar(11) * 77 < 7, 7, fvar(11) * 77)), 7
priority = 4, hit
animtype = Hard
getpower = 70 * !var(20), 30 * !var(20)
givepower = 35, 35
guardflag = MA
hitflag = MAF
hitsound = S2,2
guardsound = S130,0
pausetime = 12,12
guard.pausetime = 12,12
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 49), var(36) := -73
air.animtype = Back
fall.animtype = Back
ground.type = High
air.type = High
ground.slidetime = 18
ground.hittime  = 18
guard.hittime = 18
ground.velocity = -8
air.velocity = -4, -6.5
guard.velocity = -8
airguard.velocity = -6.65, -1
airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .5
fall = 0
air.fall = 1
fall.recover = 0
forcestand = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1120, StateTypeSet: Idle]
type = StateTypeSet
trigger1 = AnimElemTime(10) >= 0
moveType = I

[State 1120, Hard Edge Finish]
type = ChangeState
trigger1 = MoveContact
trigger1 = AnimElemTime(5) > 0 && AnimElemTime(10) < 0 
value = 1121

[State 1120, End]
type = ChangeState
trigger1 = !AnimTime
value = 301
ctrl = 1

;Strong Hard Edge Finish
[Statedef 1121]
type = S
movetype = A
physics = N
anim = 1121
ctrl = 0
poweradd = 50 * !var(20)
sprpriority = 2

[State 1121, PosSet]
type = PosSet
trigger1 = !Time
y = 0

[State 1121, Width]
type = Width
trigger1 = 1
edge = 20,0

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

[State 1121, Swing Snd]
type = PlaySnd
trigger1 = AnimElem = 2
value = 1,2
channel = 1

[State 1121, Energy Snd]
type = PlaySnd
trigger1 = AnimElem = 3
value = 1100,2
channel = 2

[State 1121, Friction]
type = VelMul
trigger1 = vel x > 0
trigger1 = AnimElemTime(3) < 0 
x = .88

[State 1121, VelStop]
type = VelSet
trigger1 = AnimElem = 2 
x = 0

[State 1121, Wing FX]
type = Explod
trigger1 = AnimElem = 3
anim = 1105
ID = 1105
pos = 40,-70
postype = P1
sprpriority = 3
scale = 0.5,0.5
ignorehitpause = 1
bindtime = -1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1121, End FX 1]
type = Explod
trigger1 = AnimElem = 1
anim = 1102
ID = 1102
pos = 40, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1
facing = -1

[State 1121, End FX 2]
type = Explod
trigger1 = AnimElem = 2
anim = 1103
ID = 1103
pos = 45, 0
postype = P1
sprpriority = 3
scale = 0.8,0.8
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1121, End FX 3]
type = Explod
trigger1 = AnimElem = 2
anim = 1103
ID = 1103
pos = 52, 0
postype = P1
sprpriority = 3
scale = 0.6,0.6
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1121, End FX 4]
type = Explod
trigger1 = AnimElem = 2
anim = 1103
ID = 1103
pos = 57, 0
postype = P1
sprpriority = 3
scale = 0.5,0.5
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1121, Hit] 
type = HitDef
trigger1 = !var(16) && var(15) < 2
trigger1 = AnimElem = 3
attr = S, SA
damage = ceil(ifElse(fvar(11) * 35 < 7, 7, fvar(11) * 35)), 7
priority = 4, hit
animtype = Hard
getpower = 30 * !var(20), 30 * !var(20)
givepower = 35, 35
guardflag = MA
hitflag = MAF
hitsound = S2,2
guardsound = S130,0
pausetime = 12,12
guard.pausetime = 12,12
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 81), var(36) := -69
air.animtype = Back
fall.animtype = Back
ground.type = High
air.type = High
ground.slidetime = 18
ground.hittime  = 18
guard.hittime = 18
ground.velocity = -6, -4.5
air.velocity = -6, -4.5
guard.velocity = -8
airguard.velocity = -6.65, -1
airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .5
fall = 1
fall.recover = 0
forcestand = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1121, StateTypeSet: Idle]
type = StateTypeSet
trigger1 = AnimElemTime(4) >= 0
moveType = I

[State 1121, End]
type = ChangeState
trigger1 = !AnimTime
value = 301
ctrl = 1 

;=========================<EX HARD EDGE>========================
[Statedef 1130]
type = S
physics = N
movetype = A
anim = 1130
ctrl = 0
velset = 0,0
sprpriority = 2
poweradd = ifelse(var(20) > 0, 0, -500)
facep2 = 1

[State 1130, MAX Timer Drain]
type = VarAdd
trigger1 = !Time
trigger1 = var(20) > 0
var(20) = -335

[State 1130, EX Flash]
type = Varset
trigger1 = !Time
var(25) = 35

[State 1130, EX Sound]
type= PlaySnd
trigger1= !Time
value = 0, ifelse(!fvar(31), 1000, 1001)

[State 1130, EX FX(Phantom)]
type = Explod
triggerall = !fvar(31)
trigger1= !Time
anim = 8210
sprpriority = 3
postype = p1
pos = 0,-68
scale = .5,.5
pausemovetime = -1
supermovetime = -1
ownpal = 1

[State 1130, EX FX 1(Divine)]
type = Explod
triggerall = fvar(31)
trigger1 = !Time
anim = 8220
sprpriority = 4
postype = p1
pos = 0, 0
bindtime = 1
facing = -1
scale = 0.5, 0.5;based on char size
pauseMoveTime = -1
superMoveTime = -1
ownpal = 1

[State 1130, EX FX 2(Divine)]
type = Explod
triggerall = fvar(31)
trigger1 = !Time
anim = 8221
sprpriority = -1
postype = p1
pos = 0, 0
bindtime = 1
facing = 1
scale = 0.5, 0.5;based on char size
pauseMoveTime = -1
superMoveTime = -1
ownpal = 1

[State 1130, Width]
type = Width
trigger1 = 1
edge = 20,0

[State 1130, Voice Snd]
type = PlaySnd
trigger1 = AnimElem = 3
value = 1100,0
channel = 1

[State 1130, Fly Snd]
type = PlaySnd
trigger1 = AnimElem = 4
value = 1000,0

[State 1130, Velocity]
type = Velset
trigger1 = AnimElem = 5
x = 25

[State 1130, Friction]
type = Velmul
trigger1 = vel x > 0
;trigger1 = AnimElemTime(5) > 0
x = .95

[State 1130, FX 1]
type = Explod
trigger1 = AnimElem = 3
anim = 1101
ID = 1101
pos = 0, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1130, FX 2]
type = Explod
trigger1 = AnimElem = 4
anim = 1102
ID = 1102
pos = 0, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1130, FX 3]
type = Explod
triggerall = StateNo = 1130
trigger1 = AnimElemTime(4) > 0
trigger1 = AnimElemTime(6) < 2
anim = 1103
ID = 1103
pos = -30, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1130, Orb FX]
type = Explod
trigger1 = AnimElem = 5
anim = 1135
ID = 1135
pos = 10, -62
postype = P1
sprpriority = 3
scale = 0.4,0.4
ignorehitpause = 1
bindtime = -1
removetime = -1
pausemovetime = 255
supermovetime = 255
ownpal = 1
removeongethit = 1

[State 1130, Initial Hit]
type = HitDef
triggerall = var(14)
triggerall = var(28)
trigger1 = !var(16) && var(15) < 1
trigger1 = AnimElem = 5
attr = S,SA
id = 1180
hitflag = MAF
guardflag = M
priority = 4,Hit
damage = ceil(ifElse(fvar(11) * 35 < 7, 7, fvar(11) * 35)), 7
getpower = 0, 0
givepower = 35, 35
pausetime = 12, 12
guard.pausetime = 12, 12
animtype = Hard
air.animtype = Back
fall.animtype = Back
ground.type = High
air.type = Low
ground.hittime = 18
ground.slidetime = 18
guard.hittime = 18
air.hittime = 120
ground.velocity = -4.45, 0
ground.cornerpush.veloff = 0
guard.velocity = -4.45
guard.cornerpush.veloff = 0
air.velocity = -4.25, -5.25
air.cornerpush.veloff = 0
yaccel = .58
fall = 0
air.fall = 1
fall.recover = 1
fall.recovertime = 120
forcestand = 1
p2facing = 1
hitsound = s2,2
guardsound = s130, 0
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 30), var(36) := -60
envshake.time = 14
envshake.ampl = 4
envshake.freq = 120
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48

[State 1130, TargetState: Stand]
type = TargetState
trigger1 = NumTarget(1180)
trigger1 = MoveHit && Target,Alive
value = 1180
ID = 1180
ignoreHitPause = 1
persistent = 0

[State 1130, Attack Success]
type = ChangeState
trigger1 = MoveContact = 1
value = 1131

[State 1130, Attack Miss]
type = ChangeState
trigger1 = Time >= 24
value = 1132

;---Attack---
[Statedef 1131]
type = S
physics = N
movetype = A
anim = 1131
ctrl = 0
poweradd = 0
velset = 0,0
sprpriority = 2

[State 1131, Extra Stock Subtract]
type = VarAdd
triggerall = var(14) > 0
trigger1 = MoveHit=1 && NumTarget
var(14) = -1
;ignorehitpause = 1

[State 1131, Restriction Set]
type = VarSet
trigger1 = MoveHit=1 && NumTarget(1190)
var(28) = 0

[State 1131, Width]
type = Width
trigger1 = 1
edge = 20,0

[State 1131, Friction]
type = VelMul
trigger1 = vel x > 0
trigger1 = AnimElemTime(3) < 0 
x = .88

[State 1131, VelStop]
type = VelSet
trigger1 = AnimElem = 2 
x = 0

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

[State 1131, Swing Snd]
type = PlaySnd
trigger1 = AnimElem = 2
value = 1,2
channel = 1

[State 1131, Energy Snd]
type = PlaySnd
trigger1 = AnimElem = 3
value = 1100,3
channel = 2

[State 1131, Burst FX]
type = Explod
trigger1 = AnimElem = 3
anim = 1136
ID = 1136
pos = 80,-69
postype = P1
sprpriority = 3
scale = 0.7,0.3
ignorehitpause = 1
bindtime = -1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1131, End FX 1]
type = Explod
trigger1 = AnimElem = 1
anim = 1102
ID = 1102
pos = 40, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1
facing = -1

[State 1131, End FX 2]
type = Explod
trigger1 = AnimElem = 2
anim = 1103
ID = 1103
pos = 45, 0
postype = P1
sprpriority = 3
scale = 0.8,0.8
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1131, End FX 3]
type = Explod
trigger1 = AnimElem = 2
anim = 1103
ID = 1103
pos = 52, 0
postype = P1
sprpriority = 3
scale = 0.6,0.6
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1131, End FX 4]
type = Explod
trigger1 = AnimElem = 2
anim = 1103
ID = 1103
pos = 57, 0
postype = P1
sprpriority = 3
scale = 0.5,0.5
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1131, Hit]
type = HitDef
triggerall = var(14)
triggerall = var(28)
trigger1 = !var(16) && var(15) < 1
trigger1 = AnimElem = 3
id = 1190
attr = S,SA
hitflag = MAF
guardflag = M
priority = 4,Hit
damage = ceil(ifElse(fvar(11) * 21 < 7, 7, fvar(11) * 21)), 7
getpower = 0, 0
givepower = 35, 35
pausetime = 10, 12
guard.pausetime = 12, 12
animtype = Hard
air.animtype = Back
fall.animtype = Back
ground.type = High
air.type = Low
ground.hittime = 18
ground.slidetime = 18
guard.hittime = 18
air.hittime = 120
ground.velocity = -7, 0;-12,-8
ground.cornerpush.veloff = 0
guard.velocity = -8
guard.cornerpush.veloff = 0
air.velocity = -7, 0
air.cornerpush.veloff = 0
yaccel = .58
fall = 1
fall.recover = 0
forcestand = 1
p2facing = 1
hitsound = s2,8
guardsound = s130, 0
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 81), var(36) := -69
envshake.time = 14
envshake.ampl = 4
envshake.freq = 120
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
;palfx.time = 64
;palfx.mul = 128,128,128
;palfx.sinadd = 96,96,96,4

;[State 1131, TargetState];hits foe into wall
;type = TargetState
;trigger1 = MoveHit && NumTarget(1190)
;trigger1 = (Target(1190), StateNo = 5000) || (Target(1190), StateNo = 5010) || (Target(1190), StateNo = 5020)
;value = 1190
;ID = 1190
;ignoreHitPause = 1

[State 1131, TargetState: Collapse]
type = TargetState
trigger1 = NumTarget(1190)
trigger1 = MoveHit && Target,Alive
value = 1190
ID = 1190
ignoreHitPause = 1
persistent = 0

;[State 1131, Flame Particles]
;type = Helper
;trigger1 = AnimElemTime(3) >= 0
;trigger1 = !NumHelper(8150)
;trigger1 = MoveHit = 1 && NumTarget
;trigger1 = !(Target, HitShakeOver)
;trigger1 = var(40) := (Target, ID)
;helperType = Normal
;stateNo = 8150
;ID = 8150
;name = "Flame Particles"
;posType = P2
;ownPal = 1
;ignoreHitPause = 1

;[State 1131, VarSet: No Juggle Check]
;type = VarSet
;trigger1 = MoveHit=1 && NumTarget
;var(15) = 0

[State 1131, StateTypeSet: Idle]
type = StateTypeSet
trigger1 = AnimElemTime(4) >= 0
movetype = I

[State 1131, End]
type = ChangeState
trigger1 = !AnimTime
value = 301
ctrl = 1

;---Miss---
[Statedef 1132]
type = S
physics = N
movetype = I
anim = 1132
ctrl = 0
sprpriority = 2
movehitpersist = 1

[State 1132, RemoveExplod]
type = RemoveExplod
trigger1 = !Time
id = 1135

[State 1132, Friction]
type = Velmul
trigger1 = vel x > 0
x = .95

[State 1132, VelStop]
type = VelSet
trigger1 = AnimElem = 2 
x = 0

[State 1132, Step Snd]
type= Playsnd
trigger1 = !Time
value = 52,0

[State 1132, End FX 1]
type = Explod
trigger1 = AnimElem = 1
anim = 1102
ID = 1102
pos = 40, 0
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1
facing = -1

[State 1132, End FX 2]
type = Explod
trigger1 = AnimElem = 2
anim = 1103
ID = 1103
pos = 45, 0
postype = P1
sprpriority = 3
scale = 0.8,0.8
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1132, End FX 3]
type = Explod
trigger1 = AnimElem = 2
anim = 1103
ID = 1103
pos = 52, 0
postype = P1
sprpriority = 3
scale = 0.6,0.6
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1132, End FX 4]
type = Explod
trigger1 = AnimElem = 2
anim = 1103
ID = 1103
pos = 57, 0
postype = P1
sprpriority = 3
scale = 0.5,0.5
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1132, End]
type = ChangeState
trigger1 = !Animtime
value = 301
ctrl = 1

;==================<Standing TargetState>=====================
;EX Hard Edge TargetState
[StateDef 1180]
type = S
moveType = H
physics  = N
velSet = 0,0

[State 1180, PosSet]
type = PosSet
trigger1 = !Time
y = 0

[State 1180, HitFallSet]
type = HitFallSet
trigger1 = !Time
value = 0

[State 1180, ChangeAnim]
type = ChangeAnim
trigger1 = !Time
value = 5012

[State 1180, ChangeAnim]
type = ChangeAnim
trigger1 = Time > 0
value = Anim

[State 1180, ChangeState]
type = ChangeState
trigger1 = HitShakeOver
value = 1181


;Sliding
[StateDef 1181]
type = S
movetype = H
physics = S

[State 1181, ChangeAnim]
type = ChangeAnim
trigger1 = !AnimTime
value = 5017

[State 1181, DefenceMulSet]
type = DefenceMulSet
trigger1 = HitOver
value = 1

[State 1181, SelfState]
type = SelfState
trigger1 = HitOver
value = 0
ctrl = 1

;==================<Collapsed TargetState>=====================
;Collapsed
[Statedef 1190]
type    = S
movetype= H
physics = S
ctrl = 0
velset = 0,0

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

[State 1190, ChangeAnim2]
type = ChangeAnim2
trigger1 = !Time
value = 1190

[State 1190, HitFallSet]
type = HitFallSet
trigger1 = 1
value = 0

[State 1190, HitVelSet]
type = HitVelSet
trigger1 = !Time
x = 1

[State 1190, PlayerPush]
type = PlayerPush
trigger1 = 1 
value = 1
ignorehitpause = 1

[State 1190, Muteki]
type = Nothitby
trigger1 = AnimElemTime(5) >= 0
time = 1
value = SCA

[State 1190, StateTypeSet]
type = StateTypeSet
trigger1 = AnimElemTime(5) >= 0
statetype = L 
physics = N

[State 1190, SelfState]
type = SelfState
trigger1 = !AnimTime 
trigger1 = Anim = 1190
value = IfElse(Alive,5120,5150)

;======================<P2 Wall Bounce>===========================
;Being Launched
;[StateDef 1190]
;type = A
;moveType = H
;physics = N
;velSet = 0,0

;[State 1190, ChangeAnim]
;type = ChangeAnim
;trigger1 = 1
;value = 5002

;[State 1190, End]
;type = ChangeState
;trigger1 = HitShakeOver
;value = 1191


;Heading Towards Wall
;[StateDef 1191]
;type = A
;moveType = H
;physics = N

;[State 1191, HitVelSet]
;type = HitVelSet
;trigger1 = !Time
;x = 1
;y = 1

;[State 1191, Gravity]
;type = VelAdd
;trigger1 = 1
;y = GetHitVar(yAccel)

;[State 1191, ScreenBound]
;type = ScreenBound
;trigger1 = 1
;value = 1
;moveCamera = 0,1

;[State 1191, PlayerPush]
;type = PlayerPush
;trigger1 = 1
;value = 0

;[State 1191, ChangeAnim]
;type = ChangeAnim
;trigger1 = !Time
;value = ifElse(SelfAnimExist(5052), 5052, 5030)

;[State 1191, Bounce Off Wall]
;type = ChangeState
;trigger1 = BackEdgeBodyDist <= 10 || FrontEdgeBodyDist <= 10
;value = 1192

;[State 1191, End]
;type = SelfState
;trigger1 = vel y > 0 && pos y >= 0
;value = 5100


;Impacting Wall
;[StateDef 1192]
;type = A
;moveType = H
;physics = N

;[State 1192, Turn]
;type = Turn
;trigger1 = !Time
;trigger1 = FrontEdgeDist < BackEdgeDist

;[State 1192, PosSet]
;type = PosSet
;trigger1 = 1
;x = -160 * Facing

;[State 1192, PosFreeze]
;type = PosFreeze
;trigger1 = 1
;x = 1
;y = 1

;[State 1192, ScreenBound]
;type = ScreenBound
;trigger1 = 1
;value = 1
;moveCamera = 0,1

;[State 1192, PlayerPush]
;type = PlayerPush
;trigger1 = 1
;value = 1

;[State 1192, ChangeAnim]
;type = ChangeAnim
;trigger1 = 1
;value = 5010

;[State 1192, Impact Sound]
;type = PlaySnd
;trigger1 = !Time
;value = F7,0

;[State 1192, End]
;type = ChangeState
;trigger1 = Time >= 4
;value = 1193


;Bouncing Off Wall
;[Statedef 1193]
;type = A
;moveType = H
;physics = N

;[State 1193, Turn]
;type = Turn
;trigger1 = !Time

;[State 1193, Gravity]
;type = VelAdd
;trigger1 = 1
;y = 0.48

;[State 1193, VelSet]
;type = VelSet
;trigger1 = !Time
;x = -2.85 ;-2.5
;y = -8.5

;[State 1193, ChangeAnim]
;type = ChangeAnim
;trigger1 = !Time
;value = ifElse(SelfAnimExist(5051), 5051, 5030)

;[State 1193, ChangeAnim]
;type = ChangeAnim
;trigger1 = Anim = 5030 && !AnimTime
;value = 5050

;[State 1193, ChangeAnim]
;type = ChangeAnim
;trigger1 = vel y > -3 && Anim = 5051 && SelfAnimExist(5061)
;value = 5061

;[State 1193, ScreenBound]
;type = ScreenBound
;trigger1 = 1
;value = 1
;moveCamera = 0,0

;[State 1193, PlayerPush]
;type = PlayerPush
;trigger1 = 1
;value = 0

;[State 1193, End]
;type = SelfState
;trigger1 = vel y > 0 && pos y >= 0
;value = 5100

;========================<CRACK COUNTER>=======================
[Statedef 1200]
type = S
movetype = I
physics = S
anim = 1200
ctrl = 0
velset = 0,0
poweradd = 70 * !var(20)
sprpriority = 1
facep2 = 1

[State 1200, Button Detect]
type = VarSet
trigger1 = !Time
var(10) = ifElse((helper(10371), var(3)) || (helper(10371), var(10)), 0, ifElse((helper(10371), var(4)) || (helper(10371), var(11)), 1, 2))

[State 1200, ChangeAnim]
type = ChangeAnim
trigger1 = !Time
value = ifElse(var(10) = 0, 1200, ifElse(var(10) = 1, 1210, 1220))

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

[State 1200, ReversalDef: High]
type = ReversalDef
trigger1 = !var(10)
trigger1 = AnimElemTime(4) < 0
attr = S,SA
reversal.attr = SCA,SA,HA
pausetime = 0,36
sparkno = -1
sparkxy = 0,0
hitsound = s130,0
p1stateno = 1201
;p2stateno =
;persistent = 1
fall = 0
;air.fall = 1
fall.recover = 1
numhits = 0
p2facing = 1

[State 1200, ReversalDef: High]
type = ReversalDef
trigger1 = !var(10)
trigger1 = AnimElemTime(4) < 0 && P2StateType=A
attr = S,SA
reversal.attr = A, NA, SA, HA
pausetime = 0,36
sparkno = -1
sparkxy = 0,0
hitsound = s130,0
p1stateno = 1201
;p2stateno =
;persistent = 1
fall = 0
;air.fall = 1
fall.recover = 1
numhits = 0
p2facing = 1

[State 1200, ReversalDef: Mid]
type = ReversalDef
trigger1 = var(10) = 1
trigger1 = AnimElemTime(4) < 0
attr = S,SA
reversal.attr = SC,NA
pausetime = 0,36
sparkno = -1
sparkxy = 0,0
hitsound = s130,0
p1stateno = 1211
;p2stateno =
;persistent = 1
fall = 0
;air.fall = 1
fall.recover = 1
numhits = 0
p2facing = 1

[State 1200, ReversalDef: Low]
type = ReversalDef
trigger1 = var(10) = 2
trigger1 = AnimElemTime(4) < 0
attr = S,SA
reversal.attr = SC,NA
pausetime = 0,36
sparkno = -1
sparkxy = 0,0
hitsound = s130,0
p1stateno = 1221
;p2stateno =
;persistent = 1
fall = 0
;air.fall = 1
fall.recover = 1
numhits = 0
p2facing = 1

[State 1200, End]
type = ChangeState
trigger1 = !AnimTime
value = 0
ctrl = 1

;Counter Attack Landing
[Statedef 1205]
type = S
movetype = I
physics = S
ctrl = 0
anim = 1205
velset = 0, 0

[State 1205, On Ground]
type = Posset
trigger1 = !Time
y = 0

[State 1205, Land Snd]
type = PlaySnd
trigger1 = Time = 1
value = 52,0

[State 1205, Landing Dust Explod]
type = Explod
trigger1 = !Time
anim = 8102
sprpriority = -3
postype = P1
scale = 0.5,0.5
pauseMoveTime = -1
superMoveTime = -1
ownPal = 1

[State 1205, End]
type = ChangeState
trigger1 = !AnimTime
value = 301
ctrl = 1

;Crack Counter Success: High
[Statedef 1201]
type    = S
movetype= A
physics = S
poweradd= 30 * !var(20)
ctrl = 0
velset = 0,0
anim = 1201
sprpriority = 2
facep2 = 1

[State 1201, SprPriority]
type = SprPriority
trigger1 = AnimElemTime(2) < 0
value = -1
ignorehitpause = 1 
persistent = 0

[State 1201, Voice]
type = PlaySnd
trigger1 = AnimElem = 5
value = 1200, 0
channel = 0

[State 1201, Swing Snd]
type = PlaySnd
trigger1 = AnimElem = 6
value = 1,5
channel = 1

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

[State 1201, Reversal Spark]
type = Helper
trigger1 = !Time
helpertype = Normal
stateno = 8020
ID = 8000
name = "Reversal Spark"
postype = p1
pos = 24,-99
facing = -1
ownpal = 1
pausemovetime = 65535
supermovetime = 65535
ignorehitpause = 1

[State 1201, AfterImages]
type = AfterImage
trigger1 = AnimElem = 3
time = 999
TimeGap  = 3
FrameGap = 4
length = 10
PalBright = 1,1,1
PalContrast = 50,50,150
PalAdd = 0,0,0
PalMul = 1,1,1
trans = add1

[State 1201, Width]
type = Width
trigger1 = 1
player = 5,0
edge = 10,0

[State 1201, Velocity]
type = VelSet
trigger1 = AnimElem = 3
x = 2
y = -5

[State 1201, Gravity]
type = VelAdd
trigger1 = AnimElemTime(3) > 0
y = .4

[State 1201, StateType: Air, No Phys]
type = StateTypeSet
trigger1 = AnimElemTime(3) >= 0
StateType = A
physics = N

[State 1201, HitDef]
type = HitDef
trigger1 = !var(16) && var(15) < 1
trigger1 = AnimElem = 6 
attr = A,SA   
hitflag = MAF     
guardflag = HA      
animtype = Hard     
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 91 < 7, 7, fvar(11) * 91)), 7
getpower = 50 * !var(20), 30 * !var(20)
givepower = 30, 30
pausetime = 12,12
guard.pausetime = 12, 12
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 61), var(36) := -61
hitsound = s2,5
guardsound = s130, 0
air.animType = Back
fall.animType = Back
ground.type = Low      ;Low,Trip,None
air.type = Low
ground.slidetime = 18
ground.hittime = 18
guard.hittime = 18
ground.velocity = -1.5, 6
guard.velocity = -8
air.velocity = -1.5, 6
airguard.velocity = -6.5, -1
airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .5
fall = 1
fall.recover = 0
forcestand = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1201, End]
type = ChangeState
trigger1 = AnimElemTime(3) > 0
trigger1 = pos y > -vel y
value = 1205

;Crack Counter Success: Mid
[Statedef 1211]
type    = S
movetype= A
physics = S
poweradd= 30 * !var(20)
ctrl = 0
velset = 0,0
anim = 1211
sprpriority = 2
facep2 = 1

[State 1211, SprPriority]
type = SprPriority
trigger1 = AnimElemTime(2) < 0
value = -1
ignorehitpause = 1 
persistent = 0

[State 1211, Voice]
type = PlaySnd
trigger1 = AnimElem = 5
value = 1200, 0
channel = 0

[State 1211, Swing Snd]
type = PlaySnd
trigger1 = AnimElem = 6
value = 1,5
channel = 1

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

[State 1211, Reversal Spark]
type = Helper
trigger1 = !Time
helpertype = Normal
stateno = 8020
ID = 8000
name = "Reversal Spark"
postype = p1
pos = 28,-73
facing = -1
ownpal = 1
pausemovetime = 65535
supermovetime = 65535
ignorehitpause = 1

[State 1211, AfterImages]
type = AfterImage
trigger1 = AnimElem = 3
time = 999
TimeGap  = 3
FrameGap = 4
length = 10
PalBright = 1,1,1
PalContrast = 50,50,150
PalAdd = 0,0,0
PalMul = 1,1,1
trans = add1

[State 1211, Width]
type = Width
trigger1 = 1
player = 5,0
edge = 10,0

[State 1211, Velocity]
type = VelSet
trigger1 = AnimElem = 3
x = 2
y = -5

[State 1211, Gravity]
type = VelAdd
trigger1 = AnimElemTime(3) > 0
y = .4

[State 1211, StateType: Air, No Phys]
type = StateTypeSet
trigger1 = AnimElemTime(3) >= 0
StateType = A
physics = N

[State 1211, HitDef]
type = HitDef
trigger1 = !var(16) && var(15) < 1
trigger1 = AnimElem = 6 
attr = A,SA   
hitflag = MAF     
guardflag = HA      
animtype = Hard     
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 91 < 7, 7, fvar(11) * 91)), 7
getpower = 50 * !var(20), 30 * !var(20)
givepower = 30, 30
pausetime = 12,12
guard.pausetime = 12, 12
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 61), var(36) := -61
hitsound = s2,5
guardsound = s130, 0
air.animType = Back
fall.animType = Back
ground.type = Low      ;Low,Trip,None
air.type = Low
ground.slidetime = 18
ground.hittime = 18
guard.hittime = 18
ground.velocity = -1.5, 6
guard.velocity = -8
air.velocity = -1.5, 6
airguard.velocity = -6.5, -1
airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .5
fall = 1
fall.recover = 0
forcestand = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1211, End]
type = ChangeState
trigger1 = AnimElemTime(3) > 0
trigger1 = pos y > -vel y
value = 1205

;Crack Counter Success: Low
[Statedef 1221]
type    = S
movetype= A
physics = S
poweradd= 30 * !var(20)
ctrl = 0
velset = 0,0
anim = 1221
sprpriority = 2
facep2 = 1

[State 1221, SprPriority]
type = SprPriority
trigger1 = AnimElemTime(2) < 0
value = -1
ignorehitpause = 1 
persistent = 0

[State 1221, Voice]
type = PlaySnd
trigger1 = AnimElem = 5
value = 1200, 0
channel = 0

[State 1221, Swing Snd]
type = PlaySnd
trigger1 = AnimElem = 6
value = 1,5
channel = 1

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

[State 1221, Reversal Spark]
type = Helper
trigger1 = !Time
helpertype = Normal
stateno = 8020
ID = 8000
name = "Reversal Spark"
postype = p1
pos = 20,-40
facing = -1
ownpal = 1
pausemovetime = 65535
supermovetime = 65535
ignorehitpause = 1

[State 1221, AfterImages]
type = AfterImage
trigger1 = AnimElem = 3
time = 999
TimeGap  = 3
FrameGap = 4
length = 10
PalBright = 1,1,1
PalContrast = 50,50,150
PalAdd = 0,0,0
PalMul = 1,1,1
trans = add1

[State 1221, Width]
type = Width
trigger1 = 1
player = 5,0
edge = 10,0

[State 1221, Velocity]
type = VelSet
trigger1 = AnimElem = 3
x = 2
y = -5

[State 1221, Gravity]
type = VelAdd
trigger1 = AnimElemTime(3) > 0
y = .4

[State 1221, StateType: Air, No Phys]
type = StateTypeSet
trigger1 = AnimElemTime(3) >= 0
StateType = A
physics = N

[State 1221, HitDef]
type = HitDef
trigger1 = !var(16) && var(15) < 1
trigger1 = AnimElem = 6 
attr = A,SA   
hitflag = MAF     
guardflag = HA      
animtype = Hard     
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 91 < 7, 7, fvar(11) * 91)), 7
getpower = 50 * !var(20), 30 * !var(20)
givepower = 30, 30
pausetime = 12,12
guard.pausetime = 12, 12
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 61), var(36) := -61
hitsound = s2,5
guardsound = s130, 0
air.animType = Back
fall.animType = Back
ground.type = Low      ;Low,Trip,None
air.type = Low
ground.slidetime = 18
ground.hittime = 18
guard.hittime = 18
ground.velocity = -1.5, 6
guard.velocity = -8
air.velocity = -1.5, 6
airguard.velocity = -6.5, -1
airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .5
fall = 1
fall.recover = 0
forcestand = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1221, End]
type = ChangeState
trigger1 = AnimElemTime(3) > 0
trigger1 = pos y > -vel y
value = 1205

;========================<EX CRACK COUNTER>=======================
[Statedef 1230]
type = S
movetype = I
physics = S
anim = 1230
ctrl = 0
velset = 0,0
poweradd = ifelse(var(20) > 0, 0, -500)
sprpriority = 1
facep2 = 1

[State 1230, MAX Timer Drain]
type = VarAdd
trigger1 = !Time
trigger1 = var(20) > 0
var(20) = -335

[State 1230, EX Flash]
type = Varset
trigger1 = !Time
var(25) = 25

[State 1230, EX Sound]
type= PlaySnd
trigger1= !Time
value = 0, ifelse(!fvar(31), 1000, 1001)

[State 1230, EX FX(Phantom)]
type = Explod
triggerall = !fvar(31)
trigger1= !Time
anim = 8210
sprpriority = 3
postype = p1
pos = 9,-73
scale = .5,.5
pausemovetime = -1
supermovetime = -1
ownpal = 1

[State 1230, EX FX 1(Divine)]
type = Explod
triggerall = fvar(31)
trigger1 = !Time
anim = 8220
sprpriority = 4
postype = p1
pos = 0, 0
bindtime = 1
facing = -1
scale = 0.5, 0.5;based on char size
pauseMoveTime = -1
superMoveTime = -1
ownpal = 1

[State 1230, EX FX 2(Divine)]
type = Explod
triggerall = fvar(31)
trigger1 = !Time
anim = 8221
sprpriority = -1
postype = p1
pos = 0, 0
bindtime = 1
facing = 1
scale = 0.5, 0.5;based on char size
pauseMoveTime = -1
superMoveTime = -1
ownpal = 1

[State 1230, Voice]
type = PlaySnd
trigger1 = AnimElem = 2
value = 0,0
channel = 0

[State 1230, Safety]
type = SuperPause
trigger1 = !Time
time = 0
p2defmul = 1
anim = -1
sound = -1
darken = 0

[State 1230, ReversalDef]
type = ReversalDef
trigger1 = AnimElemTime(4) < 0
attr = S,ST
reversal.attr = SCA,SA,HA,NA
pausetime = 0,0
sparkno = -1
sparkxy = 0,0
hitsound = s130,0
p1stateno = 1231
p2stateno = 1234
;persistent = 1
fall = 1
fall.recover = 1
;air.fall = 1
numhits = 0

[State 1230, End]
type = ChangeState
trigger1 = !AnimTime
value = 0
ctrl = 1

;EX Crack Counter: Success
[Statedef 1231]
type = S
movetype = A
physics = S
anim = 1231
velset = 0, 0
poweradd = 0
sprpriority = 2

[State 1231, Safety]
type = ChangeState
trigger1 = !Time && !NumTarget
value = 0
ctrl = 1

[State 1231, More Safety]
type = NotHitBy
trigger1 = 1
value = SCA

[State 1231, TargetState]
type = TargetState
trigger1 = AnimElem = 2
trigger1 = NumTarget
value = 1235

[State 1231, Target Facing]
type = TargetFacing
trigger1 = NumTarget
Trigger1 = AnimElemTime(2) >= 0
value = -1

[State 1231, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoAutoTurn

[State 1231, Reversal Spark]
type = Helper
trigger1 = !Time
helpertype = Normal
stateno = 8020
ID = 8000
name = "Reversal Spark"
postype = p1
pos = 28,-73
facing = -1
ownpal = 1
pausemovetime = 65535
supermovetime = 65535
ignorehitpause = 1

[State 1231, Voice]
type = PlaySnd
trigger1 = AnimElem = 5
value = 1000, 2
channel = 0

[State 1231, Impact Shake]
type = EnvShake
trigger1 = AnimElem = 7
time = 14
freq = 120
ampl = 4

[State 1231, Slam Snd]
type = PlaySnd
trigger1 = AnimElem = 7
value = 2,7
channel = 2

[State 1231, Slam Snd 2]
type = PlaySnd
trigger1 = AnimElem = 7
value = 2,2

[State 1231, Impact Dust]
type = Helper
trigger1 = AnimElem = 7
helperType = Normal
stateNo = 8110
ID = 8110
name = "Impact Dust"
posType = P1
facing = -1
pos = 50,0
ownPal = 1

[State 1231, Width]
type = Width
trigger1 = AnimElemTime(2)>=0 && AnimElemTime(11) < 0
edge = 45,70

;[State 1231, Turn]
;type = Turn
;trigger1 = AnimElem = 2

[State 810, Bind 2]
type = TargetBind
trigger1 = AnimElemTime(2) >= 0 && AnimElemTime(3) < 0
trigger1 = NumTarget
pos = ceil(-42 * const(size.xScale)), ceil(0 * const(size.yScale))

[State 1231, Bind 3]
type = TargetBind
trigger1 = AnimElemTime(3) >= 0 && AnimElemTime(4) < 0
trigger1 = NumTarget
pos = ceil(-40 * const(size.xScale)), ceil(0 * const(size.yScale))

[State 1231, Bind 4]
type = TargetBind
trigger1 = AnimElemTime(4) >= 0 && AnimElemTime(5) < 0
trigger1 = NumTarget
pos = ceil(-40 * const(size.xScale)), ceil(-79 * const(size.yScale))

[State 1231, Bind 5]
type = TargetBind
trigger1 = AnimElemTime(5) >= 0 && AnimElemTime(6) < 0
trigger1 = NumTarget
pos = ceil(-20 * const(size.xScale)), ceil(-95 * const(size.yScale))

[State 1231, Bind 6]
type = TargetBind
trigger1 = AnimElemTime(6) >= 0 && AnimElemTime(7) < 0
trigger1 = NumTarget
pos = ceil(25 * const(size.xScale)), ceil(-90 * const(size.yScale))

[State 1231, Bind 7]
type = TargetBind
trigger1 = AnimElem = 7
trigger1 = NumTarget
pos = ceil(50 * const(size.xScale)), ceil(0 * const(size.yScale))
time = 1

[State 1231, Damage 7]
type = TargetLifeAdd
trigger1 = NumTarget && AnimElem = 7
value = floor(ifElse(133 * fvar(11) < 7, -7, -133 * fvar(11)))

[State 1231, Throw 7]
type = TargetState
trigger1 = NumTarget && AnimElem = 7
value = 1236

[State 1231, TargetPowerAdd]
type = TargetPowerAdd
trigger1 = NumTarget && AnimElem = 7
value = 35

[State 1231, HitAdd]
type = HitAdd
trigger1 = NumTarget && AnimElem = 7
value = 1

[State 1231, VarAdd]
type = VarAdd
trigger1 = NumTarget && AnimElem = 7
var(13) = 1

[State 1231, Juggle]
type = VarAdd
trigger1 = NumTarget && AnimElem = 7
var(15) = 1
ignoreHitPause = 1

[State 1231, No Juggle Flag]
type = VarSet
trigger1 = NumTarget && AnimElem = 7
var(16) = 0
ignoreHitPause = 1

[State 1231, State End]
type = ChangeState
trigger1 = !AnimTime
value = 0
ctrl = 1

;EX Crack Counter(Target Paused)
[Statedef 1234]
type = A
movetype = H
physics = N
velset = 0,0
sprpriority = 2

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

[State 1234, No Push]
type = PlayerPush
trigger1 = 1
value = 0

[State 1234, PosFreeze]
type = PosFreeze
trigger1 = 1
value = 1

[State 1234, ChangeAnim]
type = ChangeAnim
trigger1 = 1
value = Anim
elem = AnimElemNo(0)

[State 1234, End]
type = SelfState
trigger1 = Time >= 24
value = 5040

;EX Crack Counter(Target)
[Statedef 1235]
type = S
movetype = H
physics = N
ctrl = 0
sprpriority = -1

[State 1235, On Ground]
type = PosSet
trigger1 = !Time
y = 0

;[State 1235, Turn]
;type = Turn
;trigger1 = !Time

[State 1235, StopSound]
type = StopSnd
trigger1 = !Time
channel = 0

[State 1235, Screenbound]
type = ScreenBound
Trigger1 = 1
value = 1
movecamera = 0,0

[State 1235, ChangeAnim2]
type = ChangeAnim2
Trigger1 = !Time
value = 1235

;In case attacker loses binding on player for any reason, this controller
;guarantees that the player will never get stuck in this thrown state.
[State 1235, Safety]
type = SelfState
trigger1 = !gethitvar(isbound)
value = 5050

;EX Crack Counter(Target 2nd)
[Statedef 1236]
type = A
physics = N
movetype = H
ctrl = 0
velset = 0,0
sprpriority = -1

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

[State 1236, ChangeAnim2]
type = ChangeAnim2
trigger1 = !Time
value = 821

[State 1236, End]
type = ChangeState
trigger1 = Time >= 6
value = 1391;1237(old bounce State)

;EX Crack Counter(Target 3rd)
;Unused now keep it just in case...
[Statedef 1237]
type = A
physics = N
movetype = H
ctrl = 0
velset = 0,0
sprpriority = 0

[State 1237, On Ground]
type = PosSet
trigger1 = !Time
y = 0

[State 1237, ChangeAnim2]
type = ChangeAnim2
trigger1 = !Time
value = 821

[State 1237, ScreenBound]
type = ScreenBound
trigger1 = 1
value = 1
movecamera = 1,0

[State 1237, Gravity]
type = VelAdd
trigger1 = 1
y = .56

[State 1237, Velocity]
type = VelSet
trigger1 = Time = 1
x = -0.8
y = -8.5

[State 1237, Turn]
type = Turn
trigger1 = Time >= 8 && vel y>0 && pos y>-vel y

[State 1237, End]
type = SelfState
trigger1 = Time >= 8 && vel y>0 && pos y>-vel y
value = 5110

;[State 1237, End]
;type = SelfState
;trigger1 = vel y>0
;trigger1 = pos y>-vel y
;value = 5100

;========================<RAGE RUN>=======================
[Statedef 1300]
type = S
movetype = I
physics = N
anim = 1300
ctrl = 0
velset = 7,0
poweradd = 70 * !var(20)
sprpriority = 2
facep2 = 1

[State 1200, Button Detect]
type = VarSet
trigger1 = !Time
var(10) = ifElse((helper(10371), var(3)) || (helper(10371), var(10)), 0, ifElse((helper(10371), var(4)) || (helper(10371), var(11)), 1, 2))

[State 1300, Width]
type = Width
trigger1 = 1
edge = 5,0

[State 1300, Dash Snd]
type = PlaySnd
trigger1 = AnimElem = 1
value = 1300,0
channel = 1

[State 1300, Step Snd 1]
type = PlaySnd
trigger1 = AnimElem = 2
value = 100,0

[State 1300, Step Snd 2]
type = PlaySnd
trigger1 = AnimElem = 6
value = 100,1

[State 1300, "Dunk" Type]
type = ChangeState
triggerall = Time >= 9
triggerall = !var(10)
trigger1 = P2BodyDist x <= 15
value = 1302
ctrl = 0

[State 1300, "Save" Type]
type = ChangeState
triggerall = Time >= 9
triggerall = var(10) = 1
trigger1 = Time = 17
trigger2 = P2BodyDist x <= 15
value = 1310
ctrl = 0

[State 1300, "Shift" Type]
type = ChangeState
triggerall = Time >= 1
triggerall = var(10) = 2
trigger1 = P2BodyDist x <= 0
value = 1320
ctrl = 0

[State 1300, End(Miss)]
type = ChangeState
trigger1 = Time = 17 && !var(10)
trigger2 = Time = 24 && var(10) = 2
value = 1301
ctrl = 0

;Rage Run(miss)
[Statedef 1301]
type = S
physics = N
ctrl = 0
anim = 1301

[State 1301, Friction]
type = VelMul
trigger1 = vel x > 0
trigger1 = 1
x = .9

[State 1301, Skid Snd]
type = PlaySnd
trigger1 = AnimElem = 1
value = 101,0

[State 1301, VelStop]
type = VelSet
trigger1 = !AnimTime
x = 0

[State 1301, End]
type = ChangeState
trigger1 = !AnimTime
value = 301
ctrl = 1

;Rage Run "Dunk" Type
[Statedef 1302]
type = A
movetype = A
physics = N
anim = 1302
ctrl = 0
velset = 0,0
poweradd = 0
sprpriority = 2

[State 1302, Width]
type = Width
trigger1 = 1
edge = 5,0

[State 1302, Voice]
type = PlaySnd
trigger1 = AnimElem = 4
value = 1300,1
channel = 0

[State 1302, Jump Snd]
type = PlaySnd
trigger1 = AnimElem = 1
value = 41,0

[State 1302, Swing Snd]
type = PlaySnd
trigger1 = AnimElem = 5
value = 1,2
channel = 1

[State 1302, Energy Snd]
type = PlaySnd
trigger1 = AnimElem = 5
value = 1100,2
channel = 2

[State 1302, Dust Helper]
type = Helper
trigger1 = AnimElem = 1
helperType = Normal
stateNo = 8100
ID = 8100
name = "Jump Dust"
posType = P1
ownPal = 1

[State 1302, Wing FX]
type = Explod
trigger1 = AnimElem = 6
anim = 1306
ID = 1306
pos = 40,-70
postype = P1
sprpriority = 3
scale = 0.5,0.5
ignorehitpause = 1
bindtime = 1
pausemovetime = 65535
supermovetime = 65535
ownpal = 1
removeongethit = 1

[State 1302, Velocity]
type = VelSet
trigger1 = AnimElem = 1
x = 3
y = -6

[State 1302, Gravity]
type = VelAdd
trigger1 = 1
y = .5

[State 1302, Hit] 
type = HitDef
trigger1 = !var(16) && var(15) < 1
trigger1 = AnimElem = 6
attr = A, SA
damage = ceil(ifElse(fvar(11) * 77 < 7, 7, fvar(11) * 77)), 7
priority = 4, hit
animtype = Up
getpower = 50 * !var(20), 30 * !var(20)
givepower = 35, 35
guardflag = HA
hitflag = MAF
hitsound = S2,2
guardsound = S130,0
pausetime = 12,12
guard.pausetime = 12,12
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 59), var(36) := -47
air.animtype = Up
fall.animtype = Up
ground.type = High
air.type = High
ground.slidetime = 18
ground.hittime  = 18
guard.hittime = 18
ground.velocity = -1.8, 6
air.velocity = -1.8, 6
guard.velocity = -8
airguard.velocity = -6.65, -1
airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .5
fall = 1
fall.recover = 0
forcestand = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1302, End]
type = ChangeState
trigger1 = AnimElemTime(5) > 0
trigger1 = pos y > -vel y
value = 1305

;"Dunk" Type Landing
[Statedef 1305]
type = S
movetype = I
physics = S
ctrl = 0
anim = 1305
velset = 0, 0

[State 1305, EX Anim]
type = ChangeAnim
trigger1 = !Time
trigger1 = PrevStateNo = 1331
value = 1308

[State 1305, RemoveExplod: EX Dunk FX]
type = RemoveExplod
trigger1 = 1
id = 1335

[State 1305, On Ground]
type = Posset
trigger1 = !Time
y = 0

[State 1305, Land Snd]
type = PlaySnd
trigger1 = Time = 1
value = 52,0

[State 1305, Landing Dust Explod]
type = Explod
trigger1 = !Time
anim = 8102
sprpriority = -3
postype = P1
scale = 0.5,0.5
pauseMoveTime = -1
superMoveTime = -1
ownPal = 1

[State 1305, End]
type = ChangeState
trigger1 = !AnimTime
value = 301
ctrl = 1

;Rage Run "Save" Type
[Statedef 1310]
type = S
physics = N
ctrl = 0
anim = 1310

[State 1310, Friction]
type = VelMul
trigger1 = vel x > 0
trigger1 = 1
x = .9

[State 1310, Skid Snd]
type = PlaySnd
trigger1 = AnimElem = 1
value = 101,0

[State 1310, VelStop]
type = VelSet
trigger1 = !AnimTime
x = 0

[State 1310, End]
type = ChangeState
trigger1 = !AnimTime
value = 301
ctrl = 1

;Rage Run "Shift" Type
[Statedef 1320]
type = S
physics = N
ctrl = 0
anim = 1320
sprpriority = 2

[State 1320, Velocity]
type = VelSet
trigger1 = AnimElem = 1
x = 18

[State 1320, Friction]
type = VelMul
trigger1 = vel x > 0
trigger1 = 1
x = .9

[State 1320, Voice]
type = Playsnd
trigger1 = AnimElem = 1
value = 0,4
channel = 0

[State 1320, VelStop]
type = VelSet
trigger1 = AnimElem = 4
x = 0

[State 1320, Shift SFX]
type = PlaySnd
trigger1 = AnimElem = 1
value = 1300,2

[State 1320, Muteki]
type = NotHitBy
trigger1 = AnimElemTime(4) < 0
value = SCA

[State 1320, No Push]
type = PlayerPush
trigger1 = AnimElemTime(4) < 0
value = 0

[State 1320, Transparency]
type = trans
trigger1 = Time=[0,5]
trans = addalpha
alpha = 256-(Time*50),Time*50

[State 1320, Transparency]
type = trans
trigger1 = Time=[6,8]
trans = addalpha
alpha = (Time-6)*80,256-((Time-6)*80)

[State 1320, Turn]
type = Turn
trigger1 = AnimElemTime(3) >= 0
trigger1 = p2dist x < 0

[State 1320, End]
type = ChangeState
trigger1 = !AnimTime
value = 301
ctrl = 1

;========================<EX RAGE RUN>=======================
[Statedef 1330]
type = S
movetype = I
physics = N
anim = 1300
ctrl = 0
velset = 9,0
poweradd = ifelse(var(20) > 0, 0, -500)
sprpriority = 2
facep2 = 1

[State 1330, MAX Timer Drain]
type = VarAdd
trigger1 = !Time
trigger1 = var(20) > 0
var(20) = -335

[State 1330, EX Sound]
type = PlaySnd
trigger1 = !Time
value = 0, ifelse(!fvar(31), 1000, 1001)

[State 1330, EX Flash]
type = VarSet
trigger1 = !Time
var(25) = 35

[State 1330, EX FX(Phantom)]
type = Explod
triggerall = !fvar(31)
trigger1 = !Time
anim = 8210
sprPriority = 3
posType = p1
pos = 28, -68
scale = 0.5, 0.5
pauseMoveTime = -1
superMoveTime = -1
ownPal = 1

[State 1330, EX FX 1(Divine)]
type = Explod
triggerall = fvar(31)
trigger1 = !Time
anim = 8220
sprpriority = 4
postype = p1
pos = 0, 0
bindtime = 1
facing = -1
scale = 0.5, 0.5;based on char size
pauseMoveTime = -1
superMoveTime = -1
ownpal = 1

[State 1330, EX FX 2(Divine)]
type = Explod
triggerall = fvar(31)
trigger1 = !Time
anim = 8221
sprpriority = -1
postype = p1
pos = 0, 0
bindtime = 1
facing = 1
scale = 0.5, 0.5;based on char size
pauseMoveTime = -1
superMoveTime = -1
ownpal = 1

[State 1330, Width]
type = Width
trigger1 = 1
edge = 5,0

[State 1330, Dash Snd]
type = PlaySnd
trigger1 = AnimElem = 1
value = 1300,0
channel = 1

[State 1330, Step Snd 1]
type = PlaySnd
trigger1 = AnimElem = 2
value = 100,0

[State 1330, Step Snd 2]
type = PlaySnd
trigger1 = AnimElem = 6
value = 100,1

[State 1330, EX "Dunk" Type]
type = ChangeState
triggerall = Time >= 1
trigger1 = P2BodyDist x <= 10
value = 1331
ctrl = 0

[State 1330, End(Miss)]
type = ChangeState
trigger1 = Time >= 24
value = 1301
ctrl = 0

;EX "Dunk" Type
[Statedef 1331]
type = S
movetype = A
physics = N
anim = 1330
ctrl = 0
velset = 0,0
poweradd = 0
sprpriority = 2

[State 1331, Extra Stock Subtract]
type = VarAdd
triggerall = var(14) > 0
trigger1 = MoveHit=1 && NumTarget
var(14) = -1
;ignorehitpause = 1

[State 1331, Restriction Set]
type = VarSet
trigger1 = MoveHit=1 && NumTarget(1390)
var(40) = 0

[State 1331, Width]
type = Width
trigger1 = 1
edge = 5,0

[State 1331, EX Flash]
type = VarSet
trigger1 = !Time
var(25) = 35

[State 1331, Voice]
type = PlaySnd
trigger1 = AnimElem = 5
value = 1300,1
channel = 0

[State 1331, Jump Snd]
type = PlaySnd
trigger1 = AnimElem = 2
value = 41,0

[State 1331, Swing Snd]
type = PlaySnd
trigger1 = AnimElem = 6
value = 1,2
channel = 1

[State 1331, Energy Snd]
type = PlaySnd
trigger1 = AnimElem = 6
value = 1200,1
channel = 2

[State 1331, Dust Helper]
type = Helper
trigger1 = AnimElem = 2
helperType = Normal
stateNo = 8100
ID = 8100
name = "Jump Dust"
posType = P1
ownPal = 1

[State 1331, Dunk FX]
type = Explod
trigger1 = AnimElem = 7
anim = 1335
ID = 1335
pos = 60,-50
postype = P1
sprpriority = 3
scale = 0.5,0.5
ignorehitpause = 1
bindtime = -1
removetime = -1
pausemovetime = 255
supermovetime = 255
ownpal = 1
removeongethit = 1

[State 1331, StateTypeSet: Air, No Phys]
type = StateTypeSet
trigger1 = AnimElem = 2
statetype = A
physics = N

[State 1331, Velocity]
type = VelSet
trigger1 = AnimElem = 2
x = 4
y = -7;-8

[State 1331, Gravity]
type = VelAdd
trigger1 = AnimElemTime(2) >= 0 && AnimElemTime(7) < 0
y = .56

[State 1331, Gravity]
type = VelAdd
trigger1 = AnimElemTime(7) >= 0
y = .72

[State 1331, Hit] 
type = HitDef
triggerall = var(14)
triggerall = var(31)
trigger1 = !var(16) && var(15) < 1
trigger1 = AnimElem = 7
id = 1390
attr = A, SA
damage = ceil(ifElse(fvar(11) * 63 < 7, 7, fvar(11) * 63)), 7
priority = 4, hit
animtype = Hard
getpower = 0, 0
givepower = 35, 35
guardflag = HA
hitflag = MAF
hitsound = S2,2
guardsound = S130,0
pausetime = 10,12
guard.pausetime = 14,12
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 59), var(36) := -47
air.animtype = Back
fall.animtype = Back
ground.type = High
air.type = High
ground.slidetime = 18
ground.hittime  = 18
guard.hittime = 18
ground.velocity = -1.5, 8
air.velocity = -1.5, 8
guard.velocity = -8
airguard.velocity = -6.65, -1
airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .5
fall = 1
fall.recover = 0
forcestand = 1
p2facing = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1331, P2 Custom State]
type = TargetState
trigger1= MoveHit =1 && NumTarget(1390)
trigger1= Target(1390),MoveType=H
ID = 1390
value = 1390
ignorehitpause=0

[State 1331, Juggle Reset]
type = VarSet
trigger1 = MoveHit=1 && NumTarget
var(15) = 0
ignoreHitPause=1

[State 1331, End]
type = ChangeState
trigger1 = AnimElemTime(6) > 0
trigger1 = pos y > -vel y
value = 1305

;===============Hit by EX Rage Run(Fall)============
[Statedef 1390]
type = A
movetype = H
physics = N
velset = -1.5,8

[State 1390, Width]
type = Width
trigger1 = 1
edge = 25,-25
player = 25,0

[State 1390, ChangeAnim]
type = ChangeAnim
trigger1 = !Time
value = 5030

[State 1390, Muteki]
type = NotHitBy
trigger1 = 1
value = SCA
ignorehitpause = 1

[State 1390, Bounce]
type = ChangeState
trigger1 = Pos Y >= 0 && Vel Y > 0;pos y > -vel y
value = 1391

;Ground Bounce Neo
[Statedef 1391]
type = A
movetype = H
physics = N
velset = 0,0

[State 1391, On Ground]
type = PosSet
trigger1 = !Time
y = 0

[State 1391, Muteki]
type = NotHitBy
trigger1 = AnimElemTime(2)<0
value = SCA

[State 1391, SFX]
type = PlaySnd
triggerall = PrevStateNo!=1236
trigger1 = Time=1
value = F7, (sysvar(1) > 5) + (sysvar(1) > 14)

[State 1391, EnvShake]
type = EnvShake
triggerall = PrevStateNo!=1236
trigger1 = !Time
time = 14
ampl = 5

[State 1391, ChangeAnim2]
type = ChangeAnim2
trigger1 = !Time
value = 6160;5160

[State 1391, Velset]
type = VelSet
trigger1 = AnimElemTime(2)=0;Time=0
x = -0.8
y = -6.5

[State 1391, Gravity]
type = VelAdd
trigger1 = 1
y = 0.42
;------------------
[State 1391, AngleAdd];special thanks to Zzyzzyxx
type = AngleAdd
trigger1 = Time > 2
value = ifelse((facing != enemynear, facing), 22, -22)

[State 1391, AngleDraw]
type = AngleDraw
trigger1 = Time > 2

[State 1391, AngleSet]
type = AngleSet
trigger1 = (pos y-16)>-vel y;pos y > -vel y
value = 0
ignorehitpause = 1
;------------------
[State 1391, End]
type = SelfState
trigger1 = (pos y-16)>-vel y
value = 5100

;=======================<RISING TACKLE>=======================
[Statedef 1400]
type = S
movetype = A
physics = N
anim = 1400
ctrl = 0
velset = 0,0
poweradd = 70 * !var(20)
sprpriority = 2
facep2 = 1

[State 1400, Width]
type = Width
trigger1 = 1
edge = 8,0

[State 1400, Muteki]
type = Nothitby
trigger1 = AnimElemTime(4)<0
time = 1
value = SCA

[State 1400, Voice]
type = PlaySnd
trigger1 = AnimElem = 1
value = 1400,0
channel = 0

[State 1400, Jump Snd]
type = PlaySnd
trigger1 = AnimElem = 6
value = 41,0

[State 1400, Swing Snd]
type = PlaySnd
trigger1 = AnimElem = 2
trigger2 = AnimElem = 7
trigger3 = AnimElem = 10
value = 1,2
channel = 1

[State 1400, Dust Helper]
type = Helper
trigger1 = AnimElem = 6
helperType = Normal
stateNo = 8100
ID = 8100
name = "Jump Dust"
posType = P1
ownPal = 1

[State 1400, StateTypeSet: Air, No Phys]
type = StateTypeSet
trigger1 = AnimElem = 6
statetype = A
physics = N

[State 1400, Velocity]
type = VelSet
trigger1 = AnimElem = 1
x = 1

[State 1400, Friction]
type = Velmul
trigger1 = vel x > 0
trigger1 = AnimElemTime(1) > 0
x = 0.95

[State 1400, Velocity]
type = VelSet
trigger1 = AnimElem = 6
y = -6.3

[State 1400, Gravity]
type = VelAdd
trigger1 = AnimElemTime(6) > 0
y = .65

[State 1400, VelStop]
type = VelSet
trigger1 = AnimElem = 10
x = 0

[State 1400, Hit 1] 
type = HitDef
trigger1 = !var(16) && var(15) < 1
trigger1 = AnimElem = 3
attr = S, SA
damage = ceil(ifElse(fvar(11) * 56 < 7, 7, fvar(11) * 56)), 7
priority = 4, hit
animtype = Hard
getpower = 30*!var(20), 30*!var(20)
givepower = 35, 35
guardflag = M
hitflag = MAF
hitsound = S2,2
guardsound = S130,0
pausetime = 12,12
guard.pausetime = 12,12
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 28), var(36) := -71
air.animtype = Back
fall.animtype = Back
ground.type = Low
air.type = Low
ground.slidetime = 18
ground.hittime  = 18
guard.hittime = 18
ground.velocity = -1.8, -7.5
air.velocity = -1.8, -7.5
guard.velocity = -8
;airguard.velocity = -6.65, -1
;airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .45
fall = 1
fall.recover = 0
forcestand = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1400, Hits 2+] 
type = HitDef
trigger1 = !var(16) && var(15) < 3
trigger1 = AnimElem = 7 || AnimElem = 8 || AnimElem = 9 || AnimElem = 10
attr = A, SA
damage = ceil(ifElse(fvar(11) * 21 < 7, 7, fvar(11) * 21)), 4
priority = 4, hit
animtype = Hard
getpower = 30*!var(20), 30*!var(20)
givepower = 35, 35
guardflag = MA
hitflag = MAF
hitsound = S2,2
guardsound = S130,0
pausetime = 6,6
guard.pausetime = 6,6
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 28), var(36) := -64
air.animtype = Back
fall.animtype = Back
ground.type = High
air.type = High
ground.slidetime = 18
ground.hittime  = 18
guard.hittime = 18
ground.velocity = -1.85, -10
air.velocity = -1.85, -10
guard.velocity = -8
airguard.velocity = -6.65, -1
airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .5
fall = 1
fall.recover = 0
forcestand = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1400, StateTypeSet: Idle]
type = StateTypeSet
trigger1 = AnimElemTime(11) >= 0
moveType = I

[State 1400, End]
type = ChangeState
trigger1 = AnimElemTime(10) > 0
trigger1 = pos y > -vel y
value = 1405

;Rising Tackle Landing
[Statedef 1405]
type = S
movetype = I
physics = S
ctrl = 0
anim = 1405
velset = 0, 0

[State 1405, On Ground]
type = Posset
trigger1 = !Time
y = 0

[State 1405, Land Snd]
type = PlaySnd
trigger1 = Time = 1
value = 52,0

[State 1405, Landing Dust Explod]
type = Explod
trigger1 = !Time
anim = 8102
sprpriority = -3
postype = P1
scale = 0.5,0.5
pauseMoveTime = -1
superMoveTime = -1
ownPal = 1

[State 1405, End]
type = ChangeState
trigger1 = !AnimTime
value = 301
ctrl = 1

;Medium
[Statedef 1410]
type = S
movetype = A
physics = N
anim = 1410
ctrl = 0
velset = 0,0
poweradd = 70 * !var(20)
sprpriority = 2
facep2 = 1

[State 1410, Width]
type = Width
trigger1 = 1
edge = 8,0

[State 1410, Muteki]
type = Nothitby
trigger1 = AnimElemTime(4)<0
time = 1
value = SCA

[State 1410, Voice]
type = PlaySnd
trigger1 = AnimElem = 1
value = 1400,0
channel = 0

[State 1410, Jump Snd]
type = PlaySnd
trigger1 = AnimElem = 6
value = 41,0

[State 1410, Swing Snd]
type = PlaySnd
trigger1 = AnimElem = 2
trigger2 = AnimElem = 7
trigger3 = AnimElem = 10
trigger4 = AnimElem = 13
value = 1,2
channel = 1

[State 1410, Dust Helper]
type = Helper
trigger1 = AnimElem = 6
helperType = Normal
stateNo = 8100
ID = 8100
name = "Jump Dust"
posType = P1
ownPal = 1

[State 1410, StateTypeSet: Air, No Phys]
type = StateTypeSet
trigger1 = AnimElem = 6
statetype = A
physics = N

[State 1410, Velocity]
type = VelSet
trigger1 = AnimElem = 1
x = 1.5

[State 1410, Friction]
type = Velmul
trigger1 = vel x > 0
trigger1 = AnimElemTime(1) > 0
x = 0.95

[State 1410, Velocity]
type = VelSet
trigger1 = AnimElem = 6
y = -8

[State 1410, Gravity]
type = VelAdd
trigger1 = AnimElemTime(6) > 0
y = .65

[State 1410, VelStop]
type = VelSet
trigger1 = AnimElem = 12
x = 0

[State 1410, Hit 1] 
type = HitDef
trigger1 = !var(16) && var(15) < 1
trigger1 = AnimElem = 3
attr = S, SA
damage = ceil(ifElse(fvar(11) * 49 < 7, 7, fvar(11) * 49)), 7
priority = 4, hit
animtype = Hard
getpower = 30*!var(20), 30*!var(20)
givepower = 35, 35
guardflag = M
hitflag = MAF
hitsound = S2,2
guardsound = S130,0
pausetime = 12,12
guard.pausetime = 12,12
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 28), var(36) := -71
air.animtype = Back
fall.animtype = Back
ground.type = Low
air.type = Low
ground.slidetime = 18
ground.hittime  = 18
guard.hittime = 18
ground.velocity = -1.8, -7.5
air.velocity = -1.8, -7.5
guard.velocity = -8
;airguard.velocity = -6.65, -1
;airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .45
fall = 1
fall.recover = 0
forcestand = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1410, Hits 2+] 
type = HitDef
trigger1 = !var(16) && var(15) < 4
trigger1 = AnimElem = 7 || AnimElem = 8 || AnimElem = 9 || AnimElem = 10 || AnimElem = 11 || AnimElem = 12
attr = A, SA
damage = ceil(ifElse(fvar(11) * 21 < 7, 7, fvar(11) * 21)), 4
priority = 4, hit
animtype = Hard
getpower = 30*!var(20), 30*!var(20)
givepower = 35, 35
guardflag = MA
hitflag = MAF
hitsound = S2,2
guardsound = S130,0
pausetime = 6,6
guard.pausetime = 6,6
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 28), var(36) := -64
air.animtype = Back
fall.animtype = Back
ground.type = High
air.type = High
ground.slidetime = 18
ground.hittime  = 18
guard.hittime = 18
ground.velocity = -1.85, -10
air.velocity = -1.85, -10
guard.velocity = -8
airguard.velocity = -6.65, -1
airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .5
fall = 1
fall.recover = 0
forcestand = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1410, StateTypeSet: Idle]
type = StateTypeSet
trigger1 = AnimElemTime(13) >= 0
moveType = I

[State 1410, End]
type = ChangeState
trigger1 = AnimElemTime(12) > 0
trigger1 = pos y > -vel y
value = 1405

;Strong
[Statedef 1420]
type = S
movetype = A
physics = N
anim = 1420
ctrl = 0
velset = 0,0
poweradd = 70 * !var(20)
sprpriority = 2
facep2 = 1

[State 1420, Width]
type = Width
trigger1 = 1
edge = 8,0

[State 1420, Muteki]
type = Nothitby
trigger1 = AnimElemTime(5)<0
time = 1
value = SCA

[State 1420, Voice]
type = PlaySnd
trigger1 = AnimElem = 1
value = 1400,0
channel = 0

[State 1420, Jump Snd]
type = PlaySnd
trigger1 = AnimElem = 6
value = 41,0

[State 1420, Swing Snd]
type = PlaySnd
trigger1 = AnimElem = 2
trigger2 = AnimElem = 7
trigger3 = AnimElem = 10
trigger4 = AnimElem = 13
value = 1,2
channel = 1

[State 1420, Dust Helper]
type = Helper
trigger1 = AnimElem = 6
helperType = Normal
stateNo = 8100
ID = 8100
name = "Jump Dust"
posType = P1
ownPal = 1

[State 1420, StateTypeSet: Air, No Phys]
type = StateTypeSet
trigger1 = AnimElem = 6
statetype = A
physics = N

[State 1420, Velocity]
type = VelSet
trigger1 = AnimElem = 1
x = 2

[State 1420, Friction]
type = Velmul
trigger1 = vel x > 0
trigger1 = AnimElemTime(1) > 0
x = 0.95

[State 1420, Velocity]
type = VelSet
trigger1 = AnimElem = 6
y = -10.2

[State 1420, Gravity]
type = VelAdd
trigger1 = AnimElemTime(6) > 0
y = .65

[State 1420, VelStop]
type = VelSet
trigger1 = AnimElem = 14
x = 0

[State 1420, Hit 1] 
type = HitDef
trigger1 = !var(16) && var(15) < 1
trigger1 = AnimElem = 3
attr = S, SA
damage = ceil(ifElse(fvar(11) * 63 < 7, 7, fvar(11) * 63)), 7
priority = 4, hit
animtype = Hard
getpower = 30*!var(20), 30*!var(20)
givepower = 35, 35
guardflag = M
hitflag = MAF
hitsound = S2,2
guardsound = S130,0
pausetime = 12,12
guard.pausetime = 12,12
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 28), var(36) := -71
air.animtype = Back
fall.animtype = Back
ground.type = Low
air.type = Low
ground.slidetime = 18
ground.hittime  = 18
guard.hittime = 18
ground.velocity = -1.8, -7.5
air.velocity = -1.8, -7.5
guard.velocity = -8
;airguard.velocity = -6.65, -1
;airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .45
fall = 1
fall.recover = 0
forcestand = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1420, Hits 2+] 
type = HitDef
trigger1 = !var(16) && var(15) < 5
trigger1 = AnimElem = 7 || AnimElem = 8 || AnimElem = 9 || AnimElem = 10 || AnimElem = 11 || AnimElem = 12 || AnimElem = 13 || AnimElem = 14
attr = A, SA
damage = ceil(ifElse(fvar(11) * 14 < 7, 7, fvar(11) * 14)), 4
priority = 4, hit
animtype = Hard
getpower = 30*!var(20), 30*!var(20)
givepower = 35, 35
guardflag = MA
hitflag = MAF
hitsound = S2,2
guardsound = S130,0
pausetime = 6,6
guard.pausetime = 6,6
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 28), var(36) := -64
air.animtype = Back
fall.animtype = Back
ground.type = High
air.type = High
ground.slidetime = 18
ground.hittime  = 18
guard.hittime = 18
ground.velocity = -1.85, -10.5
air.velocity = -1.85, -10.5
guard.velocity = -8
airguard.velocity = -6.65, -1
airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .5
fall = 1
fall.recover = 0
forcestand = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1420, StateTypeSet: Idle]
type = StateTypeSet
trigger1 = AnimElemTime(15) >= 0
moveType = I

[State 1420, End]
type = ChangeState
trigger1 = AnimElemTime(14) > 0
trigger1 = pos y > -vel y
value = 1405

;=======================<EX RISING TACKLE>=======================
[StateDef 1430]
type = S
physics = N
moveType = A
anim = 1420
ctrl = 0
velset = 0,0
sprPriority = 2
poweradd = ifelse(var(20) > 0, 0, -500)
faceP2 = 1

[State 1430, MAX Timer Drain]
type = VarAdd
trigger1 = !Time
trigger1 = var(20) > 0
var(20) = -335

[State 1430, EX Sound]
type = PlaySnd
trigger1 = !Time
value = 0, ifelse(!fvar(31), 1000, 1001)

[State 1430, EX Flash]
type = VarSet
trigger1 = !Time
var(25) = 50

[State 1430, EX FX(Phantom)]
type = Explod
triggerall = !fvar(31)
trigger1 = !Time
anim = 8210
sprPriority = 3
posType = p1
pos = 5, -48
scale = 0.5, 0.5
pauseMoveTime = -1
superMoveTime = -1
ownPal = 1

[State 1430, EX FX 1(Divine)]
type = Explod
triggerall = fvar(31)
trigger1 = !Time
anim = 8220
sprpriority = 4
postype = p1
pos = 0, 0
bindtime = 1
facing = -1
scale = 0.5, 0.5;based on char size
pauseMoveTime = -1
superMoveTime = -1
ownpal = 1

[State 1430, EX FX 2(Divine)]
type = Explod
triggerall = fvar(31)
trigger1 = !Time
anim = 8221
sprpriority = -1
postype = p1
pos = 0, 0
bindtime = 1
facing = 1
scale = 0.5, 0.5;based on char size
pauseMoveTime = -1
superMoveTime = -1
ownpal = 1

[State 1430, Width]
type = Width
trigger1 = 1
edge = 8,0

[State 1430, Muteki]
type = Nothitby
trigger1 = AnimElemTime(7)<0
time = 1
value = SCA

[State 1430, Voice]
type = PlaySnd
trigger1 = AnimElem = 1
value = 1400,0
channel = 0

[State 1430, Jump Snd]
type = PlaySnd
trigger1 = AnimElem = 6
value = 41,0

[State 1430, Swing Snd]
type = PlaySnd
trigger1 = AnimElem = 2
trigger2 = AnimElem = 7
trigger3 = AnimElem = 10
trigger4 = AnimElem = 13
value = 1,2
channel = 1

[State 1430, Dust Helper]
type = Helper
trigger1 = AnimElem = 6
helperType = Normal
stateNo = 8100
ID = 8100
name = "Jump Dust"
posType = P1
ownPal = 1

[State 1430, StateTypeSet: Air, No Phys]
type = StateTypeSet
trigger1 = AnimElem = 6
statetype = A
physics = N

[State 1430, Velocity]
type = VelSet
trigger1 = AnimElem = 1
x = 2.5

[State 1430, Friction]
type = Velmul
trigger1 = vel x > 0
trigger1 = AnimElemTime(1) > 0
x = 0.98

[State 1430, Velocity]
type = VelSet
trigger1 = AnimElem = 6
y = -11

[State 1430, Gravity]
type = VelAdd
trigger1 = AnimElemTime(6) > 0
y = .62

[State 1430, VelStop]
type = VelSet
trigger1 = AnimElem = 14
x = 0

[State 1430, Hit 1] 
type = HitDef
trigger1 = !var(16) && var(15) < 2
trigger1 = AnimElem = 3
attr = S, SA
damage = ceil(ifElse(fvar(11) * 56 < 7, 7, fvar(11) * 56)), 7
priority = 4, hit
animtype = Hard
getpower = 0, 0
givepower = 35, 35
guardflag = M
hitflag = MAF
hitsound = S2,2
guardsound = S130,0
pausetime = 16,16
guard.pausetime = 12,12
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 28), var(36) := -71
air.animtype = Back
fall.animtype = Back
ground.type = Low
air.type = Low
ground.slidetime = 18
ground.hittime  = 18
guard.hittime = 18
ground.velocity = -1.8, -7.5
air.velocity = -1.8, -7.5
guard.velocity = -8
;airguard.velocity = -6.65, -1
;airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .45
fall = 1
fall.recover = 0
forcestand = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1430, Hits 2+] 
type = HitDef
trigger1 = !var(16) && var(15) < 7
trigger1 = AnimElem = 7 || AnimElem = 8 || AnimElem = 9 || AnimElem = 10 || AnimElem = 11 || AnimElem = 12 || AnimElem = 13 || AnimElem = 14
attr = A, SA
damage = ceil(ifElse(fvar(11) * 14 < 7, 7, fvar(11) * 14)), 4
priority = 4, hit
animtype = Hard
getpower = 0, 0
givepower = 35, 35
guardflag = MA
hitflag = MAF
hitsound = S2,2
guardsound = S130,0
pausetime = 6,6
guard.pausetime = 6,6
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 28), var(36) := -64
air.animtype = Back
fall.animtype = Back
ground.type = High
air.type = High
ground.slidetime = 18
ground.hittime  = 18
guard.hittime = 18
ground.velocity = -1.85, -10.5
air.velocity = -1.85, -10.5
guard.velocity = -8
airguard.velocity = -6.65, -1
airguard.ctrlTime = 16
ground.cornerPush.velOff = 0
guard.cornerPush.velOff = 0
air.cornerPush.velOff = 0
yaccel = .5
fall = 1
fall.recover = 0
forcestand = 1
palFX.time = 12 * var(9)
palFX.add = 255,255,255
palFX.sinAdd= -255,-255,-255,48
envshake.time = 14
envshake.ampl = 4
envShake.freq = 120

[State 1430, StateTypeSet: Idle]
type = StateTypeSet
trigger1 = AnimElemTime(15) >= 0
moveType = I

[State 1430, End]
type = ChangeState
trigger1 = AnimElemTime(14) > 0
trigger1 = pos y > -vel y
value = 1405

;==================<SHINKU NAGE>==================
[Statedef 1500]
type    = S
movetype= A
physics = S
juggle  = 0
velset = 0,0
ctrl = 0
poweradd = 70 * !var(20)
anim = 1500
facep2 = 1

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

[State 1500, Throw]
type = Hitdef
trigger1 = AnimElem = 4
trigger1 = !var(38)
attr = S, ST
priority = 4,Miss
getpower = 35 * !var(20)
givepower = 0
hitflag = M-
numhits = 0
sparkno = -1
p1stateno = 1501
hitsound = s800, 0
fall = 1
fall.recover = 0

[State 1500, Miss Voice]
type = PlaySnd
trigger1 = AnimElem = 5
value = 1500,0
channel = 0

[State 1500, Swing Snd]
type = PlaySnd
trigger1 = AnimElem = 5
value = 1,0
channel = 1

[State 1500, StateTypeSet: Idle]
type = StateTypeSet
trigger1 = AnimElemTime(5) >= 0
moveType = I

[State 1500, End]
type = ChangeState
trigger1 = !AnimTime
value = 0
ctrl = 1

;Shinku Nage(Success)
[Statedef 1501]
type = S
movetype = A
physics = S
anim = 1501
velset = 0, 0
poweradd = 0
sprpriority = 2

[State 1501, Turn]
type = Turn
trigger1 = !Time

[State 1501, Safety]
type = ChangeState
trigger1 = !Time && !NumTarget
value = 0
ctrl = 1

[State 1501, More Safety]
type = NotHitBy
trigger1 = 1
value = SCA

[State 1501, TargetState]
type = TargetState
trigger1 = !Time && NumTarget
value = 1505

[State 1501, Target Facing]
type = TargetFacing
trigger1 = Time <= 1
value = 1

[State 1501, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoAutoTurn

[State 1501, Voice]
type = PlaySnd
trigger1 = AnimElem = 2
value = 1500, 1
channel = 0

[State 1501, Width]
type = Width
trigger1 = AnimElemTime(5) < 0
edge = 20,0

[State 1501, Width]
type = Width
trigger1 = AnimElemTime(5) = 0
edge = 60,0

[State 1501, AfterImages]
type = AfterImage
trigger1 = AnimElem = 4
time = 999
TimeGap  = 3
FrameGap = 4
length = 10
PalBright = 1,1,1
PalContrast = 50,50,150
PalAdd = 0,0,0
PalMul = 1,1,1
trans = add1

[State 1501, RemoveAfterImages]
type = AfterImageTime
trigger1 = AnimElem = 12
time = 0

[State 1501, Bind 1]
type = TargetBind
trigger1 = AnimElemTime(2) < 0
trigger1 = NumTarget
pos = ceil(-50 * const(size.xScale)), ceil(-55 * const(size.yScale))

[State 1501, Bind 2]
type = TargetBind
trigger1 = AnimElemTime(2) >= 0 && AnimElemTime(3) < 0
trigger1 = NumTarget
pos = ceil(-26 * const(size.xScale)), ceil(-89 * const(size.yScale))

[State 1501, Bind 3]
type = TargetBind
trigger1 = AnimElemTime(3) >= 0 && AnimElemTime(4) < 0
trigger1 = NumTarget
pos = ceil(16 * const(size.xScale)), ceil(-132 * const(size.yScale))

[State 1501, Bind 4]
type = TargetBind
trigger1 = AnimElemTime(4) >= 0 && AnimElemTime(5) < 0
trigger1 = NumTarget
pos = ceil(21 * const(size.xScale)), ceil(-117 * const(size.yScale))

[State 1501, Bind 5]
type = TargetBind
trigger1 = AnimElemTime(5) >= 0 && AnimElemTime(6) < 0
trigger1 = NumTarget
pos = ceil(43 * const(size.xScale)), ceil(-122 * const(size.yScale))

[State 1501, Bind 6]
type = TargetBind
trigger1 = AnimElem = 6
trigger1 = NumTarget
pos = ceil(75 * const(size.xScale)), ceil(-80 * const(size.yScale))
time = 1

[State 1501, Damage 6]
type = TargetLifeAdd
trigger1 = NumTarget && AnimElem = 6
value = floor(ifElse(84 * fvar(11) < 7, -7, -84 * fvar(11)))

[State 1501, Throw 6]
type = TargetState
trigger1 = NumTarget && AnimElem = 6
value = 1506

[State 1501, TargetPowerAdd]
type = TargetPowerAdd
trigger1 = NumTarget && AnimElem = 6
value = 35

[State 1501, PowerAdd]
type = PowerAdd
trigger1 = NumTarget && AnimElem = 6 && !var(20)
value = 70

[State 1501, HitAdd]
type = HitAdd
trigger1 = NumTarget && AnimElem = 6
value = 1

[State 1501, VarAdd]
type = VarAdd
trigger1 = NumTarget && AnimElem = 6
var(13) = 1

[State 1501, No Juggle]
type = VarAdd
trigger1 = NumTarget && AnimElem = 6
var(15) = 0
ignoreHitPause = 1

[State 1501, No Juggle]
type = VarSet
trigger1 = NumTarget && AnimElem = 6
var(16) = 0
ignoreHitPause = 1

[State 1501, VarSet]
type = VarSet
trigger1 = !Time
var(4) = 0

[State 1501, VarSet: State Detection Range]
type = VarSet
triggerall = AnimElemTime(1) >= 0 && AnimElemTime(7) < 0
trigger1 = (helper(10371), var(0)) && (helper(10371), var(1)) || (helper(10371), var(1)) && (helper(10371), var(2)) || (helper(10371), var(0)) && (helper(10371), var(2))
var(4) = 1

[State 1501, Rasetsu]
type = ChangeState
triggerall = AnimElemTime(6) >= 0 && AnimElemTime(7) < 0
trigger1 = var(4) = 1
value = 1510

[State 1501, State End]
type = ChangeState
trigger1 = !AnimTime
value = 300
ctrl = 1

;(EX)Shinku Nage(Target)
[Statedef 1505]
type = A
movetype = H
physics = N
ctrl = 0
sprpriority = 1

[State 1505, Screenbound]
type = ScreenBound
Trigger1 = 1
value = 1
movecamera = 0,0

[State 1505, ChangeAnim2]
type = ChangeAnim2
Trigger1 = !Time
value = 1505

;In case attacker loses binding on player for any reason, this controller
;guarantees that the player will never get stuck in this thrown state.
[State 1505, Safety]
type = SelfState
trigger1 = !gethitvar(isbound)
value = 5050

;Shinku Nage(Target Thrown)
[Statedef 1506]
type = A
physics = N
movetype = H
ctrl = 0
velset = 0,0
sprpriority = 0

[State 1506, ScreenBound]
type = ScreenBound
trigger1 = 1
value = 1
movecamera = 1,0

[State 1506, Gravity]
type = VelAdd
trigger1 = 1
y = .49

[State 1506, Velocity]
type = VelSet
trigger1 = !Time
x = 4
y = -7.5

[State 1506, EnvShake]
type = EnvShake
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
time = 20

[State 1506, End] ;Hit ground
type = SelfState
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
value = 5100 ;Hit ground

;Rasetsu(holding)
[StateDef 1510]
type = S
physics = S
moveType = A
anim = 1510
ctrl = 0
velset = 0,0
sprPriority = 2
poweradd = 0
;faceP2 = 1

[State 1510, Voice]
type = PlaySnd
trigger1 = AnimElem = 3
value = 0,3
channel = 0
persistent = 0

[State 1510, Rasetsu Hand FX]
type = Explod
trigger1 = !NumExplod(1512)
trigger1 = AnimElem = 3
anim = 1512
ID = 1512
pos = -1, -3
postype = P1
sprpriority = 3
scale = 1,1
ignorehitpause = 1
bindtime = -1
removetime = -1
pausemovetime = 255
supermovetime = 255
ownpal = 1
removeongethit = 1

[State 1510, End: Brake]
type = ChangeState
triggerall = Time < 6
trigger1 = Command != "hold_x" && Command != "hold_y"
trigger2 = Command != "hold_y" && Command != "hold_z"
trigger3 = Command != "hold_z" && Command != "hold_x"
value = 0
ctrl = 1

[State 1510, End: Rasetsu Blast]
type = ChangeState
triggerall = Time >= 7
trigger1 = Command != "hold_x" && Command != "hold_y"
trigger2 = Command != "hold_y" && Command != "hold_z"
trigger3 = Command != "hold_z" && Command != "hold_x"
trigger4 = Time > 129
value = 1511

;Rasetsu Blast
[StateDef 1511]
type = S
physics = S
moveType = A
anim = 1511
ctrl = 0
velset = 0,0
sprPriority = 2
poweradd = 30 * !var(20)
;faceP2 = 1

[State 1511, Voice]
type = PlaySnd
trigger1 = AnimElem = 1
value = 1500,2
channel = 0

[State 1511, Rasetsu Snd]
type = PlaySnd
trigger1 = AnimElem = 1
value = 1500, 3
channel = 2

[State 1511, Width: Player]
type = Width
trigger1 = AnimElemTime(6) < 0
player = 10,0

[State 1511, Projectile]
type = Helper
trigger1 = AnimElemTime(3) = 0
helperType = Normal
stateNo = 1515
ID = 1515
name = "Rasetsu"
posType = P1
pos = 0,0
size.xScale = 0.5
size.yScale = 0.5
keyctrl = 1
ownpal = 1
facing = 1
persistent = 0
ignorehitpause = 1

[State 1511, End]
type = ChangeState
trigger1 = !AnimTime
value = 0
ctrl = 1

;==================<EX SHINKU NAGE>==================
[Statedef 1530]
type    = S
movetype= A
physics = S
juggle  = 0
velset = 0,0
ctrl = 0
poweradd = ifelse(var(20) > 0, 0, -500)
anim = 1530
facep2 = 1

[State 1530, MAX Timer Drain]
type = VarAdd
trigger1 = !Time
trigger1 = var(20) > 0
var(20) = -335

[State 1530, EX Sound]
type = PlaySnd
trigger1 = !Time
value = 0, ifelse(!fvar(31), 1000, 1001)

[State 1530, EX Flash]
type = VarSet
trigger1 = !Time
var(25) = 20

[State 1530, EX FX(Phantom)]
type = Explod
triggerall = !fvar(31)
trigger1 = !Time
anim = 8210
sprPriority = 3
posType = p1
pos = 10, -57
scale = 0.5, 0.5
pauseMoveTime = -1
superMoveTime = -1
ownPal = 1

[State 1530, EX FX 1(Divine)]
type = Explod
triggerall = fvar(31)
trigger1 = !Time
anim = 8220
sprpriority = 4
postype = p1
pos = 0, 0
bindtime = 1
facing = -1
scale = 0.5, 0.5;based on char size
pauseMoveTime = -1
superMoveTime = -1
ownpal = 1

[State 1530, EX FX 2(Divine)]
type = Explod
triggerall = fvar(31)
trigger1 = !Time
anim = 8221
sprpriority = -1
postype = p1
pos = 0, 0
bindtime = 1
facing = 1
scale = 0.5, 0.5;based on char size
pauseMoveTime = -1
superMoveTime = -1
ownpal = 1

[State 1530, AttackDist]
type = AttackDist
trigger1 = 1
value = 0

[State 1530, Throw]
type = Hitdef
triggerall = var(14)
triggerall = var(29)
trigger1 = AnimElem = 4
trigger1 = P2StateNo!=[150,152]
attr = S, ST
priority = 7,Miss
getpower = 0
givepower = 0
hitflag = M
numhits = 0
sparkno = -1
p1stateno = 1531
hitsound = s800, 0
fall = 1
fall.recover = 0

[State 1530, Miss Voice]
type = PlaySnd
trigger1 = AnimElem = 5
value = 1500,0
channel = 0

[State 1530, Swing Snd]
type = PlaySnd
trigger1 = AnimElem = 5
value = 1,0
channel = 1

[State 1530, StateTypeSet: Idle]
type = StateTypeSet
trigger1 = AnimElemTime(5) >= 0
moveType = I

[State 1530, End]
type = ChangeState
trigger1 = !AnimTime
value = 0
ctrl = 1

;EX Shinku Nage(Success)
[Statedef 1531]
type = S
movetype = A
physics = S
anim = 1531
velset = 0, 0
poweradd = 0
sprpriority = 2

[State 1531, Extra Stock Subtract]
type = VarAdd
triggerall = var(14) > 0
trigger1 = !Time && NumTarget
var(14) = -1
;ignorehitpause = 1

[State 1531, Restriction Set]
type = VarSet
trigger1 = !Time && NumTarget
var(29) = 0

[State 1531, Turn]
type = Turn
trigger1 = !Time

[State 1531, Safety]
type = ChangeState
trigger1 = !Time && !NumTarget
value = 0
ctrl = 1

[State 1531, More Safety]
type = NotHitBy
trigger1 = 1
value = SCA

[State 1531, TargetState]
type = TargetState
trigger1 = !Time && NumTarget
value = 1505

[State 1531, Target Facing]
type = TargetFacing
trigger1 = Time <= 1
value = 1

[State 1531, AssertSpecial]
type = AssertSpecial
trigger1 = 1
flag = NoAutoTurn

[State 1531, EX Flash]
type = VarSet
trigger1 = !Time
var(25) = 15

[State 1531, Voice]
type = PlaySnd
trigger1 = AnimElem = 2
value = 1500, 1
channel = 0

[State 1531, Width]
type = Width
trigger1 = AnimElemTime(5) < 0
edge = 20,0

[State 1531, Width]
type = Width
trigger1 = AnimElemTime(5) = 0
edge = 60,0

[State 1531, AfterImages]
type = AfterImage
trigger1 = AnimElem = 4
time = 999
TimeGap  = 3
FrameGap = 4
length = 10
PalBright = 1,1,1
PalContrast = 50,50,150
PalAdd = 0,0,0
PalMul = 1,1,1
trans = add1

[State 1531, RemoveAfterImages]
type = AfterImageTime
trigger1 = !AnimTime
time = 0

[State 1531, Bind 1]
type = TargetBind
trigger1 = AnimElemTime(2) < 0
trigger1 = NumTarget
pos = ceil(-50 * const(size.xScale)), ceil(-55 * const(size.yScale))

[State 1531, Bind 2]
type = TargetBind
trigger1 = AnimElemTime(2) >= 0 && AnimElemTime(3) < 0
trigger1 = NumTarget
pos = ceil(-26 * const(size.xScale)), ceil(-89 * const(size.yScale))

[State 1531, Bind 3]
type = TargetBind
trigger1 = AnimElemTime(3) >= 0 && AnimElemTime(4) < 0
trigger1 = NumTarget
pos = ceil(16 * const(size.xScale)), ceil(-132 * const(size.yScale))

[State 1531, Bind 4]
type = TargetBind
trigger1 = AnimElemTime(4) >= 0 && AnimElemTime(5) < 0
trigger1 = NumTarget
pos = ceil(21 * const(size.xScale)), ceil(-117 * const(size.yScale))

[State 1531, Bind 5]
type = TargetBind
trigger1 = AnimElemTime(5) >= 0 && AnimElemTime(6) < 0
trigger1 = NumTarget
pos = ceil(43 * const(size.xScale)), ceil(-122 * const(size.yScale))

[State 1531, Bind 6]
type = TargetBind
trigger1 = AnimElem = 6
trigger1 = NumTarget
pos = ceil(75 * const(size.xScale)), ceil(-80 * const(size.yScale))
time = 1

[State 1531, Damage 6]
type = TargetLifeAdd
trigger1 = NumTarget && AnimElem = 6
value = floor(ifElse(91 * fvar(11) < 7, -7, -91 * fvar(11)))

[State 1531, Throw 6]
type = TargetState
trigger1 = NumTarget && AnimElem = 6
value = 1535

[State 1531, TargetPowerAdd]
type = TargetPowerAdd
trigger1 = NumTarget && AnimElem = 6
value = 35

[State 1531, HitAdd]
type = HitAdd
trigger1 = NumTarget && AnimElem = 6
value = 1

[State 1531, VarAdd]
type = VarAdd
trigger1 = NumTarget && AnimElem = 6
var(13) = 1

[State 1531, No Juggle]
type = VarAdd
trigger1 = NumTarget && AnimElem = 6
var(15) = 0
ignoreHitPause = 1

[State 1531, No Juggle]
type = VarSet
trigger1 = NumTarget && AnimElem = 6
var(16) = 0
ignoreHitPause = 1

[State 1531, State End]
type = ChangeState
trigger1 = !AnimTime
value = 0
ctrl = 1

;EX Shinku Nage(Target Thrown)
[Statedef 1535]
type = A
physics = N
movetype = H
ctrl = 0
velset = 0,0
sprpriority = 0

[State 1535, ScreenBound]
type = ScreenBound
trigger1 = 1
value = 1
movecamera = 1,0

[State 1535, Gravity]
type = VelAdd
trigger1 = 1
y = .42

[State 1535, Velocity]
type = VelSet
trigger1 = !Time
x = 4
y = -7.65

[State 1535, EnvShake]
type = EnvShake
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
time = 20

[State 1535, End] ;Hit ground
type = SelfState
trigger1 = Vel Y > 0
trigger1 = Pos Y >= 0
value = 5100 ;Hit ground