2012-01-29 11:28:19 -08:00
|
|
|
|
|
|
|
#include "Globals.h" // NOTE: MSVC stupidness requires this to be the same across all modules
|
|
|
|
|
2011-12-25 14:47:12 -08:00
|
|
|
#include "cPassiveAggressiveMonster.h"
|
|
|
|
|
|
|
|
#include "cPlayer.h"
|
|
|
|
|
|
|
|
|
2012-01-29 11:28:19 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
2011-12-25 14:47:12 -08:00
|
|
|
cPassiveAggressiveMonster::cPassiveAggressiveMonster()
|
|
|
|
{
|
|
|
|
m_EMPersonality = PASSIVE;
|
|
|
|
}
|
|
|
|
|
|
|
|
cPassiveAggressiveMonster::~cPassiveAggressiveMonster()
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
void cPassiveAggressiveMonster::TakeDamage(int a_Damage, cEntity* a_Instigator)
|
|
|
|
{
|
|
|
|
cMonster::TakeDamage(a_Damage, a_Instigator);
|
|
|
|
if(m_Target->GetEntityType() == cEntity::E_PLAYER)
|
|
|
|
{
|
|
|
|
cPlayer * Player = (cPlayer *) m_Target;
|
|
|
|
if(Player->GetGameMode() != 1)
|
|
|
|
{
|
|
|
|
m_EMState = CHASING;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
void cPassiveAggressiveMonster::EventSeePlayer(cEntity *a_Entity)
|
|
|
|
{
|
|
|
|
return cMonster::EventSeePlayer(a_Entity);
|
|
|
|
}
|