Music Books is a custom plugin that allows you to write musical compositions in Books.
Punching a jukebox with a book will play the musical composition written inside it. You can stop the playback of a music book by sneaking and punching the jukebox with the book in your hand.
If you intend to sell music books, consider copyrighting them to prevent them from being copied.
There are 7 musical notes: A, B, C, D, E, F and G.
Notes can be natural (e.g. A), sharp (e.g. A#) or flat (e.g. Ab).
Notes that are separated by spaces are played after each other. Notes that are not separated by spaces are played at the same time. This is useful for chords. For example, GBD
plays the G major chord.
There are two octaves: 0
and 1
. Notes can be played on a specific octave by adding the octave number to them, e.g. A1
. By default, notes will play on the zeroth octave.
Writing o<number of octave>
, i.e. o0
or o1
, will change the default octave of subsequent notes to that number.
There is actually a third octave: 2
. But because of a Minecraft limitation, it can only be used for the note F#
.
Notes are played every beat. Beats last for 50 milliseconds (1 Minecraft tick) by default.
d<beat duration in milliseconds>
, e.g. d200
for 200 millisecond beats.b<beats per minute>
, e.g. b100
for 100 BPM.-
. Every -
pauses for an extra beat, e.g. ---
pauses for three beats.
\
written after a note's letter will halve the beat duration. For example, F#\
will play the next note two times more quickly than F#
.*
written after a note's letter will reduce the beat duration by one third. For example, F#*
will play the next note three times more quickly than F#
./
written after a note's letter will quarter the beat duration. For example, F#/
will play the next note four times more quickly than F#
.
Change instrument by writing the instrument's code, e.g. i7
for the guitar.
Instrument Code | Instrument |
---|---|
i0 |
Piano (default) |
i1 |
Bass Drum |
i2 |
Snare Drum |
i3 |
Sticks |
i4 |
Bass |
i5 |
Flute |
i6 |
Bell |
i7 |
Guitar |
i8 |
Chime |
i9 |
Xylophone |
i10 |
Iron Xylophone |
i11 |
Cow Bell |
i12 |
Didgeridoo |
i13 |
Bit |
i14 |
Banjo |
i15 |
Pling |
i16 |
Zombie |
i17 |
Skeleton |
i18 |
Creeper Fuse |
i19 |
Ender Dragon Growl |
i20 |
Wither Skeleton |
i21 |
Piglin |
Dynamic markings determine how loudly notes are played.
Marking | Name | Level |
---|---|---|
p |
piano | “Quiet” - default loudness |
mp |
mezzo-piano | Moderately quiet |
mf |
mezzo-forte | Moderately loud |
f |
forte | Loud |
In the example below, the first three notes (A A A) are played mezzo-piano, and the last three notes (B B B) are played forte.
mp A A A f B B B
To play a single note using the next loudest dynamic marking, add an accent to it (>
). To use the next-to-next loudest dynamic marking, use a marcato (^
).
In the example below, A A A is played piano, B is played mezzo-piano, C is played mezzo-forte, and D D D is played piano.
p A A A B> C^ D D D
Labels are named collections of notes that play simultaneously with the main beat. This allows multiple instruments to be played at the same time.
A label is defined by writing notes between labelname:
and :labelname
. The label name can be anything, as long as it isn't used by another label.
In the example below, we create a label called example_label
with the notes A A A
.
example_label: A A A :example_label
:example_label
both marks the end of the label and plays the label. The notes inside the label will be played at the same time as whatever comes after the label.
In the example below, example_label
(A A A) will be played simultaneously with B B B.
example_label: A A A :example_label B B B
Creating multiple labels lets you play multiple sets of notes at the same time.
In the example below, the labels guitar_label
, piano_label
and bass_label
are all played at the same time as D D D.
guitar_label: i7 A A A :guitar_label
piano_label: i0 B B B :piano_label
bass_label: i4 C C C :bass_label
D D D
To repeat a label, just write :labelname
again.
This is a basic composition based on the folk song Kâtibim.
d225 i7
E F E D C B C D
E F E D C B A
E F E D C B C D E
----
E F E D C B C D
E F E D C B A
B D C B B A A G# A
A - E E E F E F G1 E E
D D D C D E
---
A - E E E F E F G1 E E
D D D C D E
---
A - B C D E F E D C B A
B D C B B A G# A B
----
A - B C D E F E D C B A
B D C B B A B A G# A