Browse Source

Move "build" cvar pointer check to GameDLLInit function.

hl_urbicide
Andrey Akhmichin 5 years ago
parent
commit
895e7b7503
  1. 4
      dlls/game.cpp
  2. 4
      dlls/h_export.cpp

4
dlls/game.cpp

@ -17,6 +17,8 @@ @@ -17,6 +17,8 @@
#include "util.h"
#include "game.h"
BOOL g_fIsXash3D;
cvar_t displaysoundlist = {"displaysoundlist","0"};
// multiplayer server rules
@ -453,6 +455,8 @@ cvar_t sk_player_leg3 = { "sk_player_leg3","1" }; @@ -453,6 +455,8 @@ cvar_t sk_player_leg3 = { "sk_player_leg3","1" };
void GameDLLInit( void )
{
// Register cvars here:
if( CVAR_GET_POINTER( "build" ) )
g_fIsXash3D = TRUE;
g_psv_gravity = CVAR_GET_POINTER( "sv_gravity" );
g_psv_aim = CVAR_GET_POINTER( "sv_aim" );

4
dlls/h_export.cpp

@ -28,7 +28,6 @@ @@ -28,7 +28,6 @@
// Holds engine functionality callbacks
enginefuncs_t g_engfuncs;
globalvars_t *gpGlobals;
BOOL g_fIsXash3D;
#ifdef _WIN32
@ -54,7 +53,4 @@ extern "C" void DLLEXPORT EXPORT2 GiveFnptrsToDll( enginefuncs_t *pengfuncsFromE @@ -54,7 +53,4 @@ extern "C" void DLLEXPORT EXPORT2 GiveFnptrsToDll( enginefuncs_t *pengfuncsFromE
{
memcpy( &g_engfuncs, pengfuncsFromEngine, sizeof(enginefuncs_t) );
gpGlobals = pGlobals;
if( CVAR_GET_POINTER( "build" ) )
g_fIsXash3D = TRUE;
}

Loading…
Cancel
Save