mirror of
https://github.com/YGGverse/hlsdk-portable.git
synced 2025-01-11 15:38:12 +00:00
Set EF_BRIGHTFIELD flag for monsters which stuck in the wall only in developer mode.
This commit is contained in:
parent
1d1c99af9f
commit
e239f3e1a5
@ -55,6 +55,8 @@ cvar_t *g_psv_gravity = NULL;
|
||||
cvar_t *g_psv_aim = NULL;
|
||||
cvar_t *g_footsteps = NULL;
|
||||
|
||||
cvar_t *g_psv_developer;
|
||||
|
||||
//CVARS FOR SKILL LEVEL SETTINGS
|
||||
// Agrunt
|
||||
cvar_t sk_agrunt_health1 = {"sk_agrunt_health1","0"};
|
||||
@ -462,6 +464,8 @@ void GameDLLInit( void )
|
||||
g_psv_aim = CVAR_GET_POINTER( "sv_aim" );
|
||||
g_footsteps = CVAR_GET_POINTER( "mp_footsteps" );
|
||||
|
||||
g_psv_developer = CVAR_GET_POINTER( "developer" );
|
||||
|
||||
CVAR_REGISTER( &displaysoundlist );
|
||||
CVAR_REGISTER( &allow_spectators );
|
||||
|
||||
|
@ -43,4 +43,6 @@ extern cvar_t allowmonsters;
|
||||
extern cvar_t *g_psv_gravity;
|
||||
extern cvar_t *g_psv_aim;
|
||||
extern cvar_t *g_footsteps;
|
||||
|
||||
extern cvar_t *g_psv_developer;
|
||||
#endif // GAME_H
|
||||
|
@ -33,6 +33,7 @@
|
||||
#include "decals.h"
|
||||
#include "soundent.h"
|
||||
#include "gamerules.h"
|
||||
#include "game.h"
|
||||
|
||||
#define MONSTER_CUT_CORNER_DIST 8 // 8 means the monster's bounding box is contained without the box of the node in WC
|
||||
|
||||
@ -2066,7 +2067,9 @@ void CBaseMonster::StartMonster( void )
|
||||
if( !WALK_MOVE( ENT( pev ), 0, 0, WALKMOVE_NORMAL ) )
|
||||
{
|
||||
ALERT( at_error, "Monster %s stuck in wall--level design error\n", STRING( pev->classname ) );
|
||||
pev->effects = EF_BRIGHTFIELD;
|
||||
|
||||
if( g_psv_developer && g_psv_developer->value )
|
||||
pev->effects = EF_BRIGHTFIELD;
|
||||
}
|
||||
}
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user