Fix walking in place animations when holding walk button (#37887)

Fix SpriteMovement playing when holding walk button
This commit is contained in:
Tayrtahn
2025-05-27 20:14:49 -04:00
committed by GitHub
parent 241e5836d1
commit c1b9b7e6d7
2 changed files with 10 additions and 2 deletions

View File

@@ -37,6 +37,14 @@ namespace Content.Shared.Movement.Components
public MoveButtons HeldMoveButtons = MoveButtons.None;
/// <summary>
/// Does our input indicate actual movement, and not just modifiers?
/// </summary>
/// <remarks>
/// This can be useful to filter out input from just pressing the walk button with no directions, for example.
/// </remarks>
public bool HasDirectionalMovement => (HeldMoveButtons & MoveButtons.AnyDirection) != MoveButtons.None;
// I don't know if we even need this networked? It's mostly so conveyors can calculate properly.
/// <summary>
/// Direction to move this tick.