;---------------------------------------------------------------------------
; Kunai - Straight
[Statedef 1001]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1001
poweradd = 30
sprpriority = 3

[State 1001, VarAdd]
type = VarAdd
trigger1 = var(20) < 200 && moveguarded
v = 20    ;fv =
value = 2
persistent = 1


[State 200, VarAdd]
type = VarAdd
trigger1 = var(20) >= 200 && movehit
v = 20    ;fv =
value = -200
persistent = 1

[State 0, HitOverride]
type = HitOverride
trigger1 = time = 0
attr = SCA,NA,SA,HA,NP,SP,HP
stateno = 1002
time = 9999


[State 0, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA,AT
time = 9999


[State 1001, VelSet]
type = VelSet
trigger1 = time = 0
x = 5+(random<500)

[State 1001, Hitdef]
type = hitdef
triggerall = enemynear, movetype != A
trigger1 = time = 0
attr = S, SP
damage   = 35, 5
animtype = medium
guardflag = MA
hitflag = MAF
pausetime = 10,10
hitsound   = s1000,1
sparkno = s9900
guard.sparkno = s9915
sparkxy = 35, -20
guardsound = s150,0
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
ground.velocity = -6
air.velocity = -4,-2
air.fall = 0
envshake.time = 2
envshake.ampl = 4
persistent = 1


[State 1001, Hitdef]
type = hitdef
triggerall = enemynear, movetype = A
trigger1 = time = 0
attr = S, SP
damage   = 45
animtype = medium
hitflag = MAF
pausetime = 10,15
hitsound   = s1000,1
sparkno = s9900
sparkxy = 35, -20
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
ground.velocity = -6
air.velocity = -4,-2
air.fall = 0
palfx.time = 10
palfx.mul = 256,256,256
palfx.sinadd = 0,0,0,0
palfx.add = 125,125,125
envshake.time = 6
envshake.ampl = 6
persistent = 1


[State 1001, Hitdef]
type = hitdef
Triggerall = enemynear, stateno = [130,155]
trigger1 = var(20) >= 200 && time = 0
attr = S, SP
damage   = 17, 2
animtype = medium
;guardflag = MA
hitflag = MAF
pausetime = 20,35
hitsound   = s150,10
sparkno = s9916
sparkxy = 35, -20
hitsound = s221, 0
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
ground.velocity = -6
air.velocity = -4,-2
palfx.time = 15
palfx.mul = 300,0,0
palfx.sinadd = 55,0,85,10
palfx.add = 0,0,0
envshake.time = 16
envshake.ampl = 8
persistent = 1

[State 1001, Blocked]
type = ChangeState
trigger1 = moveguarded ;|| movehit = 1 || enemynear, movetype = H
value = 1002

[State 1001, Connects]
type = ChangeState
trigger1 = movehit ;|| movehit = 1 || enemynear, movetype = H
value = 1003


[State 0, DestroySelf]
type = DestroySelf
trigger1 = FrontEdgeBodyDist <= -15 ;|| time = 80


;---------------------------------------------------------------------------
; Kunai - Misses
[Statedef 1002]
type    = S
physics = S
ctrl = 0
anim = 1004
sprpriority = 3

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


[State 0, StateTypeSet]
type = StateTypeSet
trigger1 = time = 2
statetype = A       ;S,A,C,L
physics = A         ;A,C,S,N

[State 0, StateTypeSet]
type = StateTypeSet
trigger1 = time = 30
statetype = A       ;S,A,C,L
physics = N         ;A,C,S,N


[State 1002, VelSet]
type = VelSet
trigger1 = time > 0 && time <= 20
x = -1.5
y = -3


[State 1002, DestroySelf]
type = DestroySelf
trigger1 = time = 40


;---------------------------------------------------------------------------
; Kunai - Hits
[Statedef 1003]
type    = S
movetype= A
physics = S
velset = 0,0
ctrl = 0
anim = 1003
sprpriority = 3

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

[State 1003, DestroySelf]
type = DestroySelf
trigger1 = animtime = 0
;ignorehitpause =
;persistent =

;---------------------------------------------------------------------------
; Jumonji Light Kunai
[Statedef 2101]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1014
poweradd = 0
sprpriority = 3

[State 2101, VarAdd]
type = VarAdd
trigger1 = var(20) < 175 && moveguarded
v = 20    ;fv =
value = 3
persistent = 1


[State 2101, VarAdd]
type = VarAdd
trigger1 = var(20) >= 175 && movehit
v = 20    ;fv =
value = -175
persistent = 1


[State 2101, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA, AT
time = 99999

[State 2101, VelSet]
type = VelSet
trigger1 = time > 0
x = 4
y = 4.1

[State 2101, Hitdef]
type = Hitdef
trigger1 = time = 0
attr = A, HP
damage   = 38, 10
getpower  = 0
priority = 6
animtype = heavy
guardflag = MA
hitflag = MAFPD
pausetime = 13,10
hitsound   = s1000,1
sparkno = s9920
guard.sparkno = s9915
sparkxy = 35, -20
guardsound = s150,0
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
air.hittime = 25
ground.velocity = -6
guard.velocity = -5
airguard.velocity = -5
air.velocity = -3,-4
air.fall = 1
fall.recover = 0
p2facing = 1
forcestand = 1
envshake.time = 7
envshake.ampl = 5

[State 2101, Guard Break]
type = Hitdef
Triggerall = enemynear, stateno = [130,155]
trigger1 = var(20) >= 175 && time = 0
attr = A, HP
damage   = 19, 5
getpower  = 0
priority = 6
animtype = heavy
;guardflag = MA
hitflag = MAFPD
pausetime = 20,35
hitsound = s221, 0
sparkno = s9916
sparkxy = 35, -20
ground.type = high
ground.slidetime = 10
ground.hittime  = 15
air.hittime = 15
ground.velocity = -6
guard.velocity = -5
air.velocity = -3,-3
fall.recover = 0
p2facing = 1
palfx.time = 15
palfx.mul = 300,0,0
palfx.sinadd = 55,0,85,10
palfx.add = 0,0,0
envshake.time = 16
envshake.ampl = 8
persistent = 1


[State 2101, HitOverride]
type = HitOverride
trigger1 = time = 0
attr = SCA,NA,SA,HA,NP,SP,HP
stateno = 1002
time = 9999


[State 2101, Blocked]
type = ChangeState
trigger1 = moveguarded || pos y >= -5;|| movehit = 1 || enemynear, movetype = H
value = 1002


;[State 2101, Connects]
;type = ChangeState
;trigger1 = movehit ;|| movehit = 1 || enemynear, movetype = H
;value = 1003


[State 2101, DestroySelf]
type = DestroySelf
trigger1 = FrontEdgeBodyDist <= -10 || movehit ;;|| time = 80

;---------------------------------------------------------------------------
;Air Jumonji Light Kunai
[Statedef 2201]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1014
poweradd = 0
sprpriority = 3

[State 2201, VarAdd]
type = VarAdd
trigger1 = var(20) < 175 && moveguarded
v = 20    ;fv =
value = 3
persistent = 1

[State 2201, VarAdd]
type = VarAdd
trigger1 = var(20) >= 175 && movehit
v = 20    ;fv =
value = -175
persistent = 1


[State 2201, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA, AT
time = 99999
;ignorehitpause =
;persistent =

[State 2201, VelSet]
type = VelSet
trigger1 = time > 0
x = 6
y = 6.1

[State 2201, Hitdef]
type = Hitdef
trigger1 = time = 0
attr = A, HP
damage   = 38, 10
getpower  = 0
priority = 6
animtype = heavy
guardflag = MA
hitflag = MAFPD
pausetime = 13,10
hitsound   = s1000,1
sparkno = s9920
guard.sparkno = s9915
sparkxy = 35, -20
guardsound = s150,0
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
air.hittime = 25
ground.velocity = -6
air.velocity = -3,-4
air.fall = 1
fall.recover = 0
p2facing = 1
forcestand = 1
Down.hit = 1
envshake.time = 7
envshake.ampl = 5

[State 2201, Guard Break]
type = Hitdef
Triggerall = enemynear, stateno = [130,155]
trigger1 = var(20) >= 175 && time = 0
attr = A, HP
damage   = 19, 5
getpower  = 0
priority = 6
animtype = heavy
hitflag = MA
pausetime = 20,35
hitsound   = s150,10
sparkno = s9916
sparkxy = 35, -20
hitsound = s221, 0
ground.type = high
ground.slidetime = 10
ground.hittime  = 15
air.hittime = 15
ground.velocity = -6
air.velocity = -3,-3
p2facing = 1
palfx.time = 15
palfx.mul = 300,0,0
palfx.sinadd = 55,0,85,10
palfx.add = 0,0,0
envshake.time = 16
envshake.ampl = 8
persistent = 1


[State 2201, HitOverride]
type = HitOverride
trigger1 = time = 0
attr = SCA,NA,SA,HA,NP,SP,HP
stateno = 1002
time = 9999


[State 2201, Blocked]
type = ChangeState
trigger1 = moveguarded || pos y >= -5;|| movehit = 1 || enemynear, movetype = H
value = 1002


[State 2201, DestroySelf]
type = DestroySelf
trigger1 = FrontEdgeBodyDist <= -10 || movehit ;;|| time = 80

;---------------------------------------------------------------------------
;Air Jumonji Med Kunai 1
[Statedef 2211]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1007
poweradd = 0
sprpriority = 3

[State 2201, VarAdd]
type = VarAdd
trigger1 = var(20) < 175 && moveguarded
v = 20    ;fv =
value = 3
persistent = 1


[State 2211, VarAdd]
type = VarAdd
trigger1 = var(20) >= 175 && movehit
v = 20    ;fv =
value = -175
persistent = 1


[State 2211, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA, AT
time = 99999

[State 2211, VelSet]
type = VelSet
trigger1 = time > 0
x = 3
y = 6.6

[State 2211, Hitdef]
type = Hitdef
trigger1 = time = 0
attr = A, HP
damage   = 50, 18
getpower  = 0
priority = 6
animtype = heavy
guardflag = MA
hitflag = MAFPD
pausetime = 10,8
hitsound   = s1000,1
sparkno = s9920
guard.sparkno = s9915
sparkxy = 35, -20
guardsound = s150,0
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
air.hittime = 25
ground.velocity = -6
air.velocity = -3, -3
Fall = 0
air.fall = 1
fall.recover = 0
p2facing = 1
Down.hit = 1
envshake.time = 10
envshake.ampl = 5


[State 2201, Guard Break]
type = Hitdef
Triggerall = enemynear, stateno = [130,155]
trigger1 = var(20) >= 175 && time = 0
attr = A, HP
damage   = 25, 9
getpower  = 0
priority = 6,hit
animtype = heavy
hitflag = MAFPD
pausetime = 20,35
hitsound = s221, 0
sparkno = s9916
sparkxy = 35, -20
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
air.hittime = 25
ground.velocity = -6
air.velocity = -3, -3
p2facing = 1
palfx.time = 15
palfx.mul = 300,0,0
palfx.sinadd = 55,0,85,10
palfx.add = 0,0,0
envshake.time = 16
envshake.ampl = 8
persistent = 1


[State 2201, HitOverride]
type = HitOverride
trigger1 = time = 0
attr = SCA,NA,SA,HA,NP,SP,HP
stateno = 1002
time = 9999


[State 2201, Blocked]
type = ChangeState
trigger1 = moveguarded || pos y >= -5;|| movehit = 1 || enemynear, movetype = H
value = 1002


[State 2201, DestroySelf]
type = DestroySelf
trigger1 = FrontEdgeBodyDist <= -10 || movehit;;|| time = 80

;---------------------------------------------------------------------------
;Air Jumonji Med Kunai 2
[Statedef 2212]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1014
poweradd = 0
sprpriority = 3

[State 2212, VarAdd]
type = VarAdd
trigger1 = var(20) < 175 && moveguarded
v = 20    ;fv =
value = 3
persistent = 1


[State 2212, VarAdd]
type = VarAdd
trigger1 = var(20) >= 175 && movehit
v = 20    ;fv =
value = -175
persistent = 1


[State 2212, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA, AT
time = 99999
;ignorehitpause =
;persistent =

[State 2212, VelSet]
type = VelSet
trigger1 = time > 0
x = 4.3
y = 5

[State 2212, Hitdef]
type = Hitdef
trigger1 = time = 0
attr = A, HP
damage   = 50, 18
getpower  = 0
priority = 6
animtype = heavy
guardflag = MA
hitflag = MAFPD
pausetime = 10,8
hitsound   = s1000,1
sparkno = s9920
guard.sparkno = s9915
sparkxy = 35, -20
guardsound = s150,0
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
air.hittime = 25
ground.velocity = 0
air.velocity = 0, -3
Fall = 0
air.fall = 1
fall.recover = 0
p2facing = 1
Down.hit = 1
envshake.time = 10
envshake.ampl = 5


[State 2212, Guard Break]
type = Hitdef
Triggerall = enemynear, stateno = [130,155]
trigger1 = var(20) >= 175 && time = 0
attr = A, HP
damage   = 25, 9
getpower  = 0
priority = 6,hit
animtype = heavy
hitflag = MAFPD
pausetime = 20,35
hitsound = s221, 0
sparkno = s9916
sparkxy = 35, -20
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
air.hittime = 25
ground.velocity = 0
air.velocity = 0, -5
p2facing = 1
palfx.time = 15
palfx.mul = 300,0,0
palfx.sinadd = 55,0,85,10
palfx.add = 0,0,0
envshake.time = 16
envshake.ampl = 8
persistent = 1

[State 2212, HitOverride]
type = HitOverride
trigger1 = time = 0
attr = SCA,NA,SA,HA,NP,SP,HP
stateno = 1002
time = 9999


[State 2212, Blocked]
type = ChangeState
trigger1 = moveguarded || pos y >= -5;|| movehit = 1 || enemynear, movetype = H
value = 1002


[State 2212, DestroySelf]
type = DestroySelf
trigger1 = FrontEdgeBodyDist <= -10 || movehit;;|| time = 80


;---------------------------------------------------------------------------
;Air Jumonji Med Kunai 3
[Statedef 2213]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1010
poweradd = 0
sprpriority = 3

[State 2213, VarAdd]
type = VarAdd
trigger1 = var(20) < 175 && moveguarded
v = 20    ;fv =
value = 3
persistent = 1


[State 2213, VarAdd]
type = VarAdd
trigger1 = var(20) >= 175 && movehit
v = 20    ;fv =
value = -175
persistent = 1


[State 2213, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA, AT
time = 99999
;ignorehitpause =
;persistent =

[State 2213, VelSet]
type = VelSet
trigger1 = time > 0
x = 6
y = 3

[State 2213, Hitdef]
type = Hitdef
trigger1 = time = 0
attr = A, HP
damage   = 50, 18
getpower  = 0
priority = 6
animtype = heavy
guardflag = MA
hitflag = MAFPD
pausetime = 10,8
hitsound   = s1000,1
sparkno = s9920
guard.sparkno = s9915
sparkxy = 35, -20
guardsound = s150,0
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
air.hittime = 25
ground.velocity = 6
air.velocity = 3, -3
Fall = 0
air.fall = 1
fall.recover = 0
p2facing = 1
Down.hit = 1
envshake.time = 10
envshake.ampl = 5


[State 2213, Guard Break]
type = Hitdef
Triggerall = enemynear, stateno = [130,155]
trigger1 = var(20) >= 175 && time = 0
attr = A, HP
damage   = 25, 9
getpower  = 0
priority = 6,hit
animtype = heavy
hitflag = MAFPD
pausetime = 20,35
hitsound = s221, 0
sparkno = s9916
sparkxy = 35, -20
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
air.hittime = 25
ground.velocity = 6
air.velocity = 3, -5
p2facing = 1
palfx.time = 15
palfx.mul = 300,0,0
palfx.sinadd = 55,0,85,10
palfx.add = 0,0,0
envshake.time = 16
envshake.ampl = 8
persistent = 1


[State 2213, HitOverride]
type = HitOverride
trigger1 = time = 0
attr = SCA,NA,SA,HA,NP,SP,HP
stateno = 1002
time = 9999


[State 2213, Blocked]
type = ChangeState
trigger1 = moveguarded || pos y >= -5;|| movehit = 1 || enemynear, movetype = H
value = 1002


[State 2213, DestroySelf]
type = DestroySelf
trigger1 = FrontEdgeBodyDist <= -10 || movehit ;|| time = 80

;---------------------------------------------------------------------------
;Air Jumonji Heavy Kunai
[Statedef 2206]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1001
poweradd = 0
sprpriority = 3

[State 2206, VarAdd]
type = VarAdd
trigger1 = var(20) < 175 && movecontact;moveguarded
v = 20    ;fv =
value = 3
persistent = 1


[State 2206, VarAdd]
type = VarAdd
trigger1 = var(20) >= 175 && movehit
v = 20    ;fv =
value = -175
persistent = 1


[State 2206, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA, AT
time = 99999
;ignorehitpause =
;persistent =

[State 2206, VelSet]
type = VelSet
trigger1 = time > 0
x = 7.5
y = 0

[State 2206, Hitdef]
type = Hitdef
trigger1 = time = 0
attr = A, HP
damage   = 50, 19
getpower  = 0
priority = 6
animtype = heavy
guardflag = MA
hitflag = MAFP
pausetime = 10,10
hitsound   = s1000,1
sparkno = s9920
guard.sparkno = s9915
sparkxy = 35, -20
guardsound = s150,0
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
ground.velocity = -6, -4
air.velocity = -3,-5
sparkno = s9920
guard.sparkno = s9915
;air.juggle = 7
air.fall = 1
fall.recover = 0
p2facing = 1
;forcestand = 1
envshake.time = 10
envshake.ampl = 5


[State 2201, Guard Break]
type = Hitdef
Triggerall = enemynear, stateno = [130,155]
trigger1 = var(20) >= 175 && time = 0
attr = A, HP
damage   = 25, 9
getpower  = 0
priority = 6,hit
animtype = heavy
hitflag = MAFPD
pausetime = 20,35
hitsound = s221, 0
sparkno = s9916
sparkxy = 35, -20
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
air.hittime = 25
ground.velocity = -6
air.velocity = -3, -3
p2facing = 1
palfx.time = 15
palfx.mul = 300,0,0
palfx.sinadd = 55,0,85,10
palfx.add = 0,0,0
envshake.time = 16
envshake.ampl = 8
persistent = 1


[State 2206, HitOverride]
type = HitOverride
trigger1 = time = 0
attr = SCA,NA,SA,HA,NP,SP,HP
stateno = 1002
time = 9999


[State 2206, Blocked]
type = ChangeState
trigger1 = moveguarded ;|| movehit = 1 || enemynear, movetype = H
value = 1002


[State 2206, DestroySelf]
type = DestroySelf
trigger1 = FrontEdgeBodyDist <= -10 || movehit || pos y >= -10;;|| time = 80


;---------------------------------------------------------------------------
; Jumonji Heavy Kunai #1
[Statedef 2901]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1001
poweradd = 30
sprpriority = 3

[State 0, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA
time = 99999
;ignorehitpause =
;persistent =

[State 1001, VelSet]
type = VelSet
trigger1 = time = 0
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 5
x = -3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 10
x = -3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 15
x = 3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 20
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 25
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 30
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 35
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 40
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 45
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 50
x = -3
y = -12




[State 1001, VelSet]
type = VelSet
trigger1 = time = 55
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 60
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 65
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 70
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 75
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 80
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 85
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 90
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 95
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 100
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 105
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 110
x = -3
y = -12


[State 1001, Shoot]
type = ChangeState
triggerall = time > 0 && time < 110
trigger1 = parent, anim = 2111 && Parent,stateno = 2111
trigger2 = parent, movetype = H
value = 2910
ctrl = 0

[State 1001, Shoot]
type = ChangeState
trigger1 = time = 110
value = 2910
ctrl = 0



;---------------------------------------------------------------------------
; Jumonji Heavy Kunai #2
[Statedef 2902]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1001
poweradd = 30
sprpriority = 3

[State 0, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA
time = 99999
;ignorehitpause =
;persistent =



[State 1001, VelSet]
type = VelSet
trigger1 = time = 0
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 5
x = -3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 10
x = -3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 15
x = 3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 20
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 25
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 30
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 35
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 40
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 45
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 50
x = -3
y = -12




[State 1001, VelSet]
type = VelSet
trigger1 = time = 55
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 60
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 65
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 70
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 75
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 80
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 85
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 90
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 95
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 100
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 105
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 110
x = -3
y = -12


[State 1001, Shoot]
type = ChangeState
triggerall = time > 5 && time < 110
trigger1 = parent, anim = 2111 && Parent,stateno = 2111
trigger2 = parent, movetype = H
value = 2910
ctrl = 0

[State 1001, Shoot]
type = ChangeState
trigger1 = time = 110
value = 2910
ctrl = 0




;---------------------------------------------------------------------------
; Jumonji Heavy Kunai #3
[Statedef 2903]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1001
poweradd = 30
sprpriority = 3

[State 0, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA
time = 99999
;ignorehitpause =
;persistent =



[State 1001, VelSet]
type = VelSet
trigger1 = time = 0
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 5
x = -3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 10
x = -3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 15
x = 3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 20
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 25
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 30
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 35
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 40
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 45
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 50
x = -3
y = -12




[State 1001, VelSet]
type = VelSet
trigger1 = time = 55
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 60
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 65
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 70
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 75
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 80
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 85
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 90
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 95
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 100
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 105
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 110
x = -3
y = -12


[State 1001, Shoot]
type = ChangeState
triggerall = time > 10 && time < 110
trigger1 = parent, anim = 2111 && Parent,stateno = 2111
trigger2 = parent, movetype = H
value = 2910
ctrl = 0

[State 1001, Shoot]
type = ChangeState
trigger1 = time = 110
value = 2910
ctrl = 0


;--------------------------------------------------------------------------
; Jumonji Heavy Kunai #4
[Statedef 2904]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1001
poweradd = 30
sprpriority = 3

[State 0, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA
time = 99999
;ignorehitpause =
;persistent =



[State 1001, VelSet]
type = VelSet
trigger1 = time = 0
x = -3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 5
x = 3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 10
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 15
x = -3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 20
x = -3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 25
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 30
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 35
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 40
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 45
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 50
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 55
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 60
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 65
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 70
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 75
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 80
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 85
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 90
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 95
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 100
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 105
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 110
x = -3
y = -12


[State 1001, Shoot]
type = ChangeState
triggerall = time > 0 && time < 110
trigger1 = parent, anim = 2111 && Parent,stateno = 2111
trigger2 = parent, movetype = H
value = 2910
ctrl = 0

[State 1001, Shoot]
type = ChangeState
trigger1 = time = 110
value = 2910
ctrl = 0


;--------------------------------------------------------------------------
; Jumonji Heavy Kunai #5
[Statedef 2905]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1001
poweradd = 30
sprpriority = 3

[State 0, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA
time = 99999
;ignorehitpause =
;persistent =



[State 1001, VelSet]
type = VelSet
trigger1 = time = 0
x = -3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 5
x = 3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 10
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 15
x = -3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 20
x = -3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 25
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 30
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 35
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 40
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 45
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 50
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 55
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 60
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 65
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 70
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 75
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 80
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 85
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 90
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 95
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 100
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 105
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 110
x = -3
y = -12


[State 1001, Shoot]
type = ChangeState
triggerall = time > 5 && time < 110
trigger1 = parent, anim = 2111 && Parent,stateno = 2111
trigger2 = parent, movetype = H
value = 2910
ctrl = 0

[State 1001, Shoot]
type = ChangeState
trigger1 = time = 110
value = 2910
ctrl = 0


;--------------------------------------------------------------------------
; Jumonji Kunai #6
[Statedef 2906]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1001
poweradd = 30
sprpriority = 3

[State 0, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA
time = 99999
;ignorehitpause =
;persistent =



[State 1001, VelSet]
type = VelSet
trigger1 = time = 0
x = -3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 5
x = 3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 10
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 15
x = -3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 20
x = -3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 25
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 30
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 35
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 40
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 45
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 50
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 55
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 60
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 65
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 70
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 75
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 80
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 85
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 90
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 95
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 100
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 105
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 110
x = -3
y = -12


[State 1001, Shoot]
type = ChangeState
triggerall = time > 10 && time < 110
trigger1 = parent, anim = 2111 && Parent,stateno = 2111
trigger2 = parent, movetype = H
value = 2910
ctrl = 0

[State 1001, Shoot]
type = ChangeState
trigger1 = time = 110
value = 2910
ctrl = 0

;--------------------------------------------------------------------------
; Jumonji Kunai #7
[Statedef 2907]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1001
poweradd = 30
sprpriority = 3

[State 0, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA
time = 99999
;ignorehitpause =
;persistent =

[State 1001, VelSet]
type = VelSet
trigger1 = time = 0
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 5
x = -3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 10
x = -3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 15
x = 3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 20
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 25
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 30
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 35
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 40
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 45
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 50
x = -3
y = -12




[State 1001, VelSet]
type = VelSet
trigger1 = time = 55
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 60
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 65
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 70
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 75
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 80
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 85
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 90
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 95
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 100
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 105
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 110
x = -3
y = -12


[State 1001, Shoot]
type = ChangeState
triggerall = time > 15 && time < 110
trigger1 = parent, anim = 2111 && Parent,stateno = 2111
trigger2 = parent, movetype = H
value = 2910
ctrl = 0

[State 1001, Shoot]
type = ChangeState
trigger1 = time = 110
value = 2910
ctrl = 0

;--------------------------------------------------------------------------
; Jumonji Kunai #8
[Statedef 2908]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1001
poweradd = 30
sprpriority = 3

[State 0, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA
time = 99999
;ignorehitpause =
;persistent =



[State 1001, VelSet]
type = VelSet
trigger1 = time = 0
x = -3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 5
x = 3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 10
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 15
x = -3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 20
x = -3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 25
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 30
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 35
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 40
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 45
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 50
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 55
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 60
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 65
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 70
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 75
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 80
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 85
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 90
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 95
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 100
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 105
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 110
x = -3
y = -12


[State 1001, Shoot]
type = ChangeState
triggerall = time > 15 && time < 110
trigger1 = parent, anim = 2111 && Parent,stateno = 2111
trigger2 = parent, movetype = H
value = 2910
ctrl = 0

[State 1001, Shoot]
type = ChangeState
trigger1 = time = 110
value = 2910
ctrl = 0

;--------------------------------------------------------------------------
; Jumonji Kunai #9
[Statedef 2909]
type    = S
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1001
poweradd = 30
sprpriority = 3

[State 0, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA
time = 99999
;ignorehitpause =
;persistent =

[State 1001, VelSet]
type = VelSet
trigger1 = time = 0
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 5
x = -3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 10
x = -3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 15
x = 3
y = -12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 20
x = 3
y = 12


[State 1001, VelSet]
type = VelSet
trigger1 = time = 25
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 30
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 35
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 40
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 45
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 50
x = -3
y = -12




[State 1001, VelSet]
type = VelSet
trigger1 = time = 55
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 60
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 65
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 70
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 75
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 80
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 85
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 90
x = -3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 95
x = 3
y = -12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 100
x = 3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 105
x = -3
y = 12

[State 1001, VelSet]
type = VelSet
trigger1 = time = 110
x = -3
y = -12


[State 1001, Shoot]
type = ChangeState
triggerall = time > 20 && time < 110
trigger1 = parent, anim = 2111 && Parent,stateno = 2111
trigger2 = parent, movetype = H
value = 2910
ctrl = 0

[State 1001, Shoot]
type = ChangeState
trigger1 = time = 110
value = 2910
ctrl = 0


;---------------------------------------------------------------------------
; Jumonji Kunai Flight
[Statedef 2910]
type    = S
movetype= A
physics = N
juggle  = 0
velset = 0,0
ctrl = 0
anim = 1001
sprpriority = 3

[State 2910, VarAdd]
type = VarAdd
trigger1 = var(20) < 175 && moveguarded
v = 20    ;fv =
value = 3
persistent = 1

[State 2910, VarAdd]
type = VarAdd
trigger1 = var(20) >= 175 && movehit
v = 20    ;fv =
value = -175
persistent = 1

[State 2910, Hitdef]
type = hitdef
trigger1 =  prevstateno = 2901 && time = 0
trigger2 =  prevstateno = 2902 && time = 0
trigger3 =  prevstateno = 2903 && time = 0
trigger4 =  prevstateno = 2904 && time = 0
trigger5 =  prevstateno = 2905 && time = 0
trigger6 =  prevstateno = 2906 && time = 0
trigger7 =  prevstateno = 2907 && time = 0
trigger8 =  prevstateno = 2908 && time = 0
trigger9 =  prevstateno = 2909 && time = 0
attr = S, HP
damage   = 48, 18
getpower  = 0
priority = 6, hit
animtype = heavy
guardflag = MA
hitflag = MAFP
pausetime = 10,10
hitsound   = s1000,1
sparkno = s9920
guard.sparkno = s9915
sparkxy = 35, -20
guardsound = s150,0
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
air.hittime = 25
ground.velocity = -5
air.velocity = -3,-3.5
air.fall = 1
fall.recover = 0
p2facing = 1
forcestand = 1
envshake.time = 7
envshake.ampl = 5

[State 2910, Hitdef]
type = hitdef
Triggerall = enemynear, stateno = [130,155]
trigger1 = var(20) >= 175 && prevstateno = 2901 && time = 0
trigger2 = var(20) >= 175 && prevstateno = 2902 && time = 0
trigger3 = var(20) >= 175 && prevstateno = 2903 && time = 0
trigger4 = var(20) >= 175 && prevstateno = 2904 && time = 0
trigger5 = var(20) >= 175 && prevstateno = 2905 && time = 0
trigger6 = var(20) >= 175 && prevstateno = 2906 && time = 0
trigger7 = var(20) >= 175 && prevstateno = 2907 && time = 0
trigger8 = var(20) >= 175 && prevstateno = 2908 && time = 0
trigger9 = var(20) >= 175 && prevstateno = 2909 && time = 0
attr = S, HP
damage   = 24, 9
getpower  = 0
priority = 6, hit
animtype = heavy
;guardflag = MA
hitflag = MAFP
pausetime = 10,25
hitsound = s221, 0
sparkno = s9916
;guard.sparkno = s9915
sparkxy = 35, -20
guardsound = s150,10
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
air.hittime = 25
ground.velocity = -5
air.velocity = -3,-3.5
p2facing = 1
forcestand = 1
palfx.time = 15
palfx.mul = 300,0,0
palfx.sinadd = 55,0,85,10
palfx.add = 0,0,0
envshake.time = 16
envshake.ampl = 8
persistent = 1

[State 2125, Kunai Sounds]
type = PlaySnd
trigger1 = prevstateno = 2901 && time = 0
trigger2 = prevstateno = 2902 && time = 8
trigger3 = prevstateno = 2903 && time = 16
trigger4 = prevstateno = 2904 && time = 24
trigger5 = prevstateno = 2905 && time = 32
trigger6 = prevstateno = 2906 && time = 40
trigger7 = prevstateno = 2907 && time = 48
trigger8 = prevstateno = 2908 && time = 56
trigger9 = prevstateno = 2909 && time = 64
value = 1000, 5


[State 0, VelSet]
type = VelSet
Triggerall = prevstateno = 2901
trigger1 = time > 0 ;time > 0
x = 9
;ignorehitpause =
;persistent =

[State 0, VelSet]
type = VelSet
Triggerall = prevstateno = 2902
trigger1 = time > 8 ;time > 0
x = 9
;ignorehitpause =
;persistent =

[State 0, VelSet]
type = VelSet
Triggerall = prevstateno = 2903
trigger1 = time > 16 ;time > 0
x = 9
;ignorehitpause =
;persistent =

[State 0, VelSet]
type = VelSet
Triggerall = prevstateno = 2904
trigger1 = time > 24 ;time > 0
x = 9
;ignorehitpause =
;persistent =


[State 0, VelSet]
type = VelSet
Triggerall = prevstateno = 2905
trigger1 = time > 32 ;time > 0
x = 9
;ignorehitpause =
;persistent =

[State 0, VelSet]
type = VelSet
Triggerall = prevstateno = 2906
trigger1 = time > 40 ;time > 0
x = 9
;ignorehitpause =
;persistent =


[State 0, VelSet]
type = VelSet
Triggerall = prevstateno = 2907
trigger1 = time > 48 ;time > 0
x = 9
;ignorehitpause =
;persistent =

[State 0, VelSet]
type = VelSet
Triggerall = prevstateno = 2908
trigger1 = time > 56 ;time > 0
x = 9
;ignorehitpause =
;persistent =

[State 0, VelSet]
type = VelSet
Triggerall = prevstateno = 2909
trigger1 = time > 64 ;time > 0
x = 9
;ignorehitpause =
;persistent =


[State 0, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA,AT
time = 9999


[State 1001, Blocked]
type = ChangeState
trigger1 = moveguarded ;|| movehit = 1 || enemynear, movetype = H
value = 1002


[State 0, Remove]
type = Destroyself
trigger1 = movecontact || FrontEdgeBodyDist <= -10
;anim =
;ignorehitpause =
;persistent =

;---------------------------------------------------------------------------
; Jumonji Medium Kunai
[Statedef 2951]
type    = A
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1001
poweradd = 30
sprpriority = 3

[State 2951, VarAdd]
type = VarAdd
trigger1 = var(20) < 175 && moveguarded
v = 20    ;fv =
value = 3


[State 2951, VarAdd]
type = VarAdd
trigger1 = var(20) >= 175 && movehit
v = 20    ;fv =
value = -175


[State 2951, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA,AT
time = 9999


[State 2951, Blocked]
type = ChangeState
trigger1 = moveguarded ;|| movehit = 1 || enemynear, movetype = H
value = 1002


[State 2951, PosSet]
type = Posadd
trigger1 = time > 0;!time
x = 7
;y = -1

;[State 2951, VelSet]
;type = Posadd
;trigger1 = enemynear, statetype = A
;y = -2


[State 2951, VelAdd]
type = posAdd
;Triggerall = enemynear, statetype = A
trigger1 = enemynear, Pos Y > Pos Y && pos y > 0; && p2dist x <= -80 ;&& vel y < 6; Pos Y > Pos Y); && (Vel Y < 6)
y = 0.4

[State 2951, VelAdd]
type = posAdd
trigger1 = enemynear, Pos Y < Pos Y && Pos y > 0 ;&& vel y > -6; Pos Y > Pos Y); && (Vel Y < 6)
y = -0.4


[State 2951, VelAdd]
type = posAdd
trigger1 = pos y >= 15
y = 0

[State 2951, PosAdd]
type = PosAdd
trigger1 = (P2Dist X < 60) ;&& (p2dist y < -40); Enemynear, statetype = A && (P2Dist X < 60) && (p2dist y < -80)
x = -0.5


[State 2951, VelAdd]
type = PosAdd
trigger1 = (P2Dist X < 20) ;&& (p2dist y < -80);Enemynear, statetype = A && (P2Dist X < 60) && (p2dist y < -80)
x = -1


[State 0, ChangeAnim]
type = ChangeAnim
Triggerall = p2dist x < 60
trigger1 = vel y < -1
value = 1022

[State 1001, VelSet]
type = VelSet
trigger1 = p2dist x < 0
x = 6
y = vel y


[State 2910, Hitdef]
type = hitdef
trigger1 =time = 0
attr = A, HP
damage   = 60, 16
getpower  = 0
priority = 6
animtype = hard
guardflag = MA
hitflag = MAFDP
pausetime = 10,10
hitsound   = s1000,1
sparkno = s9920
guard.sparkno = s9915
sparkxy = 35, -20
guardsound = s150,0
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
air.hittime = 25
ground.velocity = -3,-6
air.velocity = -3,-5
fall = 1
air.fall = 1
fall.recover = 0
p2facing = 1
down.hit = 1
forcestand = 1
envshake.time = 7
envshake.ampl = 5

[State 2910, Hitdef]
type = hitdef
Triggerall = enemynear, stateno = [130,155]
trigger1 = var(20) >= 175 && time = 0
attr = A, HP
damage   = 30, 8
getpower  = 0
priority = 6, hit
animtype = hard
;guardflag = MA
hitflag = MAFDP
pausetime = 10,25
hitsound   = s150,10
sparkno = s9916
;guard.sparkno = s9915
sparkxy = 35, -20
hitsound = s221, 0
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
air.hittime = 25
ground.velocity = -3
air.velocity = -3,-5
p2facing = 1
forcestand = 1
Down.hit = 1
palfx.time = 15
palfx.mul = 300,0,0
palfx.sinadd = 55,0,85,10
palfx.add = 0,0,0
envshake.time = 16
envshake.ampl = 8
persistent = 1

[State 0, DestroySelf]
type = DestroySelf
trigger1 = movecontact || pos y >= -5 || FrontEdgeBodyDist <= -10


;---------------------------------------------------------------------------
; Jumonji Medium Kunai 2
[Statedef 2952]
type    = A
movetype= A
physics = N
juggle  = 1
velset = 0,0
ctrl = 0
anim = 1005;1001
poweradd = 30
sprpriority = 3

[State 2952, VarAdd]
type = VarAdd
trigger1 = var(20) < 175 && moveguarded
v = 20    ;fv =
value = 3

[State 2952, VarAdd]
type = VarAdd
trigger1 = var(20) >= 175 && movehit
v = 20    ;fv =
value = -175


[State 0, NotHitBy]
type = NotHitBy
trigger1 = 1
value = SCA,AT
time = 9999


[State 1001, Blocked]
type = ChangeState
trigger1 = moveguarded  || pos y >=-5;|| movehit = 1 || enemynear, movetype = H
value = 1002



[State 0, ChangeAnim]
type = ChangeAnim
trigger1 = time = 12
value = 1001


[State 0, ChangeAnim]
type = ChangeAnim
trigger1 = time = 20
value = 1014



[State 0, ChangeAnim]
type = ChangeAnim
Triggerall = p2dist x < 60
trigger1 = p2dist y >= -70 && p2dist y < 0
value = 1001

[State 0, ChangeAnim]
type = ChangeAnim
Triggerall = p2dist x < 60
trigger1 = p2dist y < -70
value = 1014

[State 2952, PosAdd]
type = PosAdd
trigger1 = time > 0 ;!time
x = 6
y = -7


[State 2952, VelAdd]
type = VelAdd
trigger1 = enemynear, Pos Y > Pos Y  ; && p2dist x <= -80 ;&& vel y < 6; Pos Y > Pos Y); && (Vel Y < 6)
y = 0.4

[State 2952, VelAdd]
type = VelAdd
trigger1 = enemynear, Pos Y < Pos Y ;&& vel y > -6; Pos Y > Pos Y); && (Vel Y < 6)
y = -0.4

[State 2951, PosAdd]
type = PosAdd
trigger1 = (P2Dist X < 60) ;&& (p2dist y < -40); Enemynear, statetype = A && (P2Dist X < 60) && (p2dist y < -80)
x = -1


[State 2951, VelAdd]
type = PosAdd
trigger1 = (P2Dist X < 20) ;&& (p2dist y < -80);Enemynear, statetype = A && (P2Dist X < 60) && (p2dist y < -80)
x = -2


[State 1001, VelSet]
type = VelSet
trigger1 = p2dist x < 0
x = ifelse((p2dist x<-20),0,1.5)
y = vel y

[State 0, ChangeAnim]
type = ChangeAnim
trigger1 = p2dist x < 0
trigger1 = time = 0
value = ifelse((pos x > enemynear, pos x),1002,1007)


[State 2910, Hitdef]
type = hitdef
trigger1 =time = 0
attr = S, HP
damage   = 60, 16
getpower  = 0
priority = 6
animtype = hard
guardflag = MA
hitflag = MAFD
pausetime = 10,10
hitsound   = s1000,1
sparkno = s9920
guard.sparkno = s9915
sparkxy = 35, -20
guardsound = s150,0
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
air.hittime = 25
ground.velocity = -3,-6
air.velocity = -3,-5
fall = 1
air.fall = 1
fall.recover = 0
p2facing = 1
down.hit = 1
forcestand = 1
envshake.time = 7
envshake.ampl = 5

[State 2910, Hitdef]
type = hitdef
Triggerall = enemynear, stateno = [130,155]
trigger1 = var(20) >= 175 && time = 0
attr = S, HP
damage   = 30, 8
getpower  = 0
priority = 6, hit
animtype = hard
;guardflag = MA
hitflag = MAFD
pausetime = 10,25
hitsound = s221, 0
sparkno = s9916
;guard.sparkno = s9915
sparkxy = 35, -20
guardsound = s150,0
ground.type = high
ground.slidetime = 25
ground.hittime  = 25
air.hittime = 25
ground.velocity = -3
air.velocity = -3,-5
p2facing = 1
forcestand = 1
Down.hit = 1
palfx.time = 15
palfx.mul = 300,0,0
palfx.sinadd = 55,0,85,10
palfx.add = 0,0,0
envshake.time = 16
envshake.ampl = 8
persistent = 1

[State 0, DestroySelf]
type = DestroySelf
trigger1 = movecontact || FrontEdgeBodyDist <= -10



