Skip to content

Implement smoother chunk streaming #270

Description

@Schuwi

The server is loading chunks too fast :D
Right now the server checks which new chunks to load the instant a player crosses a chunk border and then sends all the newly loaded chunks to the player as fast as it can.
When running a release build with a server view distance of 16 the Minecraft vanilla client suffers. Every time when crossing a chunk border the client hangs for a good ~100ms while receiving the new 32 chunks sent by the server. When setting the view distance to 32 the client actually seems to lose a lot of chunks (maybe some receive-buffer overflowing or something?), so a lot of chunks in view distance are just permanently unloaded for the client.
I actually wonder how the vanilla server handles this. Maybe it's just slow enough at loading chunks ^^?
I'm not sure how to remedy this. The straightforward solution would be to implement some kind of chunk streaming queue and only send x chunks per time interval t to the client but maybe there is a better solution?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions