[wpdev-commits] wolfpack/ai ai.cpp,1.33,1.34
Brought to you by:
rip,
thiagocorrea
From: Sebastian H. <dar...@us...> - 2004-10-02 22:17:25
|
Update of /cvsroot/wpdev/wolfpack/ai In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7529/ai Modified Files: ai.cpp Log Message: huge spawnregion changes Index: ai.cpp =================================================================== RCS file: /cvsroot/wpdev/wolfpack/ai/ai.cpp,v retrieving revision 1.33 retrieving revision 1.34 diff -C2 -d -r1.33 -r1.34 *** ai.cpp 30 Sep 2004 15:37:12 -0000 1.33 --- ai.cpp 2 Oct 2004 22:15:52 -0000 1.34 *************** *** 506,510 **** cSpawnRegion* region = m_npc->spawnregion(); ! if ( region && region->contains( m_npc->pos().x, m_npc->pos().y, m_npc->pos().map ) ) { // Calculate the field we're facing. --- 506,510 ---- cSpawnRegion* region = m_npc->spawnregion(); ! if ( region && region->isValidSpot( m_npc->pos() ) ) { // Calculate the field we're facing. *************** *** 519,523 **** // Calculate a new direction. ! if ( !region->contains( newpos.x, newpos.y, newpos.map ) ) { unsigned char newdir = RandomNum( 0, 7 ); --- 519,523 ---- // Calculate a new direction. ! if ( !region->isValidSpot( newpos ) ) { unsigned char newdir = RandomNum( 0, 7 ); |