1
Music loops for a map
hello im making a map and im trying to find a way to make music loop in Minecraft 1.16 but I cant figure out how.
Create an account or sign in to comment.
10
put "/playsound (the music) master (something close to that anyway)" into a command block and time the redstone signal to power (with a hopper clock assumedly) when the other song ends..
Ask the players to turn music off in the sounds menu (so it doesn't conflict with your tracks)
Dunno if thats what you mean, but there ya go!
Ask the players to turn music off in the sounds menu (so it doesn't conflict with your tracks)
Dunno if thats what you mean, but there ya go!
Unfortunately, the only way I can think of, is to replay the music after the original music has finished. You will need to calculate how long your piece of music plays for and hook it up to a scoreboard. After that period has ended, replay the sound.
This is correct, since Minecraft doesn't know when a sound ends.
That is the best way, but I don't use scoreboards, I use /schedule command with a datapack.
does this require the data pack?
Is you use the /schedule command, yes you will need a datapack.
does this work for 1.16 and can I specify when the music starts and stops or is it just always on, I know I can stop it with /stop sound @a music/master/ambient/hostile mobs/friendly mobs/ jukebox noteblock/weather/blocks
It should work with all versions that allow you to have a timer scoreboard or /schedule, so its 1.8+
can you walk me through how to do it I would really appreciate your help. I have no experience at all using scoreboards or schedules
For scheduling:
[In the function]:
<Playsound command once>
For scoreboard:
/scoreboard objectives add timer dummy
repeating command blocks/function:
[In the function]:
<Playsound command once>
schedule function <function the playsound command is> <music time>t replace
For scoreboard:
/scoreboard objectives add timer dummy
repeating command blocks/function:
/scoreboard players add dummy timer 1
/execute if score dummy timer matches 1 run <playsound command>
/execute if score dummy timer matches <1+music duration> run scoreboard players reset dummy