# AIHasNearbyAlliedDetector

FlagsNative

# Arguments

  • int — player
  • point — loc
  • fixed — staticRange
  • fixed — mobileRange

Returns — bool

native bool AIHasNearbyAlliedDetector(
	int player,
	point loc,
	fixed staticRange,
	fixed mobileRange,
);

Category: Unclassified

# Examples

mods/core.sc2modbase.sc2data/TriggerLibs/Tactical/TactProtAI.galaxy:1255

    }
    // must not already have a nearby detector
    if (AIHasNearbyAlliedDetector(player, UnitGetPosition(aiUnit), 8.0, 16.0)) {
        return null;
    }

mods/core.sc2modbase.sc2data/TriggerLibs/Tactical/TactProtAI.galaxy:1311

    }
    // must not already have a nearby detector
    if (AIHasNearbyAlliedDetector(player, UnitGetPosition(aiUnit), 8.0, 16.0)) {
        return null;
    }

mods/starcoop/starcoop.sc2modbase.sc2data/TriggerLibs/Tactical/TactProtAI.galaxy:1214

    }
    // must not already have a nearby detector
    if (AIHasNearbyAlliedDetector(player, UnitGetPosition(aiUnit), 8.0, 16.0)) {
        return null;
    }