Well here is my -2 state (There are two because i now have a second transformation):
Code
[Statedef -2]
[State -2]
type = ChangeAnim
trigger1 = Var(1) = 90
trigger1 = Anim < 10000
trigger1 = SelfAnimExist(Anim + 10000)
value = Anim + 10000
[State -2]
type = ChangeAnim
trigger1 = Var(2) = 50
trigger1 = Anim <= 20000
trigger1 = SelfAnimExist(Anim + 20000)
value = Anim + 20000
And my walking state(Also more changanims due to a second transformation)
Code
[Statedef 20]
type = S
physics = S
sprpriority = 0
[State 20, 1]
type = VelSet
triggerall = var(0) = 0
trigger1 = command = "holdfwd"
x = const(velocity.walk.fwd.x)
[State 20, 2]
type = VelSet
triggerall = var(0) = 0
trigger1 = command = "holdback"
x = const(velocity.walk.back.x)
[State 20, 1]
type = VelSet
triggerall = var(1) = 90
trigger1 = command = "holdfwd"
x = const(velocity.walk.fwd.x) + 1
[State 20, 2]
type = VelSet
triggerall = var(1) = 90
trigger1 = command = "holdback"
x = const(velocity.walk.back.x) - 1
[State 20, 3]
type = ChangeAnim
triggerall = var(0) = 0
triggerall = vel x > 0
trigger1 = Anim != 20 && Anim != 5
trigger2 = Anim = 5 && AnimTime = 0
value = 20
[State 20, 4]
type = ChangeAnim
triggerall = var(0) = 0
triggerall = vel x < 0
trigger1 = Anim != 21 && Anim != 5
trigger2 = Anim = 5 && AnimTime = 0
value = 21
[State 20, 3]
type = ChangeAnim
triggerall = var(1) = 90
triggerall = vel x > 0
trigger1 = Anim != 1020
value = 10020
[State 20, 4]
type = ChangeAnim
triggerall = var(1) = 90
triggerall = vel x < 0
trigger1 = Anim != 1021
value = 10021
[State 20, 3]
type = ChangeAnim
triggerall = var(2) = 50
triggerall = vel x > 0
trigger1 = Anim != 1020
value = 20020
[State 20, 4]
type = ChangeAnim
triggerall = var(2) = 50
triggerall = vel x < 0
trigger1 = Anim != 1021
value = 20021
[State 20020, 3]
type = ChangeAnim
triggerall = var(1) = 90
triggerall = vel x > 0
trigger1 = Anim != 20 && Anim != 5
trigger2 = Anim = 5 && AnimTime = 0
value = 10020
[State 20020, 4]
type = ChangeAnim
triggerall = var(1) = 90
triggerall = vel x < 0
trigger1 = Anim != 21 && Anim != 5
trigger2 = Anim = 5 && AnimTime = 0
value = 10021