2
0
mirror of https://github.com/FWGS/xash3d-fwgs synced 2024-11-22 01:45:19 +01:00

engine: client: remove unncesseray int <-> qboolean branch in CL_GetMessage

This commit is contained in:
Alibek Omarov 2024-11-18 10:28:21 +03:00
parent af332eb8ac
commit c4f71f1a44

View File

@ -2602,18 +2602,12 @@ CL_GetMessage
Handles recording and playback of demos, on top of NET_ code
====================
*/
static int CL_GetMessage( byte *data, size_t *length )
static qboolean CL_GetMessage( byte *data, size_t *length )
{
if( cls.demoplayback )
{
if( CL_DemoReadMessage( data, length ))
return true;
return false;
}
return CL_DemoReadMessage( data, length );
if( NET_GetPacket( NS_CLIENT, &net_from, data, length ))
return true;
return false;
return NET_GetPacket( NS_CLIENT, &net_from, data, length );
}
static void CL_ParseNetMessage( sizebuf_t *msg, void (*parsefn)( sizebuf_t * ))