Believe it or not, there are still players that listen to music discs in Minecraft, including me.
I tried making a command loop that would play different discs for me every 5 minutes. Here's what command I use:
/execute at Quijibo run playsound minecraft:music_disc.stal record Quijibo
This successfully executes the command, and the music starts playing, but if I move away from the point where I was standing, the music fades away, as if there was a jukebox playing the music that I'm moving away from.
What I want to do is have the music follow me when moving. Is this possible to do through commands?
Best Answer
In theory the
minimumVolume
parameter should fulfil exactly this purpose, but I couldn't get it to work. Maybe that's a bug.But the
volume
parameter of/playsound
can in a way actually be used to specify a spatial volume instead of an audio volume! The trick, as described in the wiki (archive):That means that you can just enter the maximum value of a
Float
, except that it's for some reason slightly different in Minecraft. By just trying out values I found that the maximum value is:So you can use this command to play a sound everywhere:
That way it only gets 0.000000000000000000000000000024936% quieter when you go to the other end of the world.
This even works across dimensions for some reason. But when you go through a portal, the sound stops.