russells at adelie.cx
Tue Mar 8 13:29:01 EST 2005
I've been looking at the library for the hackfest. Since I don't
currently plan on using the library, I've needed to know more about
the protocol on the wire. I have a question about the protocol.
The markers at start and end of message:
const int Message::headerValue = 0xDEADBEEF;
const int Message::footerValue = 0xABCDFEDA;
as well as the message command and data size appear in the protocol in
host order, ie little endian on my, indeed most, machines. However,
stuff inside the message is converted to network order, at least in
the messages I've looked at so far. eg the player id and player name
length in MSG_SEND_NEWPLAYER_INFO messages.
Is this deliberate? Is it likely to change? The web page says that
it could change, and I was wondering just how likely that is.
-- Fortune says:
To doubt everything or to believe everything are two equally convenient
solutions; both dispense with the necessity of reflection.
-- H. Poincar'e
More information about the Hackfest