anchor.diff:  
   //Check opponents for closest House with given Alliance setting
   //Note: we check by house cells, not by entrance
  -function TKMHandsCollection.GetClosestHouse(aLoc: TKMPoint; aIndex: TKMHandIndex; aAlliance: TAllianceType; aOnlyCompleted: Boolean = True): TKMHouse;
  +function TKMHandsCollection.GetClosestHouse(aLoc: TKMPoint; aIndex: TKMHandIndex; aAlliance: TAllianceType; aTypes: THouseTypeSet = [HOUSE_MIN..HOUSE_MAX]; aOnlyCompleted: Boolean = True): TKMHouse;
   var
     I: Integer;
     H: TKMHouse;
  
positive.code: uses
    Classes,
    KM_Hand, KM_HandSpectator, KM_HouseCollection,
    KM_Houses, KM_Units, KM_UnitGroups, KM_Units_Warrior,
    KM_CommonClasses, KM_CommonTypes, KM_Defaults, KM_Points;
  
  
  
negative.code:   for I := 0 to fCount - 1 do
    if (aIndex <> I) and (Hands[aIndex].Alliances[I] = aAlliance) then
    begin
      H := fHandsList[I].Houses.FindHouse(aTypes, aLoc.X, aLoc.Y, 1, aOnlyCompleted);
      if (H <> nil) and ((Result = nil) or (H.GetDistance(aLoc) < Result.GetDistance(aLoc))) then
        Result := H;
    end;
  end;
  
  
  function TKMHandsCollection.GetHousesInRadius(aLoc: TKMPoint; aSqrRadius: Single; aIndex: TKMHandIndex; aAlliance: TAllianceType; aTypes: THouseTypeSet = [HOUSE_MIN..HOUSE_MAX]; aOnlyCompleted: Boolean = True): TKMHouseArray;
  var
    I,K,Idx: Integer;
    HA: TKMHouseArray;
  begin
    SetLength(Result, 12);
  
    Idx := 0;
    for I := 0 to fCount - 1 do
    if (I <> aIndex) and (Hands[aIndex].Alliances[I] = aAlliance) then
    begin
      HA := fHandsList[I].Houses.FindHousesInRadius(aLoc, aSqrRadius, aTypes, aOnlyCompleted);
      if (Idx + Length(HA) > Length(Result)) then
        SetLength(Result, Idx + Length(HA) + 12);
      for K := Low(HA) to High(HA) do
      begin
        Result[Idx] := HA[K];
        Idx := Idx + 1;
      end;
    end;
    SetLength(Result, Idx);
  end;
  
  
  