mp/src/game/server/ai_activity.cpp
void CAI_BaseNPC::AddActivityToSR(const char *actName, int actID) 
{
	Assert( m_pActivitySR );
	if ( !m_pActivitySR )
		return;

	// technically order isn't dependent, but it's too damn easy to forget to add new ACT_'s to all three lists.

	// NOTE: This assertion generally means that the activity enums are out of order or that new enums were not added to all
	//		 relevant tables.  Make sure that you have included all new enums in:
	//			game_shared/ai_activity.h
	//			game_shared/activitylist.cpp
	//			dlls/ai_activity.cpp
	MEM_ALLOC_CREDIT();

	static int lastActID = -2;
	Assert( actID >= LAST_SHARED_ACTIVITY || actID == lastActID + 1 || actID == ACT_INVALID );
	lastActID = actID;

	m_pActivitySR->AddString(actName, actID);
	m_iNumActivities++;
}
//-----------------------------------------------------------------------------
// Purpose: Add an activity to the activity string registry and increment
//			the acitivty counter
//-----------------------------------------------------------------------------
Add an activity to the activity string registry and increment
the acitivty counter
Add an activity to the activity string registry and increment the acitivty counter
void CAI_BaseNPC::AddActivityToSR(const char *actName, int actID) 
{
	Assert( m_pActivitySR );
	if ( !m_pActivitySR )
		return;
	MEM_ALLOC_CREDIT();
	static int lastActID = -2;
	Assert( actID >= LAST_SHARED_ACTIVITY || actID == lastActID + 1 || actID == ACT_INVALID );
	lastActID = actID;
	m_pActivitySR->AddString(actName, actID);
	m_iNumActivities++;
}
void CAI_BaseNPC :: AddActivityToSR ( const char * actName , int actID ) { Assert ( m_pActivitySR ) ; if ( ! m_pActivitySR ) return ; MEM_ALLOC_CREDIT ( ) ; static int lastActID = -2 ; Assert ( actID >= LAST_SHARED_ACTIVITY || actID == lastActID + 1 || actID == ACT_INVALID ) ; lastActID = actID ; m_pActivitySR -> AddString ( actName , actID ) ; m_iNumActivities ++ ; }
Purpose: Add an activity to the activity string registry and increment
the acitivty counter
Purpose : Add an activity to the activity string registry and increment the acitivty counter
// technically order isn't dependent, but it's too damn easy to forget to add new ACT_'s to all three lists. // NOTE: This assertion generally means that the activity enums are out of order or that new enums were not added to all //		 relevant tables.  Make sure that you have included all new enums in: //			game_shared/ai_activity.h //			game_shared/activitylist.cpp //			dlls/ai_activity.cpp