====== minecraft:play_sound ====== The ''minecraft:play_sound'' action plays a sound event at a player or position in the world. If ''this'' player is not present, it will fall back to playing the sound from the specified position. This action is always successful. ===== Fields ===== ^ Name ^ Description ^ Type ^ Default Value ^ | ''position'' | The position to target. | An [[actions:action_contexts#parameters|action context parameter]] | | | ''sound'' | The sound event to play. | A [[mc>Sounds.json#Sound_events|sound event]] | | | ''category'' | The category to play the sound in. | A [[mc>Sound#Categories|sound category]] | | | ''volume'' | The volume to use for the sound. The actual volume is picked randomly between the minimum and maximum. | A [[extras:ranges|float range]] | | | ''pitch'' | The pitch to use for the sound. The actual pitch is picked randomly between the minimum and maximum. | A [[extras:ranges|float range]] | | | ''from_entity'' | Whether to play the sound event from ''this'' player, rather than the position. | An optional boolean | ''false'' | ===== Example ===== { "type": "minecraft:play_sound", "position": "this", "sound": "minecraft:item.bottle.fill", "category": "neutral", "volume": 1.0, "pitch": 1.0 }