The bug
Ambiance / cave music can play far away from the player. This way the player might hear it less often than it should appear.
Report history
This report used to include in-game and title music as well. These were fixed in previous versions.
Code analysis
Based on 1.11 decompiled using MCP 9.35 rc1
The problem is that the method net.minecraft.client.multiplayer.WorldClient.playMoodSoundAndCheckLight(int, int, Chunk)
, which plays the ambient cave sound, is called with chunk coordinates of all visible chunks and only tests if the position tested is at least 2 meters away. This means the position can be hundreds of blocks away.
Example fix (1.11)
protected void playMoodSoundAndCheckLight(int p_147467_1_, int p_147467_2_, Chunk chunkIn)
{
super.playMoodSoundAndCheckLight(p_147467_1_, p_147467_2_, chunkIn);
if (this.ambienceTicks == 0)
{
this.updateLCG = this.updateLCG * 3 + 1013904223;
int i = this.updateLCG >> 2;
int j = i & 15;
int k = i >> 8 & 15;
int l = i >> 16 & 255;
BlockPos blockpos = new BlockPos(j + p_147467_1_, l, k + p_147467_2_);
IBlockState iblockstate = chunkIn.getBlockState(blockpos);
j = j + p_147467_1_;
k = k + p_147467_2_;
// Old code
//if (iblockstate.getMaterial() == Material.AIR && this.getLight(blockpos) <= this.rand.nextInt(8) && this.getLightFor(EnumSkyBlock.SKY, blockpos) <= 0 && this.mc.player != null && this.mc.player.getDistanceSq((double)j + 0.5D, (double)l + 0.5D, (double)k + 0.5D) > 4.0D)
//{
// this.playSound((double)j + 0.5D, (double)l + 0.5D, (double)k + 0.5D, SoundEvents.AMBIENT_CAVE, SoundCategory.AMBIENT, 0.7F, 0.8F + this.rand.nextFloat() * 0.2F, false);
// this.ambienceTicks = this.rand.nextInt(12000) + 6000;
//}
if (this.mc.player != null) {
double distanceToPlayerSquared = this.mc.player.getDistanceSq((double)j + 0.5D, (double)l + 0.5D, (double)k + 0.5D);
// The player cannot hear the sound if it is played more than 15 (sqrt(255)) blocks away
if (distanceToPlayerSquared > 4.0 && distanceToPlayerSquared <= 255.0 && iblockstate.getMaterial() == Material.AIR && this.getLight(blockpos) <= this.rand.nextInt(8) && this.getLightFor(EnumSkyBlock.SKY, blockpos) <= 0)
{
this.playSound((double)j + 0.5D, (double)l + 0.5D, (double)k + 0.5D, SoundEvents.AMBIENT_CAVE, SoundCategory.AMBIENT, 0.7F, 0.8F + this.rand.nextFloat() * 0.2F, false);
this.ambienceTicks = this.rand.nextInt(12000) + 6000;
}
}
}
}
Related issues
is duplicated by
relates to
Comments

Confirmed, but the commande /playsound music.game @a 1000 still works.

Using /playsound isn't really the same since you're basically manually telling the game to play the music instead of letting it happen naturally.

Can confirm, also this bug report is a duplicate of MC-91610.

@@unknown: MC-91610 is about not having any sound at all, this is only about having no automatic background music but rest of sounds.

To Kumasasa: The Author of MC-91610 updated his versions and status for effected versions to include the no music within the game or at the title screen. I myself tried playing the game today and noticed a lot of the sound issues have been addressed and I thank you guys for that.

Ditto, can confirmed, no music in overworld/end/nether.
What about the "Creative" music?
And music disks?

Yes, I noticed in at least the two latest snapshots 15w49 and 15w48 the music does not play on it's own, for the title screen at least. I haven't really confirmed that for in-game since I turned it off since I thought it wasn't working.

Confirmed for most minecraft 1.9 snapshots. I have played 15w40a-15w49b and have not heard background music. Have not tested in other snapshots. I can still hear all of the other sounds though.

If you want, type/copy following text.
/playsound music.creative @a ~ ~ ~ 10 1
It should play music.

We are already aware that using /playsound works โ it has nothing to do with this bug though. This bug is about the music playing normally, meaning on its own.

Still no music in 15w50a

this bug is on Mac too. i really enjoy the minecraft music and hope this gets fixed real soon.

Still no music in 15w51a ๐

No music in 15w51b, FeelsBadMan.

@all: This is not a discussion forum. If you don't have anything to contribute to the current bug like confirming if unconfirmed, work around or steps to reproduce - then simply don't do it.

16w02a: no title music, even after disabling and re-enabling music, then restarting. No sign of in-game music in any game mode or dimension. Credits music works.
Confirmed for 16w02a.
Mod please reopened.

Can confirm it's not fixed in 16w02a.

Same, not fixed in 16w02a.

It might have Something to do with sounds not being written to the correct areas, such as a witch still cackles when hostile mob sounds are off, and other things like that.(The last place I saw this was 15w51b though, so it might be fixed)

@@unknown: That is most likely not the issue, since it also occurs when all audio sliders are set to 100%.

Still an issue in 16w03a. That one really should be fixed before the actual release.

Can confirm that it's still not fixed in 16w04a.

STILL not fixed in 16w05a

Confirmed, neither music nor cave sounds in 16w05a

Not fixed in 16w05b
So, finally REALLY fixed.

Yes, really fixed! Thank you!
EDIT: well, the music is fixed, anyway. I have yet to hear any naturally-occurring cave sounds. Can anyone confirm that those work?

Not fixed. At first launch of 16w06a. I heard music play in title screen and was pleasantly surprised. But it didn't play at all in any of my worlds or on my server. Now it doesn't play anymore even in the title screen. I've toggled the music option on and off several times, but to no avail. No more music.

My music is working fine, but an hour of standing in an unlit cave system has not produced any cave sounds.
/playsound minecraft:ambient.cave ambient @p makes cave sounds, but they don't randomly play.

No cave sounds still, in 16w06a.

I've got music in 16w06a. It plays in both the menu and in game, in a world from a development snapshot that predates this bug if that makes any difference.
I was playing on 6 chunk render distance and having plenty of music. I switched to 10 chunks while in the Nether and as usual it slowed and got choppy for a few seconds, then started to come back to pace. Moments later it froze completely for several seconds--this is not normal but not unheard of in the Nether--but after coming back, the music disappeared and several minutes later there still had been no music, even after going back to the overworld and experiencing a sunset and sunrise. (They seem to trigger music sometimes.) I exited to the menu and went back in, and had music back again.

I spent more time looking into this one. At launch, the title music plays without issues. I don't have a clue as to why it didn't work at all at first. After joining a world, either local or remote, the music usually kicks in after a few seconds. Again I don't know why I had none earlier. After the first song finished playing, no more music. I continued playing for about 30 minutes without any music. When I left to the title screen, still no music. I relaunched the game and the music came back, both on the title screen and in game. But again, only for one song.

Sometimes the music goes silent but it shouldn't do that for more than about half a Minecraft day. Perhaps some chunk update or lag spike issue is causing this. Can you try playing in a lower render distance and see if the music remains, or if when it disappears it was during a lag spike?

Because of MC-94438, the lag spikes are pretty constant on my server. During daytime the server usually runs at around 16-18 TPS and during the night it runs at about 12-14 TPS. So daytime lasts around 11 to 13 minutes and nighttime lasts around 16 to 18 minutes.
I reduced my view distance to 6 chunks, stayed on for a full day cycle (+- 25 mins), and got the same result. No more music after first song is finished. The song does play completely though, nothing stops it. There's just nothing afterward.
Edit: Murphy's law; seconds after posting this, music kicked in! But that's still over 18 mins after 1st song finished.

Music is playing fine for me, but cave/ambient sounds are not played as others have already mentioned. So can confirm the cave/ambient sound issue.

Music is now playing fine in 16w06a for me so I'm confirming it fixed, I noticed it's not in the changelog, just thought I'd mention it.

look in previous comments, the music is fixed, ambience (cave sounds) not

I think the bug name/description should be updated to more accurately fit the bug now. It should be something like "In-game cave ambiance does not play automatically".

Still not hearing cave sounds in 1.9 Pre-2

I was just editing the recording I made last night of my friend and I playing survival, and randomly (about 2 hours in) I heard cave ambiance play. Didn't notice it before now.

Then we can consider this as fixed ?

I spent an hour in an unlit cave system and did not hear a single cave sound. All volume settings turned up, all other sounds are working great. I heard lots of music, bats, lava, water, nothing else.

Try spending 2 hours in or near an unlit cave system, as we were on the surface when it played. We played for 4 hours, yet it only happened that one time, so maybe it's just extremely uncommon?

Haven't heard any ambient sounds in 1.9 pre-release 3 so far ... running around in full sunlight near completely dark rooms and cave systems, I can hear zombies, skeletons, witches, bats but no cave ambience

Spent some time in caves, didn't hear anything!

1.9-pre4, /playsound minecraft:ambient.cave ambient @p works fine, but I'm still not hearing anything while hanging out in dark caves.

reopened as of @unknown comment

Grum has a really bad habit of marking bugs as resolved before he has actually done anything about it. He really needs to stop doing that. Marking a bug as fixed for a later update is just an easy way to forget about it.

Playing MC survival (1.9 pre 4) for an hour now, found a village right after spawning, removed all torches, sealed off all windows and doors to make them completely dark inside ... all houses are filled with zombies, skeletons and spiders by now, there are also dark caves directly underneath the village, but haven't heard a single cave sound so far ๐
@Krev Hard to say if he actually has done anything about it, maybe he just forgot to push his commits, maybe he didn't test it, maybe it broke again because of something else, dunno ... I just think after 3 attempts and 3 days before a major release, something like this should be fixed.

The official Mojang blog had "Fixed an issue that can affect sound positions" listed for 1.9-pre4, so I'm thinking someone went "well, that should fix it", and marked it as fixed again without actually verifying the fix.

It is fixed in 1.9 release, I know because the ambiance scared me, the thing is it only triggered when I got hit by a zombie.

Still haven't heard it once since the release of 1.9.
Interesting enough, if you turn subtitles on, you will occasionally see "Erie noise" but nothing is actually heard. I could assume these are meant to be the cave sounds.

Haven't heard any cave ambience in 1.9.1-pre1 so far ...

No ambience in caves for 1.9.2 so far

No cave ambience in 16w15a either ... the sounds even show up in the subtitles as "Erie noise" from time to time as Sebastiano La Gala mentioned, but the sound itself doesn't play at all.

Every so often when I load a chunk with a minecart in it, the subtitles will say "Minecart rolls" dispite being more than out of range of the sound. So the fact that it's also saying "Eerie noise" without playing the cave ambiance could mean that it's playing the sound in a random location for some reason, and it's (more likely than not) out of range of the player.

@Krev They're definitely not out of range all the time, especially when walking around directly next to dark rooms and above dark caves, those characteristic sounds are hard to miss when they play and I've used them quite a lot to track down dark areas in previous MC versions. Haven't heard them in any of the 1.9 snapshots and released 1.9.x versions so far.

It would seem that what I said IS the case, as I decided to test it. The test came out positive.
Here's a short video of the test & its setup: https://youtu.be/TzzswTJnHyo
I also tested this in a default world beforehand, and it would occasionally display "Eerie noise" in the subtitles, but I could never make it to the location before the sound stopped. In the video, I fixed this by making a smaller, more controlled environment to test with. It worked oddly well.
I'm gonna test some more to try and see how consistent it is, even though I'm now willing to bet it's 100% consistent.
Confirm for 1.9.3 pre-2

No in-game cave sounds in 1.9.4

Agreed. I ran around for 10+ minutes in a dark cave and there was absolutely no ambiance that played when I did not enter in the /playsound command to the chat bar.

they should change the name from "In-game cave ambiance does not play automatically / very rare" to "In-game cave ambiance plays away from the player"

because the video that Krev made explains it.

Very true, but it looks like everyone (or most) on this thread seem to be having the same issue, where none at all plays automatically even though the slider is up and the subtitles are on. ๐

the same happened to the level up sound but that was fixed

so it is playing but its not playing directly at the player

proof is on krevs video

still in 1.10 pre 1 ๐

STILL IN PRE 2 ๐

I herd people were talking about new cave sounds were added but not exactly sure if they were because the bug is still here ๐

Used playsound command just now and there are new cave ambience so this bug might get fixed soon i hope

Shows that the words are dark grey and usually in subtitles the words would be white some times u would see the arrow pointing right or left

in the screenshot it shows the problem

Can confirm for all 1.10 pre releases.
I have spent over an hour in the same cave and heard nothing, however the subtitles will mention the ambience sounds being played.
Sums up the last 7 comments in 2 sentences...

So they added 2 new ambient sounds in the last pre-release but we canโt hear them because they didnโt fix this bug?

Still in 1.10

Actually, you can use /playsound
to get it to play (it worked before, the sound is ambient.cave
). It picks one of the sixteen randomly, so I'm not sure if it will work or not. I got annoyed by them playing too much (which wasn't a bug, it was that my base is a giant cave), so when I got 1.8 I disabled them, and re-enabled them in a 1.9 snapshot but haven't heard any. I have upgraded to 1.10; to play the new sounds, use the command*:/playsound minecraft:ambient.cave master @p
Spoiler alert!!: Here is what the new sounds sound like, (I can tell the old from the new because I always live underground because... you get the point):
1. Sounds like breathing
2. Sounds like breathing and tapping
3. Sounds like a discordant warp of a bird, a computer fan, and other various, creepy sounds.
*(I have no idea why, but I started writing equation instead of command ;D)

This bug is still in 1.10 hoping this bug gets fixed in 1.11 or else it will be a bit less interesting to find caves. ๐

I mean they tryed to fix it in 1.9 pre 4 and added new cave ambience why not fix it?

Sam, this has nothing to do with the playsound command. It only has to do with cave ambiance playing naturally.

@@unknown: Please stop constantly editing your posts. 58 people are receiving an email each time you do. The preview feature exists for a reason.

I ask y'all to stop posting garbage here. I subscribed this ticket to be informed when the bug gets fixed, not to see kiddies whining again and again with every new version.

@9000awesomeness that has already said (by yours truely) about a month ago. Please stop commenting stuff that's already been said. I am watching this for information, not users repeating what others have commented

Confirmed for 16w41a
Cave ambiance still plays randomly away from player.

Confirmed for 1.11-pre1

Please post new comments in the future when confirming for newer versions, edits don't show up in the activityfeed.

The bug still in 1.11 version i miss the cave sounds :/

I can confirm that this bug STILL exists in 1.11 - no ambient cave sounds play at all .... despite subtitles indicating that they should be playing.

It's already marked as affected.

Interestingly, this bug was fixed in OptiFine 1.11_HD_U_B3
See here: http://optifine.net/changelog?f=OptiFine_1.11_HD_U_B3.jar

Confirmed for 17w06a

Confirmed for 17w13b, saw a subtitle with no sound accompanying it.

Confirmed for 17w14a.
Not sure why the bug summary/description still mention game music. The bug should be renamed to simply, "Cave Ambiance plays too far away from player"

Confirmed for 17w15a.
Also, thanks to whoever updated the summary/description.

Confirmed for 17w16a.

Confirmed for 17w16b.

Confirmed for 17w17a.

Still not fixed in 1.12-pre3 !!!
Another update to be released and this issue remains. How come that such an important feature is even kept broken before realising an update in the first place, let alone 3 more updates afterwards? Those ambient sounds exist since Minecraft alpha and are as characteristic for this game as creepers. Before 1.9, Iโve been regularly using ambience sounds in survival to detect dark caves or holes around my bases, and now โฆ you know how often I heard them after the 1.9 update in a standard survival world? One time โฆ one single time โ and only because I was by chance sprinting towards the sound while running from a few mobs.
Thereโs even a possible fix pointed out in this bug report. Is there any technical reason why this canโt be fixed over such a long period of time (nearly two years now I think?) or is every snapshot and update developed and tested with all sounds turned off before releasing them? The fact that MC-35856 still isnโt fixed either would suggest latter case. I mean, itโs pretty obvious those eery cave sounds are missing when walking around dark places or having overlapping music play when you load a different world. One would really think that the developers of the most successful game ever would at least fix such obvious bugs in a reasonable timeframe ... espcecially when there's apparently enough dev time for adding llamas or parrots. Not cool, Mojang, really not cool ๐

I haven't heard a cave sound since this bug first came out in 1.9 development snapshots. What's the point of adding more cave sounds if they can't be heard? Talk about sorting your priorities.
I put in several hours of gameplay with the subtitles turned on. I've seen a bunch of cave sounds play in the subtitles along with the very strange "minecart rolls" showing up repeatedly pretty much anywhere in the world, in places where there's no minecarts around. I still haven't heard any cave sounds, and I also can't hear any sound playing for "minecart rolls". I used spectator mode to try and discover the location of the alleged minecart, but found nothing.

Appears to be fixed in 1.12.2 pre-1.

Can confirm, it's fixed. Just did a test run and heard more ambient sounds from caves by playing for 30 min in a random world than over the last 2 years. I wish I could say "thanks Mojang for fixing this", but I made my point pretty clear in my last comment. Some things just shouldn't take that long or at least be communicated why they do so. Just glad it works now :-|

Confirm, but its working only in survival without night vision and happens pretty rare, also in minecraft 1.2.1 (ios), its still missed

Someone in MC-139255 reported that this is an issue in 18w45a again. Can anyone confirm this?

Made a quick test world with two meters of dark space beneath a flat layer of stone, perfect to provoce cave ambient sounds. Tested it in 1.13.2, heard the first one after 10 min. Then tested it in 18w45a, none after 30 min. They might really be broken again.

I did my test again, and it turns out that cave ambiance just doesn't play at all in 18w46a. Probably has to do with the new light engine changes, but that's just a guess.

I'd like to point out that this is technically no longer the same bug due to cave ambiance not playing at all (where before it only played away from the player).
Can confirm. Most likely due to sound rewrites.