Skip to content

Fix multiplayer local player footstep cadence#413

Open
colecrouter wants to merge 1 commit intoSollace:1.21.11from
colecrouter:fix/sollace-mp-footstep-cadence
Open

Fix multiplayer local player footstep cadence#413
colecrouter wants to merge 1 commit intoSollace:1.21.11from
colecrouter:fix/sollace-mp-footstep-cadence

Conversation

@colecrouter
Copy link
Copy Markdown

Fixes an issue where the local player on dedicated multiplayer servers produces footsteps at a significantly slower cadence than in singleplayer.

Problem

For the local player, the client normally uses the built-in distance-traveled counter to pace footstep events. On dedicated servers the same signal does not advance consistently enough, which makes footsteps sound noticeably slower, and trigger less walk events.

Fix

Keep the existing singleplayer behavior, but for the local player on dedicated servers switch to the same motion-based distance accumulation model already used for remote players.

This keeps singleplayer unchanged while restoring multiplayer cadence for the local player.

Considerations

0.8 is reused from "remote player" logic. In practice, it feels a hair slower when compared to SP, but it's probably fine. I would look into tweaking both together before touching that further.

There are other stale issues in regard to some sounds being irreproducibly slower on MP vs SP. I think those might be related to this quirk, as some materials' wander sounds are a lot quieter, and of course network conditions vary.

For my case, I was trying to walk on copper grates, and this would almost exclusively play the wander sound. If I overwrote the wander sound with the walk sound, footsteps were 3x slower, which tipped me off to this.

@Sollace
Copy link
Copy Markdown
Owner

Sollace commented Apr 5, 2026

Oh very nice.

Is there a similar issue you can identify with velocity?
Currently it's using the same decision tree for whether to simulate velocity data.

@colecrouter
Copy link
Copy Markdown
Author

Velocity seems OK; the events in the debug menu matched on both sides, at least. I'd need to do a deeper dive before I could point a finger.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants