CMCharacter Modules 0.1.0

Vector Air

Kind: State, air movement role · Add Component: Character Modules > States > Vector Air

Gives strong steering in the air that can even reverse a jump. Players fix a bad jump instead of losing it.

Moving in the air the modern way: control builds up the longer the stick is held, can reverse a jump, and turns the body. Generous, so players correct a jump instead of losing it.

Inspector
▼Vector Air⋮
CharacterCharacter (Character Motor)
Gravity20
Terminal Speed0
Forward Acceleration22.8
Back Acceleration45.6
Side Acceleration13.7
Minimum Cap10.65
Maximum Cap18.3
Turn Rate720
Quick Turn Angle135
Quick Turn Rate1500
The Vector Air component in the Inspector, with its defaults.
Origin. Super Mario Odyssey (2017), whose air control is famously forgiving.

How it works

The Falling mode: runs when nothing else runs.

Vector Air: in the air the way modern 3D platformers do it. The velocity is split along and across the direction the flight began in, and the stick accelerates each part on its own: forwards, harder backwards, gently sideways. Each part is capped by the take-off speed (at least minimumCap, at most maximumCap), so the stick can steer and even reverse, but not gain speed beyond what the jump brought (except diagonally, where the two caps add up: "vectoring"). The body turns toward the stick in the air, quickly when the stick points far behind it. Compare Heading Air (classic 3D platformers), which commits to the take-off heading.

The motor's Body Facing must be States. Numbers from the modern 3D platformer measurements (D44).

Combine it

  • Priority 0: when several states could run, the highest priority wins (see How modules combine).
  • Body facing: works with characters whose body faces States.
  • Used by the presets: Modern Platformer.

Properties

PropertyDescriptionRangeDefault
CharacterThe character this module belongs to. Drag its Character Motor here.None
GravityDownward acceleration, m/s² (classic arena shooters: 25 at 32 map units per metre).0 or more20
Terminal SpeedFastest fall, m/s. 0: no limit.0 or more0
Forward AccelerationAcceleration from a full stick along the take-off direction, m/s².0 or more22.8
Back AccelerationAcceleration from a full stick against it, while still moving forwards, m/s².0 or more45.6
Side AccelerationAcceleration from a full stick across it, m/s².0 or more13.7
Minimum CapEach part of the air speed may reach at least this, m/s.0 or more10.65
Maximum CapThe take-off speed sets the cap only up to this, m/s.0 or more18.3
Turn RateHow fast the body turns toward the stick in the air, degrees per second.0 or more720
Quick Turn AngleWith the stick at least this far behind the body, it turns at Quick Turn Rate, degrees.0 to 180135
Quick Turn RateTurn rate with the stick far behind the body, degrees per second.0 or more1500

Additional resources