42 aiMobState_Ramble::load(fp);
48 aiMobState_Territorial::~aiMobState_Territorial(
void)
52 void aiMobState_Territorial::perceive_active( std::string strID_Old )
57 aiMobState_Ramble::perceive_active(strID_Old);
59 pMonster->agressive(M_TRUE);
64 void aiMobState_Territorial::perceive_InRange(
unsigned state)
73 pMonster->enableBattleGUI();
76 pMonster->attackSelect(M_MATTACK_MAIN + rand()%2);
77 pMonster->attackInitiate();
82 pMonster->enableBattleGUI(M_FALSE);
83 pMonster->attackStop();
87 if( pMonster->attackIsCharged() )
89 pMonster->attack(pPlayer);
93 pMonster->attackSelect(M_MATTACK_MAIN + rand()%2);
94 pMonster->attackInitiate();
102 if( pPlayer->getPosition().x() > pMonster->getPosition().x() )
103 pMonster->setFaceDirection(+1);
105 pMonster->setFaceDirection(-1);
111 aiMobState_Ramble::perceive_InRange(state);
116 void aiMobState_Territorial::perceive_InTerritory(
unsigned state)
134 if( pPlayer->getPosition().x() > pMonster->getPosition().x() ) pMonster->move(+1);
135 else pMonster->move(-1);
139 _select_creature(M_FALSE);
145 aiMobState_Ramble::perceive_InTerritory(state);
Adds capabilities and percepts specific to monster creatures.