Interface RotatedBlockProvider

All Superinterfaces:
BlockStateProvider, Wrapper

@NullMarked @AsOf("3.0.0") public interface RotatedBlockProvider extends BlockStateProvider
Supplies block states from another provider and rotates their directional properties.
Since:
3.0.0
See Also:
  • Method Details

    • state

      @AsOf("4.0.0") BlockStateProvider state()
      The provider supplying the state to rotate.
      Returns:
      the nested block state provider
      Since:
      4.0.0
    • direction

      @AsOf("4.0.0") Optional<BlockFace> direction()
      The fixed direction used for rotation, or an empty value to choose a random direction.
      Returns:
      the optional fixed direction
      Since:
      4.0.0
    • of

      @AsOf("4.0.0") static RotatedBlockProvider of(BlockStateProvider state, Optional<BlockFace> direction)
      Creates a new rotated block provider.
      Parameters:
      state - the provider supplying the state to rotate
      direction - the fixed direction, or an empty value to choose one randomly
      Returns:
      a new rotated block provider
      Since:
      4.0.0
    • of

      @AsOf("3.0.0") static RotatedBlockProvider of(Material state)
      Creates a provider that randomly rotates the supplied material.
      Parameters:
      state - the material to supply and rotate
      Returns:
      a new rotated block provider
      Since:
      3.0.0