Page 1 of 1

Experimenting with the fxi communication protocol

Posted: Mon May 31, 2010 7:56 pm
by rotunda
As of version 1.4.6~1 the server talks protocol version 0x4501. Now I'm working on optimizations which some players asked for. Most of them are already present in the ng protocol, but I'm not going to transfer them in the same order as they were added originally.

This thread is the right place to discuss all issues related to fxi protocol modifications.

Re: Experimenting with the fxi communication protocol

Posted: Mon May 31, 2010 8:15 pm
by rotunda
The first addition is cumulative turning. It appeared in the ng protocol version 0x4F13. After the addition I'm changing the version of the fxi protocol to 0x4E00. From now on, the range 0x4E00 - 0x4EFF will be used for fxi-specific protocols.

The source code of this modified server isn't included in the "master" git branch, but in a branch called "protocol-optimizations". It will be present on your disk if you clone the repository, but then you have to issue:

Code: Select all

git checkout protocol-optimizations
To play using the modified protocol you will a modified client. Otherwise when you connect the ordinary (0x4501) protocol will be negotiated. You will find attached a patch for latest git version of the bloodspilot client.

Re: Experimenting with the fxi communication protocol

Posted: Tue Jun 01, 2010 6:35 pm
by vlad
Cumulative turning? Don't you mean absolute turning?
Also, might it be possible to masquerade as ng with blockprotocol on? That way, ng clients would also be able to use the new protocols.

Re: Experimenting with the fxi communication protocol

Posted: Wed Jun 02, 2010 11:43 pm
by Samaseon
When uau implemented this for NG he called it cumulative turning, as the client sends the cumulative sum of all mouse movements to the server in the pointer control packets, whereas the legacy protocol just sent the last movement.

Re: Experimenting with the fxi communication protocol

Posted: Sun Jun 06, 2010 4:29 pm
by rotunda
Vlad, it would be possible to just assume the ng protocol version, but we won't do that. The fxi server doesn't start supporting the ng protocol features in the same order as ng did. We don't want to create a havoc in versioning.

Re: Experimenting with the fxi communication protocol

Posted: Wed Jun 09, 2010 1:58 am
by vlad
Well, once all of the ng protocols have been implemented, would it then be possible to just switch to ng version?
Btw, what are those extra features? (Besides polygon maps, which I believe can be turned off, decimal scores, and "cumulative" turning?)

Re: Experimenting with the fxi communication protocol

Posted: Thu Jun 10, 2010 10:48 pm
by rotunda
Yes, then we could just assume version 0x4eYY is the same as 0x4f15. Beyond that there could be purely cosmetic optimizations related to sending redundant fields (e.g. player's name when swapping). To shave this off we need more packet types. Ah, and it would be nice to add base signaling when a player enters.

Re: Experimenting with the fxi communication protocol

Posted: Mon Jun 14, 2010 9:49 am
by rotunda
Ok, the protocol version is now 0x4E01 and it differs from 0x4501 with these:
* 4.E.0.0: cumulative turning
* 4.E.0.1: Show ships about to appear on bases, new team change packet.

This change from the ng protocol will not be included, because it's not really useful:
* 4.F.1.0: Send_player(): Additional %c (1 when sending player's own info).

I've merged the protocol changes done so far into the master branch.