Mojira Archive
MC-89848

playsound/sound engine pitch algorithm isn't working properly

When using the /playsound command to replicate musical notes, it is important that the notes are tuned correctly. However this does not appear to be the case, as sometimes notes are slightly sharp or flat when they shouldn't be.

To Reproduce:

1. Create a test world
2. Place a repeating command block, set to "always active", with the following command:

/playsound block.note.harp master @p ~ ~ ~ 1 1 1

A note should begin playing.

3. Change the command to

/playsound block.note.harp master @p ~ ~ ~ 1 1.05946309436 1

A new note will begin playing. It should be exactly 1 semitone higher, however it is off by more than 20 cents. If you actually wanted to play the note 20 cents lower, you should type

/playsound block.note.harp master @p ~ ~ ~ 1 1.04729412282 1

You may need an equal-tempered tuner to properly conduct the measurements.