Ejemplo n.º 1
0
 /**
  * Checks if the given position is out of the boundaries of the map.
  *
  * @param xpos The x-position to be checked.
  * @param ypos The y-position to be checked.
  * @return True if the given position isn't in the boundaries of the map. False if e given
  *     position is in the boundaries of the map. |
  *     !((xpos<=(world.getWidth()-this.getRadius()))&&((xpos>=this.getRadius()))&& | ((ypos <=
  *     world.getHeight()-this.getRadius())) && ((ypos>=this.getRadius())))
  */
 @Raw
 private boolean isOutOfTheMap(double xpos, double ypos) {
   World world = this.getWorld();
   return !((xpos <= (world.getWidth() - this.getRadius()))
       && ((xpos >= this.getRadius()))
       && ((ypos <= world.getHeight() - this.getRadius()))
       && ((ypos >= this.getRadius())));
 }