Quite a bit of churn here, but mostly nothing non-obvious. The only part I
probably changed more than I should have for this changeset was
SV_PushMove, since QW had factored out SV_Push from that. However, a quick
test of both NQ and QW seems to have everything working as normal.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Try to avoid cases where -180 != 180 or 0 != 360 by ensuring that we
use the ranges (closed->open) of [0, 360) or [-180, 180).
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Nothing really to change except the headers included and the library to
link against. Switched on WIN32_LEAN_AND_MEAN, so had to add a few extra
includes for that.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Not very well tested, but the loopback client works. Still missing entity
alpha, lerpfinish and a few other things.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Still need to implement the server side and the changes for outgoing
client commands, but this is enough that I can playback demos recorded
with protocol 666.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Uses unsigned long instead of byte so we don't need to cast between bytes
and int/long and we can use the long type for the bit tests as well. Had
to rewrite the decompress routine so that the bit order is correct within
the long words.
Things not as neat as I'd like on the QWSV side where the whole PVS/PHS
is decompressed - a bit too much pointer arithmetic to juggle but working
for now.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Instead of saving the PVS into a static buffer, save the leaf of the
client entity into the server_t struct and look up the PVS as needed. If
it is done frequently, the PVS cache should stop performance from
becoming too terrible.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Re-implement SV_FatPVS as Mod_FatPVS and move to model.c. The buffer for
the FatPVS can then be allocated the appropraite size at map load time.
Also made the bitwise OR of vis data use unsigned long type for
(potentially) better efficiency.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Thought I had some weird bug with vis info, leaf data or something but it
was just a lack of visedicts. Wicked.bsp now playable :)
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
If not enough room in the send buffer, we silently drop messages about
particles and sounds. Get the byte counts right and make a comment about
this being done intentionally and that it's currently broken...
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Finally starting to see how this all fits together. "Message" corresponds
to the reliable messages and "datagram" corresponds to the unreliable
messages. There shouldn't be any problem having reliable messages be
composed of many datagrams.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>