Sources/CryGame C++/Solution1/CryGame/XArea.cpp
//////////////////////////////////////////////////////////////////////
// do enter area - player was outside, now is inside
// calls entity OnEnterArea wich calls script OnEnterArea( player, AreaID )	

do enter area - player was outside, now is inside
calls entity OnEnterArea wich calls script OnEnterArea( player, AreaID )
do enter area - player was outside now is inside calls entity OnEnterArea wich calls script OnEnterArea ( player AreaID )
void	CXArea::EnterArea( IEntity* const pEntity, ISystem *pSystem )
{
	IEntity* pAreaAttachedEntity;
	m_PrevFade = -1;
	m_bIsActive = true;
	UpdateIDs( pSystem );
	for( unsigned int eIdx=0; eIdx<m_vEntityID.size(); eIdx++ )
	{
		pAreaAttachedEntity = pSystem->GetIEntitySystem()->GetEntity(m_vEntityID[eIdx]);
		if (pAreaAttachedEntity)
		{
			pAreaAttachedEntity->OnEnterArea( pEntity, m_AreaID);
		}
	}
}
void CXArea :: EnterArea ( IEntity * const pEntity , ISystem * pSystem ) { IEntity * pAreaAttachedEntity ; m_PrevFade = -1 ; m_bIsActive = true ; UpdateIDs ( pSystem ) ; for ( unsigned int eIdx = 0 ; eIdx < m_vEntityID . size ( ) ; eIdx ++ ) { pAreaAttachedEntity = pSystem -> GetIEntitySystem ( ) -> GetEntity ( m_vEntityID [ eIdx ] ) ; if ( pAreaAttachedEntity ) { pAreaAttachedEntity -> OnEnterArea ( pEntity , m_AreaID ) ; } } }
do enter area - player was outside, now is inside
calls entity OnEnterArea wich calls script OnEnterArea( player, AreaID )
do enter area - player was outside now is inside calls entity OnEnterArea wich calls script OnEnterArea ( player AreaID )
// if(a_LogArea->GetIVal())
 // m_pGame->m_pLog->Log("\001 CXArea::EnterArea reenter calling  %s\n", pAreaAttachedEntity->GetName() );
