mirror of
https://github.com/alliedmodders/hl2sdk.git
synced 2025-09-19 12:06:07 +08:00

* Replace g_pEntitySystem with GameEntitySystem() function; * KeyValues3, CGameSystem & CVariant updates;
17 lines
483 B
C++
17 lines
483 B
C++
#include "entityidentity.h"
|
|
#include "entitysystem.h"
|
|
#include "tier1/strtools.h"
|
|
|
|
bool CEntityIdentity::NameMatches( const char* szName ) const
|
|
{
|
|
if ( szName && szName[0] == '!' )
|
|
return GameEntitySystem()->FindEntityProcedural( szName ) == m_pInstance;
|
|
|
|
return V_CompareNameWithWildcards( szName, m_name.String() ) == 0;
|
|
}
|
|
|
|
bool CEntityIdentity::ClassMatches( const char* szClassName ) const
|
|
{
|
|
return V_CompareNameWithWildcards( szClassName, m_designerName.String() ) == 0;
|
|
}
|