if not(IsDifferentTeam(targ, ent))
return FALSE; // enemy is on our team
- if(autocvar_g_monsters_target_infront)
+ if(autocvar_g_monsters_target_infront || ent.spawnflags & MONSTERFLAG_INFRONT)
if(ent.enemy != targ)
{
float dot;
const float MONSTERFLAG_APPEAR = 2; // delay spawn until triggered
const float MONSTERFLAG_NORESPAWN = 4;
const float MONSTERFLAG_FLY_VERTICAL = 8; // fly/swim vertically
+const float MONSTERFLAG_INFRONT = 16; // only check for enemies infront of us
const float MONSTERFLAG_SPAWNED = 512; // flag for spawned monsters
.float msound_delay; // restricts some monster sounds