Example #1
0
  public double wallSmoothing(
      Point2D.Double startLocation,
      double goAngleRadians,
      int orientation,
      double currentDistance) {

    if (currentDistance < _smoothAwayDistance) {
      orientation *= -1;
    }

    double smoothedAngle =
        DUtils.wallSmoothing(
            DUtils.battleField,
            DUtils.battleFieldWidth,
            DUtils.battleFieldHeight,
            startLocation,
            goAngleRadians,
            orientation,
            _wallStick);

    return smoothedAngle;
  }