}
@Override
public boolean hasFlower(IBeeHousing housing) {
IFlowerProvider provider = genome.getFlowerProvider();
Vect coords = new Vect(housing.getXCoord(), housing.getYCoord(), housing.getZCoord());
Vect posCurrent = new Vect(0, 0, 0);
int[] areaAr = genome.getTerritory();
Vect area = new Vect(areaAr[0], areaAr[1], areaAr[2]).multiply(housing.getTerritoryModifier(genome, 1f));
if (area.x < 1)
area.x = 1;
if (area.y < 1)
area.y = 1;
if (area.z < 1)
area.z = 1;
Vect offset = new Vect(-Math.round(area.x / 2), -Math.round(area.y / 2), -Math.round(area.z / 2));
boolean hasFlower = false;
while (advancePosition(posCurrent, area)) {
Vect posBlock = posCurrent.add(coords);
posBlock = posBlock.add(offset);
if (provider.isAcceptedFlower(housing.getWorld(), this, posBlock.x, posBlock.y, posBlock.z)) {
hasFlower = true;
break;
}
}