/// You have to set myAllyTeamId before callign this function. NOT thread safe! static inline bool unit_IsEnemy(CUnit* unit) { return (!teamHandler->Ally(unit->allyteam, myAllyTeamId) && !unit_IsNeutral(unit)); }
/// You have to set myAllyTeamId before calling this function. NOT thread safe! static inline bool unit_IsFriendly(const CUnit* unit) { return (teamHandler->Ally(unit->allyteam, myAllyTeamId) && !unit_IsNeutral(unit)); }
/// You have to set myAllyTeamId before calling this function. NOT thread safe! static inline bool unit_IsNeutralAndInLos(const CUnit* unit) { return (unit_IsNeutral(unit) && unit_IsInLos(unit)); }
/// You have to set myAllyTeamId before calling this function. NOT thread safe! static inline bool unit_IsNeutralAndInLosOrRadar(const CUnit* unit) { return (unit_IsNeutral(unit) && (unit_IsInSensor(unit, LOS_INLOS | LOS_INRADAR))); }