Interface CustomBlockComponents


public interface CustomBlockComponents
This class is used to store components for a custom block or custom block permutation.
Since:
2.2.0
  • Method Details

    • selectionBox

      @Nullable BoxComponent selectionBox()
      Gets the selection box component Equivalent to "minecraft:selection_box"
      Returns:
      the selection box
      Since:
      2.2.0
    • collisionBox

      @Deprecated(since="2.9.5") @Nullable BoxComponent collisionBox()
      Deprecated.
      Use collisionBoxes() instead
      Gets the collision box component Equivalent to "minecraft:collision_box"
      Returns:
      the collision box
      Since:
      2.2.0
    • collisionBoxes

      @NonNull Set<BoxComponent> collisionBoxes()
      Gets the collision boxes component. Equivalent to "minecraft:collision_box", which can be either one, none, or up to 16 collision boxes.
      Returns:
      the collision boxes
      Since:
      2.9.5
    • displayName

      @Nullable String displayName()
      Gets the display name component. Equivalent to "minecraft:display_name"
      Returns:
      the display name
      Since:
      2.2.0
    • geometry

      @Nullable GeometryComponent geometry()
      Gets the geometry component. Equivalent to "minecraft:geometry"
      Returns:
      the geometry
      Since:
      2.2.0
    • materialInstances

      @NonNull Map<String,MaterialInstance> materialInstances()
      Gets the material instances component Equivalent to "minecraft:material_instances"
      Returns:
      the material instances
      Since:
      2.2.0
    • placementFilter

      @Nullable List<PlacementConditions> placementFilter()
      Gets the placement filter component Equivalent to "minecraft:placement_filter"
      Returns:
      the placement filter
      Since:
      2.2.0
    • destructibleByMining

      @Nullable Float destructibleByMining()
      Gets the destructible by mining component Equivalent to "minecraft:destructible_by_mining"
      Returns:
      the destructible by mining value
      Since:
      2.2.0
    • friction

      @Nullable Float friction()
      Gets the friction component Equivalent to "minecraft:friction"
      Returns:
      the friction value
      Since:
      2.2.0
    • lightEmission

      @Nullable Integer lightEmission()
      Gets the light emission component Equivalent to "minecraft:light_emission"
      Returns:
      the light emission value
      Since:
      2.2.0
    • lightDampening

      @Nullable Integer lightDampening()
      Gets the light dampening component Equivalent to "minecraft:light_dampening"
      Returns:
      the light dampening value
      Since:
      2.2.0
    • transformation

      @Nullable TransformationComponent transformation()
      Gets the transformation component Equivalent to "minecraft:transformation"
      Returns:
      the transformation
      Since:
      2.2.0
    • unitCube

      @Deprecated(since="2.2.2") boolean unitCube()
      Deprecated.
      Use geometry() and compare with `minecraft:geometry.full_block` instead.
      Gets the unit cube component Equivalent to "minecraft:unit_cube"
      Returns:
      the rotation
      Since:
      2.2.0
    • placeAir

      boolean placeAir()
      Gets if the block should place only air Equivalent to setting a dummy event to run on "minecraft:on_player_placing"
      Returns:
      if the block should place only air
      Since:
      2.2.0
    • tags

      @NonNull Set<String> tags()
      Gets the set of tags Equivalent to "tag:some_tag"
      Returns:
      the set of tags
      Since:
      2.2.0
    • builder

      Create a Builder for CustomBlockComponents
      Returns:
      a CustomBlockComponents.Builder
      Since:
      2.2.0