Minecraft:Jukebox song definition: Difference between revisions
From SAS Gaming Wiki
More actions
Sync: updated from Minecraft |
Sync: updated from Minecraft |
||
| Line 7: | Line 7: | ||
<div class="treeview"> | <div class="treeview"> | ||
* {{nbt|compound}} The root object. | * {{nbt|compound}} The root object. | ||
** {{nbt|string}}{{nbt|compound|sound_event}}: {{json ref|server-side sound event|inline=1}} — The event to play when the item is inserted in a jukebox. Note that only vanilla ''Minecraft'' sound events have a server-side sound event that can be referenced directly by {{nbt|string}} ID; custom sound events must be specified in {{nbt|compound}} object form. | ** {{nbt|string}}{{nbt|compound|sound_event}}: {{json ref|server-side sound event|inline=1}} — The event to play when the item is inserted in a jukebox. Note that only vanilla ''Minecraft'' sound events have a server-side sound event that can be referenced directly by {{nbt|string}} ID; custom sound events must be specified in {{nbt|compound}} object form. The {{nbt|float|range}} value is ignored, since jukebox songs are transmitted to clients as part of the jukebox update event and not as normal sounds. | ||
*** {{nbt inherit/sound event}} | *** {{nbt inherit/sound event}} | ||
** {{nbt|string}}{{nbt|compound|description}}: A [[Minecraft:text component]] to display in the tooltip of the item. | ** {{nbt|string}}{{nbt|compound|description}}: A [[Minecraft:text component]] to display in the tooltip of the item. | ||
Latest revision as of 11:11, 15 September 2026
A jukebox song is a song played when an item with the Template:Cd item data component is inserted into a Minecraft:jukebox. Jukebox songs can be defined using Minecraft:JSON files in a Minecraft:data pack at the path Template:Cd.
JSON format
Jukebox songs are defined using the following format:
- Template:Nbt The root object.
- Template:NbtTemplate:Nbt: Template:Json ref — The event to play when the item is inserted in a jukebox. Note that only vanilla Minecraft sound events have a server-side sound event that can be referenced directly by Template:Nbt ID; custom sound events must be specified in Template:Nbt object form. The Template:Nbt value is ignored, since jukebox songs are transmitted to clients as part of the jukebox update event and not as normal sounds.
- Template:NbtTemplate:Nbt: A Minecraft:text component to display in the tooltip of the item.
- Template:Nbt: The length of the song in seconds. Determines the length of the redstone output of the jukebox. If the sound is longer, it is cut off after this time.
- Template:Nbt: Value between 0 and 15 — The redstone power output by a Minecraft:comparator when placed next to a jukebox playing this song.
History
Template:Navbox Java Edition technical
Minecraft:de:Plattenspielermusikdefinition Minecraft:fr:Définition de chanson de jukebox Minecraft:ko:주크박스 곡 정의 Minecraft:pt:Definição de música do toca-discos Minecraft:uk:Визначення пісні програвача Minecraft:zh:唱片机曲目定义格式