Add MOVE_TO_PLAYER flag if fighter is an ally not hasn't got FOLLOWS flag set.

This commit is contained in:
Steve 2015-11-30 12:41:11 +00:00
parent f0891dcfd6
commit 999c0eedb3
1 changed files with 4 additions and 0 deletions

View File

@ -52,6 +52,10 @@ Entity *spawnFighter(char *name, int x, int y, int side)
{
case SIDE_ALLIES:
f->aiAggression = rand() % 3;
if (!(f->aiFlags & AIF_FOLLOWS_PLAYER))
{
f->aiFlags |= AIF_MOVES_TO_PLAYER;
}
break;
case SIDE_PIRATE: