Add AnyBuildingAt method to BuildingInfluence.

This commit is contained in:
Paul Chote
2021-03-28 11:20:56 +01:00
committed by reaperrr
parent 19c7e14393
commit bc286b78bf
4 changed files with 10 additions and 6 deletions

View File

@@ -114,7 +114,7 @@ namespace OpenRA.Mods.Cnc.Traits
var blockedByNeighbours = Map.Ramp[cell] == 0 && !Common.Util.ExpandFootprint(cell, false)
.All(c => check(cell, c));
return !blockedByNeighbours && (resourceType == info.VeinType || BuildingInfluence.GetBuildingAt(cell) == null);
return !blockedByNeighbours && (resourceType == info.VeinType || !BuildingInfluence.AnyBuildingAt(cell));
}
}
}