Cornerpush and you - An introduction.

This short article came to be after receiving a question from a fellow forum member asking me why having proper cornerpush was important and the way it was handled in commercial games.

I wrote this article to give both an insight to MUGEN coders looking to get a better understand of cornerpush and casual readers who want to know more about how cornerpush works in their beloved fighting games, to this end the article also includes references to the MUGEN engine, but even if you are not interested in MUGEN at all it is still a good read and a good reference to understand the importance of cornerpush and how it relates to the way games handle hits.

By the end of this article we will have learned what the fundamental rules of cornerpush are and why "breaking" them is a bad idea, in this particular article MUGEN works as an excellent example.

This is a list of jargon that I may be using here:

  1. "Hitstun": This describes the small window of time where the game "pauses" right after registering a collision between two characters. Hitstun is commonly used to allow the player to input any additional follow up moves to create chain combos.
  2. "Constants": This refers to a set of numbers defined for every character in MUGEN that modify the way the character is affected by velocities such as the ones received after getting hit. These constants are what makes a "heavy" character feel slower than a "lighter" character, for example, comparing "Zangief" to "Cammy" from the Street Fighter series of games.
  3. "Hitstun timings (notation)": Commonly referred to as "pausetimes" in the MUGEN engine, the notation X,Y is defined as follows: X marks the "hitstun" frames P1 receives after connecting an attack, and similarly, Y makes the "hitstun" frames P2 receives after getting hit by an attack.
  4. "Advantage frames": An usual fighting game terms that references the difference between how many "frames" it takes P1 to return to his idle state after a move to the "frames" it takes for P2 to go idle after getting hit. For example, if a character X punches character Y and character X returns to his idle state after 24 total game frames and character Y returns to his neutral state after 32 total game frames then it can be said that character X has an "8 frame advantage" over P2.
  5. "Hit velocity": This refers to the velocity an opponent receives after getting hit by a move.
  6. "Gethit state": This refers to the action a character performs after getting hit by a move, represented visually by a "hurting" animation. The player has no control of his character during this state.
  7. "Slide time": This refers to the amount of "frames" a character moves for during a gethit state. If character Y gets hit by a move from character X and character Y is affected by hit velocity for an M amount of frames, then it is said that the slidetime for that particular hit was "M".

Ah, cornerpush. It's kind of an issue in MUGEN because it never had a proper cornerpush system to begin with.

I'll try to explain it as best as I can.

Cornerpush was basically created to nerf pressure from locking you down in a corner, creating an almost "corner-less" environment per-se, it's supposed to act the same way regular hits do: you hit someone and they get pushed back when their hitstun is over, in the corner if you hit someone you are the one who gets pushed back once their hitstun is over.

Commercial games use the most logical solution to the cornerpush, the same amount of force you'd cause to the opponent is cast on to you in the corner as long as no special exceptions are being played at the same time (for example, most games will reset a cornerpush if the opponent gets hit by an outside object, more on this in a bit).

MUGEN's, however, doesn't follow any of this at all.

For example, using Terry_WLS:

Pushback distance caused by a mid-screen hitting punch:

Pushback distance caused by corner hitting punch (using MUGEN default cornerpush):

There is a total difference of 14 pixels between each punch, which is a huge disparity that creates a whole different combo game in the corner, this is terrible. Keep in mind, this was also tested with an opponent using "ideal" friction, if we test it with someone like CvS Sieger....

Mid-screen:

Corner:

This has a total difference of 23 pixels! Almost twice as much as our previous case, with opponents like him the combos are going to be completely different, and the cornerpush is something that stacks up over each hit creating even more and more errors, and it's all due to MUGEN not using the constants properly; all the mid-screen velocities are calculated using your opponent's friction constant, and the cornerpush is calculated using yours, this is a huge problem.

2.- MUGEN never applies cornerpush at the right time.

This is probably my favorite example to explain how bad MUGEN's cornerpush is and how important it is to have a proper system for it.

Terry has a special command move in KOF2003 called "Combination Blow", which is a follow up to his close fierce basic.

It all sounds okay so far, but the thing is, KOF plays with the hit stun timings for close fierce in order for that second hit to connect properly. Instead of having the usual 12,13 hitstun it uses an unconventional 6,13 hitstun (half!) in order to give Terry enough advantage frames to have the follow up connect.

Just to illustrate, here is a gif of said basic, frame by frame in KOF:

And another KOF gif with the follow up:

And now look at what happens with the same data under MUGEN's cornerpush system:

As a result, this is what happens in the end:

Terrible, isn't it? This problem was what made me switch to custom cornerpush. :P

This should also make it easier to figure out what the real special rules for cornerpush should be!

And a very special (and important) rule:

For example, Ryu's Hadouken projectile:

Those are the rules every game follows to the letter. Without them, combos would be completely chaotic in any game.

It's also worth mentioning that some games also introduce extra rules, like allowing a character to be pushed during air-to-ground interaction (Capcom vs. SNK 2) or even air-to-air interaction (Blazblue), but in the end the theory behind it always follows those rules.

My solution for MUGEN:

My cornerpush system for MUGEN doesn't fix the problem as a whole because every character has a different friction constant, this will always make mid-screen combos different with every character. What I did was fix the corner side of the problem by introducing every cornerpush velocity by myself (this means, the opponent's velocity is irrelevant to my calculations, I use whatever I defined on my hitdef instead).

This makes it so every combo you create in the corner will always work with different opponents unless it relies on heavy collision box tricks, at least one part of it is consistent now!

My solution DOES fix all of the problems the original one had, however, by applying the cornerpush at the proper moments and ending it appropriately. My system would also work for recreating any cornerpush system in existence by merely adding the extra rules required, and I've also heard of extremely good results by using it as-is with the same type of calculations.

It all depends on what you want, you could modify my system to use the exact same vels the opponent is getting or just use the same way I calculate friction, both of those solutions would already make your work feel much better by a significant margin. What also I like about mine is that I made it as user friendly as possible, and I have already taken care of all the possible bugs that it could cause, so I can definitely vouch for it.

In any case, I hope this helps you understand cornerpush a little better.

If you have any more questions feel free to drop me a line.

Until next time!

~ Vans