Skip to content

Commit

Permalink
SV_ProcessFile: Wrap Con_Printf in Con_NetPrintf to avoid spam in HLD…
Browse files Browse the repository at this point in the history
…S console
  • Loading branch information
s1lentq committed Jul 24, 2020
1 parent 987ee51 commit 98db467
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions rehlds/engine/sv_main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3514,7 +3514,7 @@ void SV_ProcessFile(client_t *cl, char *filename)

if (filename[0] != '!')
{
Con_Printf("Ignoring non-customization file upload of %s\n", filename);
Con_NetPrintf("Ignoring non-customization file upload of %s\n", filename);
return;
}

Expand All @@ -3534,13 +3534,13 @@ void SV_ProcessFile(client_t *cl, char *filename)

if (!bFound)
{
Con_Printf("%s: Unrequested decal\n", __func__);
Con_NetPrintf("%s: Unrequested decal\n", __func__);
return;
}

if (resource->nDownloadSize != cl->netchan.tempbuffersize)
{
Con_Printf("%s: Downloaded %i bytes for purported %i byte file\n", __func__, cl->netchan.tempbuffersize, resource->nDownloadSize);
Con_NetPrintf("%s: Downloaded %i bytes for purported %i byte file\n", __func__, cl->netchan.tempbuffersize, resource->nDownloadSize);
return;
}

Expand All @@ -3549,7 +3549,7 @@ void SV_ProcessFile(client_t *cl, char *filename)
#ifdef REHLDS_FIXES
if (!CustomDecal_Validate(cl->netchan.tempbuffer, cl->netchan.tempbuffersize))
{
Con_Printf("Invalid custom decal from %s\n", cl->name);
Con_NetPrintf("Invalid custom decal from %s\n", cl->name);
return;
}

Expand All @@ -3571,7 +3571,7 @@ void SV_ProcessFile(client_t *cl, char *filename)

iCustomFlags |= (FCUST_FROMHPAK | FCUST_WIPEDATA | RES_CUSTOM);
if (!COM_CreateCustomization(&cl->customdata, resource, -1, iCustomFlags, NULL, NULL))
Con_Printf("Error parsing custom decal from %s\n", cl->name);
Con_NetPrintf("Error parsing custom decal from %s\n", cl->name);
}

qboolean SV_FilterPacket(void)
Expand Down

0 comments on commit 98db467

Please sign in to comment.