Skip to content

Tutorial: Footstep Configuration

OreCruncher edited this page Dec 16, 2016 · 13 revisions

This tutorial assumes that you have already created a Json configuration file. If you haven’t please read Tutorial: External Configuration Files.

The “footsteps” entry in the configuration file is used to specify what sounds to play when a player is walking on or through a block.

   "footsteps":{
	"minecraft:barrier":"NOT_EMITTER",
	"minecraft:air":"NOT_EMITTER",
	"minecraft:stone":"stone",
	"minecraft:grass":"grass",
	"minecraft:grass_path":"grass"
   }

The list is comprised of value pairs. The value on the right is the acoustic profile to apply to the block that is specified on the left side. Above, “minecraft:air” is not an emitter so it is set to “NOT_EMITTER”. The block “minecraft:stone” is set to have the acoustic profile of “stone”.

In the above example the block specification would apply to a block that is a singleton (i.e. “minecraft:barrier” has no variants), or if the block had variants it would apply to all variants of that block. If you wanted to specify an acoustic for a specific variant you need to have an entry for it. For example:

"minecraft:sponge^0":"organic_dry",
"minecraft:sponge^1":"mud",

The sponge has two variants - one that is dry, and one that has absorbed water. The dry version will have the acoustic of “organic_dry”, and the wet one will have the acoustic of “mud”. Note that the variant is specified after the carat “^”.

A more complicated example is that of “minecraft:double_plant”:

"minecraft:double_plant":"NOT_EMITTER",
"minecraft:double_plant+messy":"MESSY_GROUND",
"minecraft:double_plant^0+foliage":"brush",
"minecraft:double_plant^1+foliage":"brush_straw_transition",
"minecraft:double_plant^2+foliage":"brush",
"minecraft:double_plant^3+foliage":"brush_straw_transition",
"minecraft:double_plant^4+foliage":"brush_straw_transition",
"minecraft:double_plant^5+foliage":"brush_straw_transition",
"minecraft:double_plant^8+foliage":"brush",
"minecraft:double_plant^9+foliage":"brush",
"minecraft:double_plant^10+foliage":"brush",
"minecraft:double_plant^11+foliage":"brush",
"minecraft:double_plant^12+foliage":"brush",
"minecraft:double_plant^13+foliage":"brush",
"minecraft:double_plant^14+foliage":"brush",
"minecraft:double_plant^15+foliage":"brush",

The first thing to note is that the block specifications have either a “+messy” or “+foliage” added to the entry. These are called substrates.

  • messy This is the acoustic that is played when a player moves through a block like reeds.
  • foliage This is the acoustic that is played when Dynamic Surroundings checks for foliage above the block the player is standing on. Typically this acoustic is played in addition to the acoustics of the block beneath the player.

Other possible substrates are:

  • carpet This acoustic is for when Dynamic Surroundings does a carpet check. Obviously carpets fall into this category, but other things that use this acoustic style are pressure plates and snow layers.
  • bigger This acoustic is special to things like fences. The bounding box of a fence extends a half block above thus it is considered “bigger”. (For fences it is preferential to use the acoustic “#fence” because it simplifies configuration.)

It is worth pointing out that multiple acoustics can be combined for a block. For example, this is what the Minecraft standing banner looks like:

"minecraft:standing_banner":"rug,straw,squeakywood",
"minecraft:standing_banner+foliage":"rug,straw,squeakywood",

The standing banner, both from a block perspective and a foliage perspective, will play three acoustics when triggered: rug, straw, and squeakywood. Combining acoustics is a good way to get a different sound.