I've attached a (Word generated) HTML-file with the
proposed protocols/headers to be used. Plz bomb them
:)
I will be making them smaller, but I'm not going to
'bit fuck' too much, so it will be byte-level profit
or no profit.
Most notable, position protocol is still missing,
guess why ?
Leon
__________________________________________________
Do You Yahoo!?
Yahoo! Autos - Get free new car price quotes
http://autos.yahoo.com
Title: Level 1 protocol
Level 1 protocol
Main header (for compression test, may or may
not stay, depending on profit gained by the compression)
|
16b Lengte bericht
|
8b Compression identifyer (and endian check
atm)
|
|
|
Block data, current maximum +/- 512
bytes(see 2nd level protocol)
|
The first 4 bytes will be compressed back in
2.
Level 2 protocol
|
0
|
15
|
16
|
31
|
|
4b size header
|
12b FLAGS
|
16b TOS (Type of Service)
|
|
16b
Sequence nr (from client per TOS)
|
16b
Sequence nr (from server per TOS)
|
|
Dataveld
(maximaal 512 bytes)
|
|
|
|
|
|
�b� as in bit !
List of found FLAGS (bit level, left to right)
|
0
|
Confirm msg
|
Packet should be confirmed by server/client
|
|
1
|
Do NOT parse
|
Server should NOT try to interprete the
message (on the lower level)
|
|
2
|
To Server
|
Packet only meant for the server
|
|
3
|
To ALL
|
Packet should be sent to all clients on this
server
|
|
4
|
To FOV
|
Packet should be sent to all clients withing
field of view
|
|
5
|
Loopback
|
Packet should be loopbacked WITH
interpretion (�without� can be set with �do not parse� flag)
|
|
6
|
|
Reserved flags (or slack)
|
|
7
|
|
|
|
8
|
|
|
|
9
|
|
|
|
10
|
|
|
|
11
|
|
|
Level 3 protocols (Client to Server [C2S]
and/or Server to Client[S2C]):
[C2S] Requesting a connection
|
0
|
15
|
16
|
31
|
|
8b flags
|
8b Minimal major version sender
|
8b major version sender
|
8b minor version sender
|
|
|
16b
Sequence number question/response
|
|
8b
len
nick
|
Nickname(max
50bytes)
|
|
8b
len
fdm
|
Flight
Dynamics model used (max 50bytes)
|
|
8b
Max traffic downstream (kB/s)
|
8b
Max traffic upstream (kB/s)
|
|
|
8b
update/sec
|
8b
reserved
|
16b
Vliegtuig FOV
|
|
|
|
|
|
|
|
|
�b� als in bit !
FLAGS(in order):
|
0
|
New connection
|
Create a
new connection, if a connection already existed then alle history will be
terminated and reinitialised.
|
|
1
|
Mutate
connection
|
Alteration
of the static parameters given by the client, history will be kept intact
(when possible).
|
|
2
|
Drop connection
|
Drop
connection and all corresponding objects, if no such message was received,
automatic clean up will happen after 10(?)seconds of idling.
|
|
3
|
Confirmation
|
[S2C]
Confirm initialisation/mutation/drop connection
|
|
4
|
Denial
|
[S2C]
Deny initialisation/mutation connection
|
|
5
|
Error
|
[S2C]
error in message
|
|
6
|
Reserved
|
|
|
7
|
Reserved
|
|
[S2C] Giving the static parameters of the
other clients on the server (or within FOV ?):
|
8b # players
|
Reserved
|
Reserved
|
Reserved
|
|
8b
len
nick
|
8b
Client ID
|
(x)b
Nickname (char �\r� terminates) maximum 20 characters (buffer limit)
|
|
8b
len plane
|
(x)b
Nickname (char �\r� terminates) maximum 20 characters (buffer limit)
|
|
8b
len fdm
|
(x)b
Flight Model (char �\r� terminates) maximum 20 characters (buffer limit)
|
|
|
|
|
|
This should allow for at least 8 players.
[C2S] Ping
|
32b A test long (is same as int on my
platform)
|
|
32b A test float
|
|
64b A test double
|
|
xBytes string �Multiplayer Engine Version
[...]� (char �\r� terminates)
|
[S2C] Pong
Same message, but recompiled by server (going
through all layers)
Minimal protocols yet to define:
Full position updates, Delta position updates,
chatmessage-exchange protocols, server-info protocol, ack/neg protocols.
|