One area where DirectQ falls short by comparison to some other engines is in it's coordinate system. DirectQ coordinates are fairly standard, with a max of 4096 (it's actually 0.125 less, but we won't quibble). To address this I've just added a new protocol to enable me to extend this out to stupidly huge values. This new protocol is number 10003, and now becomes the default; the other previous protocols (15, BJP, BJP2 and BJP3) remain as selectable options via the sv_protocol command, of course.
Instead of quantizing coords and transmitting as a short, or even as a long, I've decided to transmit the native float data. Coords are stored as floats on both the client and the server anyway, and the quantization/reduction only has effect during message transmission, so why not?
The new max coordinate for DirectQ is 3.402823466e+38F.
I've also done the same to angles, so we'll get more accurate aiming. Otherwise it's functionally identical to PROTOCOL_VERSION_BJP3.
Implementation details of this protocol are subject to change between now and release, but post-release I'll likely end up freezing it and adding any further extensions to a PROTOCOL_VERSION_MH2, retaining the original PROTOCOL_VERSION_MH for compatibility reasons.
Tuesday, September 29, 2009
The Joy of Protocols
Posted by
mhquake
at
7:17 PM
Subscribe to:
Post Comments (Atom)
0 comments:
Post a Comment