# Combat Diff Flag Sort Buildings Priority

Grammar — Perform action action on the combat diffculty flag for player player - Sort Buildings Priority
FlagsNative | Function

When enabled, allows the combat AI to prioritize the order it will attack buildings in.

# Arguments

Returns — bool

native bool AICombatDiffFlagCatSortBuildingsPrio(
	int player,
	int action,
);

Category: AI Advanced / Tactical / Functions

# Examples

# campaigns/liberty.sc2campaign

MapScript.galaxy

// L1210
AICombatDiffFlagCatSortBuildingsPrio(PlayerGroupLoopCurrent(), c_combatFlagDisable)
// L1210
AICombatDiffFlagCatSortBuildingsPrio(PlayerGroupLoopCurrent(), c_combatFlagDisable)

# mods/core.sc2mod

BaseAI.galaxy

// L62
AICombatDiffFlagCatSortBuildingsPrio   (player, AIDiffThreshold(player, c_combatFlagDisable, c_skirEasy  ,   c_combatFlagEnable))
// L75
AICombatDiffFlagCatSortBuildingsPrio   (player, AIDiffThreshold(player, c_combatFlagDisable, c_campAdvanced, c_combatFlagEnable))
// L112
AICombatDiffFlagCatSortBuildingsPrio   (player, AIDiffThreshold(player, c_combatFlagDisable, c_campAdvanced, c_combatFlagEnable))