Interface VeinMiningPattern

All Known Implementing Classes:
VeinMiningPatternDefault, VeinMiningPatternStaircase, VeinMiningPatternTunnel

public interface VeinMiningPattern
Represents a pattern used to allocate blocks for vein mining.
  • Method Details

    • getKey

      @NotNull @NotNull NamespacedKey getKey()
      Get the NamespacedKey of this pattern.
      Returns:
      the key
    • allocateBlocks

      @NotNull @NotNull Set<BlockPosition> allocateBlocks(@NotNull @NotNull BlockAccessor blockAccessor, @NotNull @NotNull BlockPosition origin, @NotNull @NotNull BlockFace destroyedFace, @NotNull @NotNull VeinMinerBlock block, @NotNull @NotNull VeinMiningConfig config, @Nullable @Nullable BlockList aliasList)
      Allocate all BlockPositions that should be mined according to the input values.
      Parameters:
      blockAccessor - the block accessor
      origin - the position at which the vein mining was initiated
      destroyedFace - the face on which the block was destroyed
      block - the type of VeinMinerBlock that was broken at the origin
      config - the configuration applicable for this instance of vein mining
      aliasList - a BlockList of all blocks that should also be considered. May be empty
      Returns:
      the allocated block positions
    • allocateBlocks

      @NotNull default @NotNull Set<BlockPosition> allocateBlocks(@NotNull @NotNull BlockAccessor blockAccessor, @NotNull @NotNull BlockPosition origin, @NotNull @NotNull BlockFace destroyedFace, @NotNull @NotNull VeinMinerBlock block, @NotNull @NotNull VeinMiningConfig config)
      Allocate all BlockPositions that should be mined according to the input values.
      Parameters:
      blockAccessor - the block accessor
      origin - the position at which the vein mining was initiated
      destroyedFace - the face on which the block was destroyed
      block - the type of VeinMinerBlock that was broken at the origin
      config - the configuration applicable for this instance of vein mining
      Returns:
      the allocated block positions
    • getPermission

      @Nullable default @Nullable String getPermission()
      Get the permission node required to use this pattern.
      Returns:
      the permission node, or null if none