private void manageDiplomacy(Realm realm) {
Vector<Coordinate> circleCoordinates = realm.normalizeCoordinates(Utility.getCircleCoordinates(coordinate, realm, 1));
for (Coordinate checkCoordinate : circleCoordinates) {
Tile checkTile = realm.getTile(checkCoordinate);
if (checkTile.getSettlement() != null) {
Player movingUnitsPlayer = unit.getPlayer();
Player neighborTileCityPlayer = checkTile.getSettlement().getPlayer();
setDiplomaticStatusToPeaceIfNeeded(realm, movingUnitsPlayer, neighborTileCityPlayer);
}
Iterator<Unit> unitIterator = checkTile.getUnitsIterator();
while (unitIterator.hasNext()) {
Unit checkUnit = unitIterator.next();
Player movingUnitsPlayer = unit.getPlayer();
Player neighborTileUnitPlayer = checkUnit.getPlayer();
setDiplomaticStatusToPeaceIfNeeded(realm, movingUnitsPlayer, neighborTileUnitPlayer);
}
}
}