The sample showcases some of the most common mechanics in platformer games. It is important to know these mechanics are showcased as an example and more specific game mechanics might need specific implementations.
This allows the player to control the height of the jump by holding the jump button.
This system changes the character's velocity when it reaches the maximum height of the jump. This mechanic is not so common in platformer games but in games with large environments it helps performing long jumps while the player is pressing the jump button and improves the feeling of control.
Coyote time allows the character to perform a jump for a few frames after falling off a platform. It is used to avoid punishing the player for incorrectly pressing the jump button.
This system allows performing a linear and constant movement in the input direction when the dash button is pressed. It stores the movement direction, and the duration in frames can be setup in the DashConfigAsset.
Double Or Multiple Jumps
This allows the player to perform multiple jumps while in the air. Set it up on the Double Jump Config Asset file. It is also possible to set up a minimum vertical speed to allow the character to jump again.
Jump Input Buffer
The input buffer allows the player to perform a jump even when pressing the jump button before reaching the ground. This mechanic is used to not punish the player for pressing the jump button before the correct time.
Pushing Physics Bodies
This mechanic allows the character to push physics bodies by holding the control button. It has the hit reference where it is possible to check if the collision object is a physic body and then add an impulse.
The mechanic introduces platforms that can be crossed by jumping or by moving downwards when grounded.
When the character touches a wall, it can perform a new jump. This is not an extra jump as in the double jump.