Browse Source

Fix monsters precache with custom sound folders via monstermaker.

theyhunger
Night Owl 7 years ago
parent
commit
820a33f278
  1. 24
      dlls/monstermaker.cpp

24
dlls/monstermaker.cpp

@ -151,7 +151,29 @@ void CMonsterMaker::Precache( void )
{ {
CBaseMonster::Precache(); CBaseMonster::Precache();
UTIL_PrecacheOther( STRING( m_iszMonsterClassname ) ); if( pev->message )
{
edict_t *pent;
pent = CREATE_NAMED_ENTITY( m_iszMonsterClassname );
if( FNullEnt( pent ) )
{
ALERT( at_console, "NULL Ent in UTIL_PrecacheOther\n" );
return;
}
CBaseEntity *pEntity = CBaseEntity::Instance( VARS( pent ) );
pEntity->pev->message = pev->message;
if( pEntity )
pEntity->Precache();
REMOVE_ENTITY( pent );
}
else
UTIL_PrecacheOther( STRING( m_iszMonsterClassname ) );
} }
//========================================================= //=========================================================

Loading…
Cancel
Save