LobbyProtocol: when is gamehash sent to client?

LobbyProtocol: when is gamehash sent to client?

Discuss development of lobby clients, server, autohosts and auto-download software.

Moderators: Moderators, Lobby Developers

Post Reply
abma
Spring Developer
Posts: 3798
Joined: 01 Jun 2009, 00:08

LobbyProtocol: when is gamehash sent to client?

Post by abma »

When is the gamehash sent to the client?

according to docs, the gamehash is sent to the server when a client opens a battle:
http://springrts.com/dl/LobbyProtocol/P ... TLE:client

but it is never sent back to the client it seems:
http://springrts.com/dl/LobbyProtocol/P ... NED:server

oO

did i miss something?

in lobbyserver its received and stored (hashcode):

https://github.com/spring/uberserver/bl ... l.py#L1640

but only send on JOINBATTLE?

http://springrts.com/dl/LobbyProtocol/P ... TLE:server


hu?

it seems thats the initial implementation of these command(s):

https://github.com/spring/uberserver/bl ... rotocol.py


why do clients receive map hashes for all open battles but not the game hash?
User avatar
jK
Spring Developer
Posts: 2299
Joined: 28 Jun 2007, 07:30

Re: LobbyProtocol: when is gamehash sent to client?

Post by jK »

I don't understand your `question`

Never the less, afaik the original implementation only know 1 hash (result of game + map hash) all splittings of those in the lobby protocol were added later.
So all bogus stuff comes from that (instead of cleanly implementing an arbitrary data interface, ppl glued their stuff on it).
abma
Spring Developer
Posts: 3798
Joined: 01 Jun 2009, 00:08

Re: LobbyProtocol: when is gamehash sent to client?

Post by abma »

jK wrote:Never the less, afaik the original implementation only know 1 hash (result of game + map hash) all splittings of those in the lobby protocol were added later.
So all bogus stuff comes from that (instead of cleanly implementing an arbitrary data interface, ppl glued their stuff on it).
ok, then it makes sense, but it was done in a very bad way.

an arbitrary data interface is still missing :-|
gajop
Moderator
Posts: 3051
Joined: 05 Aug 2009, 20:42

Re: LobbyProtocol: when is gamehash sent to client?

Post by gajop »

AFAIK, the original hash was the product of the map, game but also the engine. This was designed to prevent desyncs due to wrong engine versions, or something like that.
I think we should prefer separate hashes for each module type that can be stored correctly in third party systems and not require the engine to compute (therefor ideally it would be just md5/sha hashes).
abma
Spring Developer
Posts: 3798
Joined: 01 Jun 2009, 00:08

Re: LobbyProtocol: when is gamehash sent to client?

Post by abma »

I think we should prefer separate hashes for each module type that can be stored correctly in third party systems and not require the engine to compute (therefor ideally it would be just md5/sha hashes).
not sure if thats the proper name, but the sdp hashes for all required files (=the same hashcode as retrieved from unitsync) should be used, but without any dependant files. games can be distributed via rapid or as zip and the sdp hash can be used to check if file contents are the same.
Post Reply

Return to “Lobby Clients & Server”