Interface SurfaceWaterDepthFilter

All Superinterfaces:
PlacementFilter, PlacementModifier, Wrapper

@NullMarked @AsOf("3.0.0") public interface SurfaceWaterDepthFilter extends PlacementFilter
Returns the current position if the number of motion blocking blocks under the surface is less than or equal to the maximum water depth. Otherwise returns empty.
Since:
3.0.0
See Also:
  • Method Details

    • maxWaterDepth

      @AsOf("3.0.0") int maxWaterDepth()
      The maximum allowed water depth.
      Returns:
      the maximum water depth
      Since:
      3.0.0
    • of

      @AsOf("3.0.0") static SurfaceWaterDepthFilter of(int maxWaterDepth)
      Creates a new surface water depth filter.
      Parameters:
      maxWaterDepth - the maximum allowed water depth
      Returns:
      a new surface water depth filter
      Since:
      3.0.0