gd: made wall jump more intuitive and act like a double jump
Some checks failed
Create tag and build when new code gets to main / BumpTag (push) Successful in 17s
Create tag and build when new code gets to main / Export (push) Failing after 1s

This commit is contained in:
2025-07-04 14:15:09 +02:00
parent cf98e6c36c
commit 767d0fc768
6 changed files with 50 additions and 20 deletions

View File

@ -8,9 +8,10 @@ public partial class MoveSystem : Node3D
{
public enum JumpTypes
{
SIMPLE_JUMP,
DOUBLE_JUMP,
JUMP_FROM_DASH
SimpleJump,
DoubleJump,
JumpFromDash,
JumpFromWall
}
public record MoveSystemParameters(
@ -196,15 +197,18 @@ public partial class MoveSystem : Node3D
var jumpForce = 0.0f;
switch (jumpType)
{
case JumpTypes.DOUBLE_JUMP:
case JumpTypes.DoubleJump:
jumpForce = _gravity.CalculateDoubleJumpForce();
break;
case JumpTypes.SIMPLE_JUMP:
case JumpTypes.SimpleJump:
jumpForce = _gravity.CalculateJumpForce();
break;
case JumpTypes.JUMP_FROM_DASH:
case JumpTypes.JumpFromDash:
jumpForce = _gravity.CalculateJumpFromDashForce();
break;
case JumpTypes.JumpFromWall:
jumpForce = _gravity.CalculateJumpFromWallForce();
break;
default:
jumpForce = _gravity.CalculateJumpForce();
break;