From b201e339c804aba7b9ef023833b7aee4fab96d96 Mon Sep 17 00:00:00 2001 From: Valentin Popov Date: Thu, 26 Nov 2026 14:21:58 +0400 Subject: fix(player): use the Control forward limit for walking Read the live Control profile for walking along the body's heading. The stock Firing Range window advances at roughly 14 units per second while the key is held. Size collision sweeps from actual requested displacement so the stock factory entrance, passage and exit still work. --- apps/fparkan-game/src/main.rs | 2 +- apps/fparkan-game/src/player_collision.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'apps/fparkan-game/src') diff --git a/apps/fparkan-game/src/main.rs b/apps/fparkan-game/src/main.rs index 6a1a046a..1c55502b 100644 --- a/apps/fparkan-game/src/main.rs +++ b/apps/fparkan-game/src/main.rs @@ -14070,7 +14070,7 @@ mod tests { &engine, cockpit, PlayerMotion { - movement: [(x - hx) / distance, (y - hy) / distance], + movement: [(x - hx) / distance, (y - hy) / distance * (8.0 / 14.0)], delta_seconds: distance.min(8.0 * 0.292) / 8.0, ..PlayerMotion::default() }, diff --git a/apps/fparkan-game/src/player_collision.rs b/apps/fparkan-game/src/player_collision.rs index adf6f339..5e1ed12e 100644 --- a/apps/fparkan-game/src/player_collision.rs +++ b/apps/fparkan-game/src/player_collision.rs @@ -227,7 +227,7 @@ mod tests { &engine, cockpit, PlayerMotion { - movement: [dx * cos + dy * sin, dy * cos - dx * sin], + movement: [dx * cos + dy * sin, (dy * cos - dx * sin) * (8.0 / 14.0)], delta_seconds: distance.min(0.8) / 8.0, ..Default::default() }, @@ -386,7 +386,7 @@ mod tests { &engine, cockpit, PlayerMotion { - movement: [dx * cos + dy * sin, dy * cos - dx * sin], + movement: [dx * cos + dy * sin, (dy * cos - dx * sin) * (8.0 / 14.0)], delta_seconds: distance.min(0.8) / 8.0, ..Default::default() }, -- cgit v1.2.3