iceball
iceball copied to clipboard
Heartbeat protocol changes
As this can't be done until the next major release, I'm making an issue in case we forget.
At a minimum, The server name max length should be increased. Any other changes we may want can go in this ticket too though.
Edit:
A game field should also be added (base in most cases).
Fields should be variable-length, either null-terminated or size-prefixed (a byte is long enough for each field, so same size of packet as null-terminated).
We may wish to review size of other fields, but with variable-length, that can be changed at any time without breaking compatibility.
The server heartbeat should serve:
- the map loading image
- fetch the current map overview
- if it or the client ( or both ) are sandboxed
Beyond 0.3:
- mod information
- if there are users with elevated privileges present
- the server description/MOTD
- map rotation
- the language limitation ( languages: property in user.json was for this )
- if the server was officially approved ( like a sticker that we trust these server owners )
- the server official website
- players may want to sort by map timeout, so that
- if it is a special occasion server, eg. league server, event server, competition server, betatesting server etc.
- average player K/D or for how skilled players is it targeted
Maybe for another issue:
- if the server was "punished" so it went down the list - users would toggle if they want to show punished servers at all
- whether you can voxelauth to it
No, the heartbeat server should give you a list of servers. That's it. Some stuff, such as player count and map are fine, as that's small, and should be viewable on the web list. Anything else can be added to a query plugin. I don't even understand why you'd want half of this shit anyway, and I certainly don't think anyone would want to download a 50MB serverlist every time they refresh.
At most, out of your suggestions, we could add an official tag to certain servers, but that would be on the masterserver=> client (i.e. JSON) side of things, so is completely irrelevant to this ticket.
Updated main post.
We should shift to a protocol that lets us add or remove fields without changing the heartbeat version, JSON perhaps. That would also stop fixed-width fields, let us accept optional fields, allow servers to send stuff which is supported by one serverlist but not by another, and so on.
JSON sounds like a good idea, purely because it allows changing the protocol whenever we want. None of this waiting for next major release nonsense.