;---------------------------------------------------------------------------
; A Dashing Puncher
[Statedef 1000]
type = S
movetype = A
physics = N				
velset = 0,0			
ctrl = 0				
anim = 1000				
poweradd = IfElse(var(31) = 0, 100, 0)		
sprpriority = 2			
facep2 = 1

[State 1000, VelSet]
type = VelSet
trigger1 = AnimElem = 3
x = 10

[State 1000, VelMul]
type = VelMul
trigger1 = AnimElemTime(3) > 0 
x = 1

[State 1000, Voice]
type = PlaySnd 
trigger1 = AnimElem = 6
value = S1000,0
channel = 0
ignorehitpause = 1

[State 1000, Drive Cancel]
type = VarAdd
triggerall = PrevStateNo = [1000,2999]
trigger1 = !Time
var(30) = IfElse(var(31) = 0, -500, -90)
ignorehitpause = 1
persistent = 0

[State 12000, Drive Cancel Helper]
type = Helper
triggerall = PrevStateNo = [1000,2999]
trigger1 = !Time
name = "Drive/HD Cancel"
ID = 12000
stateno = 12000
pos = 0,0
postype = p1  
facing = 1
keyctrl = 0
ownpal = 1

[State 1000, 1]
type = HitDef
triggerall = IfElse(Var(31) = 0, var(15) < 3, var(15) < 4)
trigger1 = AnimElem = 7
attr = S, SA			
damage = floor(85*fvar(20)), 5
animtype = Heavy			
guardflag = MA			
hitflag = MAF
priority = 5, Hit			
pausetime = 11,11	
sparkno = S10001
guard.sparkno = S10131				
sparkxy = -10, -75		
hitsound = S5, 5			
guardsound = S6, 1	
ground.type = High	
ground.slidetime = 20
ground.hittime = 20
guard.hittime = 17
ground.velocity = -2.5, -10.8
guard.velocity = -11.1796875
air.velocity = -2.5, -10.8
air.animtype = Back				
yaccel = 0.5
ground.cornerpush.veloff = 0
getpower = IfElse(!var(31), 100, 0), IfElse(!var(31), 100, 0)
givepower = 100
fall = 1
fall.recovertime = 60
guard.dist = 20

[State 1000, VelSet]
type = VelSet
trigger1 = AnimElem = 7
x = 0

[State 1000, VarSet]
type = VarSet
triggerall = MoveHit
triggerall = NumTarget
trigger1 = Target, HitFall = 1
var(15) = IfElse(var(15) < 2, 2, 3)
ignorehitpause = 1
persistent = 0

[State 1000, StateTypeSet]
type = StateTypeSet
trigger1 = AnimElem = 9
movetype = I

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

;---------------------------------------------------------------------------
; C Dashing Puncher
[Statedef 1001]
type = S
movetype = A
physics = N				
velset = 0,0			
ctrl = 0				
anim = 1001				
poweradd = IfElse(!var(31), 100, 0)		
sprpriority = 2			
facep2 = 1

[State 1001, VelSet]
type = VelSet
trigger1 = AnimElem = 3
x = 10

[State 1001, VelMul]
type = VelMul
trigger1 = AnimElemTime(3) > 0 
x = 1

[State 1001, Voice]
type = PlaySnd 
trigger1 = AnimElem = 9
value = S1000,0
channel = 0
ignorehitpause = 1

[State 1001, Drive Cancel]
type = VarAdd
triggerall = PrevStateNo = [1000,2999]
trigger1 = !Time
var(30) = IfElse(var(31) = 0, -500, -90)
ignorehitpause = 1
persistent = 0

[State 12000, Drive Cancel Helper]
type = Helper
triggerall = PrevStateNo = [1000,2999]
trigger1 = !Time
name = "Drive/HD Cancel"
ID = 12000
stateno = 12000
pos = 0,0
postype = p1  
facing = 1
keyctrl = 0
ownpal = 1

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

[State 1001, 1]
type = HitDef
triggerall = IfElse(Var(31) = 0, var(15) < 3, var(15) < 4)
trigger1 = AnimElem = 10
attr = S, SA			
damage = floor(95*fvar(20)), 5
animtype = Heavy			
guardflag = MA			
hitflag = MAF
priority = 5, Hit			
pausetime = 11,11	
sparkno = S10001
guard.sparkno = S10131				
sparkxy = -10, -75		
hitsound = S5, 5			
guardsound = S6, 1	
ground.type = High	
ground.slidetime = 20
ground.hittime = 20
guard.hittime = 17
ground.velocity = -2.5,-10.8
guard.velocity = -11.1796875
air.velocity = -2.5,-10.8
air.animtype = Back				
yaccel = 0.5
ground.cornerpush.veloff = 0
getpower = IfElse(!var(31), 125, 0), IfElse(!var(31), 125, 0)
givepower = 125
fall = 1
fall.recovertime = 60
guard.dist = 20

[State 1001, VarSet]
type = VarSet
triggerall = MoveHit
triggerall = NumTarget
trigger1 = Target, HitFall = 1
var(15) = IfElse(var(15) < 2, 2, 3)
ignorehitpause = 1
persistent = 0

[State 1001, StateTypeSet]
type = StateTypeSet
trigger1 = AnimElem = 12
movetype = I

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

;---------------------------------------------------------------------------
; Machine Gun Puncher
[Statedef 1005]
type = S
movetype = A
physics = N				
velset = 0,0			
ctrl = 0				
anim = 1005				
poweradd = IfElse(var(31) = 0, 100, 0)		
sprpriority = 2			
facep2 = 1

[State 1005, Drive Cancel]
type = VarAdd
triggerall = PrevStateNo = [1000,2999]
trigger1 = !Time
var(30) = IfElse(var(31) = 0, -500, -90)
ignorehitpause = 1
persistent = 0

[State 12000, Drive Cancel Helper]
type = Helper
triggerall = PrevStateNo = [1000,2999]
trigger1 = !Time
name = "Drive/HD Cancel"
ID = 12000
stateno = 12000
pos = 0,0
postype = p1  
facing = 1
keyctrl = 0
ownpal = 1

[State 1005, Voice]
type = PlaySnd 
trigger1 = AnimElem = 2
value = S1005,0
channel = 0
ignorehitpause = 1

[State 1005, Whiff]
type = PlaySnd 
trigger1 = AnimElem = 2
trigger2 = AnimElem = 7
trigger3 = AnimElem = 12
value = S5,6
channel = 1
ignorehitpause = 1

[State 1005, VarSet]
type = VarSet
trigger1 = !Time 
var(2) = 0

[State 1005, Machine Gun Puncher Check]
type = VarSet
trigger1 = !Time
trigger1 = command = "HCF_x" || command = "HCB_x"
var(3) = 1

[State 1005, Machine Gun Puncher Check]
type = VarSet
trigger1 = !Time
trigger1 = command = "HCF_y" || command = "HCB_y"
var(3) = 2

[State 1005, VarSet]
type = VarSet
triggerall = AnimElemTime(1) > 1
trigger1 = command = "mash_x" || command = "mash_y" 
trigger1 = AILevel = 0
var(2) = 1

[State 1005, VelSet]
type = VelSet
trigger1 = AnimElem = 2
x = 3
ignorehitpause = 1

[State 1005, VelSet]
type = VelSet
trigger1 = AnimElem = 3
x = 1
ignorehitpause = 1

[State 1005, VelSet]
type = VelSet
trigger1 = AnimElem = 11
x = 0
ignorehitpause = 1

[State 1005, 1]
type = HitDef
triggerall = Var(15) < IfElse( !Var(31), 3, 4)
trigger1 = AnimElem = 2
trigger2 = AnimElem = 7
trigger3 = AnimElem = 12
attr = S, SA			
damage = floor(IfElse(var(3) = 1, 10, 15)*fvar(20)), 5
animtype = Medium			
guardflag = MA			
hitflag = MAF
priority = 5, Hit			
pausetime = 7,7	
sparkno = S10001
guard.sparkno = S10131				
sparkxy = -10, -55		
hitsound = S5, 1			
guardsound = S6, 1	
ground.type = High	
ground.slidetime = 20
ground.hittime = 20
guard.hittime = 17
ground.velocity = 0
air.velocity = 0, -4.5
air.animtype = Back				
yaccel = 0.5
ground.cornerpush.veloff = 0
getpower = IfElse(!var(31), 50, 0), IfElse(!var(31), 50, 0)
givepower = 50
air.fall = 1
fall.recover = 0
id = 1005

[State 1005, ChangeState]
type = ChangeState
trigger1 = AnimElem = 16 && var(2)
trigger2 = AnimElem = 16 && MoveContact
trigger2 = AILevel != 0
value = 1006
ctrl = 0

[State 1005, end]
type = ChangeState
trigger1 = AnimTime = 0
value = 1008
ctrl = 0
;---------------------------------------------------------------------------
; Extra Hit 1
[Statedef 1006]
type = S
movetype = A
physics = N				
velset = 3,0			
ctrl = 0				
anim = 1006				
poweradd = IfElse(var(31) = 0, 100, 0)		
sprpriority = 2
hitcountpersist = 1

[State 1006, VarSet]
type = VarSet
trigger1 = !Time 
var(2) = 0

[State 1006, VarSet]
type = VarSet
triggerall = AnimElemTime(1) > 1
trigger1 = command = "mash_x" || command = "mash_y" 
trigger1 = AILevel = 0
var(2) = 1

[State 1006, VelSet]
type = VelSet
trigger1 = AnimElem = 2
x = 0
ignorehitpause = 1	

[State 1006, Whiff]
type = PlaySnd 
trigger1 = AnimElem = 2
value = S5,6
channel = 1
ignorehitpause = 1

[State 1006, 1]
type = HitDef
triggerall = Var(15) < IfElse( !Var(31), 3, 4)
trigger1 = AnimElem = 2
attr = S, SA			
damage = floor(IfElse(var(3) = 1, 10, 15)*fvar(20)), 5
animtype = Medium			
guardflag = MA			
hitflag = MAF
priority = 5, Hit			
pausetime = 7,7	
sparkno = S10001
guard.sparkno = S10131				
sparkxy = -10, -55		
hitsound = S5, 1			
guardsound = S6, 1	
ground.type = High	
ground.slidetime = 20
ground.hittime = 20
guard.hittime = 17
ground.velocity = 0
air.velocity = 0, -4.5
air.animtype = Back				
yaccel = 0.5
ground.cornerpush.veloff = 0
getpower = IfElse(!var(31), 50, 0), IfElse(!var(31), 50, 0)
givepower = 50
air.fall = 1
fall.recover = 0
id = 1005

[State 1006, ChangeState]
type = ChangeState
trigger1 = AnimElem = 5
trigger1 = MoveContact && AILevel != 0
value = 1007
ctrl = 0

[State 1006, end]
type = ChangeState
trigger1 = AnimElem = 5
value = IfElse(var(2) = 1, StateNo + 1, StateNo + 2)
ctrl = 0
;---------------------------------------------------------------------------
; Extra Hit 2
[Statedef 1007]
type = S
movetype = A
physics = N				
velset = 3,0			
ctrl = 0				
anim = 1007				
poweradd = IfElse(var(31) = 0, 100, 0)		
sprpriority = 2
hitcountpersist = 1

[State 1007, VarSet]
type = VarSet
trigger1 = !Time 
var(2) = 0

[State 1007, VelSet]
type = VelSet
trigger1 = AnimElem = 2
x = 0
ignorehitpause = 1

[State 1007, Whiff]
type = PlaySnd 
trigger1 = AnimElem = 2
value = S5,6
channel = 1
ignorehitpause = 1

[State 1007, 1]
type = HitDef
triggerall = Var(15) < IfElse( !Var(31), 3, 4)
trigger1 = AnimElem = 2
attr = S, SA			
damage = floor(IfElse(var(3) = 1, 10, 15)*fvar(20)), 5
animtype = Medium			
guardflag = MA			
hitflag = MAF
priority = 5, Hit			
pausetime = 7,7	
sparkno = S10001
guard.sparkno = S10131				
sparkxy = -10, -55		
hitsound = S5, 1			
guardsound = S6, 1	
ground.type = High	
ground.slidetime = 20
ground.hittime = 20
guard.hittime = 17
ground.velocity = 0
air.velocity = 0, -4.5
air.animtype = Back				
yaccel = 0.5
ground.cornerpush.veloff = 0
getpower = IfElse(!var(31), 50, 0), IfElse(!var(31), 50, 0)
givepower = 50
air.fall = 1
fall.recover = 0
id = 1005

[State 1007, Machine Gun Puncher Explod]
type = Explod
triggerall = AnimElem = 2
triggerall = NumTarget
trigger1 = NumTarget(1005) && MoveHit
anim = 11005
ID = 11005
facing = -1
pos = (Target, const(size.mid.pos.x)) - 20,-75
postype = p2 
bindtime = 1
removetime = -2
scale = 1,1
sprpriority = -1
ownpal = 1
removeongethit = 1
ignorehitpause = 1

[State 1007, end]
type = ChangeState
trigger1 = AnimTime = 0
value = StateNo + 1
ctrl = 0
;---------------------------------------------------------------------------
; Machine Gun Finish
[Statedef 1008]
type = S
movetype = A
physics = N				
velset = 0,0			
ctrl = 0				
anim = 1008				
poweradd = IfElse(var(31) = 0, 100, 0)		
sprpriority = 2
hitcountpersist = 1

[State 1008, Voice]
type = PlaySnd 
trigger1 = AnimElem = 2
value = S1008,0
channel = 0
ignorehitpause = 1	

[State 1008, Whiff]
type = PlaySnd 
trigger1 = AnimElem = 4
value = S5,7
channel = 1
ignorehitpause = 1

[State 1008, 1]
type = HitDef
triggerall = Var(15) < IfElse( !Var(31), 3, 4)
trigger1 = AnimElem = 4
attr = S, SA			
damage = floor(25*fvar(20)),15
animtype = Heavy			
guardflag = MA			
hitflag = MAF
priority = 5, Hit			
pausetime = 11,11
sparkno = S10001
guard.sparkno = S10131				
sparkxy = -10, -55		
hitsound = S5, 2			
guardsound = S6, 1	
ground.type = High	
ground.slidetime = 20
ground.hittime = 20
guard.hittime = 17
ground.velocity = -4.5,-7.5
guard.velocity = -11.1796875
air.velocity = -4.5,-7.5
air.animtype = Back				
yaccel = 0.5
ground.cornerpush.veloff = 0
getpower = IfElse(!var(31), 50, 0), IfElse(!var(31), 50, 0)
givepower = 50
fall = 1
fall.recover = 0
p2stateno = 51008
id = 1005

[State 1008, VarSet]
type = VarSet
triggerall = MoveHit
triggerall = NumTarget
trigger1 = Target, HitFall = 1
var(15) = IfElse(var(15) < 2, 2, 3)
ignorehitpause = 1
persistent = 0

[State 1008, StateTypeSet]
type = StateTypeSet
trigger1 = AnimElem = 6
movetype = I

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

;---------------------------------------------------------------------------
; B Puncher Vision (Fwd.)
[Statedef 1010]
type = S
movetype = I
physics = N				
velset = 0,0			
ctrl = 0				
anim = 1010				
poweradd = IfElse(var(31) = 0, 100, 0)		
sprpriority = 2			
facep2 = 1

[State 1010, Drive Cancel]
type = VarAdd
triggerall = (PrevStateNo = [1000,2999]) 
triggerall = PrevStateNo != 1030 && PrevStateNo != 2030
trigger1 = !Time
var(30) = IfElse(var(31) = 0, -500, -90)

[State 1010, Puncher Vision Explod 2]
type = Explod
trigger1 = !Time
anim = 11010
ID = 11010
pos = 0,0
postype = p1 
bindtime = 1
removetime = -2
scale = 1,1
sprpriority = -1
ownpal = 1
removeongethit = 1

[State 1010, Voice]
type = PlaySnd 
trigger1 = AnimElem = 1
value = S1010,0
channel = 0
ignorehitpause = 1

[State 12000, Drive Cancel Helper]
type = Helper
triggerall = (PrevStateNo = [1000,2999]) 
triggerall = PrevStateNo != 1030 && PrevStateNo != 2030
trigger1 = !Time
name = "Drive/HD Cancel"
ID = 12000
stateno = 12000
pos = 0,0
postype = p1  
facing = 1
keyctrl = 0
ownpal = 1

[State 1010, VarSet]
type = VarSet
trigger1 = !Time
var(2) = 0

[State 1010, VarSet]
type = VarSet
triggerall = AnimElemTime(1) > 1
trigger1 = command = "holdfwd" && command = "x"
trigger1 = AILevel = 0
var(2) = 1

[State 1010, VarSet]
type = VarSet
triggerall = AnimElemTime(1) > 1
trigger1 = command = "holdfwd" && command = "y"
trigger1 = AILevel = 0
var(2) = 2

[State 1010, VarSet]
type = VarSet
triggerall = AnimElemTime(1) > 1
trigger1 = command = "holdback" && command = "x" || command = "holdback" && command = "y"
trigger1 = AILevel = 0
var(2) = 3

[State 1010, VelSet]
type = VelSet
trigger1 = AnimElem = 3
x = 10

[State 1010, VelSet]
type = VelSet
trigger1 = AnimElem = 6
x = 0

[State 1010, ChangeState]
type = ChangeState
triggerall = var(2) > 0
trigger1 = AnimElemTime(6)>=0
value = IfElse(var(2) = 1, 1015, IfElse(var(2) = 2, 1017, 1030))
ctrl = 0

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

;---------------------------------------------------------------------------
; D Puncher Vision (Fwd.)
[Statedef 1011]
type = S
movetype = I
physics = N				
velset = 0,0			
ctrl = 0				
anim = 1011				
poweradd = IfElse(var(31) = 0, 100, 0)		
sprpriority = 2			
facep2 = 1

[State 1011, Drive Cancel]
type = VarAdd
triggerall = (PrevStateNo = [1000,2999]) 
triggerall = PrevStateNo != 1030 && PrevStateNo != 2030
trigger1 = !Time
var(30) = IfElse(var(31) = 0, -500, -90)

[State 1011, Puncher Vision Explod 2]
type = Explod
trigger1 = !Time
anim = 11010
ID = 11010
pos = 0,0
postype = p1 
bindtime = 1
removetime = -2
scale = 1,1
sprpriority = -1
ownpal = 1
removeongethit = 1

[State 1011, Voice]
type = PlaySnd 
trigger1 = AnimElem = 1
value = S1010,0
channel = 0
ignorehitpause = 1

[State 12000, Drive Cancel Helper]
type = Helper
triggerall = (PrevStateNo = [1000,2999]) 
triggerall = PrevStateNo != 1030 && PrevStateNo != 2030
trigger1 = !Time
name = "Drive/HD Cancel"
ID = 12000
stateno = 12000
pos = 0,0
postype = p1  
facing = 1
keyctrl = 0
ownpal = 1

[State 1011, VarSet]
type = VarSet
trigger1 = !Time
var(2) = 0

[State 1011, VarSet]
type = VarSet
triggerall = AnimElemTime(1) > 1
trigger1 = command = "holdfwd" && command = "x"
trigger1 = AILevel = 0
var(2) = 1

[State 1011, VarSet]
type = VarSet
triggerall = AnimElemTime(1) > 1
trigger1 = command = "holdfwd" && command = "y"
trigger1 = AILevel = 0
var(2) = 2

[State 1011, VarSet]
type = VarSet
triggerall = AnimElemTime(1) > 1
trigger1 = command = "holdback" && command = "x" || command = "holdback" && command = "y"
trigger1 = AILevel = 0
var(2) = 3

[State 1011, VelSet]
type = VelSet
trigger1 = AnimElem = 3
x = 10

[State 1011, VelSet]
type = VelSet
trigger1 = AnimElem = 6
x = 0

[State 1011, ChangeState]
type = ChangeState
triggerall = var(2) > 0
trigger1 = AnimElemTime(6)>=0
value = IfElse(var(2) = 1, 1015, IfElse(var(2) = 2, 1017, 1030))
ctrl = 0

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

;---------------------------------------------------------------------------
; B Puncher Vision (Back)
[Statedef 1012]
type = S
movetype = I
physics = N				
velset = 0,0			
ctrl = 0				
anim = 1012				
poweradd = IfElse(var(31) = 0, 100, 0)		
sprpriority = 2			
facep2 = 1

[State 1012, Drive Cancel]
type = VarAdd
triggerall = (PrevStateNo = [1000,2999]) 
triggerall = PrevStateNo != 1030 && PrevStateNo != 2030
trigger1 = !Time
var(30) = IfElse(var(31) = 0, -500, -90)

[State 1012, Puncher Vision Explod 2]
type = Explod
trigger1 = !Time
anim = 11010
ID = 11010
pos = 0,0
postype = p1 
bindtime = 1
removetime = -2
scale = 1,1
sprpriority = -1
ownpal = 1
removeongethit = 1

[State 1012, Voice]
type = PlaySnd 
trigger1 = AnimElem = 1
value = S1010,0
channel = 0
ignorehitpause = 1

[State 12000, Drive Cancel Helper]
type = Helper
triggerall = (PrevStateNo = [1000,2999]) 
triggerall = PrevStateNo != 1030 && PrevStateNo != 2030
trigger1 = !Time
name = "Drive/HD Cancel"
ID = 12000
stateno = 12000
pos = 0,0
postype = p1  
facing = 1
keyctrl = 0
ownpal = 1

[State 1012, VarSet]
type = VarSet
trigger1 = !Time
var(2) = 0

[State 1012, VarSet]
type = VarSet
triggerall = AnimElemTime(1) > 1
trigger1 = command = "holdfwd" && command = "x"
trigger1 = AILevel = 0
var(2) = 1

[State 1012, VarSet]
type = VarSet
triggerall = AnimElemTime(1) > 1
trigger1 = command = "holdfwd" && command = "y"
trigger1 = AILevel = 0
var(2) = 2

[State 1012, VarSet]
type = VarSet
triggerall = AnimElemTime(1) > 1
trigger1 = command = "holdback" && command = "x" || command = "holdback" && command = "y"
trigger1 = AILevel = 0
var(2) = 3

[State 1012, VelSet]
type = VelSet
trigger1 = AnimElem = 3
x = -10

[State 1012, VelSet]
type = VelSet
trigger1 = AnimElem = 6
x = 0

[State 1012, ChangeState]
type = ChangeState
triggerall = var(2) > 0
trigger1 = AnimElemTime(6)>=0
value = IfElse(var(2) = 1, 1015, IfElse(var(2) = 2, 1017, 1030))
ctrl = 0

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

;---------------------------------------------------------------------------
; D Puncher Vision (Back)
[Statedef 1013]
type = S
movetype = I
physics = N				
velset = 0,0			
ctrl = 0				
anim = 1013				
poweradd = IfElse(var(31) = 0, 100, 0)		
sprpriority = 2			
facep2 = 1

[State 1013, Drive Cancel]
type = VarAdd
triggerall = (PrevStateNo = [1000,2999]) 
triggerall = PrevStateNo != 1030 && PrevStateNo != 2030
trigger1 = !Time
var(30) = IfElse(var(31) = 0, -500, -90)

[State 1013, Puncher Vision Explod 2]
type = Explod
trigger1 = !Time
anim = 11010
ID = 11010
pos = 0,0
postype = p1 
bindtime = 1
removetime = -2
scale = 1,1
sprpriority = -1
ownpal = 1
removeongethit = 1

[State 1013, Voice]
type = PlaySnd 
trigger1 = AnimElem = 1
value = S1010,0
channel = 0
ignorehitpause = 1

[State 12000, Drive Cancel Helper]
type = Helper
triggerall = (PrevStateNo = [1000,2999]) 
triggerall = PrevStateNo != 1030 && PrevStateNo != 2030
trigger1 = !Time
name = "Drive/HD Cancel"
ID = 12000
stateno = 12000
pos = 0,0
postype = p1  
facing = 1
keyctrl = 0
ownpal = 1

[State 1013, VarSet]
type = VarSet
trigger1 = !Time
var(2) = 0

[State 1013, VarSet]
type = VarSet
triggerall = AnimElemTime(1) > 1
trigger1 = command = "holdfwd" && command = "x"
trigger1 = AILevel = 0
var(2) = 1

[State 1013, VarSet]
type = VarSet
triggerall = AnimElemTime(1) > 1
trigger1 = command = "holdfwd" && command = "y"
trigger1 = AILevel = 0
var(2) = 2

[State 1013, VarSet]
type = VarSet
triggerall = AnimElemTime(1) > 1
trigger1 = command = "holdback" && command = "x" || command = "holdback" && command = "y"
trigger1 = AILevel = 0
var(2) = 3

[State 1013, VelSet]
type = VelSet
trigger1 = AnimElem = 3
x = -10

[State 1013, VelSet]
type = VelSet
trigger1 = AnimElem = 6
x = 0

[State 1013, ChangeState]
type = ChangeState
triggerall = var(2) > 0
trigger1 = AnimElemTime(6)>=0
value = IfElse(var(2) = 1, 1015, IfElse(var(2) = 2, 1017, 1030))
ctrl = 0

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

;---------------------------------------------------------------------------
; Puncher Upper
[Statedef 1015]
type = S
movetype = A
physics = N				
velset = 0,0			
ctrl = 0				
anim = IfElse((PrevStateNo = [1010, 1011]) || PrevStateNo = 2010, 1015, 1016)				
poweradd = IfElse(var(31) = 0, 100, 0)		
sprpriority = 2			

[State 1015, ReversalDef]
type = ReversalDef
triggerall = PrevStateNo = 2010
trigger1 = AnimElemTime(5) < 0
reversal.attr = SCA,AA
pausetime = 7,7
sparkno = S10131
hitsound = S1,0
persistent = 0

[State 1015, PosAdd]
type = PosAdd
trigger1 = AnimElem = 1
x = 4

[State 1015, PosAdd]
type = PosAdd
trigger1 = AnimElem = 2
x = 4

[State 1015, PosAdd]
type = PosAdd
trigger1 = Time = 19
x = 22

[State 1015, PosAdd]
type = PosAdd
trigger1 = AnimElem = 8
x = 8

[State 1015, PosAdd]
type = PosAdd
trigger1 = AnimElem = 9
x = 4

[State 1015, PosAdd]
type = PosAdd
trigger1 = AnimElem = 10
x = 8

[State 1015, PosAdd]
type = PosAdd
trigger1 = AnimElem = 11
x = 4

[State 1015, PosAdd]
type = VelSet
trigger1 = AnimElem = 3
x = 5

[State 1015, VelMul]
type = VelMul
trigger1 = AnimElemTime(3) > 0 
x = 1

[State 1015, PosAdd]
type = VelSet
trigger1 = AnimElem = 5
x = 0

[State 1015, Voice]
type = PlaySnd 
trigger1 = AnimElem = 5
trigger2 = AnimElem = 9
value = S202,IfElse((AnimElem = 5), 0, 1)
channel = 0
ignorehitpause = 1

[State 1015, Whiffs]
type = PlaySnd 
trigger1 = AnimElem = 5
trigger2 = AnimElem = 9
value = S5,IfElse((AnimElem = 5), 7, 8)
channel = 2
ignorehitpause = 1

[State 1015, 1]
type = HitDef
triggerall = IfElse(Var(31) = 0, var(15) < 3, var(15) < 4)
trigger1 = AnimElem = 5
attr = S, SA			
damage = floor(25*fvar(20)), 5
animtype = Medium			
guardflag = MA			
hitflag = MAF
priority = 5, Hit			
pausetime = 11,11	
sparkno = S10001
guard.sparkno = S10131				
sparkxy = -10, -75		
hitsound = S5, 1			
guardsound = S6, 1	
ground.type = High	
ground.slidetime = 20
ground.hittime = 20
guard.hittime = 17
ground.velocity = 0
air.velocity = -4.5,-6.5	
air.animtype = Back				
yaccel = 0.5
ground.cornerpush.veloff = 0
getpower = IfElse(!var(31), 100, 0), IfElse(!var(31), 100, 0)
givepower = 100
air.fall = 1
fall.recover = 0
persistent = 0

[State 1015, 2]
type = HitDef
triggerall = IfElse(Var(31) = 0, var(15) < 3, var(15) < 4)
trigger1 = AnimElem = 11
attr = S, SA			
damage = floor(65*fvar(20)), 5
animtype = Heavy			
guardflag = MA			
hitflag = MAF
priority = 5, Hit			
pausetime = 11,11	
sparkno = S10001
guard.sparkno = S10131				
sparkxy = -10, -75		
hitsound = S5, 5			
guardsound = S6, 1	
ground.type = High	
ground.slidetime = 20
ground.hittime = 20
guard.hittime = 17
ground.velocity = -2.5,-10.8
guard.velocity = -11.1796875
air.velocity = -2.5,-10.8
air.animtype = Back				
yaccel = 0.5
ground.cornerpush.veloff = 0
getpower = IfElse(!var(31), 100, 0), IfElse(!var(31), 100, 0)
givepower = 100
fall = 1
fall.recovertime = 60

[State 1015, VelSet]
type = VelSet
trigger1 = AnimElem = 7
x = 0

[State 1015, VarSet]
type = VarSet
triggerall = MoveHit
triggerall = NumTarget
trigger1 = Target, HitFall = 1
var(15) = IfElse(var(15) < 2, 2, 3)
ignorehitpause = 1
persistent = 0

[State 1015, StateTypeSet]
type = StateTypeSet
trigger1 = AnimElem = 13
movetype = I

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

;---------------------------------------------------------------------------
; Puncher Straight
[Statedef 1017]
type = S
movetype = A
physics = N				
velset = 0,0			
ctrl = 0				
anim = IfElse((PrevStateNo = [1010, 1011]) || PrevStateNo = 2010, 1017, 1018)				
poweradd = IfElse(var(31) = 0, 100, 0)		
sprpriority = 2			

[State 1017, ReversalDef]
type = ReversalDef
triggerall = PrevStateNo = 2010
trigger1 = Anim = 1017 && AnimElemTime(4) < 0
trigger2 = Anim = 1018 && AnimElemTime(7) < 0
reversal.attr = SCA,AA
pausetime = 7,7
sparkno = S10131
hitsound = S1,0
persistent = 0

[State 1017, PosAdd]
type = PosAdd
triggerall = Anim = 1017
trigger1 = AnimElem = 1
x = 4

[State 1017, PosAdd]
type = PosAdd
triggerall = Anim = 1017
trigger1 = AnimElem = 2
x = 4

[State 1017, PosAdd]
type = PosAdd
triggerall = Anim = 1017
trigger1 = Time = 19
x = 22

[State 1017, PosAdd]
type = PosAdd
triggerall = Anim = 1017
trigger1 = AnimElem = 7
x = 8

[State 1017, PosAdd]
type = PosAdd
triggerall = Anim = 1017
trigger1 = AnimElem = 8
x = 4

[State 1017, PosAdd]
type = VelSet
triggerall = Anim = 1017
trigger1 = AnimElem = 2
x = 5

[State 1017, VelMul]
type = VelMul
triggerall = Anim = 1017
trigger1 = AnimElemTime(3) > 0 
x = 1

[State 1017, PosAdd]
type = VelSet
triggerall = Anim = 1017
trigger1 = AnimElem = 4
x = 0

[State 1017, VelSet]
type = VelSet
triggerall = Anim = 1018
trigger1 = AnimElem = 1
x = 8

[State 1017, VelSet]
type = PosAdd
triggerall = Anim = 1018
trigger1 = AnimElem = 4
trigger2 = AnimElem = 5
x = 8

[State 1017, VelSet]
type = VelSet
trigger1 = Anim = 1018
trigger1 = AnimElem = 6
x = 0

[State 1017, Voice 1]
type = PlaySnd
triggerall = Anim = 1017 
trigger1 = AnimElem = 3
trigger2 = AnimElem = 10
value = S202,IfElse((AnimElem = 3), 0, 1)
channel = 0
ignorehitpause = 1

[State 1017, Voice 2]
type = PlaySnd
triggerall = Anim = 1018 
trigger1 = AnimElem = 3
value = S1018,0
channel = 0
ignorehitpause = 1

[State 1015, Whiff 1]
type = PlaySnd 
trigger1 = Anim = 1017
trigger1 = AnimElem = 3
value = S5,6
channel = 2
ignorehitpause = 1

[State 1017, Whiffs 2]
type = PlaySnd 
trigger1 = Anim = 1017
trigger1 = AnimElem = 9
trigger2 = Anim = 1018
trigger2 = AnimElem = 6
value = S5,7
channel = 2
ignorehitpause = 1

[State 1017, 1]
type = HitDef
triggerall = IfElse(Var(31) = 0, var(15) < 3, var(15) < 4)
triggerall = Anim = 1017
trigger1 = AnimElem = 3
attr = S, SA			
damage = floor(25*fvar(20)), 5
animtype = Medium			
guardflag = MA			
hitflag = MAF
priority = 5, Hit			
pausetime = 11,11	
sparkno = S10001
guard.sparkno = S10131				
sparkxy = -10, -75		
hitsound = S5, 1			
guardsound = S6, 1	
ground.type = High	
ground.slidetime = 20
ground.hittime = 20
guard.hittime = 17
ground.velocity = 0
air.velocity = -4.5,-6.5	
air.animtype = Back				
yaccel = 0.5
ground.cornerpush.veloff = 0
getpower = IfElse(!var(31), 100, 0), IfElse(!var(31), 100, 0)
givepower = 100
air.fall = 1
fall.recover = 0
persistent = 0

[State 1017, 2]
type = HitDef
triggerall = IfElse(Var(31) = 0, var(15) < 3, var(15) < 4)
triggerall = Anim = 1017
trigger1 = AnimElem = 10
attr = S, SA			
damage = floor(65*fvar(20)), 5
animtype = Heavy			
guardflag = MA			
hitflag = MAF
priority = 5, Hit			
pausetime = 11,11	
sparkno = S10001
guard.sparkno = S10131				
sparkxy = -10, -75		
hitsound = S5, 5			
guardsound = S6, 1	
ground.type = High	
ground.slidetime = 20
ground.hittime = 20
guard.hittime = 17
ground.velocity = -4.5,-7.5
guard.velocity = -11.1796875
air.velocity = -4.5,-7.5
air.animtype = Back				
yaccel = 0.5
ground.cornerpush.veloff = 0
getpower = IfElse(!var(31), 100, 0), IfElse(!var(31), 100, 0)
givepower = 100
fall = 1
fall.recovertime = 60
id = 1017
p2facing = IfElse((PrevStateNo = [2010,2012]) && P2StateNo < 51017, 0, 1)

[State 1017, 3]
type = HitDef
triggerall = IfElse(Var(31) = 0, var(15) < 3, var(15) < 4)
triggerall = Anim = 1018
trigger1 = AnimElem = 7
attr = S, SA			
damage = floor(90*fvar(20)), 5
animtype = Heavy			
guardflag = MA			
hitflag = MAF
priority = 5, Hit			
pausetime = 11,11	
sparkno = S10001
guard.sparkno = S10131				
sparkxy = -10, -75		
hitsound = S5, 5			
guardsound = S6, 1	
ground.type = High	
ground.slidetime = 20
ground.hittime = 20
guard.hittime = 17
ground.velocity = -4.5,-7.5
guard.velocity = -11.1796875
air.velocity = -4.5,-7.5
air.animtype = Back				
yaccel = 0.5
ground.cornerpush.veloff = 0
getpower = IfElse(!var(31), 100, 0), IfElse(!var(31), 100, 0)
givepower = 100
fall = 1
fall.recovertime = 60
id = 1018
p2facing = IfElse((PrevStateNo = [2010,2012]) && P2StateNo < 51017, 0, 1)

[State 1017, VarSet]
type = VarSet
triggerall = MoveHit
triggerall = NumTarget
triggerall = PrevStateNo != [2010,2012]
trigger1 = Target, HitFall = 1
var(15) = IfElse(var(15) < 2, 2, 3)
ignorehitpause = 1
persistent = 0

[State 1017, VarSet]
type = VarSet
triggerall = MoveHit
triggerall = NumTarget
triggerall = PrevStateNo = [2010,2012]
trigger1 = Target, HitFall = 1
var(15) = IfElse(var(15) < 1, 0, 3)
ignorehitpause = 1
persistent = 0

[State 1017, TargetState]
type = TargetState
triggerall = NumTarget(1017) || NumTarget(1018)
trigger1 = MoveHit
trigger1 = PrevStateNo = [2010,2012]
value = 51017
ID = Anim
ignorehitpause = 1
persistent = 0

[State 1017, StateTypeSet]
type = StateTypeSet
trigger1 = Anim = 1017
trigger1 = AnimElem = 11
trigger2 = Anim = 1018
trigger2 = AnimElem = 8
movetype = I

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

;---------------------------------------------------------------------------
; A Forbidden Eagle
[Statedef 1020]
type = S
movetype = A
physics = N				
velset = 0,0			
ctrl = 0				
anim = 1020				
poweradd = IfElse(var(31) = 0, 100, 0)		
sprpriority = 2			
facep2 = 1

[State 1020, Voice]
type = PlaySnd 
trigger1 = AnimElem = 1
value = S1020,0
channel = 0
ignorehitpause = 1

[State 1020, Drive Cancel]
type = VarAdd
triggerall = PrevStateNo = [1000,2999]
trigger1 = !Time
var(30) = IfElse(var(31) = 0, -500, -90)
ignorehitpause = 1
persistent = 0

[State 12000, Drive Cancel Helper]
type = Helper
triggerall = PrevStateNo = [1000,2999]
trigger1 = !Time
name = "Drive/HD Cancel"
ID = 12000
stateno = 12000
pos = 0,0
postype = p1  
facing = 1
keyctrl = 0
ownpal = 1

[State 1020, Helper]
type = Helper
trigger1 = AnimElem = 1
name = "Eagle Shield"
ID = 21020
stateno = 21020
pos = 0,0
postype = p1   
facing = 1
keyctrl = 0
ownpal = 0
supermovetime = 0
pausemovetime = 0

[State 1020, NotHitBy]
type = NotHitBy
trigger1 = AnimElemTime(5) < 0
value = , AA,AP

[State 1020, 1]
type = HitDef
triggerall = Var(15) < IfElse(var(31) = 0, 3, 4)
trigger1 = AnimElem = 5
attr = S, SA			
damage = floor(25*fvar(20)), 5
animtype = Medium			
guardflag = HA			
hitflag = MAF
priority = 5, Hit			
pausetime = 7,7	
sparkno = S10001
guard.sparkno = S10131				
sparkxy = -10, -75		
hitsound = S5, 1			
guardsound = S6, 1	
ground.type = High	
ground.slidetime = 20
ground.hittime = 20
guard.hittime = 17
ground.velocity = 0
air.velocity = -4.5,-7.5	
air.animtype = Back				
yaccel = 0.5
ground.cornerpush.veloff = 0
getpower = IfElse(!var(31), 50, 0), IfElse(!var(31), 50, 0)
givepower = 50
air.fall = 1
fall.recover = 0
persistent = 0

[State 1020, 2]
type = HitDef
triggerall = Var(15) < IfElse(var(31) = 0, 3, 4)
trigger1 = AnimElemTime(10) >= 0 && AnimElemTime(15) < 0
attr = S, SA			
damage = floor(65*fvar(20)), 25
animtype = Heavy			
guardflag = MA			
hitflag = MAF
priority = 5, Hit			
pausetime = 7,7	
sparkno = S10001
guard.sparkno = S10131				
sparkxy = -10, -75		
hitsound = S5, 5			
guardsound = S6, 1	
ground.type = High	
ground.slidetime = 20
ground.hittime = 20
guard.hittime = 17
ground.velocity = -2.5,-10.8
guard.velocity = -11.1796875
air.velocity = -2.5,-10.8
air.animtype = Back				
yaccel = 0.5
ground.cornerpush.veloff = 0
getpower = IfElse(!var(31), 50, 0), IfElse(!var(31), 50, 0)
givepower = 50
fall = 1
fall.recovertime = 30
id = 1020
persistent = 0

[State 1020, PosAdd]
type = PosAdd
trigger1 = AnimElem = 13
x = 8

[State 1020, VarSet]
type = VarSet
triggerall = MoveHit
triggerall = NumTarget(1020)
trigger1 = Target, HitFall = 1
var(15) = IfElse(var(15) < 2, 2, 3)
ignorehitpause = 1
persistent = 0

[State 1020, StateTypeSet]
type = StateTypeSet
trigger1 = AnimElem = 14
movetype = I

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

;---------------------------------------------------------------------------
; C Forbidden Eagle
[Statedef 1021]
type = S
movetype = A
physics = N				
velset = 0,0			
ctrl = 0				
anim = 1021				
poweradd = IfElse(var(31) = 0, 100, 0)		
sprpriority = 2			
facep2 = 1

[State 1021, Helper]
type = Helper
trigger1 = AnimElem = 1
name = "Eagle Shield"
ID = 21021
stateno = 21020
pos = 0,0
postype = p1   
facing = 1
keyctrl = 0
ownpal = 0
supermovetime = 0
pausemovetime = 0

[State 1021, NotHitBy]
type = NotHitBy
trigger1 = AnimElemTime(5) < 0
value = , AA,AP

[State 1021, Voice]
type = PlaySnd 
trigger1 = AnimElem = 6
value = S1020,0
channel = 0
ignorehitpause = 1

[State 1005, Drive Cancel]
type = VarAdd
triggerall = PrevStateNo = [1000,2999]
trigger1 = !Time
var(30) = IfElse(var(31) = 0, -500, -90)
ignorehitpause = 1
persistent = 0

[State 12000, Drive Cancel Helper]
type = Helper
triggerall = PrevStateNo = [1000,2999]
trigger1 = !Time
name = "Drive/HD Cancel"
ID = 12000
stateno = 12000
pos = 0,0
postype = p1  
facing = 1
keyctrl = 0
ownpal = 1

[State 1021, 1]
type = HitDef
triggerall = Var(15) < IfElse(var(31) = 0, 3, 4)
trigger1 = AnimElem = 7
attr = S, SA			
damage = floor(25*fvar(20)), 5
animtype = Medium			
guardflag = HA			
hitflag = MAF
priority = 5, Hit			
pausetime = 7,7	
sparkno = S10001
guard.sparkno = S10131				
sparkxy = -10, -75		
hitsound = S5, 1			
guardsound = S6, 1	
ground.type = High	
ground.slidetime = 20
ground.hittime = 20
guard.hittime = 17
ground.velocity = 0
air.velocity = -4.5,-7.5	
air.animtype = Back				
yaccel = 0.5
ground.cornerpush.veloff = 0
getpower = IfElse(!var(31), 50, 0), IfElse(!var(31), 50, 0)
givepower = 50
air.fall = 1
fall.recover = 0
persistent = 0

[State 1021, 2]
type = HitDef
triggerall = Var(15) < IfElse(var(31) = 0, 3, 4)
trigger1 = AnimElemTime(12) >= 0 && AnimElemTime(17) < 0
attr = S, SA			
damage = floor(75*fvar(20)), 35
animtype = Heavy			
guardflag = MA			
hitflag = MAF
priority = 5, Hit			
pausetime = 7,7
sparkno = S10001
guard.sparkno = S10131				
sparkxy = -10, -75		
hitsound = S5, 5			
guardsound = S6, 1	
ground.type = High	
ground.slidetime = 20
ground.hittime = 20
guard.hittime = 17
ground.velocity = -2.5,-10.8
guard.velocity = -11.1796875
air.velocity = -2.5,-10.8
air.animtype = Back				
yaccel = 0.5
ground.cornerpush.veloff = 0
getpower = IfElse(!var(31), 75, 0), IfElse(!var(31), 75, 0)
givepower = 75
fall = 1
fall.recovertime = 30
id = 1021
persistent = 0

[State 1021, PosAdd]
type = PosAdd
trigger1 = AnimElem = 15
x = 8

[State 1021, VarSet]
type = VarSet
triggerall = MoveHit
triggerall = NumTarget(1021)
trigger1 = Target, HitFall = 1
var(15) = IfElse(var(15) < 2, 2, 3)
ignorehitpause = 1
persistent = 0

[State 1021, StateTypeSet]
type = StateTypeSet
trigger1 = AnimElem = 16
movetype = I

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

;---------------------------------------------------------------------------
; Puncher Weaving
[Statedef 1030]
type = S
movetype = I
physics = N				
velset = 0,0			
ctrl = 0				
anim = 1030				
poweradd = IfElse(var(31) = 0, 100, 0)		
sprpriority = 2			
facep2 = 1

[State 1030, Voice]
type = PlaySnd 
trigger1 = AnimElem = 1
value = S1030,0
channel = 0
ignorehitpause = 1

[State 1030, Drive Cancel]
type = VarAdd
triggerall = (PrevStateNo = [1000,2999]) && (PrevStateNo != [1010,1013]) && (PrevStateNo != [2010,2014])
trigger1 = !Time
var(30) = IfElse(var(31) = 0, -500, -90)
ignorehitpause = 1
persistent = 0

[State 12000, Drive Cancel Helper]
type = Helper
triggerall = (PrevStateNo = [1000,2999]) && (PrevStateNo != [1010,1013]) && (PrevStateNo != [2010,2014])
trigger1 = !Time
name = "Drive/HD Cancel"
ID = 12000
stateno = 12000
pos = 0,0
postype = p1  
facing = 1
keyctrl = 0
ownpal = 1

[State 1030, VarSet]
type = VarSet
trigger1 = !time
var(2) = 0

[State 1030, VarSet]
type = VarSet
trigger1 = !time
var(4) = 0

[State 1030, VarSet]
type = VarSet
trigger1 = !time
var(4) = ifElse(Command = "x",0,ifElse(Command = "y",1,2))

[State 1030, VarSet]
type = VarSet
trigger1 = var(4) > 1
var(4) = ifElse(Command = "hold_x",0,ifElse(Command = "hold_y",1,0))

[State 1030, AfterImage]
type = AfterImage
trigger1 = Animelem = 2
time = 20
length = 4
framegap = 1
timegap = 6
trans = add1
palcontrast = 128,128,128
paladd = 0,0,0
palmul = 1,1,1

[State 1030, Afterimage]
type = AfterImageTime
trigger1 = AnimElemTime(27) < 0
time = 4

[State 1030, VarSet]
type = VarSet
trigger1 = AnimElemTime(1) > 1
trigger1 = command = "holdfwd" && command = "x" || command = "holdfwd" && command = "y"
var(2) = 1

[State 1030, VarSet]
type = VarSet
trigger1 = AnimElemTime(1) > 1
trigger1 = command = "holdback" && command = "x" || command = "holdback" && command = "y"
var(2) = 2

[State 1030, VarSet]
type = VarSet
trigger1 = AnimElemTime(1) > 1
trigger1 = command = "fwd_a" || command = "holdfwd" && command = "b"
var(2) = IfElse(command = "fwd_a", 3, 4)

[State 1030, VarSet]
type = VarSet
trigger1 = AnimElemTime(1) > 1
trigger1 = command = "holdback" && command = "a" || command = "holdback" && command = "b"
var(2) = IfElse(command = "holdback" && command = "a", 5, 6)

[State 1030, ChangeState]
type = ChangeState
triggerall = AnimElemTime(5) >= 0
trigger1 = var(2) = 1
value = 1031
ctrl = 0

[State 1030, ChangeState]
type = ChangeState
triggerall = AnimElemTime(5) >= 0
trigger1 = var(2) = 2
value = 1032
ctrl = 0

[State 1030, ChangeState]
type = ChangeState
triggerall = AnimElemTime(5) >= 0
trigger1 = var(2) = [3,4]
value = IfElse(var(2) = 3, 1010, 1011)
ctrl = 0

[State 1030, ChangeState]
type = ChangeState
triggerall = AnimElemTime(5) >= 0
trigger1 = var(2) = [5,6]
value = IfElse(var(2) = 5, 1012, 1013)
ctrl = 0

[State 1030, end]
type = ChangeState
triggerall = time > 14
trigger1 = command != "hold_x" && var(4)= 0
trigger2 = command != "hold_y" && var(4)= 1
value = 0
ctrl = 1

;---------------------------------------------------------------------------
; Puncher Upper
[Statedef 1031]
type = S
movetype = A
physics = N				
velset = 0,0			
ctrl = 0				
anim = 1031 + IfElse(PrevStateNo < 2000, 0, 1000)				
poweradd = IfElse(var(31) = 0, 100, 0)		
sprpriority = 2		

[State 1031, PosAdd]
type = PosAdd
trigger1 = Animelem = 3
x = 8

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

[State 1031, Whiffs]
type = PlaySnd 
trigger1 = AnimElem = 2
value = S5,8
channel = 1

[State 1031, 1]
type = HitDef
triggerall = IfElse(Var(31) = 0, var(15) < 3, var(15) < 4)
trigger1 = AnimElem = 3
attr = S, SA			
damage = floor(85*fvar(20)), 5
animtype = Heavy			
guardflag = MA			
hitflag = MAF
priority = 5, Hit			
pausetime = 11,11	
sparkno = S10001
guard.sparkno = S10131				
sparkxy = -10, -75		
hitsound = S5, 5			
guardsound = S6, 1	
ground.type = High	
ground.slidetime = 20
ground.hittime = 20
guard.hittime = 17
ground.velocity = -2.5,-10.8
air.velocity = -2.5,-10.8
air.animtype = Back				
yaccel = 0.5
ground.cornerpush.veloff = 0
getpower = IfElse(!var(31), 100, 0), IfElse(!var(31), 100, 0)
givepower = 100
fall = 1
fall.recovertime = 60

[State 1031, VarSet]
type = VarSet
triggerall = PrevStateNo < 2000
triggerall = MoveHit
triggerall = NumTarget
trigger1 = Target, HitFall = 1
var(15) = IfElse(var(15) < 2, 2, 3)
ignorehitpause = 1
persistent = 0 

[State 1031, VarSet]
type = VarSet
triggerall = PrevStateNo >= 2000
triggerall = MoveHit
triggerall = NumTarget
trigger1 = Target, HitFall = 1
var(15) = IfElse(var(15) < 1, 0, 3)
ignorehitpause = 1
persistent = 0

[State 1031, StateTypeSet]
type = StateTypeSet
trigger1 = AnimElem = 5
movetype = I

[State 1031, PosAdd]
type = PosAdd
trigger1 = Animelem = 11
x = -8

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

;---------------------------------------------------------------------------
; Parrying Puncher 1
[Statedef 1032]
type = S
movetype = I
physics = N				
velset = 0,0			
ctrl = 0				
anim = 1032				
poweradd = IfElse(var(31) = 0, 100, 0)		
sprpriority = 2			
hitcountpersist = 0

[State 1032, VarSet]
type = VarSet
trigger1 = PrevStateNo > 2000
var(3) = 1

[State 1032, ReversalDef]
type = ReversalDef
trigger1 = AnimElem = 2
reversal.attr = SCA,AA,AP 
pausetime = 0,0
sparkno = S10131
hitsound = S6,1
persistent = 0

[State 1032, Projectile Killer]
type = Helper
trigger1 = AnimElem = 2
name = "Parrying Puncher Shield"
ID = 21032
stateno = 21032
pos = 0,0
postype = p1  
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
persistent = 0

[State 1032, ChangeState]
type = ChangeState
trigger1 = AnimTime = 0
value = 1033
ctrl = 0

;---------------------------------------------------------------------------
; Parrying Puncher 2
[Statedef 1033]
type = S
movetype = A
physics = N				
velset = 0,0			
ctrl = 0				
anim = 1033				
poweradd = IfElse(var(31) = 0, 100, 0)		
sprpriority = 2	
hitcountpersist = 0

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

[State 1033, Whiffs]
type = PlaySnd 
trigger1 = AnimElem = 3
value = S5,8
channel = 1

[State 1033, ReversalDef]
type = ReversalDef
trigger1 = AnimElem = 4
reversal.attr = SCA,AA,AP 
pausetime = 0,0
sparkno = S10001
hitsound = S6,1
persistent = 0

[State 1033, Projectile Killer]
type = Helper
trigger1 = AnimElem = 4
name = "Parrying Puncher Shield"
ID = 21033
stateno = 21032
pos = 0,0
postype = p1  
facing = 1
keyctrl = 0
ownpal = 1
ignorehitpause = 1
persistent = 0

[State 1033, 1]
type = HitDef
triggerall = IfElse(Var(31) = 0, var(15) < 3, var(15) < 4)
trigger1 = AnimElem = 4
attr = S, SA			
damage = floor(85 + (IfElse(var(3) = 0, 0, 30))*fvar(20)), 5
animtype = Heavy			
guardflag = MA			
hitflag = MAF
priority = 5, Hit			
pausetime = 11,11	
sparkno = S10001
guard.sparkno = S10131				
sparkxy = -10, -75		
hitsound = S5, 5			
guardsound = S6, 1	
ground.type = High	
ground.slidetime = 20
ground.hittime = 20
guard.hittime = 17
ground.velocity = -4.5,-7.5
guard.velocity = -11.1796875
air.velocity = -4.5,-7.5
air.animtype = Back				
yaccel = 0.5
ground.cornerpush.veloff = 0
getpower = IfElse(!var(31), 100, 0), IfElse(!var(31), 100, 0)
givepower = 100
fall = 1
fall.recovertime = 60
id = 1033
p2facing = IfElse(P2StateNo < 51017, 0, 1)

[State 1033, TargetState]
type = TargetState
triggerall = NumTarget(1033)
trigger1 = MoveHit
trigger1 = Var(3) = 1
value = 51017
ID = StateNo
ignorehitpause = 1
persistent = 0

[State 1033, VarSet]
type = VarSet
triggerall = MoveHit
triggerall = NumTarget
trigger1 = Target, HitFall = 1
var(15) = IfElse(var(15) < 2, 2, 3)
ignorehitpause = 1
persistent = 0

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