Interface SurfaceRule.Factory

Enclosing interface:
SurfaceRule

public static interface SurfaceRule.Factory
  • Method Details

    • overworld

      SurfaceRule overworld()
      Returns the surface rules for the vanilla overworld.
      Returns:
      the surface rules
    • overworldLike

      SurfaceRule overworldLike(boolean nearSurface, boolean bedrockRoof, boolean bedrockFloor)
      Returns the surface rules for a vanilla like overworld.
      Parameters:
      nearSurface - whether to only apply most surface rules to the surface of the world
      bedrockRoof - whether to place a bedrock roof
      bedrockFloor - whether to place a bedrock floor
      Returns:
      the custom surface rules
    • nether

      SurfaceRule nether()
      Returns the surface rules for the vanilla nether.
      Returns:
      the surface rules.
    • end

      Returns the surface rules for the vanilla end.
      Returns:
      the surface rules.
    • firstOf

      SurfaceRule firstOf(List<SurfaceRule> surfaceRules)
      Returns the surface rule for a list of surface rules of which only the first successful rule is applied.
      Parameters:
      surfaceRules - The surface rules
      Returns:
      the surface rule
    • firstOf

      SurfaceRule firstOf(SurfaceRule... surfaceRules)
      Returns the surface rule for a list of surface rules of which only the first successful rule is applied.
      Parameters:
      surfaceRules - The surface rules
      Returns:
      the surface rule
    • badlands

      SurfaceRule badlands()
      Returns the badlands surface rule.
      Returns:
      The surface rule
    • block

      SurfaceRule block(BlockState blockState)
      Returns the surface rule for setting a BlockState.
      Parameters:
      blockState - The block state
      Returns:
      the surface rule
    • test

      Returns a conditional surface rule.
      Parameters:
      conditions - The conditions
      rule - The surface rule to conditionally apply
      Returns:
      the surface rule
    • test

      Returns a conditional surface rule.
      Parameters:
      condition - The condition
      rule - The surface rule to conditionally apply
      Returns:
      the surface rule
    • not

      Returns the inverted surface condition.
      Parameters:
      condition - The surface condition to invert
      Returns:
      The inverted surface condition
    • liquidDepth

      SurfaceRule.Condition liquidDepth(int offset, int depthMultiplier)
      Returns the surface condition to check for liquid depth
      Parameters:
      offset - The offset
      depthMultiplier - The depth multiplier
      Returns:
      The surface condition
    • liquidDepthFromSurface

      SurfaceRule.Condition liquidDepthFromSurface(int offset, int depthMultiplier)
      Returns the surface condition to check for liquid depth from the nearest surface.
      Parameters:
      offset - The offset
      depthMultiplier - The depth multiplier
      Returns:
      The surface condition
    • biome

      Returns the surface condition for biomes
      Parameters:
      biomes - The list of biomes
      Returns:
      The surface condition
    • nearSurface

      SurfaceRule.Condition nearSurface()
      Returns the surface condition for blocks near to the surface of the world.
      Returns:
      The surface condition
    • hole

      Returns the surface condition for holes. Holes are located where the surface noise results in depth of zero or less.
      Returns:
      The surface condition
    • verticalGradient

      SurfaceRule.Condition verticalGradient(String randomSource, int fromY, int toY)
      Returns the surface condition to select blocks in a vertical gradient.
      Parameters:
      randomSource - The random source
      fromY - the lowest block
      toY - the highest block
      Returns:
      The surface condition
    • verticalGradient

      Returns the surface condition to select blocks in a vertical gradient.
      Parameters:
      randomSource - The random source
      fromY - the lowest block
      toY - the highest block
      Returns:
      The surface condition
    • steep

      Returns the surface condition for steep inclines.
      Returns:
      The surface condition
    • onFloor

      Returns the surface condition to check for blocks on floor surfaces.
      Returns:
      The surface condition
    • underFloor

      SurfaceRule.Condition underFloor(int depth)
      Returns the surface condition to check for blocks under floor surfaces.
      Parameters:
      depth - The depth
      Returns:
      The surface condition
    • floor

      SurfaceRule.Condition floor(int offset, boolean useDepth, int secondaryDepth)
      Returns the surface condition to check for blocks around floor surfaces.
      Parameters:
      offset - The offset
      useDepth - Whether to use depth
      secondaryDepth - The secondary depth. 0 to disable.
      Returns:
      The surface condition
    • onCeiling

      Returns the surface condition to check for blocks on ceiling surfaces.
      Returns:
      The surface condition
    • underCeiling

      SurfaceRule.Condition underCeiling(int depth)
      Returns the surface condition to check for blocks under ceiling surfaces.
      Parameters:
      depth - The depth
      Returns:
      The surface condition
    • ceiling

      SurfaceRule.Condition ceiling(int offset, boolean useDepth, int secondaryDepth)
      Returns the surface condition to check for blocks around ceiling surfaces.
      Parameters:
      offset - The offset
      useDepth - Whether to use depth
      secondaryDepth - The secondary depth. 0 to disable.
      Returns:
      The surface condition
    • snowyTemperature

      SurfaceRule.Condition snowyTemperature()
      Returns the surface condition to check for temperatures allowing snowfall.
      Returns:
      The surface condition
    • blockAbove

      SurfaceRule.Condition blockAbove(SurfaceRule.VerticalAnchor anchor, int depthMultiplier)
      Returns the surface condition to check for blocks above a y coordinate
      Parameters:
      anchor - The lowest block position
      depthMultiplier - The multiplier to apply to the surface noise
      Returns:
      The surface condition
    • surfaceAbove

      SurfaceRule.Condition surfaceAbove(SurfaceRule.VerticalAnchor anchor, int depthMultiplier)
      Returns the surface condition to check for surface blocks above a y coordinate
      Parameters:
      anchor - The lowest block position
      depthMultiplier - The multiplier to apply to the surface noise
      Returns:
      The surface condition
    • noiseThreshold

      SurfaceRule.Condition noiseThreshold(RegistryReference<Noise> noise, double min, double max)
      Returns the surface condition to match a range of given Noise.
      Parameters:
      noise - The noise
      min - the minimum value
      max - the maximum value
      Returns:
      The surface condition
    • absolute

      SurfaceRule.VerticalAnchor absolute(int y)
      Returns an SurfaceRule.VerticalAnchor at given y position.
      Parameters:
      y - The y position
      Returns:
      The anchor
    • top

      Returns an SurfaceRule.VerticalAnchor at the top of the world.
      Returns:
      The anchor
    • belowTop

      SurfaceRule.VerticalAnchor belowTop(int blocks)
      Returns an SurfaceRule.VerticalAnchor below the top of the world.
      Parameters:
      blocks - The amount of block below the top of the world
      Returns:
      The anchor
    • bottom

      Returns an SurfaceRule.VerticalAnchor at the bottom of the world.
      Returns:
      The anchor
    • aboveBottom

      SurfaceRule.VerticalAnchor aboveBottom(int blocks)
      Returns an SurfaceRule.VerticalAnchor above the bottom of the world.
      Parameters:
      blocks - The amount of block above the bottom of the world
      Returns:
      The anchor