Skip to content

Commit

Permalink
Merge pull request #69 from selimnahimi/vault-onto-patch
Browse files Browse the repository at this point in the history
Updated vaulting logic
  • Loading branch information
selimnahimi authored Sep 6, 2023
2 parents 2cd2f83 + c699e15 commit 6e16e2f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
3 changes: 3 additions & 0 deletions code/pawn/PawnController.Vaulting.cs
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,9 @@ bool ShouldVaultOnto()
if ( IsClimbing() )
return false;

if ( IsFalling() )
return false;

return true;
}

Expand Down
5 changes: 5 additions & 0 deletions code/pawn/PawnController.Wallrunning.cs
Original file line number Diff line number Diff line change
Expand Up @@ -142,4 +142,9 @@ WallRunTrace CheckForWall( bool behind = false )

return WallRunTrace.None;
}

public bool IsFalling()
{
return Entity.Velocity.z < 0f;
}
}

0 comments on commit 6e16e2f

Please sign in to comment.