Basic Info:
Platform: Any
Issue Type: Gameplay
Game Mode: Online Any (not single-player)
Server Type: Any
Map: Any
Server Name: N/A
Mods: No
Bug Description:
- If a player performs a sprint attack with any weapon as they’re releasing the sprint key, if the timing is just right, there is a chance that the server and client will register different sprint states.
- The result is that their client will perform the sprint attack animation, while the server will select a regular attack animation and try to apply damage based on that as well as replicate it to all the other players watching. This along with the character movement also trying to replicate from the quick dash will cause glitched looking animation on other people’s screen that doesn’t properly play, but will apply the regular heavy / light opener instead of the sprint attack damage at a slight range. The player performing the action will see a regular sprint attack like nothing happened.
- There is a more detailed rundown of what’s actually happening here
- As well as a short video of the bug being reproduced in the devkit in dedicated server mode (the selected animation on each side of the network being displayed in the top left) here: https://www.youtube.com/watch?v=g7f4ymeEoZw
Bug Reproduction:
- Equip a weapon
- Sprint for 750 ms to qualify for sprint attacks
- Release sprint and immediately attack (there’s a 100ms tolerance after releasing, so aim for roughly that window between releasing sprint and attacking)
- If timed correctly the situation from the above video will happen
Potential solutions:
As we discussed on that other thread… there aren’t a lot as this is a slightly impossible situation.
The most “accurate” for PvP servers would be to not do the combat action on the local computer ahead of time and wait for the server multicast to trigger it on that side too (removing the local filter from that one) → This will cause what feels like input lag on the attacking clients side exaggerated by their actual network lag, but depending on tests… might be a viable solution for PvP servers only (wouldn’t subject PvE users to that as they would see no benefit, only the downsides), so probably handle it conditionally based on whether pvp damage is enabled or not on the server.
Still, characters might feel sluggish so probably not the best idea, however it would solve all other similar “desync”-like problems.Other than that… a built in time-machine would be great so we could check if the person will release their sprint key in the next half a second
(just kidding)
As far as I can see other solutions could merely be band-aids like force-cancelling attacks if this is detected (will probably result in clunky combat when people do this without even realizing it), or trying to mitigate the effects by making sure at least that heavy opener doesn’t hit like a truck that’s getting played instead. (This could work… maybe instead of force-cancelling just skip the damage dealing part if it’s still possible at that stage).
Anyway, feel free to ignore this section, just thought I’d throw in some ideas based on what I’ve seen when looking into how this happens.