Checkpoint 1 - Basic Movement


Player Movement

I began by implementing the most basic movement features of Overdrive, which is running and jumping.

After the player could move left and right, fall off ledges and jump, I added what I think is an extremely important functionality to jumping, which is reducing the height of a jump if the jump key is released early. The player has a lot more control over their character this way and is able to perform short hops or long leaps. The level design can also now demand more precise jumps during higher difficulty sections.

The player's left and right movement in the gif above accelerates and decelerates based on a specific value, but for more control over how the character movement feels it had to be expanded with values for each of the following scenarios:

Acceleration - Rate that the player moves towards their maximum speed.

Deceleration - Rate that the player comes to a stop when pressing no keys.

Braking - Rate that the player comes to a stop when pressing the opposite direction to current movement (i.e User wants to turn around)

I experimented with these numbers until I had something that felt natural and had a satisfying weight to it. There is a fourth value which determines how much to reduce deceleration in midair. Having different deceleration and/or braking in midair creates a feeling of drifting and lower friction.

Jumps

A video from the YouTube channel Dawnosaur covered a variety of features that create more satisfying jumps in well-known platformers such as Celeste and Super Meat Boy. I implemented two of these features:

  • Reduced gravity at jump apex for additional hang-time.
  • Increased gravity while falling.

The jumping also includes a feature called 'coyote time', where a jump that is slightly too late will still register anyway. When done correctly this should only be subtle and just make the game feel more responsive.

Wall Jumps

Wall jumps work by checking for walls either side of the player. If the player is in midair and a wall is found to the left or right, the following will happen:

  • Maximum fall speed is greatly reduced to create a wall-sliding movement.
  • Jumping is allowed and will now also trigger horizontal movement based on which side the wall was detected, causing it to be a wall jump instead.

Raycasting gizmos are visible here to visualize ground and wall checks

Player Testing

Here are the two main points I identified as issues that needed fixes based on player feedback:

  1. While some people got a hang of the movement very easily and said it was good, multiple playtesters struggled with overshooting small platforms when jumping.
  2. Multiple playtesters found the timing for wall jumping to be unforgiving, and they would accidentally fall from walls (slide on left wall, press right and then jump, but player as detached from wall due to right press).

Here are my solutions:

  1. I was on the fence as to whether double-jumping needed to be in this game, but including it would allow players to gain extra air time to adjust their jumps to avoid falling, without actually changing the jumping physics for players who already found them suitable.
  2. Wall jumping will have its own separate 'coyote time' mechanic so players can jump a fraction of a second too late but still execute a wall jump.

Here is how Overdrive looks now at the first checkpoint:



References

For learning general details about good platformer movement:

https://roystan.net/articles/character-controller-2d/

For learning about creating a good jump

Leave a comment

Log in with itch.io to leave a comment.