Hitbox


 * For the website, see hitbox.tv.



A hitbox or collision bubble (sometimes hitbubble) is the main structure for how attacks are executed in most fighting games. Attacks have one or more hitboxes associated with them, and when these hitboxes overlap with a target's damageable area (often called their hurtbox or hurtbubbles), the attack is considered a hit. Hitboxes are invisible and usually, though not always, have the same shape as the attack's animation.

Overview
The two most common forms of hitbox shapes in video games are s and spheres. Neither is obviously better than the other - cuboids can more easily form long or thin attacks or targets, while spheres are easier to calculate collision detection for. Smash 64 uses cuboids whereas Melee, Brawl, Smash 4, and Ultimate use spheres and sphere-like structures known as capsules (cylinders with spheres on the ends).

In Smash 64, hacks can enable hitbox visibility (with a few limitations), such as in [[Media:SSB Hurtboxes.png|this image]]. In Melee, hitboxes can be seen with the if set to DEVELOP, though accessing it requires a cheating device. There is no easy way to display hitboxes in-game in later games, though a common technique in Brawl is to use hacks to place Super Scope shot visuals where the hitboxes are (which is significantly more involved a process and generally fails for any projectile or item). Ultimate's Training mode natively includes an option to display characters' hurtboxes when invincible or intangible, though only their portions that overlay with the character's model are shown, rather than their true shapes.

Should multiple hitboxes of a single move connect with the opponent, only one of them will count. The order of precedence is known as the "hitbox stack" - hitboxes higher in the stack will override ones lower should they both hit at the same time. Mechanically, this is denoted by giving each hitbox an ID number, and lower numbers indicate higher precedence (higher stack position). For example, Marth's down aerial in Melee features its tipper hitbox on top of the stack, so hitting with both a tipper and non-tipper hitbox will result in the tipper counting, even if the majority of the opponent was hit by the other hitboxes. By contrast, the move in Brawl has the tipper on the bottom, so the tipper can only hit if none of the other hitboxes do. As a result, even though the sizes and positions of the hitboxes did not change much between games, the tipper is more difficult to hit in Brawl than in Melee.

Hitboxes that are separated from a character's hurtboxes are often called disjointed, which is usually an advantage, as they can connect from a farther distance, while keeping the attacker safer from retaliation and reducing the likelihood of trading blows. Examples of disjointed hitboxes include most weapon-based attacks, and more infamously the up tilts of in Smash 64 and  in Brawl, as well as some of 's moves when using Arsene.

An interesting property of hitboxes in the Super Smash Bros. series is that under most conditions, they occupy not only the space where they currently are, but also the space where they were one frame ago, as well as all the space in between (in a straight line, regardless of what the animation might look like during intervening subframes). This characteristic, known as interpolation, helps to prevent situations where a fast projectile may end up passing through a character in less than a frame without hitting them. On the other hand, hurtboxes do not interpolate in this way, so a fast-moving object (such as Fox during his Illusion) may be able to move through a slow or stationary hitbox without being damaged. In addition, certain hitboxes from Brawl onward use a stretch effect to create a very long hitbox, for example in and Aura Storm, instead of interpolating. It is unclear how this hitbox-stretching mechanism operates when time is slowed via Training mode or other effects, as the games render subframes, whereas Smash 64 and Melee simply reduce the overall framerate.

Hitboxes in three dimensions
It is a common misconception that, like in most other fighting games, hitboxes and hurtboxes only operate in two dimensions. In actuality, they interact in all three dimensions equally, even though the majority of gameplay elements are restricted to two-dimensional movement. As a result, Super Smash Bros. is more accurately described as a 2.5D game.

Notable examples of unexpected behavior due to the 3D nature of hitboxes include:
 * Animations where characters lean sideways can result in attacks missing them. King Dedede's spot dodge in Brawl is a notorious example, allowing him to dodge attacks with narrow hitboxes even after his intangibility ends.
 * Attacks that swing in a horizontal arc can hit characters of different widths at different times. For example, Peach's neutral aerial in Smash 4 usually hits Zero Suit Samus a frame later than most other characters. Similarly, Yoshi's running grab in Melee is so off to the side of the playing plane that it often misses skinny characters, such as Zelda or Marth, which is demonstrated in this clip where aMSa's Yoshi misses a grab at point blank range against PewPewU's Marth.

When playing on a two-dimensional stage such as Flat Zone, many of these quirks disappear, due to characters being almost completely flattened along the camera's axis. However, some new quirks can arise: if hitboxes are produced when an arcing attack is normally not yet in the playable plane, the flattening effect results in them being able to hit earlier than expected. For example, Charizard's forward tilt in Smash 4 can land its flame hitbox sooner than usual. It is also important to note that only the characters are flattened; their hitboxes and hurtboxes continue to operate as three-dimensional objects in a three-dimensional world, so maneuvers such as using the Dragoon are not affected.

Players tend to refer to any unexpected behavior of this nature as fault of the "z-axis", as z traditionally refers to the third dimension in a three-dimensional environment. This tends to result in confusion when character moveset data is decoded, as while the camera's axis is indeed along the z-axis of stages, for characters and most other gameplay objects, the z-axis is the one that points forwards.

Special properties
Prior to Ultimate some hitboxes are listed as "special hitboxes" which have additional properties. In Ultimate, these properties are included for every hitbox.

Some other properties have been found, but their effect is currently unknown.

Hitbox related flags
These are flags used in an animation's script in order to create, alter, or remove different types of hitboxes.

Trapbox
In Melee, a trapbox is the hitbox left on the ground during Ness' yo-yo glitch. It is called a trapbox because this hitbox is not attached at all to any kind of attack but instead just sits wherever it was when the glitch occurred. Using a new attack will overwrite the hitbox with the new attack's properties and relocate it to the new attack, which due to the interframe stretching effect will cause it to hit everything between it and Ness.

Trivia

 * In SSB, grabs are normal hitboxes with no apparent mechanism for distinction from attacks. In Melee, grab hitboxes and inert hitboxes are 0%-damage hitboxes with "grab" or "inert" for an effect. Both grabs and inert hitboxes are separate objects in Brawl and SSB4, though in rare cases a 0%-damage hitbox is used as an inert one.
 * The single largest hitbox in Melee can be found when Raikou is released from a Poké Ball.
 * Because characters enter a recoil animation upon being hit, pausing the game during the freeze frames can make it appear as if the attack's hitboxes are misaligned or too large.
 * This is especially prominent in Ultimate with the addition of Special Zoom and Finish Zoom. When an attack triggers one of these effects, the resulting zoom-in and slowdown can cause this apparent discrepancy to be much more noticeable.