Skip to content

mcutils:strippable

Vanilla strippable block behavior.

Registering

Before you can use this component you need to register it.

js
import { system } from "@minecraft/server";
import { StrippableComponent } from "@lpsmods/mc-utils";

system.beforeEvents.startup.subscribe((event) => {
  event.blockComponentRegistry.registerCustomComponent(StrippableComponent.typeId, new StrippableComponent());
});

Component

Options

NameTypeDefaultDescription
blockstring
sound_eventstringdig.wood

Examples

Log

json
{
  "format_version": "1.21.100",
  "minecraft:block": {
    "description": {
      "identifier": "wiki:custom_log",
      "traits": {
        "minecraft:placement_position": {
          "enabled_states": ["minecraft:block_face"]
        }
      }
    },
    "components": {
      "mcutils:strippable": {
        "block": "wiki:stripped_log",
        "sound_event": "dig.wood"
      }
    }
  }
}

Not associated with or approved by Mojang Studios or Microsoft