Player Movement

From Minecraft Parkour Wiki
Revision as of 18:38, 3 January 2021 by MCPK (talk | contribs) (added to Sprinting)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Every tick, the game checks for the player's inputs, and translates them into motion.

This article doesn't deal with the exact math. For the full picture, see Movement Formulas.

Jumping

The player can jump up to 1.249m high. (1.252 in 1.9+). To start a jump, the player must have been on ground the previous tick: this allows the player to initiate a jump one tick after running off a block

In short, jumping sets the player's vertical speed to 0.42. Every tick, this speed is decreased by 0.08, then multiplied by 0.98.


Walking

Walking is the default movement state, adding 0.1 units of acceleration every tick (times 0.98 if not strafing).

The terminal walking speed on ground is 0.22 m/t.


Sprinting

Sprinting is activated by walking and pressing the Sprint key, or by double-tapping forward.

If the Sprint key isn't held, the player stops sprinting after 30 seconds. Colliding with a wall also causes the player to stop sprinting.

Sprinting is 30% faster than walking, granting a total of 0.13 units of acceleration every tick (times 0.98 if not strafing).

If the player jumps while sprinting, they gain 0.2 units of acceleration towards the direction they are facing (even if they are strafing). This is why sprintjumping is the most efficient technique to gain speed. The terminal sprinting speed on ground is 0.286 m/t.

Sprinting in air is delayed by one tick.

Sneaking

Sprinting is activated by pressing the Sneak key.

Sneaking is the slowest movement speed, being 70% slower than walking and granting only 0.0294 units of acceleration per tick.

If the player is strafing, the acceleration is added as is in both directions, making the player move 2 times faster, with about 0.0416 units of acceleration per tick.


More importantly, sneaking allows the player to move towards the edge of a block without falling, which is useful for positioning.

  • In 1.8, it prevents the player from falling 1 block or more.
  • In 1.11+, it prevents the player from falling more than 0.6b (the player's stepping height).

Note that sneaking works with "1 tick of delay": if it's activated while walking off a ledge, the player will stop moving for a tick as if it worked, but will start falling on the next. This phenomenon is commonly called "shift glitch".


Another property of sneaking on a ledge is that it doesn't reset the player's speed even if they don't appear to be moving. This can be used to gain a little more speed for jumps with no momentum.


Sneaking lowers the player's bounding box in 1.9+:

  • By default, the player is 1.8m tall
  • When sneaking in versions 1.9 - 1.13, the player is 1.65m tall.
  • When sneaking in versions 1.14+, the player is only 1.5m tall, making them able to fit under 1.5b ceilings.