;================================================================================
; SPECIALS
;================================================================================
;================================================================================
;Ventose 
;================================================================================
[Statedef 1000]
type    = S
movetype= A
physics = N
poweradd= 109
ctrl = 0
velset = 0
sprpriority = 2
juggle = 8
facep2 = 1
anim = ifElse((helper(10371), var(0) = [1,3]),1000,1010)

;=======================================;Variables
[State 1000, Projectile Speed]
type = VarSet
trigger1 = !time
v = 15
value = ifelse((helper(10371), var(0) = [1,3]),3,7)
;=======================================;Animations/Statetypes
[State 1000, StateTypeSet]
type = StateTypeSet
trigger1 = anim = 1000 && animelem = 7
trigger2 = anim = 1010 && animelem = 14
movetype = I 
;=======================================;Effects
[State 1000, 1]
type = PlaySnd
trigger1 = anim = 1000 && animelem = 5
trigger2 = anim = 1010 && animelem = 5
value = 200,8
channel = 0
persistent = 0

[State 1000, 1]
type = PlaySnd
trigger1 = anim = 1010 && animelem = 13
value = 200,9
channel = 0
persistent = 0
;=======================================;Helpers
[State 1000: Helper];Hand Fire
type = helper
trigger1 = anim = 1000 || anim = 1010
trigger1 = animelem = 5
helpertype = Normal
id = 1001
pos = 0, 0 ;50
postype = p1
facing = 1
stateno = 1001
keyctrl = 0
ownpal = 1
supermovetime = 0
pausemovetime = 0
persistent = 0   
[State 1000: Helper];Hand Fire C
type = helper
trigger1 = anim = 1010
trigger1 = animelem = 13
helpertype = Normal
id = 1011
pos = 0, 0 ;50
postype = p1
facing = 1
stateno = 1011
keyctrl = 0
ownpal = 1
supermovetime = 0
pausemovetime = 0
persistent = 0    
[State 1000: Helper];Projectile A
type = helper
trigger1 = anim = 1000
trigger1 = animelem = 6
helpertype = Normal
id = 1005
pos = 0, 0 ;50
postype = p1
facing = 1
stateno = 1005
keyctrl = 0
ownpal = 1
supermovetime = 0
pausemovetime = 0
persistent = 0
[State 1000: Helper];Projectile C
type = helper
trigger1 = anim = 1010
trigger1 = animelemtime(13) = 1
helpertype = Normal
id = 1005
pos = 0, 0 ;50
postype = p1
facing = 1
stateno = 1015
keyctrl = 0
ownpal = 1
supermovetime = 0
pausemovetime = 0
persistent = 0
;=======================================;End
[State 1000, 6]
type = ChangeState
trigger1 = !animtime
value = 0
ctrl = 1
;================================================================================
; Ventose A Effects
;================================================================================
[Statedef 1001]
type = A
movetype = I
physics = N
ctrl = 0
velset = 0, 0
ownpal = 1
anim = 1001
sprpriority = 3
juggle = 10

;=======================================;Effects
[State 1050, Trans]
type = Trans
trigger1 = 1;root, var(27)
trans = add1
ignorehitpause = 1
[State 65000: AfterImage]
type = AfterImage
trigger1 = (!Time)
time = 9999999
length = 12
palbright = 12,12,12;,136
palcontrast = 120,120,120;,136
paladd = 0,0,0
timegap = 1
framegap = 1
trans = add
ignorehitpause = 1
[State 7001, Assert]
type = AssertSpecial
trigger1 = 1
flag = noshadow
ignorehitpause = 1
[State 1000, sound]
type = PlaySnd
trigger1 = animelem = 2
value = 1000,1
persistent = 0
;=======================================;Bindings
[State 1415, BindToRoot]
type = BindToRoot
trigger1 = 1
time = 1
pos = 0,0
;=======================================;End
[State 1000, DestroySelf]
type = DestroySelf
trigger1 = root,stateno != 1000
trigger2 = animtime = 0
;================================================================================
;Ventose A Projectile
;================================================================================
[Statedef 1005]
type = A
movetype = A
physics = N
ctrl = 0
ownpal = 1
sprpriority = 4

;=======================================;
;PROJECTILE REFLECTION COMPATIBILITY    ;
;?????????????                   ;
;by Vans                                ;
;GUIDE:                                 ;
;FOR PROJECTILE / ?????              	;
;sysvar(0) = 131072                     ;
;sysvar(1) = REFLECTED_BEHAVIOR_STATE   ;
;=======================================;
[State 1005, COMPATIBILITY]
type = VarSet
trigger1 = !time 
sysvar(0) = 131072
[State 1005, REFLECTED STATE]
type = VarSet
trigger1 = !time
sysvar(1) = 1007
;=======================================;Movement
[State 1050, VelSet]
type = VarSet
trigger1 = !time && !prevstateno
var(15) = root,var(15)
[State 1050, VelSet]
type = VelSet
trigger1 = animelem = 5
x = var(15)
[State 1050, VelSet]
type = PosAdd
trigger1 = animelem = 4
x = 50
[State 1050, VelSet]
type = PosAdd
trigger1 = animelem = 5
trigger2 = animelem = 6
x = 20
persistent = 0
; POS X SAVER 
[State 3000000]
type = VarSet
trigger1 = 1
var(4) = ceil(pos x)
ignorehitpause = 1
; POS Y SAVER 
[State 3000000]
type = VarSet
trigger1 = 1
var(5) = ceil(pos y)
;=======================================;Animations
[State 1000, Anim]
Type = ChangeAnim
Trigger1 = !Time && !prevstateno 
Value = 1005 
ignorehitpause = 1
;=======================================;Projectile Properties
[State -2, Damage Dampener]; Scaling in action
type= attackmulset
trigger1= 1
value= ifelse(root,var(51),0.63,1)
ignorehitpause= 1
[State 1000, projs only]
type = HitBy
trigger1 = 1
value = SCA, NP, SP
ignorehitpause = 1
[State 10012, override]
type = HitOverride
trigger1 = !time
attr = SCA, AA, AP, AT
stateno = 1006
time = -1
ignorehitpause = 1
[State -2, Juggle Killer]
type = ParentVarSet
triggerall = root,var(44) = 0
trigger1 = movehit && P2Statetype = A
var(16) = ifelse(root,var(51),60,0)
[State -2, Juggle Killer]
type = ParentVarSet
triggerall = root,var(44)
trigger1 = movehit && P2Statetype = A
var(16) = 60
ignorehitpause = 1
persistent = 0
[State -2, Air Limiter]
type = ParentvarSet
trigger1 = MoveContact && NumTarget
var(40) = 1
ignorehitpause = 1
persistent = 0
[State -2, FlagHitToParent]
type = ParentVarSet
trigger1 = MoveHit && NumTarget
var(58) = 20
ignorehitpause = 1
persistent = 0
[State -2, VarSet]
type = ParentVarSet
trigger1 = MoveContact && NumTarget
var(9) = 1
persistent = 0
ignorehitpause=1
[State -2, VarSet];Counter Hit Reset
type = ParentVarSet
trigger1 = root,var(57) >= 22 
var(57) = 0
ignorehitpause = 1
;=======================================;Effects
[State 1050, Trans]
type = Trans
trigger1 = 1;root, var(27)
trans = add1
ignorehitpause = 1
[State 65000: AfterImage]
type = AfterImage
trigger1 = (!Time)
time = 9999999
length = 12
palbright = 12,12,12;,136
palcontrast = 120,120,120;,136
paladd = 0,0,0
timegap = 1
framegap = 1
trans = add
ignorehitpause = 1
[State 7001, Assert]
type = AssertSpecial
trigger1 = 1
flag = noshadow
ignorehitpause = 1
[State 1000, Sound]
type = PlaySnd
trigger1 = MoveContact && NumTarget
value = 3+(root,var(32)*2),ifelse(MoveHit,3,13)
persistent = 0
[State 1000, Sound]
type = PlaySnd
trigger1 = MoveHit && NumTarget
value = 1000,11
persistent = 0
[State 3000, ContactSpark]
type = Explod
trigger1 = MoveContact && NumTarget
anim = (ifelse(MoveHit,(17002+(root,var(31)*10000)),(17502+(root,var(31)*10000))))
ID = 1000
pos = ifelse(p2dist x < 0, 0, ifelse(p2dist x < 10, ceil(p2dist x), 10)),-68
postype = p1
facing = -1
bindtime = 1
removetime = -2
sprpriority = 8
shadow = 0,0,0
ownpal = 1
persistent = 0

[State -2, Helper]
type = Helper
trigger1 = !numhelper(50000) && !numhelper(50001)
trigger1 = WinKO
helpertype = normal
name = "K.O."
ID = 50001
stateno = 50000
pos = 160,120
postype = left    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 0
supermovetime = 999999999999
pausemovetime = 999999999999
ignorehitpause = 1
;=======================================;Hitdefs
[State 210, 1]
type = HitDef
triggerall = root,var(40) < 1 || root,var(57) > 0 || root,var(16) > 0
trigger1 = (animelemno(0) = [1,12])
attr = S, SP
damage = floor(83*ifelse(var(56),1.25,1)),0
animtype = Hard
air.animtype = back
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 1, 12
guard.pausetime = 1,11
sparkno = -1
sparkxy = -10, -44
hitsound = -1
guardsound = s3+(root,var(32)*2), 13
guard.sparkno = -1
ground.type = High
ground.slidetime = 17
ground.hittime  = 16
ground.velocity = -11.1796875
fall.yvelocity = -2.5
guard.velocity = -11.1796875
air.type = High
air.velocity = -4.5,-7
air.hittime = 13
air.juggle = 0
getpower = 94,94
givepower = 16,16
id = 1005
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
yaccel = .5
air.fall = 1
fall.recover = 1
fall.recovertime = 120
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
Palfx.time       = 17+13
Palfx.add       = 0,189,0
Palfx.sinadd   = 0,-40,0,10
Palfx.color     = 128
Palfx.invertall = 0
;=======================================;End
[State 1000, DestroySelf]
type = DestroySelf
triggerall = time > 1
trigger1 = FrontEdgeDist <= -40

[State 1005, End]
type=changeState
trigger1= movecontact
value=1006
ignorehitpause = 0
persistent = 0
;=======================================;Recovery for target
[State -2, P2 Safe Fall]
type = TargetState
trigger1 = NumTarget = 1
trigger1 = Target, command = "recovery"
trigger1 = Target, pos y >= -30 && Target, vel y > 0
trigger1 = Target, Alive && Target, HitFall && Target, GetHitVar(fall.recover)
trigger1 = Target, StateNo = 5030 || Target, StateNo = 5035 || Target, StateNo = 5050 || Target, StateNo = 5071
value = 5205
ignoreHitPause = 1
;================================================================================
;Ventose A Projectile Disperse
;================================================================================
[Statedef 1006]
type = A
movetype = I
physics = N
ctrl = 0
velset = 0, 0
ownpal = 1
anim = 1006 
sprpriority = 4
;=======================================;Projectile Properties
[State 1005, PROJECTILE ACTIVE]
type = VarSet
trigger1 = !time 
var(20) = 1
;=======================================;Effects
[State 1050, Trans]
type = Trans
trigger1 = 1;root, var(27)
trans = add1
ignorehitpause = 1
[State 65000: AfterImage]
type = AfterImage
trigger1 = (!Time)
time = 9999999
length = 12
palbright = 12,12,12;,136
palcontrast = 120,120,120;,136
paladd = 0,0,0
timegap = 1
framegap = 1
trans = add
ignorehitpause = 1
[State 7001, Assert]
type = AssertSpecial
trigger1 = 1
flag = noshadow
ignorehitpause = 1
;=======================================;End
[State 10002, DestroySelf]
type = DestroySelf
trigger1 = animtime = 0 && numtarget = 0
;=======================================;Recovery for Target
[State -2, P2 Safe Fall]
type = TargetState
trigger1 = NumTarget = 1
trigger1 = Target, command = "recovery"
trigger1 = Target, pos y >= -30 && Target, vel y > 0
trigger1 = Target, Alive && Target, HitFall && Target, GetHitVar(fall.recover)
trigger1 = Target, StateNo = 5030 || Target, StateNo = 5035 || Target, StateNo = 5050 || Target, StateNo = 5071
value = 5205
ignoreHitPause = 1

;================================================================================
;Ventose A Reflected
;================================================================================
[Statedef 1007]
type = A
movetype = A
physics = N
ctrl = 0
ownpal = 1
sprpriority = 4

;=======================================;
;PROJECTILE REFLECTION COMPATIBILITY    ;
;?????????????                   ;
;by Vans                                ;
;GUIDE:                                 ;
;FOR PROJECTILE / ?????              	;
;sysvar(0) = 131072                     ;
;sysvar(1) = REFLECTED_BEHAVIOR_STATE   ;
;=======================================;
[State 1005, COMPATIBILITY]
type = VarSet
trigger1 = !time 
sysvar(0) = 131072
[State 1005, REFLECTED STATE]
type = VarSet
trigger1 = !time
sysvar(1) = 1005
[State 1005, PROJECTILE ACTIVE]
type = VarSet
trigger1 = !time 
var(20) = 1
;=======================================;Movement
[State 1050, VelSet]
type = VarSet
trigger1 = !time && !prevstateno
var(15) = root,var(15)
[State 1050, VelSet]
type = VelSet
trigger1 = time = 1
x = var(15)
; POS X SAVER 
[State 3000000]
type = VarSet
trigger1 = 1
var(4) = ceil(pos x)
ignorehitpause = 1
; POS Y SAVER 
[State 3000000]
type = VarSet
trigger1 = 1
var(5) = ceil(pos y)
;=======================================;Animations
[State 1000, Anim]
Type = ChangeAnim
Trigger1 = !Time && !prevstateno 
Value = 1007 
ignorehitpause = 1
;=======================================;Projectile Properties
[State -2, Damage Dampener]; Scaling in action
type= attackmulset
trigger1= 1
value= ifelse(root,var(51),0.63,1)
ignorehitpause= 1
[State 1000, projs only]
type = HitBy
trigger1 = 1
value = SCA, NP, SP
ignorehitpause = 1
[State 10012, override]
type = HitOverride
trigger1 = !time
attr = SCA, AA, AP, AT
stateno = 1006
time = -1
ignorehitpause = 1
[State -2, Juggle Killer]
type = ParentVarSet
trigger1 = movehit && P2Statetype = A
var(16) = ifelse(root,var(51),60,0)
ignorehitpause = 1
persistent = 0
[State -2, Air Limiter]
type = ParentvarSet
trigger1 = MoveContact && NumTarget
var(40) = 1
ignorehitpause = 1
persistent = 0
[State -2, FlagHitToParent]
type = ParentVarSet
trigger1 = MoveHit && NumTarget
var(58) = 20
ignorehitpause = 1
persistent = 0
[State -2, VarSet]
type = ParentVarSet
trigger1 = MoveContact && NumTarget
var(9) = 1
persistent = 0
ignorehitpause=1
[State -2, VarSet];Counter Hit Reset
type = ParentVarSet
trigger1 = root,var(57) >= 22 
var(57) = 0
ignorehitpause = 1
;=======================================;Effects
[State 1050, Trans]
type = Trans
trigger1 = 1;root, var(27)
trans = add1
ignorehitpause = 1
[State 65000: AfterImage]
type = AfterImage
trigger1 = (!Time)
time = 9999999
length = 12
palbright = 12,12,12;,136
palcontrast = 120,120,120;,136
paladd = 0,0,0
timegap = 1
framegap = 1
trans = add
ignorehitpause = 1
[State 7001, Assert]
type = AssertSpecial
trigger1 = 1
flag = noshadow
ignorehitpause = 1
[State 1000, Sound]
type = PlaySnd
trigger1 = MoveContact && NumTarget
value = 3+(root,var(32)*2),ifelse(MoveHit,3,13)
persistent = 0
[State 1000, Sound]
type = PlaySnd
trigger1 = MoveHit && NumTarget
value = 1000,11
persistent = 0
[State 3000, ContactSpark]
type = Explod
trigger1 = MoveContact && NumTarget
anim = (ifelse(MoveHit,(17002+(root,var(31)*10000)),(17502+(root,var(31)*10000))))
ID = 1000
pos = ifelse(p2dist x < 0, 0, ifelse(p2dist x < 10, ceil(p2dist x), 10)),-68
postype = p1
facing = -1
bindtime = 1
removetime = -2
sprpriority = 8
shadow = 0,0,0
ownpal = 1
persistent = 0
;=======================================;Hitdef
[State 210, 1]
type = HitDef
affectteam = F
triggerall = root,var(40) < 1 || root,var(57) > 0 || root,var(16) > 0
trigger1 = (animelemno(0) = [1,8])
attr = S, SP
damage = floor(83*ifelse(var(56),1.25,1)),0
animtype = Hard
air.animtype = back
guardflag = MA
hitflag = MAF
priority = 3, Hit
sparkno = -1
sparkxy = -10, -40
hitsound = -1
guardsound = 3+(root,var(32)*2), 13
guard.sparkno = -1
ground.type = High
pausetime = 1,12
guard.pausetime = 0,11
ground.slidetime = 17
ground.hittime = 16
guard.hittime = 16
guard.slidetime = 17
guard.ctrltime = 24
ground.velocity =  -11.1796875
guard.velocity = -11.1796875
air.type = High
air.velocity =-4.5, -7
air.hittime = 13
air.juggle = 0
getpower = 94,94
givepower = 16,16
id = 1005
air.fall = 1
fall.recover = 1
fall.recovertime = 120
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
Palfx.time       = 17+13
Palfx.add       = 0,189,0
Palfx.sinadd   = 0,-40,0,10
Palfx.color     = 128
Palfx.invertall = 0
;=======================================;
;PROJECTILE REFLECTION COMPATIBILITY    ;
;?????????????                   ;
;by Vans                                ;
;GUIDE:                                 ;
;FOR PROJECTILE / ?????              	;
;sysvar(0) = 131072                     ;
;sysvar(1) = REFLECTED_BEHAVIOR_STATE   ;
;=======================================;
id = sysvar(0)
;=======================================;

[State 1411, Collision]
type = VarSet
trigger1 = movecontact ;&& numtarget
var(54) = 1
persistent = 0
ignorehitpause=1

[State 1000, DestroySelf]
type = DestroySelf
triggerall = time > 1
trigger1 = FrontEdgeDist <= -40

;=======================================;
;PROJECTILE REFLECTION COMPATIBILITY    ;
;?????????????                   ;
;by Vans                                ;
;GUIDE:                                 ;
;FOR PROJECTILE / ?????              	;
;sysvar(0) = 131072                     ;
;sysvar(1) = REFLECTED_BEHAVIOR_STATE   ;
;FOR REFLECTOR / ??????????HELPER?	;
;sysvar(0) = 262144                     ;
;=======================================;
[State 1007, Turn]
type = Turn
Trigger1 = !Time 
;=======================================;
[State 1206, ChangeState]
type = ChangeState
trigger1 = var(54)
trigger1 = root,NumProjID(262144)
value = sysvar(1)
ctrl = 0
ignorehitpause = 1
;=======================================;End
[State 1005, End]
type=changeState
trigger1= movecontact
value=1006
ignorehitpause = 0
persistent = 0
;=======================================;Recovery for target
[State -2, P2 Safe Fall]
type = TargetState
trigger1 = NumTarget = 1
trigger1 = Target, command = "recovery"
trigger1 = Target, pos y >= -30 && Target, vel y > 0
trigger1 = Target, Alive && Target, HitFall && Target, GetHitVar(fall.recover)
trigger1 = Target, StateNo = 5030 || Target, StateNo = 5035 || Target, StateNo = 5050 || Target, StateNo = 5071
value = 5205
ignoreHitPause = 1
;================================================================================
; Ventose C Effects
;================================================================================
[Statedef 1011]
type = A
movetype = I
physics = N
ctrl = 0
velset = 0, 0
ownpal = 1
anim = 1011
sprpriority = 3
juggle = 10

;=======================================;Effects
[State 1050, Trans]
type = Trans
trigger1 = 1;root, var(27)
trans = add1
ignorehitpause = 1
[State 65000: AfterImage]
type = AfterImage
trigger1 = (!Time)
time = 9999999
length = 12
palbright = 12,12,12;,136
palcontrast = 120,120,120;,136
paladd = 0,0,0
timegap = 1
framegap = 1
trans = add
ignorehitpause = 1
[State 7001, Assert]
type = AssertSpecial
trigger1 = 1
flag = noshadow
ignorehitpause = 1
[State 1000, sound]
type = PlaySnd
trigger1 = animelem = 2
value = 1000,2
persistent = 0
;=======================================;Bindings
[State 1415, BindToRoot]
type = BindToRoot
trigger1 = 1
time = 1
pos = 0,0
;=======================================;End
[State 1000, DestroySelf]
type = DestroySelf
trigger1 = root,stateno != 1000
trigger2 = animtime = 0
;================================================================================
;Ventose C Projectile
;================================================================================
[Statedef 1015]
type = A
movetype = A
physics = N
ctrl = 0
ownpal = 1
sprpriority = 4

;=======================================;
;PROJECTILE REFLECTION COMPATIBILITY    ;
;?????????????                   ;
;by Vans                                ;
;GUIDE:                                 ;
;FOR PROJECTILE / ?????              	;
;sysvar(0) = 131072                     ;
;sysvar(1) = REFLECTED_BEHAVIOR_STATE   ;
;=======================================;
[State 1005, COMPATIBILITY]
type = VarSet
trigger1 = !time 
sysvar(0) = 131072
[State 1005, REFLECTED STATE]
type = VarSet
trigger1 = !time
sysvar(1) = 1017
;=======================================;Movement
[State 1050, VelSet]
type = VarSet
trigger1 = !time && !prevstateno
var(15) = root,var(15)
[State 1050, VelSet]
type = VelSet
trigger1 = animelem = 5
x = var(15)
[State 1050, VelSet]
type = PosAdd
trigger1 = animelem = 4
x = 50
; POS X SAVER 
[State 3000000]
type = VarSet
trigger1 = 1
var(4) = ceil(pos x)
ignorehitpause = 1
; POS Y SAVER 
[State 3000000]
type = VarSet
trigger1 = 1
var(5) = ceil(pos y)
;=======================================;Animations
[State 1000, Anim]
Type = ChangeAnim
Trigger1 = !Time && !prevstateno 
Value = 1015 
ignorehitpause = 1
;=======================================;Projectile Properties
[State -2, Damage Dampener]; Scaling in action
type= attackmulset
trigger1= 1
value= ifelse(root,var(51),0.63,1)
ignorehitpause= 1

[State 1000, projs only]
type = HitBy
trigger1 = 1
value = SCA, NP, SP
ignorehitpause = 1
[State 10012, override]
type = HitOverride
trigger1 = !time
attr = SCA, AA, AP, AT
stateno = 1016
time = -1
ignorehitpause = 1

[State -2, Juggle Killer]
type = ParentVarSet
trigger1 = movehit && P2Statetype = A
trigger1 = var(18) = 2
var(16) = ifelse(root,var(51),60,35)
ignorehitpause = 1
persistent = 0
[State -2, Juggle Killer]
type = ParentVarSet
trigger1 = movehit && P2Statetype = A
trigger1 = var(18) = 1
var(16) = ifelse(root,var(51),60,0)
ignorehitpause = 1
persistent = 0
[State -2, Air Limiter]
type = ParentvarSet
trigger1 = MoveContact && NumTarget
var(40) = 1
ignorehitpause = 1
persistent = 0
[State -2, FlagHitToParent]
type = ParentVarSet
trigger1 = MoveHit && NumTarget
var(58) = 20
ignorehitpause = 1
persistent = 0
[State -2, VarSet]
type = ParentVarSet
trigger1 = MoveContact && NumTarget
var(9) = 1
persistent = 0
ignorehitpause=1

[State -2, VarSet];Counter Hit Reset
type = ParentVarSet
trigger1 = root,var(57) >= 22 
var(57) = 0
ignorehitpause = 1
;=====================;Multihit Projectile Properties
[State 1015, VarSet]
type = VarSet
trigger1 = !time && !prevstateno
var(18) = 2
[State 1015, VarSet]
type = VarAdd
trigger1 = !time && prevstateno = 1015
var(18) = -1
ignorehitpause = 1
persistent = 0
[State 1005, End]
type=changeState
trigger1= movecontact && numtarget
trigger1 = var(18) = 2
value= 1015
ignorehitpause = 0
persistent = 0
;=======================================;Effects
[State 1000: Helper];Overlay
type = helper
trigger1 = animelem = 3
helpertype = Normal
id = 1018
pos = 0, 0 ;50
postype = p1
facing = 1
stateno = 1018
keyctrl = 0
ownpal = 1
supermovetime = 0
pausemovetime = 0
persistent = 0   

[State 1050, Trans]
type = Trans
trigger1 = 1;root, var(27)
trans = add1
ignorehitpause = 1
[State 65000: AfterImage]
type = AfterImage
trigger1 = (!Time)
time = 9999999
length = 12
palbright = 12,12,12;,136
palcontrast = 120,120,120;,136
paladd = 0,0,0
timegap = 1
framegap = 1
trans = add
ignorehitpause = 1
[State 7001, Assert]
type = AssertSpecial
trigger1 = 1
flag = noshadow
ignorehitpause = 1

[State 1000, Sound]
type = PlaySnd
trigger1 = MoveContact && NumTarget
value = 3+(root,var(32)*2),ifelse(MoveHit,3,13)
persistent = 0
ignorehitpause = 1
[State 1000, Sound]
type = PlaySnd
trigger1 = MoveHit && NumTarget
value = 1000,11
persistent = 0
channel = 4
ignorehitpause = 1

[State 3000, ContactSpark]
type = Explod
trigger1 = MoveContact && NumTarget
anim = (ifelse(MoveHit,(17002+(root,var(31)*10000)),(17502+(root,var(31)*10000))))
ID = 1000
pos = ifelse(p2dist x < 0, 0, ifelse(p2dist x < 10, ceil(p2dist x), 10)),-68
postype = p1
facing = -1
bindtime = 1
removetime = -2
sprpriority = 8
shadow = 0,0,0
ownpal = 1
persistent = 0

[State -2, Helper]
type = Helper
trigger1 = !numhelper(50000) && !numhelper(50001)
trigger1 = WinKO
helpertype = normal
name = "K.O."
ID = 50001
stateno = 50000
pos = 160,120
postype = left    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 0
supermovetime = 999999999999
pausemovetime = 999999999999
ignorehitpause = 1
;=======================================;Hitdefs
[State 210, 1]
type = HitDef
triggerall = var(18) = 2
triggerall = root,var(40) < 1 || root,var(57) > 0 || root,var(16) > 0
trigger1 = (animelemno(0) = [1,12])
attr = S, SP
damage = floor(75*ifelse(var(56),1.25,1)),0
animtype = Hard
air.animtype = back
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 1, 12
guard.pausetime = 1,11
sparkno = -1
sparkxy = -10, -44
hitsound = -1
guardsound = s3+(root,var(32)*2), 13
guard.sparkno = -1
ground.type = High
ground.slidetime = 17
ground.hittime  = 16
ground.velocity = 0
fall.yvelocity = -2.5
guard.velocity = -11.1796875
air.type = High
air.velocity = -4.5,-7
air.hittime = 13
air.juggle = 0
getpower = 94,94
givepower = 16,16
id = 1005
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
yaccel = .5
air.fall = 1
fall.recover = 1
fall.recovertime = 120
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
Palfx.time       = 17+13
Palfx.add       = 0,189,0
Palfx.sinadd   = 0,-40,0,10
Palfx.color     = 128
Palfx.invertall = 0

[State 210, 1]
type = HitDef
triggerall = var(18) = 1
triggerall = root,var(40) < 1 || root,var(57) > 0 || root,var(16) > 0
trigger1 = (animelemno(0) = [1,12])
attr = S, SP
damage = floor(75*ifelse(var(56),1.25,1)),0
animtype = Hard
air.animtype = back
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 1, 12
guard.pausetime = 1,11
sparkno = -1
sparkxy = -10, -44
hitsound = -1
guardsound = s3+(root,var(32)*2), 13
guard.sparkno = -1
ground.type = High
ground.slidetime = 17
ground.hittime  = 16
ground.velocity = -4.5,-7
fall.yvelocity = -2.5
guard.velocity = -11.1796875
air.type = High
air.velocity = -4.5,-7
air.hittime = 13
air.juggle = 0
getpower = 94,94
givepower = 16,16
fall = 1
id = 1005
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
yaccel = .5
fall = 1
fall.recover = 1
fall.recovertime = 120
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
Palfx.time       = 17+13
Palfx.add       = 0,189,0
Palfx.sinadd   = 0,-40,0,10
Palfx.color     = 128
Palfx.invertall = 0

;=======================================;End
[State 1000, DestroySelf]
type = DestroySelf
triggerall = time > 1
trigger1 = FrontEdgeDist <= -40
[State 1005, End]
type=changeState
trigger1= movecontact
value=1016
ignorehitpause = 0
persistent = 0
;=======================================;Recovery for target
[State -2, P2 Safe Fall]
type = TargetState
trigger1 = NumTarget = 1
trigger1 = Target, command = "recovery"
trigger1 = Target, pos y >= -30 && Target, vel y > 0
trigger1 = Target, Alive && Target, HitFall && Target, GetHitVar(fall.recover)
trigger1 = Target, StateNo = 5030 || Target, StateNo = 5035 || Target, StateNo = 5050 || Target, StateNo = 5071
value = 5205
ignoreHitPause = 1
;================================================================================
;Ventose C Projectile Disperse
;================================================================================
[Statedef 1016]
type = A
movetype = I
physics = N
ctrl = 0
velset = 0, 0
ownpal = 1
anim = 1006 
sprpriority = 4
;=======================================;Projectile Properties
[State 1005, PROJECTILE ACTIVE]
type = VarSet
trigger1 = !time 
var(20) = 1
;=======================================;Effects
[State 1050, Trans]
type = Trans
trigger1 = 1;root, var(27)
trans = add1
ignorehitpause = 1
[State 65000: AfterImage]
type = AfterImage
trigger1 = (!Time)
time = 9999999
length = 12
palbright = 12,12,12;,136
palcontrast = 120,120,120;,136
paladd = 0,0,0
timegap = 1
framegap = 1
trans = add
ignorehitpause = 1
[State 7001, Assert]
type = AssertSpecial
trigger1 = 1
flag = noshadow
ignorehitpause = 1
[State 7001, Assert]
type = AssertSpecial
trigger1 = 1
flag = noshadow
ignorehitpause = 1
;=======================================;End
[State 10002, DestroySelf]
type = DestroySelf
trigger1 = animtime = 0 && numtarget = 0
;=======================================;Recovery for target
[State -2, P2 Safe Fall]
type = TargetState
trigger1 = NumTarget = 1
trigger1 = Target, command = "recovery"
trigger1 = Target, pos y >= -30 && Target, vel y > 0
trigger1 = Target, Alive && Target, HitFall && Target, GetHitVar(fall.recover)
trigger1 = Target, StateNo = 5030 || Target, StateNo = 5035 || Target, StateNo = 5050 || Target, StateNo = 5071
value = 5205
ignoreHitPause = 1
;================================================================================
;Ventose C Reflected
;================================================================================
[Statedef 1017]
type = A
movetype = A
physics = N
ctrl = 0
ownpal = 1
sprpriority = 4

;=======================================;
;PROJECTILE REFLECTION COMPATIBILITY    ;
;?????????????                   ;
;by Vans                                ;
;GUIDE:                                 ;
;FOR PROJECTILE / ?????              	;
;sysvar(0) = 131072                     ;
;sysvar(1) = REFLECTED_BEHAVIOR_STATE   ;
;=======================================;
[State 1005, COMPATIBILITY]
type = VarSet
trigger1 = !time 
sysvar(0) = 131072
[State 1005, REFLECTED STATE]
type = VarSet
trigger1 = !time
sysvar(1) = 1015
[State 1005, PROJECTILE ACTIVE]
type = VarSet
trigger1 = !time 
var(20) = 1
;=======================================;Movement
[State 1050, VelSet]
type = VarSet
trigger1 = !time && !prevstateno
var(15) = root,var(15)
[State 1050, VelSet]
type = VelSet
trigger1 = time = 1
x = var(15)
; POS X SAVER 
[State 3000000]
type = VarSet
trigger1 = 1
var(4) = ceil(pos x)
ignorehitpause = 1
; POS Y SAVER 
[State 3000000]
type = VarSet
trigger1 = 1
var(5) = ceil(pos y)
;=======================================;Animations
[State 1000, Anim]
Type = ChangeAnim
Trigger1 = !Time && !prevstateno 
Value = 1015 
ignorehitpause = 1
;=======================================;Projectile Properties
[State -2, Damage Dampener]; Scaling in action
type= attackmulset
trigger1= 1
value= ifelse(root,var(51),0.63,1)
ignorehitpause= 1

[State 1000, projs only]
type = HitBy
trigger1 = 1
value = SCA, NP, SP
ignorehitpause = 1
[State 10012, override]
type = HitOverride
trigger1 = !time
attr = SCA, AA, AP, AT
stateno = 1016
time = -1
ignorehitpause = 1
;=====================;Multihit Projectile Properties
[State 1015, VarSet]
type = VarSet
trigger1 = !time && prevstateno != 1017
var(10) = 2
[State 1015, VarSet]
type = VarAdd
trigger1 = !time && prevstateno = 1017
var(10) = -1
ignorehitpause = 1
persistent = 0
[State 1005, End]
type=changeState
trigger1= movecontact && numtarget
trigger1 = var(10) = 2
value= 1017
ignorehitpause = 0
persistent = 0

[State -2, Juggle Killer]
type = ParentVarSet
trigger1 = movehit && P2Statetype = A
trigger1 = var(18) = 2
var(16) = ifelse(root,var(51),60,35)
ignorehitpause = 1
persistent = 0
[State -2, Juggle Killer]
type = ParentVarSet
trigger1 = movehit && P2Statetype = A
trigger1 = var(18) = 1
var(16) = ifelse(root,var(51),60,0)
ignorehitpause = 1
persistent = 0
[State -2, Air Limiter]
type = ParentvarSet
trigger1 = MoveContact && NumTarget
var(40) = 1
ignorehitpause = 1
persistent = 0
[State -2, FlagHitToParent]
type = ParentVarSet
trigger1 = MoveHit && NumTarget
var(58) = 20
ignorehitpause = 1
persistent = 0
[State -2, VarSet]
type = ParentVarSet
trigger1 = MoveContact && NumTarget
var(9) = 1
persistent = 0
ignorehitpause=1

[State -2, VarSet];Counter Hit Reset
type = ParentVarSet
trigger1 = root,var(57) >= 22 
var(57) = 0
ignorehitpause = 1
;=======================================;Effects
[State 1050, Trans]
type = Trans
trigger1 = 1;root, var(27)
trans = add1
ignorehitpause = 1
[State 65000: AfterImage]
type = AfterImage
trigger1 = (!Time)
time = 9999999
length = 12
palbright = 12,12,12;,136
palcontrast = 120,120,120;,136
paladd = 0,0,0
timegap = 1
framegap = 1
trans = add
ignorehitpause = 1
[State 7001, Assert]
type = AssertSpecial
trigger1 = 1
flag = noshadow
ignorehitpause = 1

[State 1000, Sound]
type = PlaySnd
trigger1 = MoveContact && NumTarget
value = 3+(root,var(32)*2),ifelse(MoveHit,3,13)
persistent = 0
ignorehitpause = 1
[State 1000, Sound]
type = PlaySnd
trigger1 = MoveHit && NumTarget
value = 1000,11
persistent = 0
channel = 4
ignorehitpause = 1

[State 3000, ContactSpark]
type = Explod
trigger1 = MoveContact && NumTarget
anim = (ifelse(MoveHit,(17002+(root,var(31)*10000)),(17502+(root,var(31)*10000))))
ID = 1000
pos = ifelse(p2dist x < 0, 0, ifelse(p2dist x < 10, ceil(p2dist x), 10)),-68
postype = p1
facing = -1
bindtime = 1
removetime = -2
sprpriority = 8
shadow = 0,0,0
ownpal = 1
persistent = 0

[State 7001, Assert]
type = AssertSpecial
trigger1 = 1
flag = noshadow
ignorehitpause = 1
;=======================================;Hitdefs
[State 210, 1]
type = HitDef
affectteam = F
triggerall = var(10) = 2
triggerall = root,var(40) < 1 || root,var(57) > 0 || root,var(16) > 0
trigger1 = (animelemno(0) = [1,8])
attr = S, SP
damage = floor(75*ifelse(var(56),1.25,1)),0
animtype = Hard
air.animtype = back
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 1, 12
guard.pausetime = 1,11
sparkno = -1
sparkxy = -10, -44
hitsound = -1
guardsound = s3+(root,var(32)*2), 13
guard.sparkno = -1
ground.type = High
ground.slidetime = 17
ground.hittime  = 16
ground.velocity = 0
fall.yvelocity = -2.5
guard.velocity = -11.1796875
air.type = High
air.velocity = -4.5,-7
air.hittime = 13
air.juggle = 0
getpower = 94,94
givepower = 16,16
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
yaccel = .5
air.fall = 1
fall.recover = 1
fall.recovertime = 120
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
Palfx.time       = 17+13
Palfx.add       = 0,189,0
Palfx.sinadd   = 0,-40,0,10
Palfx.color     = 128
Palfx.invertall = 0
;=======================================;
;PROJECTILE REFLECTION COMPATIBILITY    ;
;?????????????                   ;
;by Vans                                ;
;GUIDE:                                 ;
;FOR PROJECTILE / ?????              	;
;sysvar(0) = 131072                     ;
;sysvar(1) = REFLECTED_BEHAVIOR_STATE   ;
;=======================================;
id = sysvar(0)
;=======================================;

[State 210, 1]
type = HitDef
affectteam = F
triggerall = var(10) = 1
triggerall = root,var(40) < 1 || root,var(57) > 0 || root,var(16) > 0
trigger1 = (animelemno(0) = [1,8])
attr = S, SP
damage = floor(75*ifelse(var(56),1.25,1)),0
animtype = Hard
air.animtype = back
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 1, 12
guard.pausetime = 1,11
sparkno = -1
sparkxy = -10, -44
hitsound = -1
guardsound = s3+(root,var(32)*2), 13
guard.sparkno = -1
ground.type = High
ground.slidetime = 17
ground.hittime  = 16
ground.velocity = -4.5,-7
fall.yvelocity = -2.5
guard.velocity = -11.1796875
air.type = High
air.velocity = -4.5,-7
air.hittime = 13
air.juggle = 0
getpower = 94,94
givepower = 16,16
fall = 1
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
yaccel = .5
fall = 1
fall.recover = 1
fall.recovertime = 120
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
Palfx.time       = 17+13
Palfx.add       = 0,189,0
Palfx.sinadd   = 0,-40,0,10
Palfx.color     = 128
Palfx.invertall = 0
;=======================================;
;PROJECTILE REFLECTION COMPATIBILITY    ;
;?????????????                   ;
;by Vans                                ;
;GUIDE:                                 ;
;FOR PROJECTILE / ?????              	;
;sysvar(0) = 131072                     ;
;sysvar(1) = REFLECTED_BEHAVIOR_STATE   ;
;=======================================;
id = sysvar(0)
;=======================================;
[State 1411, Collision]
type = VarSet
trigger1 = movecontact ;&& numtarget
var(54) = 1
persistent = 0
ignorehitpause=1

[State 1000, DestroySelf]
type = DestroySelf
triggerall = time > 1
trigger1 = FrontEdgeDist <= -40

;=======================================;
;PROJECTILE REFLECTION COMPATIBILITY    ;
;?????????????                   ;
;by Vans                                ;
;GUIDE:                                 ;
;FOR PROJECTILE / ?????              	;
;sysvar(0) = 131072                     ;
;sysvar(1) = REFLECTED_BEHAVIOR_STATE   ;
;FOR REFLECTOR / ??????????HELPER?	;
;sysvar(0) = 262144                     ;
;=======================================;
[State 1007, Turn]
type = Turn
Trigger1 = !Time && prevstateno != 1017 
[State 1206, ChangeState]
type = ChangeState
trigger1 = var(54)
trigger1 = root,NumProjID(262144)
value = sysvar(1)
ctrl = 0
ignorehitpause = 1
;=======================================;

[State 1005, End]
type=changeState
trigger1= movecontact
value=1016
ignorehitpause = 0
persistent = 0

[State -2, P2 Safe Fall]
type = TargetState
trigger1 = NumTarget = 1
trigger1 = Target, command = "recovery"
trigger1 = Target, pos y >= -30 && Target, vel y > 0
trigger1 = Target, Alive && Target, HitFall && Target, GetHitVar(fall.recover)
trigger1 = Target, StateNo = 5030 || Target, StateNo = 5035 || Target, StateNo = 5050 || Target, StateNo = 5071
value = 5205
ignoreHitPause = 1
;================================================================================
; Ventose C Overlay
;================================================================================
[Statedef 1018]
type = A
movetype = I
physics = N
ctrl = 0
velset = 0, 0
ownpal = 1
anim = 1018
sprpriority = 4
juggle = 10

;=======================================;Animations
[State 811, Anim]
Type = ChangeAnim
Triggerall = numhelper(1005)
Trigger1 = anim = 1018
Trigger1 = helper(1005),stateno = 1016
Trigger1 = helper(1005),animelem = 1
Value = anim+1
ignorehitpause = 0

[State 811, Anim]
Type = Turn
Triggerall = numhelper(1005)
Trigger1 = anim = 1018
Trigger1 = helper(1005),stateno = 1017
persistent = 0
;=======================================;Effects
[State 1050, Trans]
type = Trans
trigger1 = 1;root, var(27)
trans = add1
ignorehitpause = 1
[State 65000: AfterImage]
type = AfterImage
trigger1 = (!Time)
time = 9999999
length = 12
palbright = 12,12,12;,136
palcontrast = 120,120,120;,136
paladd = 0,0,0
timegap = 1
framegap = 1
trans = add
ignorehitpause = 1
[State 7001, Assert]
type = AssertSpecial
trigger1 = 1
flag = noshadow
ignorehitpause = 1
;=======================================;Bindings
[State 1415, BindToRoot]
type = BindToParent
trigger1 = 1
time = 1
pos = 0,0
;=======================================;End
[State 1000, DestroySelf]
type = DestroySelf
trigger1 = anim = 1019
trigger1 = animtime = 0
trigger2 = numhelper(1005) = 0
;================================================================================
;Nivose
;================================================================================
[Statedef 1100]
type    = S                      
movetype= A                    
physics = N                     
juggle  = 10              
velset = 0,0                    
ctrl = 0                       
poweradd= 100                                
sprpriority = 2
facep2 = 1
anim = ifElse((helper(10371), var(3) = [1,3]),1100,1110)

;=======================================;Animations and StateType
[State 1300, StateTypeSet]
type = StateTypeSet
trigger1 = anim = 1100 && animelem = 5
trigger2 = anim = 1110 && animelem = 4
statetype = A

[State 1300, ChangeAnim]
type = ChangeAnim
triggerall = !animtime
trigger1 = anim = 1100
trigger2 = anim = 1110
value = anim+1
;=======================================; Vels && Movement
[State 1300, VelSet]
type = VelSet
trigger1 = anim = 1100 && animelem = 2
trigger2 = anim = 1110 && animelem = 2
x = 5
[State 1300, VelSet]
type = VelSet
trigger1 = anim = 1100 && animelem = 5
x = 5
y = -6
[State 1300, VelSet]
type = VelSet
trigger1 = anim = 1110 && animelem = 4
x = 8.54156494140625
y = -8
[State 1300, VelSet]
type = VelSet
trigger1 = anim = 1101 && animelem = 1
trigger2 = anim = 1111 && animelem = 1
x = 0
y = vel y

[State 1300, VelAdd]
type = VelAdd
trigger1 = animelemtime(5) > 0
trigger1 = anim = 1100 
trigger2 = animelemtime(1) > 0
trigger2 = anim = 1101 || anim = 1111
trigger3 = animelemtime(4) > 0
trigger3 = anim = 1110
y = 0.42578125

[State 1300, VelSet]
type = VelMul
trigger1 = anim = 1100 && animelemtime(5) > 0
x = 0.854156494140625
[State 1300, VelSet]
type = VelMul
trigger1 = anim = 1110 && animelemtime(4) > 0
x = 0.868080539910180 ;0.86808053991018038359427337915292

;=======================================;Effects 
[State 1000: Helper];Leg Fire
type = helper
trigger1 = anim = 1100 || anim = 1110
trigger1 = animelem = 2
helpertype = Normal
id = 1105
pos = 0, 0 ;50
postype = p1
facing = 1
stateno = 1105
keyctrl = 0
ownpal = 1
supermovetime = 0
pausemovetime = 0
persistent = 0 

[State 1000, 1]
type = PlaySnd
trigger1 = anim = 1100 && animelem = 1
trigger2 = anim = 1110 && animelem = 1
value = 200,10+(cond(anim=1110,1,0))
channel = 0
persistent = 0
ignorehitpause = 1

[State 3303, Dust]
type = Explod
trigger1 = anim = 1100 && animelem = 5
trigger2 = anim = 1110 && animelem = 4
anim = 12005
pos = -24,0
postype = p1  ;p2,front,back,left,right
sprpriority = 3
ownpal = 1
persistent = 0
;=======================================;Hitdefs
[State 210, 1]
type = HitDef
triggerall = anim = 1100 
triggerall = var(40) < 1 || var(57) > 0 || var(16) > 0
trigger1 = AnimElemtime(3) >= 0 && Animelemtime(4) < 0
attr = S, SA
damage = floor(66*ifelse(var(56),1.25,1)),8
animtype = Hard
air.animtype = back
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 11, 13
guard.pausetime = 11,12
sparkno = s17002+(var(31)*10000)
sparkxy = -10,-81
hitsound = s3+(var(32)*2),3
guardsound = s3+(var(32)*2), 13
guard.sparkno = s17502+(var(31)*10000)
ground.type = low
ground.slidetime = 17
ground.hittime  = 16
ground.velocity = 0
fall.yvelocity = -2.5
air.type = High
air.velocity = -4.5,-7
air.hittime = 13
air.juggle = 0
getpower = 94,94
givepower = 16,16
id = 1100
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
yaccel = .5
Air.fall = 1
fall.recover = 1
fall.recovertime = 120
persistent = 0
Palfx.time       = 17+13
Palfx.add       = 0,189,0
Palfx.sinadd   = 0,-40,0,10
Palfx.color     = 128
Palfx.invertall = 0

[State 210, 1]
type = HitDef
triggerall = anim = 1100 
triggerall = var(40) < 1 || var(57) > 0 || var(16) > 0
trigger1 = AnimElemtime(5) >= 0 && Animelemtime(6) < 0
attr = S, SA
damage = floor(116*ifelse(var(56),1.25,1)),8
animtype = Hard
air.animtype = back
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 11, 13
guard.pausetime = 11,12
sparkno = s17002+(var(31)*10000)
sparkxy = -10,-84
hitsound = s3+(var(32)*2),3
guardsound = s3+(var(32)*2), 13
guard.sparkno = s17502+(var(31)*10000)
ground.type = low
ground.slidetime = 17
ground.hittime  = 16
ground.velocity = -4.5,-7
fall.yvelocity = -2.5
air.type = High
air.velocity = -4.5,-7
air.hittime = 13
air.juggle = 0
getpower = 94,94
givepower = 16,16
id = 1100
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
yaccel = .5
fall = 1
fall.recover = 1
fall.recovertime = 120
persistent = 0
Palfx.time       = 17+13
Palfx.add       = 0,189,0
Palfx.sinadd   = 0,-40,0,10
Palfx.color     = 128
Palfx.invertall = 0

[State 210, 1]
type = HitDef
triggerall = anim = 1110 
triggerall = var(40) < 1 || var(57) > 0 || var(16) > 0
trigger1 = AnimElemtime(3) >= 0 && Animelemtime(4) < 0
attr = S, SA
damage = floor(75*ifelse(var(56),1.25,1)),8
animtype = Hard
air.animtype = back
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 11, 13
guard.pausetime = 11,12
sparkno = s17002+(var(31)*10000)
sparkxy = -10,-81
hitsound = s3+(var(32)*2),3
guardsound = s3+(var(32)*2), 13
guard.sparkno = s17502+(var(31)*10000)
ground.type = low
ground.slidetime = 17
ground.hittime  = 16
ground.velocity = 0
fall.yvelocity = -2.5
air.type = High
air.velocity = -4.5,-7
air.hittime = 13
air.juggle = 0
getpower = 94,94
givepower = 16,16
id = 1100
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
yaccel = .5
Air.fall = 1
fall.recover = 1
fall.recovertime = 120
persistent = 0
Palfx.time       = 17+13
Palfx.add       = 0,189,0
Palfx.sinadd   = 0,-40,0,10
Palfx.color     = 128
Palfx.invertall = 0

[State 210, 1]
type = HitDef
triggerall = anim = 1110 
triggerall = var(40) < 1 || var(57) > 0 || var(16) > 0
trigger1 = AnimElemtime(4) >= 0 && Animelemtime(5) < 0
attr = S, SA
damage = floor(133*ifelse(var(56),1.25,1)),8
animtype = Hard
air.animtype = back
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 11, 13
guard.pausetime = 11,12
sparkno = s17002+(var(31)*10000)
sparkxy = -10,-84
hitsound = s3+(var(32)*2),3
guardsound = s3+(var(32)*2), 13
guard.sparkno = s17502+(var(31)*10000)
ground.type = low
ground.slidetime = 17
ground.hittime  = 16
ground.velocity = -4.5,-7
fall.yvelocity = -2.5
air.type = High
air.velocity = -4.5,-7
air.hittime = 13
air.juggle = 0
getpower = 94,94
givepower = 16,16
id = 1100
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
yaccel = .5
fall = 1
fall.recover = 1
fall.recovertime = 120
persistent = 0
Palfx.time       = 17+13
Palfx.add       = 0,189,0
Palfx.sinadd   = 0,-40,0,10
Palfx.color     = 128
Palfx.invertall = 0

;=======================================;End
[State 1000, 6]
type = ChangeState
triggerall = statetype = A
trigger1 = Vel Y + Pos Y >= 0
value = stateno+1
ctrl = 0

;================================================================================
;Nivose Landing
;================================================================================
[Statedef 1101]
type = S
movetype = I
physics = N
poweradd= 0
ctrl = 0
velset = 0,0
sprpriority = 2

;=======================================;Animations
[State 1000, ChangeAnim]
type = ChangeAnim
trigger1 = !time
value = 1102+(cond(anim=1101,10,0))
;=======================================;Movements
[State 852, PosSet]
type = PosSet
trigger1 = !time
y = 0
;=======================================;Effects
[State -3, land]
type = PlaySnd
trigger1 = !time
value =  (2+(var(32)*10))+var(41),2
;=======================================;End
[State 220,2]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1
;================================================================================
;Nivose FX
;================================================================================
[Statedef 1105]
type = A
movetype = I
physics = N
ctrl = 0
velset = 0, 0
ownpal = 1
anim = 1105
sprpriority = 3
juggle = 10

;=======================================;Effects
[State 1050, Trans]
type = Trans
trigger1 = 1;root, var(27)
trans = add1
ignorehitpause = 1
[State 65000: AfterImage]
type = AfterImage
trigger1 = (!Time)
time = 9999999
length = 12
palbright = 12,12,12;,136
palcontrast = 120,120,120;,136
paladd = 0,0,0
timegap = 1
framegap = 1
trans = add
ignorehitpause = 1
[State 7001, Assert]
type = AssertSpecial
trigger1 = 1
flag = noshadow
ignorehitpause = 1
[State 1000, sound]
type = PlaySnd
trigger1 = animelem = 2
value = 1000,2
persistent = 0
;=======================================;Bindings
[State 1415, BindToRoot]
type = BindToRoot
trigger1 = root,anim = 1100
trigger2 = root,anim = 1110
time = 1
pos = 45,15
;=======================================;End
[State 1000, DestroySelf]
type = DestroySelf
trigger1 = root,stateno != 1100
trigger2 = animtime = 0
;================================================================================
;Vendemiaire
;================================================================================
[Statedef 1200]
type    = S                      
movetype= A                    
physics = N                     
juggle  = 10              
velset = 0,0                    
ctrl = 0                       
poweradd= 100                                
sprpriority = 2
facep2 = 1
anim = 1200

;=======================================;Anims and StateType
[State 1300, StateTypeSet]
type = StateTypeSet
trigger1 = animelem = 6
Movetype = I
;=======================================;Effects 
[State 1000, sound]
type = PlaySnd
trigger1 = animelem = 6
value = 1000,3
persistent = 0
;=======================================;Hitdef
[State 11040, 1]
type = HitDef
triggerall = p2stateno != 40 && p2stateno !=52 ; Cannot grab during jump start / jump land
triggerall = var(19) = 0 ; Opponent isn't in guarding state
Trigger1 = animelem = 5
attr = S, ST          
hitflag = M -        
priority = 1, Miss   
sparkno = -1         
p1sprpriority = 1                     
p1facing = 1
p2facing = 1          
p1stateno = 1201
p2stateno = 1202
ground.velocity = 0,0
guard.dist = 0       
fall = 1              
ID = 1500
numhits=0
air.animtype = back
fall.xvelocity = -2.5
fall.yvelocity = -4
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
yaccel = .5
ground.velocity = 0,0

[State 220,2]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1
;================================================================================
;Vendemiaire Success
;================================================================================
[StateDef 1201]
type    = S 
MoveType = A
physics = N
VelSet = 0,0
Anim = 1201
SprPriority = 2
ctrl = 0

[State 810, bind]
type = TargetBind
trigger1 = animelemtime(1) >= 0 && animelemtime(20) < 0
pos = 34, 0

[State 1000, 1]
type = PlaySnd
trigger1 = animelem = 4
value = 200,12
channel = 0
persistent = 0
ignorehitpause = 1
[State 200, Punch Attempt Sound]
type = Playsnd
trigger1 = animelem = 3
trigger2 = animelem = 8
trigger3 = animelem = 19
value = 3+(var(32)*2),2
ignorehitpause = 1

[State 210, 1]
type = HitDef
triggerall = var(40) < 1 || var(57) > 0 || var(16) > 0
trigger1 = AnimElemtime(4) >= 0 && animelemtime(5) < 0
attr = S, SA
damage = floor(42*ifelse(var(56),1.25,1)),8
animtype = Hard
air.animtype = back
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 3, 6
guard.pausetime = 3,6
sparkno = s17002+(var(31)*10000)
sparkxy = 0,-60
hitsound = s3+(var(32)*2),3
guardsound = s3+(var(32)*2), 13
guard.sparkno = s17502+(var(31)*10000)
ground.type = High
ground.slidetime = 17
ground.hittime  = 16
ground.velocity = 0
fall.yvelocity = -2.5
guard.velocity = 0
air.type = High
air.velocity = -4.5,-7
air.hittime = 13
air.juggle = 0
getpower = 94,94
givepower = 16,16
id = 1200
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
yaccel = .5
Air.fall = 1
fall.recover = 1
fall.recovertime = 120
persistent = 0
kill = 0

[State 210, 1]
type = HitDef
triggerall = var(40) < 1 || var(57) > 0 || var(16) > 0
trigger1 = AnimElemtime(9) >= 0 && animelemtime(10) < 0
attr = S, SA
damage = floor(133*ifelse(var(56),1.25,1)),8
animtype = Hard
air.animtype = back
guardflag = MA
hitflag = MAF
priority = 4, Hit
pausetime = 3, 6
guard.pausetime = 3,6
sparkno = s17002+(var(31)*10000)
sparkxy = -30,-70
hitsound = s3+(var(32)*2),7
guardsound = s3+(var(32)*2), 13
guard.sparkno = s17502+(var(31)*10000)
ground.type = Low
ground.slidetime = 17
ground.hittime  = 16
ground.velocity = 0
fall.yvelocity = -2.5
guard.velocity = 0
air.type = High
air.velocity = -4.5,-7
air.hittime = 13
air.juggle = 0
getpower = 94,94
givepower = 16,16
id = 1200
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
yaccel = .5
Air.fall = 1
fall.recover = 1
fall.recovertime = 120
persistent = 0
kill = 0

[State 210, 1]
type = HitDef
triggerall = var(40) < 1 || var(57) > 0 || var(16) > 0
trigger1 = animelemtime(20) >= 0 && animelemtime(21) < 0
attr = S, SA
damage = floor(133*ifelse(var(56),1.25,1)),8
animtype = Up
air.animtype = Up
guardflag = M
hitflag = MAF
priority = 4, Hit
sparkno = s17002+(var(31)*10000)
sparkxy = -10, -80
hitsound = s3+(var(32)*2),9
guardsound = s3+(var(32)*2), 13
guard.sparkno = s17502+(var(31)*10000)
ground.type = Low
pausetime = 10,11
guard.pausetime = 10,11
ground.slidetime = 17
ground.hittime = 16
guard.hittime = 16
guard.slidetime = 17
guard.ctrltime = 24
ground.velocity = -2,-21
guard.velocity = -11.1796875
air.type = High
air.velocity = -2,-21
fall.yvelocity = -3
air.hittime = 13
air.juggle = 0
getpower = 47,47
givepower = 16,16
p2stateno = 10230
ground.cornerpush.veloff = 0
guard.cornerpush.veloff = 0
air.cornerpush.veloff = 0
yaccel = 0.5
fall = 1
fall.recover = 1
fall.recovertime = 120
persistent = 0

[State 801, 10]
type = ChangeState
Trigger1 = animtime = 0
value = 0
ctrl = 1 

[StateDef 1202]
Type = S
MoveType =  H
VelSet = 0, 0
sprpriority = -1 
Ctrl = 0

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

[State 0, PosSet]
type = posset
trigger1 = time = 0
y = 0

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

[State 811, Anim]
Type = ChangeAnim2
Trigger1 = !Time
Value = 1202

[State 820, 2]
type = SelfState
Trigger1 = animtime = 0
value = 0
ctrl = 1

;================================================================================
;XI LAUNCHER HIT SHAKE
[Statedef 10230]
type    = A
movetype= H
physics = N
velset = 0,0

[State 10200, Anim];Custom animation
type = ChangeAnim
trigger1 = selfanimexist(5051)
trigger1 = !time
value = 5051
[State 10200, Anim];No Custom animation
type = ChangeAnim
trigger1 = !selfanimexist(5051)
trigger1 = !time
value = 5030
[State 10200, Anim];loop
type = ChangeAnim
triggerall = anim = [5030,5051]
trigger1 = HitShakeOver != 1
value = anim

[State 10900, State]
type = ChangeState
trigger1 = HitShakeOver = 1
value = 10231

;================================================================================
;XI LAUNCHER FLYING 
[Statedef 10231]
type    = A
movetype= H
physics = N

[State 10100, Anim]
type = ChangeAnim
triggerall = anim = 5030
trigger1 = !time 
value = 5050

[State 5050, 2] ;Coming down anim
type = ChangeAnim
trigger1 = anim = 5051
trigger1 = (GetHitVar(animtype) = [0,3]) && time = 13 
value = 5050
persistent = 0

[State 5050, 2] ;Coming down anim
type = ChangeAnim
trigger1 = anim = 5051
trigger1 = (GetHitVar(animtype) = [4,5]) && animtime = 0
trigger1 = SelfAnimExist(anim+10)
value = anim+10
persistent = 0

[State 10900, 1]
type = HitVelSet
trigger1 = !time
y = 1
x = 1

[State 10900, VelMul]
type = VelAdd
trigger1 = time > 0 && time < 8
y = 1.625

[State 10900, VelMul]
type = VelAdd
trigger1 = time > 0 && time >= 8
y = .625

[State 5050, 4] ;Recover near ground
type = SelfState
triggerall = Vel Y > 0
triggerall = Pos Y >= -30
triggerall = alive
triggerall = CanRecover
trigger1 = Command = "recovery"
value = 5200 ;HITFALL_RECOVER

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

[State 10900, Hit ground]
type = SelfState
trigger1 = time
trigger1 = Vel Y + Pos Y >= 0
value = 5100