; _________________________________________
;| Demitri by Jmorphman                    |
; ŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻ
;==============================================================================================
;========================================<SPECIAL MOVES>=======================================
;==============================================================================================

;========================<CHAOS FLARE>=============================
[StateDef 1000]
type = S
physics = N
moveType = A
anim = 1000
ctrl = 0
velSet = 0,0
sprPriority = 1
powerAdd = 72 * !var(20)
faceP2 = ifElse((PrevStateNo = [100,106]), 0, 1)

[State 1000, Button Detect]
type = VarSet
trigger1 = !Time && !AILevel
;ifElse((command = "z" || command = "rlsz"), 2, ifElse((command = "y" || command = "rlsy"), 1, 0))
var(10) = ifElse((NumExplod(90000220) || NumExplod(90000225)), 2, ifElse((NumExplod(90000210) || NumExplod(90000215)), 1, 0))

[State 1000, Button Detect (AI)]
type = VarSet
trigger1 = !Time && AILevel
var(10) = ifElse((P2MoveType = H || Random < 500), 2, ifElse(Random < 500, 1, 0))

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

[State 1000, Chaos Flare sound effect]
type = PlaySnd
trigger1 = AnimElem = 4
value = 1000,1
channel = 1

[State 1000, Projectile]
type = Helper
trigger1 = AnimElem = 4
helperType = Normal
stateNo = 1005
ID = 1005
name = "Chaos Flare Projectile"
posType = P1
pos = ceil(45 * const(size.xScale)), ceil(-70 * const(size.yScale))
size.xScale = const(size.xScale) * 0.5
size.yScale = 0.5
ownPal = 1

[State 1000, Width]
type = Width
trigger1 = AnimElemTime(4) = -1
value = 30,0

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



;========================<ES CHAOS FLARE>=============================
[StateDef 1030]
type = S
physics = N
moveType = A
anim = 1030
ctrl = 0
velSet = 0,0
sprPriority = 1
powerAdd = -1000
faceP2 = ifElse((PrevStateNo = [100,106]), 0, 1)

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

[State 1030, ES FX]
type = Explod
trigger1 = !Time
anim = 8210
sprPriority = 3
posType = p1
pos = ceil(16 * const(size.xScale)), ceil(-79 * const(size.yScale))
scale = 0.5, 0.5
pauseMoveTime = -1
superMoveTime = -1
ownPal = 1

[State 1030, ES Startup Sound]
type = PlaySnd
trigger1 = !Time
value = 0,1000
channel = 1

[State 1030, Voice]
type = PlaySnd
trigger1 = !Time
value = 1030,0
channel = 0

[State 1030, Chaos Flare sound effect]
type = PlaySnd
trigger1 = AnimElemTime(5) = 1
value = 1000,1
channel = 3

[State 1030, Chaos Flare startup effect (Right)]
type = Explod
trigger1 = !Time
anim = 1034
ID = 1034
bindTime = -1
sprPriority = 3
posType = P1
pos = ceil(-48 * const(size.xScale)), ceil(-76 * const(size.yScale))
scale = const(size.xScale) * 0.5, 0.5
ownPal = 1
removeOnGetHit = 1
ignoreHitPause = 0

[State 1030, ModifyExplod]
type = ModifyExplod
trigger1 = AnimElem = 2
ID = 1034
posType = P1
pos = ceil(-54 * const(size.xScale)), ceil(-95 * const(size.yScale))

[State 1030, ModifyExplod]
type = ModifyExplod
trigger1 = AnimElem = 3
ID = 1034
posType = P1
pos = ceil(-28 * const(size.xScale)), ceil(-68 * const(size.yScale))

[State 1030, ModifyExplod]
type = ModifyExplod
trigger1 = AnimElem = 4
ID = 1034
posType = P1
pos = ceil(4 * const(size.xScale)), ceil(-60 * const(size.yScale))

[State 1030, ModifyExplod]
type = ModifyExplod
trigger1 = AnimElem = 5
ID = 1034
posType = P1
pos = ceil(89 * const(size.xScale)), ceil(-64 * const(size.yScale))

[State 1030, ModifyExplod]
type = ModifyExplod
trigger1 = AnimElem = 6
ID = 1034
sprPriority = 1

[State 1030, Chaos Flare startup effect (Left)]
type = Explod
trigger1 = !Time
anim = 1034
ID = 11034
bindTime = -1
sprPriority = -1
posType = P1
pos = ceil(32 * const(size.xScale)), ceil(-88 * const(size.yScale))
scale = const(size.xScale) * 0.5, 0.5
ownPal = 1
removeOnGetHit = 1
ignoreHitPause = 0

[State 1030, ModifyExplod]
type = ModifyExplod
trigger1 = AnimElem = 2
ID = 11034
posType = P1
pos = ceil(25 * const(size.xScale)), ceil(-103 * const(size.yScale))

[State 1030, ModifyExplod]
type = ModifyExplod
trigger1 = AnimElem = 3
ID = 11034
posType = P1
pos = ceil(32 * const(size.xScale)), ceil(-72 * const(size.yScale))

[State 1030, ModifyExplod]
type = ModifyExplod
trigger1 = AnimElem = 4
ID = 11034
posType = P1
pos = ceil(48 * const(size.xScale)), ceil(-68 * const(size.yScale))

[State 1030, RemoveExplod]
type = RemoveExplod
trigger1 = AnimElem = 5
ID = 11034

[State 1030, Projectile]
type = Helper
trigger1 = AnimElemTime(5) = 1
helperType = Normal
stateNo = 1035
ID = 1035
name = "ES Chaos Flare Projectile"
posType = P1
pos = ceil(57 * const(size.xScale)), ceil(-60 * const(size.yScale))
size.xScale = const(size.xScale) * 0.5
size.yScale = 0.5
ownPal = 1

[State 1030, Width]
type = Width
trigger1 = AnimElemTime(5) = 0
value = 30,0

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



;========================<CHAOS FLARE (AIR)>=============================
[StateDef 1050]
type = A
physics = N
moveType = A
anim = 1050
ctrl = 0
sprPriority = 1
powerAdd = 72 * !var(20)
faceP2 = 0

[State 1050, Button Detect]
type = VarSet
trigger1 = !Time && !AILevel
;ifElse((command = "z" || command = "rlsz"), 2, ifElse((command = "y" || command = "rlsy"), 1, 0))
var(10) = ifElse((NumExplod(90000220) || NumExplod(90000225)), 2, ifElse((NumExplod(90000210) || NumExplod(90000215)), 1, 0))

[State 1050, Button Detect (AI)]
type = VarSet
trigger1 = !Time && AILevel
var(10) = ifElse((P2MoveType = H || Random < 500), 2, ifElse(Random < 500, 1, 0))

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

[State 1050, Chaos Flare sound effect]
type = PlaySnd
trigger1 = AnimElem = 4
value = 1000,1
channel = 1

[State 1050, Projectile]
type = Helper
trigger1 = AnimElem = 4
helperType = Normal
stateNo = 1005
ID = 1005
name = "Chaos Flare Projectile"
posType = P1
pos = ceil(33 * const(size.xScale)), ceil(-78 * const(size.yScale))
size.xScale = const(size.xScale) * 0.5
size.yScale = 0.5
ownPal = 1

[State 1050, VelMul]
type = VelMul
trigger1 = !Time
x = 0.125
y = 0.125

[State 1050, VelAdd]
type = VelAdd
trigger1 = Time && AnimElemTime(4) < 0
y = 0.0732421875

[State 1050, VelSet]
type = VelSet
trigger1 = AnimElem = 4
x = ifElse(var(10) = 2, -3.75, ifElse(var(10) = 1, -2.8125, -1.875))
y = -2.5

[State 1050, VelAdd]
type = VelAdd
trigger1 = AnimElemTime(4) > 0
y = 0.48828125

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

[State 1050, ChangeState]
type = ChangeState
trigger1 = pos y > -vel y
value = 1051


;Landing
[StateDef 1051]
type = S
anim = 47
physics = N
moveType = I
velSet = 0,0

[State 1051, PosSet]
type = PosSet
trigger1 = 1
y = 0

[State 1051, 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 1051, Landing Sound]
type = PlaySnd
trigger1 = !Time
value = 52,0
channel = 4

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



;========================<ES CHAOS FLARE (AIR)>=============================
[StateDef 1080]
type = S
physics = N
moveType = A
anim = 1080
ctrl = 0
sprPriority = 1
powerAdd = -1000
faceP2 = 0

[State 1080, ES Flash]
type = VarSet
trigger1 = 1
var(25) = 2

[State 1080, ES FX]
type = Explod
trigger1 = !Time
anim = 8210
sprPriority = 3
posType = p1
pos = ceil(16 * const(size.xScale)), ceil(-79 * const(size.yScale))
scale = 0.5, 0.5
pauseMoveTime = -1
superMoveTime = -1
ownPal = 1

[State 1080, ES Startup Sound]
type = PlaySnd
trigger1 = !Time
value = 0,1000
channel = 1

[State 1080, Voice]
type = PlaySnd
trigger1 = !Time
value = 1030,0
channel = 0

[State 1080, Chaos Flare sound effect]
type = PlaySnd
trigger1 = AnimElem = 4
value = 1000,1
channel = 3

[State 1080, Chaos Flare startup effect (Right)]
type = Explod
trigger1 = !Time
anim = 1084
ID = 1084
bindTime = -1
removeTime = -1
sprPriority = 3
posType = P1
pos = ceil(-56 * const(size.xScale)), ceil(-76 * const(size.yScale))
scale = const(size.xScale) * 0.5, 0.5
ownPal = 1
removeOnGetHit = 1
ignoreHitPause = 0

[State 1080, ModifyExplod]
type = ModifyExplod
trigger1 = AnimElem = 2
ID = 1084
posType = P1
pos = ceil(-44 * const(size.xScale)), ceil(-73 * const(size.yScale))

[State 1080, ModifyExplod]
type = ModifyExplod
trigger1 = AnimElem = 3
ID = 1084
posType = P1
pos = ceil(-20 * const(size.xScale)), ceil(-64 * const(size.yScale))

[State 1080, ModifyExplod]
type = ModifyExplod
trigger1 = AnimElem = 4
ID = 1084
posType = P1
pos = ceil(67 * const(size.xScale)), ceil(-73 * const(size.yScale))

[State 1080, ModifyExplod]
type = ModifyExplod
trigger1 = AnimElem = 5
ID = 1084
sprPriority = 1

[State 1080, Chaos Flare startup effect (Left)]
type = Explod
trigger1 = !Time
anim = 1084
ID = 11084
bindTime = -1
sprPriority = -1
posType = P1
pos = ceil(20 * const(size.xScale)), ceil(-86 * const(size.yScale))
scale = const(size.xScale) * 0.5, 0.5
ownPal = 1
removeOnGetHit = 1
ignoreHitPause = 0

[State 1080, ModifyExplod]
type = ModifyExplod
trigger1 = AnimElem = 2
ID = 11084
posType = P1
pos = ceil(20 * const(size.xScale)), ceil(-73 * const(size.yScale))

[State 1080, ModifyExplod]
type = ModifyExplod
trigger1 = AnimElem = 3
ID = 11084
posType = P1
pos = ceil(24 * const(size.xScale)), ceil(-70 * const(size.yScale))

[State 1080, RemoveExplod]
type = RemoveExplod
trigger1 = AnimElem = 4
ID = 11084

[State 1080, Projectile]
type = Helper
trigger1 = AnimElemTime(4) = 1
helperType = Normal
stateNo = 1035
ID = 1035
name = "ES Chaos Flare Projectile"
posType = P1
pos = ceil(57 * const(size.xScale)), ceil(-60 * const(size.yScale))
size.xScale = const(size.xScale) * 0.5
size.yScale = 0.5
ownPal = 1

[State 1080, VelMul]
type = VelMul
trigger1 = !Time
x = 0.125
y = 0.125

[State 1080, VelAdd]
type = VelAdd
trigger1 = Time && AnimElemTime(4) < 1
y = 0.0732421875

[State 1080, VelSet]
type = VelSet
trigger1 = AnimElemTime(4) = 1
x = -1.875
y = -2.5

[State 1080, VelAdd]
type = VelAdd
trigger1 = AnimElemTime(4) > 1
y = 0.48828125

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

[State 1080, ES Flash off]
type = VarSet
trigger1 = pos y > -vel y
var(25) = 0

[State 1080, RemoveExplod]
type = RemoveExplod
trigger1 = pos y > -vel y
ID = 1084

[State 1080, ChangeState]
type = ChangeState
trigger1 = pos y > -vel y
value = 1051



;=====================<DEMON CRADLE>==========================
[StateDef 1100]
type = S
physics = N
moveType = A
anim = 1100
ctrl = 0
velSet = 0,0
sprPriority = 1
powerAdd = 72 * !var(20)
faceP2 = ifElse((PrevStateNo = [100,106]), 0, 1)

[State 1100, Button Detect]
type = VarSet
trigger1 = !Time && !AILevel
;ifElse((command = "z" || command = "rlsz"), 2, ifElse((command = "y" || command = "rlsy"), 1, 0))
var(10) = ifElse((NumExplod(90000220) || NumExplod(90000225)), 2, ifElse((NumExplod(90000210) || NumExplod(90000215)), 1, 0))

[State 1100, Button Detect (AI)]
type = VarSet
trigger1 = !Time && AILevel
var(10) = ifElse((P2MoveType = H || Random < 500), 2, ifElse(Random < 500, 1, 0))

[State 1100, ChangeAnim]
type = ChangeAnim
trigger1 = !Time
value = ifElse(var(10) = 0, 1100, ifElse(var(10) = 1, 1110, 1120))

[State 1100, Voice]
type = PlaySnd
trigger1 = !Time
value = 1100,0
channel = 0

[State 1100, Jump Sound]
type = PlaySnd
trigger1 = AnimElem = 4
value = 1100,1
channel = 1

[State 1100, StateTypeSet: Air, Physics: None]
type = StateTypeSet
trigger1 = AnimElem = 4
stateType = A
physics = N

[State 1100, Dust Helper]
type = Helper
trigger1 = AnimElemTime(4) = 1
helperType = Normal
stateNo = 8100
ID = 8100
name = "Demon Cradle Dust"
posType = P1
ownPal = 1

[State 1100, VelSet]
type = VelSet
trigger1 = AnimElemTime(4) = 1
y = ifElse(var(10) = 2, -7.5, ifElse(var(10) = 1, -6.5625, -5.625))

[State 1100, VelAdd]
type = VelAdd
trigger1 = AnimElemTime(4) > 1
y = 0.390625

[State 1100, NotHitBy]
type = NotHitBy
trigger1 = AnimElemTime(3) < 0 && var(10) = [0,1]
trigger2 = AnimElemTime(4) < 0 && var(10) = 2
value = SCA
time = 1

[State 1100, Ground Hit]
type = HitDef
trigger1 = !var(16) && (var(15) < 1)
trigger1 = AnimElem = 2
attr = S, SA
hitFlag = MAF
guardFlag = M
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * ifElse(var(10) = 2, 140, ifElse(var(10) = 1, 126, 112)) < 7, 7, fvar(11) * ifElse(var(10) = 2, 140, ifElse(var(10) = 1, 126, 112)))), 7
getPower = ifElse(!var(13), 144, 72) * !var(20), 36 * !var(20)
givePower = 36, 36
pauseTime = 12,12
guard.pauseTime = 12,12
animType = Hard
air.animType = Hard
fall.animType = Hard
ground.type = Low
air.type = Low
ground.hitTime = 18
ground.slideTime = 18
guard.hitTime = 18
air.hitTime = 120
ground.velocity = -3.75, -10
ground.cornerPush.velOff = 0
guard.velocity = -12.64
guard.cornerPush.velOff = 0
air.velocity = -3.75, -10
air.cornerPush.velOff = 0
yAccel = 0.732421875
fall = 1
fall.recover = 1
fall.recoverTime = 120
forceStand = 1
hitSound = -1 + 0 * (var(31) := 2)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 30), var(36) := -68
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, Air Hit]
type = HitDef
trigger1 = !var(16) && (var(15) < 1)
trigger1 = AnimElem = 4 && !MoveContact && !MoveReversed
attr = A, SA
hitFlag = MAF
guardFlag = MA
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * ifElse(var(10) = 2, 98, ifElse(var(10) = 1, 84, 70)) < 7, 7, fvar(11) * ifElse(var(10) = 2, 98, ifElse(var(10) = 1, 84, 70)))), 7
getPower = ifElse(!var(13), 144, 72) * !var(20), 36 * !var(20)
givePower = 36, 36
pauseTime = 12,12
guard.pauseTime = 12,12
animType = Back
air.animType = Back
fall.animType = Back
ground.type = Low
air.type = Low
ground.hitTime = 18
ground.slideTime = 18
guard.hitTime = 18
air.hitTime = 120
ground.velocity = -3.75, -10
ground.cornerPush.velOff = 0
guard.velocity = -12.64
guard.cornerPush.velOff = 0
air.velocity = -3.75, -10
air.cornerPush.velOff = 0
airGuard.velocity = -8, -1
airGuard.cornerPush.velOff = 0
yAccel = 0.732421875
fall = 1
fall.recover = 1
fall.recoverTime = 120
forceStand = 1
hitSound = -1 + 0 * (var(31) := 5)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 50), var(36) := -95
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(11) >= 0 && var(10) = [0,1]
trigger2 = AnimElemTime(13) >= 0 && var(10) = 2
moveType = I

[State 1100, End]
type = ChangeState
trigger1 = pos y > -vel y
value = 1101


;Landing
[StateDef 1101]
type = S
anim = 1101
physics = N
moveType = I
velSet = 0,0

[State 1101, PosSet]
type = PosSet
trigger1 = 1
y = 0

[State 1101, 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 1101, Landing Sound]
type = PlaySnd
trigger1 = !Time
value = 52,0
channel = 4

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



;========================<ES DEMON CRADLE>=============================
[StateDef 1130]
type = S
physics = N
moveType = A
anim = 1130
ctrl = 0
velSet = 0,0
sprPriority = 1
powerAdd = -1000
faceP2 = ifElse((PrevStateNo = [100,106]), 0, 1)

[State 1130, ES Flash]
type = VarSet
trigger1 = !Time
var(25) = 44

[State 1130, ES FX]
type = Explod
trigger1 = !Time
anim = 8210
sprPriority = 3
posType = P1
pos = ceil(15 * const(size.xScale)), ceil(-48 * const(size.yScale))
scale = 0.5, 0.5
pauseMoveTime = -1
superMoveTime = -1
ownPal = 1

[State 1130, ES Startup Sound]
type = PlaySnd
trigger1 = !Time
value = 0,1000
channel = 1

[State 1130, Voice]
type = PlaySnd
trigger1 = !Time
value = 1130,0
channel = 0

[State 1130, ES Demon Cradle FX]
type = Explod
trigger1 = !Time
anim = 1135
ID = 1135
sprPriority = 3
posType = P1
scale = const(size.xScale) * 0.5, const(size.yScale) * 0.5
bindTime = -1
ownPal = 1
removeOnGetHit = 1
ignoreHitPause = 0

[State 1130, ES Demon Cradle sound effect]
type = PlaySnd
trigger1 = AnimElem = 3
value = 1130,1
channel = 3

[State 1130, StateTypeSet: Air, Physics: None]
type = StateTypeSet
trigger1 = AnimElem = 3
stateType = A
physics = N

[State 1130, Dust Helper]
type = Helper
trigger1 = AnimElemTime(3) = 1
helperType = Normal
stateNo = 8100
ID = 8100
name = "ES Demon Cradle Dust"
posType = P1
ownPal = 1

[State 1130, VelSet]
type = VelSet
trigger1 = AnimElemTime(3) = 1
y = -7.5

[State 1130, VelAdd]
type = VelAdd
trigger1 = AnimElemTime(3) > 1
y = 0.390625

[State 1130, NotHitBy]
type = NotHitBy
trigger1 = AnimElemTime(3) < 0
value = SCA
time = 1

[State 1130, Ground Hit]
type = HitDef
trigger1 = !var(16) && (var(15) < 1)
trigger1 = AnimElem = 2
attr = S, SA
hitFlag = MAF
guardFlag = M
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 35 < 7, 7, fvar(11) * 35)), 7
getPower = 0,0
givePower = 36, 36
pauseTime = 2,2
guard.pauseTime = 2,2
animType = Hard
air.animType = Hard
fall.animType = Hard
ground.type = Low
air.type = Low
ground.hitTime = 18
ground.slideTime = 18
guard.hitTime = 18
air.hitTime = 120
ground.velocity = -2.5, -10
ground.cornerPush.velOff = 0
guard.velocity = -12.64
guard.cornerPush.velOff = 0
air.velocity = -2.5, -10
air.cornerPush.velOff = 0
yAccel = 0.732421875
fall = 1
fall.recover = 1
fall.recoverTime = 120
forceStand = 1
hitSound = -1 + 0 * (var(31) := 2)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 30), var(36) := -68
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 1130, Air Hits]
type = HitDef
trigger1 = !var(16) && (var(15) < (1 + HitCount) && HitCount < 8)
trigger1 = AnimElem = 3 || AnimElem = 4 || AnimElem = 5 || AnimElem = 6 || AnimElem = 7 || AnimElem = 8 || AnimElem = 9 || AnimElem = 10 || AnimElem = 11
attr = A, SA
hitFlag = MAF
guardFlag = MA
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 35 < 7, 7, fvar(11) * 35)), 7
getPower = 0,0
givePower = 36, 36
pauseTime = 2,2
guard.pauseTime = 2,2
animType = Back
air.animType = Back
fall.animType = Back
ground.type = Low
air.type = Low
ground.hitTime = 18
ground.slideTime = 18
guard.hitTime = 18
air.hitTime = 120
ground.velocity = -2.5, -10
ground.cornerPush.velOff = 0
guard.velocity = -12.64
guard.cornerPush.velOff = 0
air.velocity = -2.5, -10
air.cornerPush.velOff = 0
airGuard.velocity = -8, -1
airGuard.cornerPush.velOff = 0
yAccel = 0.732421875
fall = 1
fall.recover = 1
fall.recoverTime = 120
forceStand = 1
hitSound = -1 + 0 * (var(31) := 5)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 35), var(36) := -90
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 1130, StateTypeSet: Idle]
type = StateTypeSet
trigger1 = AnimElemTime(12) >= 0
moveType = I

[State 1130, End]
type = ChangeState
trigger1 = pos y > -vel y
value = 1101



;=====================<DASHING DEMON CRADLE>==========================
[StateDef 1150]
type = S
physics = N
moveType = A
anim = 1150
ctrl = 0
velSet = 0,0
sprPriority = 1
powerAdd = 72 * !var(20)
faceP2 = ifElse((PrevStateNo = [100,106]), 0, 1)

[State 1150, Button Detect]
type = VarSet
trigger1 = !Time && !AILevel
;ifElse((command = "z" || command = "rlsz"), 2, ifElse((command = "y" || command = "rlsy"), 1, 0))
var(10) = ifElse((NumExplod(90000220) || NumExplod(90000225)), 2, ifElse((NumExplod(90000210) || NumExplod(90000215)), 1, 0))

[State 1150, Button Detect (AI)]
type = VarSet
trigger1 = !Time && AILevel
var(10) = ifElse((P2MoveType = H || Random < 500), 2, ifElse(Random < 500, 1, 0))

[State 1150, ChangeAnim]
type = ChangeAnim
trigger1 = !Time
value = ifElse(var(10) = 0, 1150, ifElse(var(10) = 1, 1160, 1170))

[State 1150, Voice]
type = PlaySnd
trigger1 = !Time
value = 1100,0
channel = 0

[State 1150, Jump Sound]
type = PlaySnd
trigger1 = AnimElem = 3
value = 1100,1
channel = 1

[State 1150, StateTypeSet: Air, Physics: None]
type = StateTypeSet
trigger1 = AnimElem = 3
stateType = A
physics = N

[State 1150, Dust Helper]
type = Helper
trigger1 = AnimElemTime(3) = 1
helperType = Normal
stateNo = 8100
ID = 8100
name = "Demon Cradle Dust"
posType = P1
ownPal = 1

[State 1150, VelSet]
type = VelSet
trigger1 = AnimElemTime(3) = 1
x = ifElse(var(10) = 2, 6.25, ifElse(var(10) = 1, 4.375, 2.5))
y = ifElse(var(10) = 2, -6.875, ifElse(var(10) = 1, -6.25, -5.625))

[State 1150, VelAdd]
type = VelAdd
trigger1 = vel x > 0
x = ifElse(var(10) = 2, -0.1586914063, ifElse(var(10) = 1, -0.09765625, -0.048828125))

[State 1150, VelAdd]
type = VelAdd
trigger1 = AnimElemTime(3) > 1
y = 0.390625

[State 1150, NotHitBy]
type = NotHitBy
trigger1 = AnimElemTime(3) < 0
value = SCA
time = 1

[State 1150, Ground Hit]
type = HitDef
trigger1 = !var(16) && (var(15) < 1)
trigger1 = AnimElem = 2
attr = S, SA
hitFlag = MAF
guardFlag = M
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * ifElse(var(10) = 2, 112, ifElse(var(10) = 1, 98, 84)) < 7, 7, fvar(11) * ifElse(var(10) = 2, 112, ifElse(var(10) = 1, 98, 84)))), 7
getPower = ifElse(!var(13), 144, 72) * !var(20), 36 * !var(20)
givePower = 36, 36
pauseTime = 12,12
guard.pauseTime = 12,12
animType = Hard
air.animType = Hard
fall.animType = Hard
ground.type = Low
air.type = Low
ground.hitTime = 18
ground.slideTime = 18
guard.hitTime = 18
air.hitTime = 120
ground.velocity = -3.75, -10
ground.cornerPush.velOff = 0
guard.velocity = -12.64
guard.cornerPush.velOff = 0
air.velocity = -3.75, -10
air.cornerPush.velOff = 0
yAccel = 0.732421875
fall = 1
fall.recover = 1
fall.recoverTime = 120
forceStand = 1
hitSound = -1 + 0 * (var(31) := 2)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 62), var(36) := -59
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 1150, Air Hit]
type = HitDef
trigger1 = !var(16) && (var(15) < 1)
trigger1 = AnimElem = 3 && !MoveContact && !MoveReversed
attr = A, SA
hitFlag = MAF
guardFlag = MA
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * ifElse(var(10) = 2, 91, ifElse(var(10) = 1, 77, 63)) < 7, 7, fvar(11) * ifElse(var(10) = 2, 91, ifElse(var(10) = 1, 77, 63)))), 7
getPower = ifElse(!var(13), 144, 72) * !var(20), 36 * !var(20)
givePower = 36, 36
pauseTime = 12,12
guard.pauseTime = 12,12
animType = Back
air.animType = Back
fall.animType = Back
ground.type = Low
air.type = Low
ground.hitTime = 18
ground.slideTime = 18
guard.hitTime = 18
air.hitTime = 120
ground.velocity = -3.75, -10
ground.cornerPush.velOff = 0
guard.velocity = -12.64
guard.cornerPush.velOff = 0
air.velocity = -3.75, -10
air.cornerPush.velOff = 0
airGuard.velocity = -8, -1
airGuard.cornerPush.velOff = 0
yAccel = 0.732421875
fall = 1
fall.recover = 1
fall.recoverTime = 120
forceStand = 1
hitSound = -1 + 0 * (var(31) := 5)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 50), var(36) := -95
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 1150, StateTypeSet: Idle]
type = StateTypeSet
trigger1 = AnimElemTime(10) >= 0 && !var(10)
trigger2 = AnimElemTime(11) >= 0 && var(10)
moveType = I

[State 1150, End]
type = ChangeState
trigger1 = pos y > -vel y
value = 1101



;========================<ES DASHING DEMON CRADLE>=============================
[StateDef 1180]
type = S
physics = N
moveType = A
anim = 1180
ctrl = 0
velSet = 0,0
sprPriority = 1
powerAdd = -1000
faceP2 = ifElse((PrevStateNo = [100,106]), 0, 1)

[State 1180, ES Flash]
type = VarSet
trigger1 = !Time
var(25) = 40

[State 1180, ES FX]
type = Explod
trigger1 = !Time
anim = 8210
sprPriority = 3
posType = P1
pos = ceil(15 * const(size.xScale)), ceil(-48 * const(size.yScale))
scale = 0.5, 0.5
pauseMoveTime = -1
superMoveTime = -1
ownPal = 1

[State 1180, ES Startup Sound]
type = PlaySnd
trigger1 = !Time
value = 0,1000
channel = 1

[State 1180, Voice]
type = PlaySnd
trigger1 = !Time
value = 1130,0
channel = 0

[State 1180, ES Demon Cradle FX]
type = Explod
trigger1 = !Time
anim = 1185
ID = 1185
sprPriority = 3
posType = P1
scale = const(size.xScale) * 0.5, const(size.yScale) * 0.5
bindTime = -1
ownPal = 1
removeOnGetHit = 1
ignoreHitPause = 0

[State 1180, ES Demon Cradle sound effect]
type = PlaySnd
trigger1 = AnimElem = 3
value = 1130,1
channel = 3

[State 1180, StateTypeSet: Air, Physics: None]
type = StateTypeSet
trigger1 = AnimElem = 3
stateType = A
physics = N

[State 1180, Dust Helper]
type = Helper
trigger1 = AnimElemTime(3) = 1
helperType = Normal
stateNo = 8100
ID = 8100
name = "ES Demon Cradle Dust"
posType = P1
ownPal = 1

[State 1180, VelSet]
type = VelSet
trigger1 = AnimElemTime(3) = 1
x = 6.25
y = -6.875

[State 1180, VelAdd]
type = VelAdd
trigger1 = vel x > 0
x = -0.1586914063

[State 1180, VelAdd]
type = VelAdd
trigger1 = AnimElemTime(3) > 1
y = 0.390625

[State 1180, NotHitBy]
type = NotHitBy
trigger1 = AnimElemTime(4) < 0
value = SCA
time = 1

[State 1180, Ground Hit]
type = HitDef
trigger1 = !var(16) && (var(15) < 1)
trigger1 = AnimElem = 2
attr = S, SA
hitFlag = MAF
guardFlag = M
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 35 < 7, 7, fvar(11) * 35)), 7
getPower = 0,0
givePower = 36, 36
pauseTime = 2,2
guard.pauseTime = 2,2
animType = Hard
air.animType = Hard
fall.animType = Hard
ground.type = Low
air.type = Low
ground.hitTime = 18
ground.slideTime = 18
guard.hitTime = 18
air.hitTime = 120
ground.velocity = -3.75, -8
ground.cornerPush.velOff = 0
guard.velocity = -12.64
guard.cornerPush.velOff = 0
air.velocity = -3.75, -8
air.cornerPush.velOff = 0
yAccel = 0.732421875
fall = 1
fall.recover = 1
fall.recoverTime = 120
forceStand = 1
hitSound = -1 + 0 * (var(31) := 2)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 62), var(36) := -59
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 1180, Air Hits]
type = HitDef
trigger1 = !var(16) && (var(15) < (1 + HitCount) && HitCount < 8)
trigger1 = AnimElem = 3 || AnimElem = 4 || AnimElem = 5 || AnimElem = 6 || AnimElem = 7 || AnimElem = 8 || AnimElem = 9 || AnimElem = 10
attr = A, SA
hitFlag = MAF
guardFlag = MA
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 35 < 7, 7, fvar(11) * 35)), 7
getPower = 0,0
givePower = 36, 36
pauseTime = 2,2
guard.pauseTime = 2,2
animType = Back
air.animType = Back
fall.animType = Back
ground.type = Low
air.type = Low
ground.hitTime = 18
ground.slideTime = 18
guard.hitTime = 18
air.hitTime = 120
ground.velocity = -3.75, -8
ground.cornerPush.velOff = 0
guard.velocity = -12.64
guard.cornerPush.velOff = 0
air.velocity = -3.75, -8
air.cornerPush.velOff = 0
airGuard.velocity = -8, -1
airGuard.cornerPush.velOff = 0
yAccel = 0.732421875
fall = 1
fall.recover = 1
fall.recoverTime = 120
forceStand = 1
hitSound = -1 + 0 * (var(31) := 5)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 50), var(36) := -95
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 1180, StateTypeSet: Idle]
type = StateTypeSet
trigger1 = AnimElemTime(11) >= 0
moveType = I

[State 1180, Width]
type = Width
trigger1 = AnimElemTime(2) < 0
edge = 20,0

[State 1180, Width]
type = Width
trigger1 = AnimElemTime(2) >= 0 && AnimElemTime(11) < 0
edge = 40,0

[State 1180, End]
type = ChangeState
trigger1 = pos y > -vel y
value = 1101



;=====================<BAT SPIN>==========================
[StateDef 1200]
type = A
physics = N
moveType = A
anim = 1200
ctrl = 0
velSet = 0,0
sprPriority = 1
powerAdd = 72 * !var(20)
faceP2 = ifElse(((PrevStateNo = [100,106]) || StateType = A) && PrevStateNo != 52, 0, 1)

[State 1200, Button Detect]
type = VarSet
trigger1 = !Time && !AILevel
;ifElse((command = "c" || command = "rlsc"), 2, ifElse((command = "b" || command = "rlsb"), 1, 0))
var(10) = ifElse((NumExplod(90000250) || NumExplod(90000255)), 2, ifElse((NumExplod(90000240) || NumExplod(90000245)), 1, 0))

[State 1200, Button Detect (AI)]
type = VarSet
trigger1 = !Time && AILevel
var(10) = ifElse((P2MoveType = H || P2Dist x > 250 || Random < 333), 2, ifElse(P2Dist x > 100, 1, 0))

[State 1200, Warp sound]
type = PlaySnd
trigger1 = AnimElemTime(8) = 1
value = 1200,0
channel = 1

[State 1200, Fading away sound]
type = PlaySnd
trigger1 = AnimElem = 10
value = 100,0
channel = 3

[State 1200, Bat Spin dust cloud]
type = Explod
trigger1 = AnimElemTime(8) = 1
anim = 1205
sprPriority = 3
posType = P1
pos = 0, ceil(-68 * const(size.yScale))
scale = const(size.xScale) * 0.5,0.5
ownPal = 1
removeOnGetHit = 1
ignoreHitPause = 1

[State 1200, Bat Spin dust cloud (Bottom layer)]
type = Explod
trigger1 = AnimElemTime(8) = 1
anim = 1206
sprPriority = 3
posType = P1
pos = 0, ceil(-68 * const(size.yScale))
scale = const(size.xScale) * 0.5,0.5
ownPal = 1
removeOnGetHit = 1
ignoreHitPause = 1

[State 1200, Fade Out]
type = Trans
trigger1 = AnimElemTime(8) >= 0 && AnimElemTime(11) < 0
trans = AddAlpha
alpha = 256 - (48 * AnimElemTime(8)), 48 * AnimElemTime(8)
ignoreHitPause = 1

[State 1200, Fade In]
type = Trans
trigger1 = AnimElemTime(12) >= 0 && AnimElemTime(14) < 0
trans = AddAlpha
alpha = 48 * (AnimElemTime(12) + 1), 256 - 48 * (AnimElemTime(12) + 1)
ignoreHitPause = 1

[State 1200, PosSet]
type = PosSet
trigger1 = AnimElem = 12
y = -96

[State 1200, PosAdd]
type = PosAdd
trigger1 = AnimElem = 12 && var(10)
x = ifElse(var(10) = 2, 159, 96)

[State 1200, VelSet]
type = VelSet
trigger1 = AnimElem = 14
x = 6.875
y = 6.25
persistent = 0

[State 1200, Hit Count Reset]
type = VarSet
trigger1 = !Time
var(11) = 0

[State 1200, High Hits]
type = HitDef
trigger1 = !var(16) && (var(15) < (1 + HitCount))
trigger1 = AnimElem = 14 || AnimElem = 16 || AnimElem = 18 || AnimElem = 20 || AnimElem = 22 || AnimElem = 24
attr = A, SA
hitFlag = MAF
guardFlag = MA
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 42 < 7, 7, fvar(11) * 42)), 7
getPower = ifElse(!var(13), 144, 72) * !var(20), 36 * !var(20)
givePower = 36, 36
pauseTime = 12,12
guard.pauseTime = 12,12
animType = Hard
air.animType = Back
fall.animType = Back
ground.type = High
air.type = High
ground.hitTime = 12
ground.slideTime = 12
guard.hitTime = 12
air.hitTime = 120
ground.velocity = -5,0
ground.cornerPush.velOff = 0
guard.velocity = -5
guard.cornerPush.velOff = 0
air.velocity = -3.75, -10
air.cornerPush.velOff = 0
airGuard.velocity = -8, -1
airGuard.cornerPush.velOff = 0
yAccel = 0.732421875
fall = 0
air.fall = 1
fall.recover = 1
fall.recoverTime = 120
forceStand = 1
hitSound = -1 + 0 * (var(31) := 5)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 32), var(36) := -21
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 1200, Low Hits]
type = HitDef
trigger1 = !var(16) && (var(15) < (1 + HitCount))
trigger1 = AnimElem = 15 || AnimElem = 17 || AnimElem = 19 || AnimElem = 21 || AnimElem = 23 || AnimElem = 25
attr = A, SA
hitFlag = MAF
guardFlag = MA
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 42 < 7, 7, fvar(11) * 42)), 7
getPower = ifElse(!var(13), 144, 72) * !var(20), 36 * !var(20)
givePower = 36, 36
pauseTime = 12,12
guard.pauseTime = 12,12
animType = Hard
air.animType = Back
fall.animType = Back
ground.type = Low
air.type = Low
ground.hitTime = 12
ground.slideTime = 12
guard.hitTime = 12
air.hitTime = 120
ground.velocity = -5,0
ground.cornerPush.velOff = 0
guard.velocity = -5
guard.cornerPush.velOff = 0
air.velocity = -3.75, -10
air.cornerPush.velOff = 0
airGuard.velocity = -8, -1
airGuard.cornerPush.velOff = 0
yAccel = 0.732421875
fall = 0
air.fall = 1
fall.recover = 1
fall.recoverTime = 120
forceStand = 1
hitSound = -1 + 0 * (var(31) := 5)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 32), var(36) := -21
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 1200, Hit Count Increment]
type = VarAdd
trigger1 = MoveContact = 1 && var(30) = HitPauseTime
trigger2 = MoveReversed = 1
var(11) = 1
ignoreHitPause = 1

[State 1200, Rebound]
type = ChangeState
trigger1 = var(11) >= 3 && MoveReversed != 1
value = 1201
ignoreHitPause = 0

[State 1200, End]
type = ChangeState
trigger1 = pos y > -vel y
value = 1202


;Rebound off opponent
[StateDef 1201]
type = A
physics = N
moveType = A
velSet = 0,0
anim = 1201
ctrl = 0
sprPriority = 1
hitCountPersist = 1

[State 1201, VelSet]
type = VelSet
trigger1 = !Time
x = -3.90625
y = -7.03125

[State 1201, VelAdd]
type = VelAdd
trigger1 = Time > 0
y = 0.5859375

[State 1201, StateTypeSet: Idle]
type = StateTypeSet
trigger1 = !Time
moveType = I

[State 1201, ChangeState]
type = ChangeState
trigger1 = pos y > -vel y
value = 1202


;Landing
[StateDef 1202]
type = S
anim = 47
physics = N
moveType = I
velSet = 0,0

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

[State 1202, 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 1202, Landing Sound]
type = PlaySnd
trigger1 = !Time
value = 52,0
channel = 5

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



;=====================<ES BAT SPIN>==========================
[StateDef 1230]
type = A
physics = N
moveType = A
anim = 1200
ctrl = 0
velSet = 0,0
sprPriority = 1
powerAdd = -1000
faceP2 = ifElse(((PrevStateNo = [100,106]) || StateType = A) && PrevStateNo != 52, 0, 1)

[State 1230, ES Flash]
type = VarSet
trigger1 = !Time
var(25) = 39

[State 1230, ES FX]
type = Explod
trigger1 = !Time
anim = 8210
sprPriority = 3
posType = p1
pos = ceil(16 * const(size.xScale)), ceil(-79 * const(size.yScale))
scale = 0.5, 0.5
pauseMoveTime = -1
superMoveTime = -1
ownPal = 1

[State 1230, ES Startup Sound]
type = PlaySnd
trigger1 = !Time
value = 0,1000
channel = 1

[State 1230, Voice]
type = PlaySnd
trigger1 = !Time
value = 1230,0
channel = 0

[State 1230, Warp sound]
type = PlaySnd
trigger1 = AnimElemTime(8) = 1
value = 1200,0
channel = 3

[State 1230, Fading away sound]
type = PlaySnd
trigger1 = AnimElem = 10
value = 100,0
channel = 4

[State 1230, Bat Spin dust cloud]
type = Explod
trigger1 = AnimElemTime(8) = 1
anim = 1205
sprPriority = 3
posType = P1
pos = 0, ceil(-68 * const(size.yScale))
scale = const(size.xScale) * 0.5,0.5
ownPal = 1
removeOnGetHit = 1
ignoreHitPause = 1

[State 1230, Bat Spin dust cloud (Bottom layer)]
type = Explod
trigger1 = AnimElemTime(8) = 1
anim = 1206
sprPriority = 3
posType = P1
pos = 0, ceil(-68 * const(size.yScale))
scale = const(size.xScale) * 0.5,0.5
ownPal = 1
removeOnGetHit = 1
ignoreHitPause = 1

[State 1230, Fade Out]
type = Trans
trigger1 = AnimElemTime(8) >= 0 && AnimElemTime(11) < 0
trans = AddAlpha
alpha = 256 - (48 * AnimElemTime(8)), 48 * AnimElemTime(8)
ignoreHitPause = 1

[State 1230, Fade In]
type = Trans
trigger1 = AnimElemTime(12) >= 0 && AnimElemTime(14) < 0
trans = AddAlpha
alpha = 48 * (AnimElemTime(12) + 1), 256 - 48 * (AnimElemTime(12) + 1)
ignoreHitPause = 1

[State 1230, PosSet]
type = PosSet
trigger1 = AnimElem = 12
y = -96

[State 1230, PosAdd]
type = PosAdd
trigger1 = AnimElem = 12
x = 96

[State 1230, VelSet]
type = VelSet
trigger1 = AnimElem = 14
x = 6.875
y = 6.25
persistent = 0

[State 1230, High Hits]
type = HitDef
trigger1 = !var(16) && (var(15) < (1 + HitCount))
trigger1 = AnimElem = 14 || AnimElem = 16 || AnimElem = 18 || AnimElem = 20 || AnimElem = 22 || AnimElem = 24
attr = A, SA
hitFlag = MAF
guardFlag = MA
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 21 < 7, 7, fvar(11) * 21)), 7
getPower = 0,0
givePower = 36, 36
pauseTime = 12,12
guard.pauseTime = 12,12
animType = Hard
air.animType = Back
fall.animType = Back
ground.type = High
air.type = High
ground.hitTime = 12
ground.slideTime = 12
guard.hitTime = 12
air.hitTime = 120
ground.velocity = -5,0
ground.cornerPush.velOff = 0
guard.velocity = -5
guard.cornerPush.velOff = 0
air.velocity = -3.75, -10
air.cornerPush.velOff = 0
airGuard.velocity = -8, -1
airGuard.cornerPush.velOff = 0
yAccel = 0.732421875
fall = 0
air.fall = 1
fall.recover = 1
fall.recoverTime = 120
forceStand = 1
hitSound = -1 + 0 * (var(31) := 5)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 32), var(36) := -21
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 1230, Low Hits]
type = HitDef
trigger1 = !var(16) && (var(15) < (1 + HitCount))
trigger1 = AnimElem = 15 || AnimElem = 17 || AnimElem = 19 || AnimElem = 21 || AnimElem = 23 || AnimElem = 25
attr = A, SA
hitFlag = MAF
guardFlag = MA
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 21 < 7, 7, fvar(11) * 21)), 7
getPower = 0,0
givePower = 36, 36
pauseTime = 12,12
guard.pauseTime = 12,12
animType = Hard
air.animType = Back
fall.animType = Back
ground.type = Low
air.type = Low
ground.hitTime = 12
ground.slideTime = 12
guard.hitTime = 12
air.hitTime = 120
ground.velocity = -5,0
ground.cornerPush.velOff = 0
guard.velocity = -5
guard.cornerPush.velOff = 0
air.velocity = -3.75, -10
air.cornerPush.velOff = 0
airGuard.velocity = -8, -1
airGuard.cornerPush.velOff = 0
yAccel = 0.732421875
fall = 0
air.fall = 1
fall.recover = 1
fall.recoverTime = 120
forceStand = 1
hitSound = -1 + 0 * (var(31) := 5)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 32), var(36) := -21
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 1230, ES Flash off]
type = PalFX
triggerAll = pos y + 6.25  > -vel y && AnimElemTime(12) > 0
trigger1 = !MoveContact
trigger2 = MoveContact = 1 && HitPauseTime = 1
time = 1
ignoreHitPause = 1

[State 1230, End]
type = ChangeState
trigger1 = pos y > -vel y
value = 1202



;=====================<NEGATIVE STOLEN>==========================
[StateDef 1300]
type = S
physics = S
moveType = A
anim = 1300
ctrl = 0
velSet = 0,0
sprPriority = 1
powerAdd = 0
faceP2 = ifElse((PrevStateNo = [100,106]), 0, 1)

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

[State 1300, HitDef]
type = HitDef
trigger1 = AnimElem = 3
trigger1 = P2BodyDist x < 55
trigger1 = !var(38)
attr = S, ST
hitFlag = M-
priority = 7, Miss
getPower = 0,0
givePower = 0,0
sparkNo = -1 +0 * (var(33) := 0)
guard.sparkNo = -1 +0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 40), var(36) := -50
hitSound = -1 +0 * (var(31) := 800)
guardSound = -1 +0 * (var(32) := 0)
fall = 1
fall.recover = 1
numHits = 0
p1StateNo = 1310

[State 1300, Voice (Missed)]
type = PlaySnd
trigger1 = AnimElem = 5
value = 5000,0
channel = 0

[State 1300, Woosh Sound]
type = PlaySnd
trigger1 = AnimElem = 5
value = 1,0
channel = 1

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

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


;Success
[Statedef 1310]
type = S
physics = N
moveType = A
anim = 1310
ctrl = 0
velSet = 0,0
sprPriority = 1
powerAdd = 72 * !var(20)

[State 1310, Lost Target]
type = ChangeState
trigger1 = !Time && !NumTarget
value = 0
ctrl = 1

[State 1310, Throw]
type = TargetState
trigger1 = !Time && NumTarget
value = 1315

[State 1310, Width]
type = Width
trigger1 = 1
edge = 48,32
ignoreHitPause = 1

[State 1310, TargetBind 1]
type = TargetBind
trigger1 = NumTarget
trigger1 = AnimElemTime(3) < 0
pos = ceil(28 * const(size.xScale)), 0

[State 1310, TargetBind 2]
type = TargetBind
triggerAll = NumTarget
trigger1 = AnimElemTime(3) >= 0 && AnimElemTime(4) < 0
trigger2 = AnimElemTime(7) >= 0 && AnimElemTime(8) < 0
pos = ceil(47 * const(size.xScale)), ceil(-85 * const(size.yScale))

[State 1310, TargetBind 3]
type = TargetBind
triggerAll = NumTarget
trigger1 = AnimElemTime(4) >= 0 && AnimElemTime(5) < 0
trigger2 = AnimElemTime(8) >= 0 && AnimElemTime(9) < 0
pos = ceil(7 * const(size.xScale)), ceil(-85 * const(size.yScale))

[State 1310, TargetBind 4]
type = TargetBind
triggerAll = NumTarget
trigger1 = AnimElemTime(5) >= 0 && AnimElemTime(6) < 0
trigger2 = AnimElemTime(9) >= 0 && AnimElemTime(10) < 0
pos = ceil(-47 * const(size.xScale)), ceil(-85 * const(size.yScale))

[State 1310, TargetBind 5]
type = TargetBind
triggerAll = NumTarget
trigger1 = AnimElemTime(6) >= 0 && AnimElemTime(7) < 0
trigger2 = AnimElemTime(10) >= 0 && AnimElemTime(11) < 0
pos = ceil(-7 * const(size.xScale)), ceil(-85 * const(size.yScale))

[State 1310, TargetBind 6]
type = TargetBind
trigger1 = NumTarget
trigger1 = AnimElemTime(11) >= 0 && AnimElemTime(12) < 0
pos = ceil(-42 * const(size.xScale)), ceil(-84 * const(size.yScale))

[State 1310, TargetBind 7]
type = TargetBind
triggerAll = NumTarget
trigger1 = AnimElemTime(12) >= 0 && AnimElemTime(13) < 0
trigger2 = AnimElemTime(16) >= 0 && AnimElemTime(17) < 0
trigger3 = AnimElemTime(20) >= 0 && AnimElemTime(21) < 0
trigger4 = AnimElemTime(24) >= 0
pos = ceil(-50 * const(size.xScale)), ceil(-51 * const(size.yScale))

[State 1310, TargetBind 8]
type = TargetBind
triggerAll = NumTarget
trigger1 = AnimElemTime(13) >= 0 && AnimElemTime(14) < 0
trigger2 = AnimElemTime(17) >= 0 && AnimElemTime(18) < 0
trigger3 = AnimElemTime(21) >= 0 && AnimElemTime(22) < 0
pos = ceil(-7 * const(size.xScale)), ceil(-48 * const(size.yScale))

[State 1310, TargetBind 9]
type = TargetBind
triggerAll = NumTarget
trigger1 = AnimElemTime(14) >= 0 && AnimElemTime(15) < 0
trigger2 = AnimElemTime(18) >= 0 && AnimElemTime(19) < 0
trigger3 = AnimElemTime(22) >= 0 && AnimElemTime(23) < 0
pos = ceil(47 * const(size.xScale)), ceil(-51 * const(size.yScale))

[State 1310, TargetBind 10]
type = TargetBind
triggerAll = NumTarget
trigger1 = AnimElemTime(15) >= 0 && AnimElemTime(16) < 0
trigger2 = AnimElemTime(19) >= 0 && AnimElemTime(20) < 0
trigger3 = AnimElemTime(23) >= 0 && AnimElemTime(24) < 0
pos = ceil(6 * const(size.xScale)), ceil(-48 * const(size.yScale))

[State 1310, Voice]
type = PlaySnd
trigger1 = AnimElem = 10
value = 1310,0
channel = 0

[State 1310, Jump sound]
type = PlaySnd
trigger1 = AnimElemTime(3) = 2
value = 41,0
channel = 1

[State 1310, StateTypeSet: Air, Physics: None]
type = StateTypeSet
trigger1 = AnimElemTime(3) = 2
stateType = A
physics = N

[State 1310, Dust Helper]
type = Helper
trigger1 = AnimElemTime(3) = 2
helperType = Normal
stateNo = 8100
ID = 8100
name = "Negative Stolen Dust"
posType = P1
ownPal = 1

[State 1310, VelSet]
type = VelSet
trigger1 = AnimElemTime(3) = 2
y = -15

[State 1310, VelAdd]
type = VelAdd
trigger1 = AnimElemTime(3) > 2
y = 0.78125

[State 1310, End]
type = ChangeState
trigger1 = pos y > -vel y
value = 1311


;Slamming Opponent Into Floor
[StateDef 1311]
type = S
anim = 811
physics = N
moveType = A
velSet = 0,0

[State 1311, TargetBind]
type = TargetBind
trigger1 = NumTarget
trigger1 = !TIme
pos = ceil(-17 * const(size.xScale)), ceil(-26 * const(size.yScale))

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

[State 1311, Slamming Sound]
type = PlaySnd
trigger1 = NumTarget && !Time
value = 811,0
channel = 3

[State 1311, EnvShake]
type = EnvShake
trigger1 = NumTarget && !Time
time = 14
ampl = -4
freq = 120

[State 1311, Impact Dust]
type = Helper
trigger1 = NumTarget && !Time
helperType = Normal
stateNo = 8110
ID = 8110
name = "Impact Dust"
posType = P1
facing = -1
ownPal = 1

[State 1311, Damage]
type = TargetLifeAdd
trigger1 = NumTarget && !Time
value = floor(ifElse(168 * fvar(11) < 7, -7, -168 * fvar(11)))

[State 1311, TargetPowerAdd]
type = TargetPowerAdd
trigger1 = NumTarget && !Time
value = 36

[State 1311, Power]
type = PowerAdd
trigger1 = NumTarget && !Time && !var(20)
value = 72

[State 1311, HitAdd]
type = HitAdd
trigger1 = NumTarget && !Time
value = 1

[State 1311, VarAdd]
type = VarAdd
trigger1 = NumTarget && !Time
var(13) = 1

[State 1311, Juggle]
type = VarAdd
trigger1 = NumTarget && !Time
var(15) = 1
ignoreHitPause = 1

[State 1311, Juggle]
type = VarSet
trigger1 = NumTarget && !Time
var(16) = 1
ignoreHitPause = 1

[State 1311, Throw]
type = TargetState
trigger1 = NumTarget && !Time
value = 816

[State 1311, StateTypeSet: Air, Physics: None]
type = StateTypeSet
trigger1 = Time = 8
stateType = A
physics = N

[State 1311, VelSet]
type = VelSet
trigger1 = Time = 8
x = -3.75
y = -3.515625

[State 1311, VelAdd]
type = VelAdd
trigger1 = Time > 8
y = 0.48828125

[State 1311, Throw]
type = TargetState
trigger1 = NumTarget && Time = 8
value = 817

[State 1311,End]
type = ChangeState
trigger1 = pos y > -vel y
value = 812



;===========<NEGATIVE STOLEN (TARGET)>==========
;Being Thrown
[StateDef 1315]
type = A
moveType = H
physics = N
velSet = 0,0
sprPriority = 0

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

[State 1315, Turn]
type = Turn
trigger1 = !Time
trigger1 = NumEnemy
trigger1 = Facing = EnemyNear, Facing
ignoreHitPause = 1

[State 1315, ScreenBound]
type = ScreenBound
trigger1 = 1
value = 0
moveCamera = 0,0
ignoreHitPause = 1

[State 1315, SprPriority]
type = SprPriority
trigger1 = 1
value = 0

[State 1315, SprPriority]
type = SprPriority
trigger1 = AnimElemTime(6) >= 0 && AnimElemTime(7) < 0
trigger2 = AnimElemTime(10) >= 0 && AnimElemTime(11) < 0
trigger3 = AnimElemTime(13) >= 0 && AnimElemTime(14) < 0
value = 2



;========================<HELL RIDE>=============================
[StateDef 1400]
type = S
physics = N
moveType = A
anim = 1400
ctrl = 0
velSet = 0,0
sprPriority = 1
powerAdd = 36 * !var(20)
faceP2 = 1

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

[State 1400, Jump Sound]
type = PlaySnd
trigger1 = AnimElemTime(3) = 1
value = 40,0
channel = 1

[State 1400, StateTypeSet: Air, Physics: None]
type = StateTypeSet
trigger1 = AnimElemTime(3) = 1
stateType = A
physics = N

[State 1400, Dust Helper]
type = Helper
trigger1 = AnimElemTime(3) = 1
helperType = Normal
stateNo = 8100
ID = 8100
name = "Hell Ride Dust"
posType = P1
ownPal = 1

[State 1400, VarSet]
type = VarSet
trigger1 = AnimElemTime(3) = 1
fvar(0) = (P2dist x / 27)

[State 1400, VelSet]
type = VelSet
trigger1 = AnimElemTime(3) = 1
x = ifElse(EnemyNear, MoveType = H, fvar(0) - (EnemyNear, vel x) * ifElse(Facing = EnemyNear, Facing, -0.25, 1) / 1.5, fvar(0))
y = -10

[State 1400, VelAdd]
type = VelAdd
trigger1 = AnimElemTime(3) > 1
y = 0.78125

[State 1400, HitDef]
type = HitDef
trigger1 = AnimElem = 11
ID = 1400
attr = A, SA
hitFlag = FD
guardFlag = L
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 49 < 7, 7, fvar(11) * 49)), 0
getPower = ifElse(!var(13), 72, 36) * !var(20), 12 * !var(20)
givePower = 36, 36
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 = 18
ground.velocity = 0, 0
ground.cornerPush.velOff = 0
guard.velocity = 0
guard.cornerPush.velOff = 0
air.velocity = 0, -7.73
air.cornerPush.velOff = 0
down.velocity = 0, 0
down.cornerpush.veloff = 0
yAccel = 0.58
fall = 0
fall.recover = 1
fall.recoverTime = 18
hitSound = -1 + 0 * (var(31) := 5)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8012)
guard.sparkNo = -1 + 0 * (var(34) := 8000)
sparkXY = -10 + 0 * (var(35) := 18), var(36) := -10
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, TargetDrop]
type = TargetDrop
trigger1 = NumTarget(1400) > 1
ID = 1400
keepOne = 1
excludeID = 1400
ignoreHitPause = 1

[State 1400, TargetBind]
type = TargetBind
triggerAll = NumTarget(1400)
trigger1 = P2Dist x < -15 || P2Dist x > 50
time = 1
ID = 1400
pos = ifElse(P2Dist x > 50, 50, -15),0
ignoreHitPause = 1
persistent = 0

[State 1400, Opponent Recover]
type = TargetState
trigger1 = NumTarget(1400)
value = 1405
ID = 1400
ignoreHitPause = 1
persistent = 0

[State 1400, PosSet]
type = PosSet
triggerAll = NumTarget(1400)
triggerAll = MoveContact = 1
trigger1 = P2Dist y > 30
y = -20
ignoreHitpause = 1

[State 1400, ChangeAnim]
type = ChangeAnim
trigger1 = MoveContact = 1 && HitPauseTime
trigger1 = Anim = 1400
trigger1 = HitPauseTime <= 10
value = 1401
elem = 2
ignoreHitPause = 1

[State 1400, Finish]
type = ChangeState
trigger1 = Anim = 1401
value = 1401
ignoreHitPause = 0

[State 1400, End]
type = ChangeState
trigger1 = pos y > -vel y
value = 1402


;Finish
[StateDef 1401]
type = A
physics = N
moveType = I
ctrl = 0
sprPriority = 1
hitCountPersist = 1

[State 1401, VelSet]
type = VelSet
trigger1 = !Time
x = -fvar(0)
y = -10

[State 1401, VelAdd]
type = VelAdd
trigger1 = Time > 0
y = 0.78125

[State 1401, ChangeState]
type = ChangeState
trigger1 = pos y > -vel y
value = 1402


;Landing
[StateDef 1402]
type = S
anim = 47
physics = N
moveType = I
velSet = 0,0

[State 1402, PosSet]
type = PosSet
trigger1 = 1
y = 0

[State 1402, 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 1402, Landing Sound]
type = PlaySnd
trigger1 = !Time
value = 52,0
channel = 5

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


;Hit by Hell Ride
[StateDef 1405]
type = L
moveType = H
physics = N
velSet = 0,0

[State 1405, PosSet]
type = PosSet
trigger1 = 1
y = 0
ignoreHitPause = 1

[State 1405, VarSet]
type = VarSet
trigger1 = !Time
sysvar(2) = 5080

[State 1405, VarAdd]
type = VarAdd
trigger1 = !Time
trigger1 = (Anim = [5081,5089]) || (Anim = [5111,5119])
trigger1 = SelfAnimExist(sysvar(2) + (Anim % 10))
sysvar(2) = Anim % 10

[State 1405, VarSet]
type = VarSet
trigger1 = !Time
trigger1 = sysvar(2) = 5090
trigger1 = !SelfAnimExist(5090)
sysvar(2) = 5030

[State 1405, ChangeAnim]
type = ChangeAnim
trigger1 = 1
value = sysvar(2)

[State 1405, ChangeState]
type = ChangeState
trigger1 = HitShakeOver
value = 1406


;Knocked back
[Statedef 1406]
type = L
moveType = H
physics = C

[State 1406, PosSet]
type = PosSet
trigger1 = 1
y = 0
ignoreHitPause = 1

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

[State 1406, VelSet]
type = VelSet
trigger1 = HitOver
x = 0

[State 1406, VarSet]
type = VarSet
trigger1 = !Time
sysvar(0) = 1

[State 1406, ChangeState]
type = ChangeState
trigger1 = HitOver && Alive
value = 1407

[State 1406, SelfState]
type = SelfState
trigger1 = HitOver && !Alive
value = 5150


;Recover
[StateDef 1407]
type = L
moveType = H
physics = N

[State 1407, FallEnvShake]
type = FallEnvShake
trigger1 = !Time

[State 1407, ChangeAnim]
type = ChangeAnim
trigger1 = SelfAnimExist(5110 + (Anim % 10))
trigger1 = Anim = [5081,5089]
value = 5110 + (Anim % 10)
persistent = 0

[State 1407, ChangeAnim]
type = ChangeAnim
triggerAll = !Time
triggerAll = Anim != [5110,5119]
trigger1 = Anim != [5161,5169]
trigger2 = !SelfAnimExist(5170 + (Anim % 10))
value = 5170

[State 1407, ChangeAnim]
type = ChangeAnim
triggerAll = !Time
triggerAll = Anim != [5110,5119]
trigger1 = Anim = [5161,5169]
trigger1 = SelfAnimExist(5170 + (Anim % 10))
value = 5170 + (Anim % 10)

[State 1407, HitFallDamage]
type = HitFallDamage
trigger1 = !Time

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

[State 1407, VarSet]
type = VarSet
trigger1 = !Time
trigger1 = GetHitVar(fall.yVel) != 0
sysvar(1) = floor(vel y)

[State 1407, PlaySnd]
type = PlaySnd
trigger1 = !Time
trigger1 = !sysvar(0)
value = F7, (sysvar(1) > Const720p(20)) + (sysvar(1) > Const720p(56))

[State 1407, Explod]
type = Explod
trigger1 = !Time
trigger1 = !sysvar(0)
anim = F(60 + (sysvar(1) > Const720p(20)) + (sysvar(1) > Const720p(56)))
pos = 0, 0
sprPriority = ifElse(sysvar(1) <= Const720p(56), -10, 10)

[State 1407, VelSet]
type = VelSet
trigger1 = !Time
y = 0

[State 1407, ChangeAnim]
type = ChangeAnim
triggerAll = Anim = [5171,5179]
triggerAll = SelfAnimExist(5110 + (Anim % 10))
trigger1 = !AnimTime
trigger2 = sysvar(0)
value = 5110 + (Anim % 10)
persistent = 0

[State 1407, ChangeAnim]
type = ChangeAnim
triggerAll = Anim != [5111,5119]
trigger1 = !AnimTime
trigger2 = sysvar(0)
value = 5110
persistent = 0

[State 1407, SelfState]
type = SelfState
triggerAll = !Alive
trigger1 = !AnimTime
trigger2 = sysvar(0)
trigger3 = Anim = [5110,5119]
value = 5150

[State 1407, VarSet]
type = VarSet
trigger1 = sysvar(0)
trigger1 = !Time
sysvar(0) = 0

[State 1407, VelMul]
type = VelMul
trigger1 = 1
x = 0.85

[State 1407, VelSet]
type = VelSet
trigger1 = abs(vel x) < const(movement.down.friction.threshold)
persistent = 0
x = 0

[State 1407, SelfState]
type = SelfState
trigger1 = !Time
value = 5120



;========================<ES HELL RIDE>=============================
[StateDef 1430]
type = S
physics = N
moveType = A
anim = 1430
ctrl = 0
velSet = 0,0
sprPriority = 1
powerAdd = -1000
faceP2 = 1

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

[State 1430, ES FX]
type = Explod
trigger1 = !Time
anim = 8210
sprPriority = 3
posType = P1
pos = ceil(15 * const(size.xScale)), ceil(-48 * const(size.yScale))
scale = 0.5, 0.5
pauseMoveTime = -1
superMoveTime = -1
ownPal = 1

[State 1430, ES Startup Sound]
type = PlaySnd
trigger1 = !Time
value = 0,1000
channel = 1

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

[State 1430, Jump Sound]
type = PlaySnd
trigger1 = AnimElemTime(3) = 1
value = 40,0
channel = 3

[State 1430, StateTypeSet: Air, Physics: None]
type = StateTypeSet
trigger1 = AnimElemTime(3) = 1
stateType = A
physics = N

[State 1430, Dust Helper]
type = Helper
trigger1 = AnimElemTime(3) = 1
helperType = Normal
stateNo = 8100
ID = 8100
name = "ES Hell Ride Dust"
posType = P1
ownPal = 1

[State 1430, VarSet]
type = VarSet
trigger1 = AnimElemTime(3) = 1
fvar(0) = (P2dist x / 27)

[State 1430, VelSet]
type = VelSet
trigger1 = AnimElemTime(3) = 1
x = ifElse(EnemyNear, MoveType = H, fvar(0) - (EnemyNear, vel x) * ifElse(Facing = EnemyNear, Facing, -0.25, 1) / 1.5, fvar(0))
y = -10

[State 1430, VelAdd]
type = VelAdd
trigger1 = AnimElemTime(3) > 1
y = 0.78125

[State 1430, HitDef]
type = HitDef
trigger1 = AnimElem = 11
ID = 1430
attr = A, SA
hitFlag = FD
guardFlag = L
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 21 < 7, 7, fvar(11) * 21)), 0
getPower = 0,0
givePower = 36, 36
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 = 18
ground.velocity = 0, 0
ground.cornerPush.velOff = 0
guard.velocity = 0
guard.cornerPush.velOff = 0
air.velocity = 0, -7.73
air.cornerPush.velOff = 0
down.velocity = 0, 0
down.cornerpush.veloff = 0
yAccel = 0.58
fall = 0
fall.recover = 1
fall.recoverTime = 18
hitSound = -1 + 0 * (var(31) := 5)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8012)
guard.sparkNo = -1 + 0 * (var(34) := 8000)
sparkXY = -10 + 0 * (var(35) := 18), var(36) := -10
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, TargetDrop]
type = TargetDrop
trigger1 = NumTarget(1430) > 1
ID = 1430
keepOne = 1
excludeID = 1430
ignoreHitPause = 1

[State 1430, TargetBind]
type = TargetBind
triggerAll = NumTarget(1430)
trigger1 = P2Dist x < -15 || P2Dist x > 15
time = 1
ID = 1430
pos = ifElse(P2Dist x > 15, 15, -15),0
ignoreHitPause = 1
persistent = 0

[State 1430, Opponent Recover]
type = TargetState
trigger1 = NumTarget(1430)
value = 1405
ID = 1430
ignoreHitPause = 1
persistent = 0

[State 1430, PosSet]
type = PosSet
triggerAll = NumTarget(1430)
triggerAll = MoveContact = 1
trigger1 = P2Dist y > 30
y = -20
ignoreHitpause = 1

[State 1430, ChangeAnim]
type = ChangeAnim
trigger1 = MoveContact = 1 && HitPauseTime
trigger1 = Anim = 1430
trigger1 = HitPauseTime <= 10
value = 1431
elem = 2
ignoreHitPause = 1

[State 1430, Finish]
type = ChangeState
trigger1 = Anim = 1431
value = 1431
ignoreHitPause = 0

[State 1430, End]
type = ChangeState
trigger1 = pos y > -vel y
value = 1402


;Finish
[StateDef 1431]
type = A
physics = N
moveType = A
ctrl = 0
velSet = 0,0
sprPriority = 1
hitCountPersist = 1

[State 1431, ES Flash]
type = VarSet
trigger1 = !Time
var(25) = 64

[State 1431, Hit 1, 3]
type = HitDef
trigger1 = !var(16) && (var(15) < 1)
trigger1 = AnimElem = 4 || AnimElem = 6
ID = 1431
attr = A, SA
hitFlag = FD
guardFlag = L
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 35 < 7, 7, fvar(11) * 35)), 0
getPower = 0,0
givePower = 36, 36
pauseTime = 4,4
guard.pauseTime = 4,4
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 = 0, 0
ground.cornerPush.velOff = 0
guard.velocity = 0
guard.cornerPush.velOff = 0
air.velocity = 0, -7.73
air.cornerPush.velOff = 0
down.velocity = 0, 0
down.cornerpush.veloff = 0
yAccel = 0.58
fall = 0
fall.recover = 1
fall.recoverTime = 120
hitSound = -1 + 0 * (var(31) := 5)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8012)
guard.sparkNo = -1 + 0 * (var(34) := 8000)
sparkXY = -10 + 0 * (var(35) := 5), var(36) := -24
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 1431, Hit 2, 4]
type = HitDef
trigger1 = !var(16) && (var(15) < 1)
trigger1 = AnimElem = 5 || AnimElem = 7
ID = 1431
attr = A, SA
hitFlag = FD
guardFlag = L
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 35 < 7, 7, fvar(11) * 35)), 0
getPower = 0,0
givePower = 36, 36
pauseTime = 4,4
guard.pauseTime = 4,4
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 = 0, 0
ground.cornerPush.velOff = 0
guard.velocity = 0
guard.cornerPush.velOff = 0
air.velocity = -3.23, -7.73
air.cornerPush.velOff = 0
down.velocity = 0, 0
down.cornerpush.veloff = 0
yAccel = 0.58
fall = 0
fall.recover = 1
fall.recoverTime = 120
hitSound = -1 + 0 * (var(31) := 5)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8012)
guard.sparkNo = -1 + 0 * (var(34) := 8000)
sparkXY = -10 + 0 * (var(35) := -8), var(36) := -14
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 1431, TargetDrop]
type = TargetDrop
trigger1 = NumTarget(1431) > 1
ID = 1431
keepOne = 1
excludeID = 1431
ignoreHitPause = 1

[State 1431, Opponent Recover]
type = TargetState
trigger1 = NumTarget(1431)
trigger1 = Target, StateType = L
value = 1405
ID = 1431
ignoreHitPause = 1
persistent = 0

[State 1431, Jump Sound]
type = PlaySnd
trigger1 = AnimElem = 11
value = 40,0
channel = 4

[State 1431, Dust Helper]
type = Helper
trigger1 = AnimElem = 11
helperType = Normal
stateNo = 8100
ID = 8100
name = "ES Hell Ride Dust"
posType = P1
ownPal = 1

[State 1431, VelSet]
type = VelSet
trigger1 = AnimElem = 11
x = -fvar(0)
y = -10

[State 1431, VelAdd]
type = VelAdd
trigger1 = AnimElemTime(11) > 0
y = 0.78125

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

[State 1431, ChangeState]
type = ChangeState
trigger1 = pos y > -vel y
value = 1402



;=====================<PUNCH ZERO COUNTER>==========================
[StateDef 2900]
type = S
physics = N
moveType = A
anim = 2900
ctrl = 0
velSet = 0,0
sprPriority = 1
powerAdd = 0

[State 2900, NotHitBy]
type = NotHitBy
trigger1 = AnimElemTime(4) < 0
value = SCA
time = 1
ignoreHitPause = 1

[State 2900, Voice]
type = PlaySnd
trigger1 = !Time
value = 1100,0
channel = 0

[State 2900, Jump Sound]
type = PlaySnd
trigger1 = AnimElem = 3
value = 1100,1
channel = 1

[State 2900, StateTypeSet: Air, Physics: None]
type = StateTypeSet
trigger1 = AnimElem = 3
stateType = A
physics = N

[State 2900, Dust Helper]
type = Helper
trigger1 = AnimElemTime(3) = 1
helperType = Normal
stateNo = 8100
ID = 8100
name = "Demon Cradle Dust"
posType = P1
ownPal = 1

[State 2900, VelSet]
type = VelSet
trigger1 = AnimElemTime(3) = 1
y = -5.625

[State 2900, VelAdd]
type = VelAdd
trigger1 = AnimElemTime(3) > 1
y = 0.390625

[State 2900, Ground Hit]
type = HitDef
trigger1 = !var(16) && (var(15) < 1)
trigger1 = AnimElem = 2
attr = S, SA
hitFlag = MAF
guardFlag = M
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 42 < 7, 7, fvar(11) * 42)), 0
getpower = 0,0
givePower = 36, 36
pauseTime = 12, 12
guard.pauseTime = 12, 12
animType = DiagUp
air.animType = DiagUp
fall.animType = DiagUp
ground.type = Low
air.type = Low
ground.hitTime = 18
ground.slideTime = 18
guard.hitTime = 18
air.hitTime = 120
ground.velocity = -5.54, -5.25
ground.cornerPush.velOff = 0
guard.velocity = -10.52
guard.cornerPush.velOff = 0
air.velocity = -5.54, -5.25
air.cornerPush.velOff = 0
yaccel = 0.58
fall = 1
fall.recover = 1
fall.recoverTime = 120
forceStand = 1
hitSound = -1 + 0 * (var(31) := 2)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 30), var(36) := -68
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 2900, Air Hit]
type = HitDef
trigger1 = !var(16) && (var(15) < 1)
trigger1 = AnimElem = 3 && !MoveContact && !MoveReversed
attr = A, SA
hitFlag = MAF
guardFlag = MA
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 42 < 7, 7, fvar(11) * 42)), 0
getpower = 0,0
givePower = 36, 36
pauseTime = 12,12
guard.pauseTime = 12,12
animType = DiagUp
air.animType = DiagUp
fall.animType = DiagUp
ground.type = Low
air.type = Low
ground.hitTime = 18
ground.slideTime = 18
guard.hitTime = 18
air.hitTime = 120
ground.velocity = -5.54, -5.25
ground.cornerPush.velOff = 0
guard.velocity = -10.52
guard.cornerPush.velOff = 0
air.velocity = -5.54, -5.25
air.cornerPush.velOff = 0
airGuard.velocity = -8, -1
airGuard.cornerPush.velOff = 0
yaccel = 0.58
fall = 1
fall.recover = 1
fall.recoverTime = 120
forceStand = 1
hitSound = -1 + 0 * (var(31) := 5)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8001)
sparkXY = -10 + 0 * (var(35) := 50), var(36) := -95
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
kill = 0

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

[State 2900, End]
type = ChangeState
trigger1 = pos y > -vel y
value = 2901


;Landing
[StateDef 2901]
type = S
anim = 47
physics = N
moveType = I
velSet = 0,0

[State 2901, PosSet]
type = PosSet
trigger1 = 1
y = 0

[State 2901, 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 2901, Landing Sound]
type = PlaySnd
trigger1 = !Time
value = 52,0
channel = 4

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



;========================<KICK ZERO COUNTER>=============================
[StateDef 2910]
type = S
physics = N
moveType = A
anim = 2910
ctrl = 0
velSet = 0,0
sprPriority = 1
powerAdd = 0

[State 2910, NotHitBy]
type = NotHitBy
trigger1 = AnimElemTime(3) < 0
value = SCA
time = 1
ignoreHitPause = 1

[State 2910, Voice]
type = PlaySnd
trigger1 = AnimElem = 2
value = 4,1
channel = 0

[State 2910, Woosh Sound]
type = PlaySnd
trigger1 = AnimElem = 2
value = 1,5
channel = 1

[State 2910, HitDef]
type = HitDef
trigger1 = !var(16) && var(15) < 1
trigger1 = AnimElem = 3
attr = C, SA
hitFlag = MAF
guardFlag = M
priority = 4, Hit
damage = ceil(ifElse(fvar(11) * 42 < 7, 7, fvar(11) * 42)), 0
getPower = 0,0
givepower = 36, 36
pauseTime = 12,12
guard.pauseTime = 12,12
animType = DiagUp
air.animType = DiagUp
fall.animType = DiagUp
ground.type = Low
air.type = Low
ground.hitTime = 18
ground.slideTime = 18
guard.hitTime = 18
air.hitTime = 120
ground.velocity = -5.54, -5.25
ground.cornerPush.velOff = 0
guard.velocity = -10.52
guard.cornerPush.velOff = 0
air.velocity = -5.54, -5.25
air.cornerPush.velOff = 0
yAccel = 0.58
fall = 1
fall.recover = 1
fall.recoverTime = 120
forceStand = 1
hitSound = -1 + 0 * (var(31) := 5)
guardSound = -1 + 0 * (var(32) := 0)
sparkNo = -1 + 0 * (var(33) := 8013)
guard.sparkNo = -1 + 0 * (var(34) := 8000)
sparkXY = -10 + 0 * (var(35) := 132), var(36) := -49
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
kill = 0

[State 2910, ChangeAnimElem]
type = ChangeAnim
trigger1 = MoveContact = 1 && HitPauseTime
trigger1 = AnimElemTime(3) >= 0 && AnimElemTime(4) <= 0
trigger1 = HitPauseTime <= 10
value = 450
elem = 4
ignoreHitPause = 1

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

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