Spike wrote:
you can encode the extra ent bits into the flags byte, as there's 3 unused bits there, or just add a flag to separate ent+channel.
Also, make sure you fix signed->unsigned in cl_parsemuzzleflash* too
By fixing this you mean adding a cast the first ReadShort() call in CL_ParseMuzzleFlash() and CL_ParseMuzzleFlash2()?
Code: Select all
i = MSG_ReadShort (&net_message);
to
Code: Select all
i = (unsigned short)MSG_ReadShort (&net_message);
Using the unused bits in flags isn't required for a modified client (which supports a new protocol) to connect to a vanilla server, as the client can just check the protocol version and parse accordingly.
Putting the 3 extra bits into the flags byte could be done like this:
Code: Select all
flags |= ( ((unsigned short)ent & (32768|16384|8192)) >> 8 );
qbism wrote:
kmq2 uses additional byte flags for more sounds, animation frames, etc. similar to QIP or FQ extended protocols.
I didn't add any new animation frames to KMQ2. I did add larger model and sound indexes, larger 24-bit map coordinates (20.3), 2 more models per entity (modelindex 5 and 6), and entity alpha and looped sound attenuation.