Page MenuHomeFeedback Tracker

Huge speeds during player rotation and subsequent terrible prediction of remote players positions
New, NormalPublic

Description

I'd like to request an investigation and hopefully a remedy or a fix for a long going issue of remote players position jumping around unreasonably during their fast rotation.

Here are two videos that show this issue in action:
Player moving forward and rotating with huge DPI: https://www.youtube.com/watch?v=sJclEvswR64
Player evading enemy fire by going in circles and rotating a lot: https://youtu.be/x8kKPJk5UdA?t=21

This happens because player units rotate around their collision shape center ("CfgMovesMaleSdr" >> "States" >> x >> "collisionShape") which shifts forward when you move forward, while velocity is calculated from entity position. Quick mouse movements move entity position by a large amount resulting in a few moments of huge speed increases. You can reproduce and observe this with this code snippet:

player setAnimSpeedCoef 0.1;
pos = getPosWorld player;
onEachFrame {
    hintSilent ([
        speed player toFixed 1
        ,vectorMagnitude velocity player toFixed 1
        ,vectorMagnitude velocityModelSpace player toFixed 1
        ,((getPosWorld player distance2d pos) / diag_deltaTime) toFixed 1
    ] joinString "\n");
    pos = getPosWorld player;
    drawIcon3D ["\A3\ui_f\data\map\groupicons\selector_selected_ca.paa", [0,0,1,1], ASLtoAGL pos, 0.4, 0.4, 0, "pos"];
}

Execute it, then run forward, observe tiny velocity in hint (<1), now start going forward and quickly turning with the mouse and observe sudden speed increase, because entity position changes a lot despite unit barely moving. You can also try this with setAnimSpeedCoef 1 which will produce same effect. You can also observe this by opening GPS and seeing how much its zoom jumps during fast rotations reflecting unit velocity.

This huge speed increase broadcasts over the network and clients extrapolate this state into far movement, resulting in players dashing around, going through walls and stairs, seriously ruining both gameplay and immersion. Players that know about this sort of exploit can start running while turning to make them extremely hard to hit giving them a lot of unfair advantage.

Details

Severity
None
Resolution
Open
Reproducibility
Always
Operating System
Windows 10 x64
Category
Movement
Additional Information

Tweaking or removing collision shape for movement is not a solution here because it will ruin Arma 3 movement feel that everyone got used to and introduce new clipping issues.

Here are few ideas for a solution:

  • Calculate player velocity using collision shape instead of entity position, the same shape that unit rotates around.
  • Introduce some kind of sanity checks for remote unit state extrapolation/prediction.

Event Timeline

SaMatra created this task.Dec 12 2023, 6:24 PM
SaMatra updated the task description. (Show Details)Dec 12 2023, 6:28 PM
TRAGER added a subscriber: TRAGER.Dec 12 2023, 9:58 PM
This comment was removed by dedmen.
This comment was removed by dedmen.
dedmen added a subscriber: dedmen.Aug 21 2024, 3:28 PM