Sound (Interaction)

Customize the sound the machine make when placed, broken, step on...

The interaction_sound property can be used to customize which sound the machine will make when the player place/break/hit/step on/fell on it.

There are 2 ways of using this property :

Copying another block

Simply specify a block id to the property and the machine will copy all sounds it make.

You can also use the namespace:block[property1=value1,property2=value2] syntax here as some blocks may have different sounds depending on their state.

Example

This machine will make the same sound than a netherite block.

"appearance": {
    "interaction_sound": "minecraft:netherite_block"
}

Tweaking sounds individually

The 5 interaction sounds break, place, hit, fall and step can be defined independently.

You can define them using either :

  • A block : namespace:block_id

  • A blockstate : namespace:block_id[property=value, property2=value2]

  • A sound : namespace:sound_id

Look at the suggestions given by the /playsound command in game to see all available sound ids. You can also add your own sounds.

You can also specify a volume and pitch that will be used when playing the sound.

Default value for both volume and pitch is 1.0

Example

This machine will have the sound of the stone when placed, the grass when broken, and the npc hurt sound when step on.

"appearance": {
    "interaction_sound": {
      "volume": 1.0,
      "pitch": 1.0,
      "place": "minecraft:stone",
      "break": "minecraft:grass",
      "step": "minecraft:entity.villager.hurt"
    }
}

Last updated