Browse Source

Add cvar to skip unicode check(Same as 4cdb80dce7)

hltopdown
Night Owl 6 years ago committed by Alibek Omarov
parent
commit
86229f7926
  1. 5
      dlls/client.cpp
  2. 2
      dlls/game.cpp

5
dlls/client.cpp

@ -51,6 +51,7 @@ extern int gmsgSayText; @@ -51,6 +51,7 @@ extern int gmsgSayText;
extern int gmsgBhopcap;
extern cvar_t allow_spectators;
extern cvar_t multibyte_only;
extern int g_teamplay;
@ -287,6 +288,10 @@ decodeFinishedMaybeCESU8: @@ -287,6 +288,10 @@ decodeFinishedMaybeCESU8:
bool Q_UnicodeValidate( const char *pUTF8 )
{
bool bError = false;
if( !multibyte_only.value )
return true;
while( *pUTF8 )
{
unsigned int uVal;

2
dlls/game.cpp

@ -43,6 +43,7 @@ cvar_t allowmonsters = { "mp_allowmonsters","0", FCVAR_SERVER }; @@ -43,6 +43,7 @@ cvar_t allowmonsters = { "mp_allowmonsters","0", FCVAR_SERVER };
cvar_t bhopcap = { "mp_bhopcap", "1", FCVAR_SERVER };
cvar_t allow_spectators = { "allow_spectators", "0", FCVAR_SERVER }; // 0 prevents players from being spectators
cvar_t multibyte_only = { "mp_multibyte_only", "0", FCVAR_SERVER };
cvar_t mp_chattime = { "mp_chattime","10", FCVAR_SERVER };
@ -480,6 +481,7 @@ void GameDLLInit( void ) @@ -480,6 +481,7 @@ void GameDLLInit( void )
CVAR_REGISTER( &defaultteam );
CVAR_REGISTER( &allowmonsters );
CVAR_REGISTER( &bhopcap );
CVAR_REGISTER( &multibyte_only );
CVAR_REGISTER( &mp_chattime );

Loading…
Cancel
Save