Vec3 vecNewTarget = RandomPositionGenerator.findRandomTargetBlockAwayFrom(e, 16, 7, this.thisPos);
if (vecNewTarget == null)
{
continue;
}
PathNavigate nav = e.getNavigator();
if (nav == null)
{
continue;
}
Vec3 vecOldTarget = null;
if (nav.getPath() != null && !nav.getPath().isFinished())
{
vecOldTarget = nav.getPath().getPosition(e);
}
double distanceNew = vecNewTarget.squareDistanceTo(this.xCoord, this.yCoord, this.zCoord);
if (distanceNew > e.getDistanceSq(this.xCoord, this.yCoord, this.zCoord))
{