I was trying to implement a cornerpush system for my own in a WIP, using the minimal set of variables possible... Just for the challenge.
First of all, put this line in every hitdef:
ground.cornerpush.veloff = 0
Just this line is really necessary, for more information just click in this spoiler \/
Spoiler, click to toggle visibilty
HitDef (SCTRLs):
ground.cornerpush.veloff = x_velocity (float) Determines the additional velocity (velocity offset) to impart to the player if he lands a ground hit in the corner. Setting this to a higher value will cause the player to be "pushed back" farther out of the corner. If omitted, default value depends on the attr parameter. If arg1 of attr is "A", default value is 0. Otherwise, defaults to 1.3 * guard.velocity.
air.cornerpush.veloff = x_velocity (float) Determines the additional velocity (velocity offset) to impart to the player if he lands a hit to an aerial opponent in the corner. Setting this to a higher value will cause the player to be "pushed back" farther out of the corner. Defaults to ground.cornerpush.veloff if omitted.
down.cornerpush.veloff = x_velocity (float) Determines the additional velocity (velocity offset) to impart to the player if he lands a hit on a downed opponent in the corner. Setting this to a higher value will cause the player to be "pushed back" farther out of the corner. Defaults to ground.cornerpush.veloff if omitted.
guard.cornerpush.veloff = x_velocity (float) Determines the additional velocity (velocity offset) to impart to the player if his hit is guarded in the corner. Setting this to a higher value will cause the player to be "pushed back" farther out of the corner. Defaults to ground.cornerpush.veloff if omitted.
airguard.cornerpush.veloff = x_velocity (float) Determines the additional velocity (velocity offset) to impart to the player if his hit is guarded in the corner. Setting this to a higher value will cause the player to be "pushed back" farther out of the corner. Defaults to guard.cornerpush.veloff if omitted.
This goes before any Pause or SuperPause SCTRL (generally on Super states):
[State 3000, Explod]
type = Explod
trigger1 = *SAME_CONDITIONS*
anim = *BLANK_ANIM*
ID = 97413000
postype = p1
removetime = 2 ; <= Don't change this value.
[State 3000, Super A]
type = SuperPause
trigger1 = *SAME_CONDITIONS*
(...)
And finally, in StateNo -2
[State -2, Null]
type = Null
trigger1 = NumTarget && StateType!= A
trigger1 = !(Target, HitShakeOver)
trigger1 = var(40):= 10
trigger2 = var(40):= (var(40) - (var(40) > 0))
ignorehitpause = 1
[State -2, PosAdd]
type = PosAdd
triggerall = NumTarget && StateType!= A && !NumExplod(97413000)
triggerall = StateNo!= [800,899] ; Throws
trigger1 = Target, HitShakeOver && var(40)
trigger1 = Target, BackEdgeBodyDist<= 0 || Target, FrontEdgeBodyDist<= 0
trigger1 = !(Target, StateType = A || Target, StateType = L)
x = Target, GetHitVar(xVel) * Target, Facing * var(40) * .1
ignorehitpause = 1
That's it.
If you find any bugs, please report it here.