mojira.dev
MC-46634

Thunder volume not affected by weather volume settings

The bug

During a thunderstorm, the volume level of the thunder was drowning out other noises (like the music I play in the background), so I opened the volume controls to adjust it down to a tolerable level.

Adjusting weather volume to OFF is the only way to make it change volume. Adjusting weather volume from 0% to 100% had no noticeable effect on the volume of the thunder.

Code Analysis

Code analysis by @unknown can be found in this comment

Related issues

Comments

migrated

Can confirm. When I put the weather volume to 1% I still hear the storm but no the rain

michael

The fix for this problem should fix most of the sound volume related bugs.

wagn

This issue still appears to affect 1.9

migrated

Anybody else seeing this in 1.9 too?

Jeuv

Can confirm in 1.9

migrated

Bump. Still affects 16w39c.

migrated

Is this still an issue in the latest snapshot 16w44a? If so please update the affected versions.

This is an automated comment on any open or reopened issue with out-of-date affected versions.

Torabi

@unknown, please don't do that. Many of the issues you've commented on are not so old or neglected for us to request that the issue be updated, so you've generated a lot of unnecessary spam, without contributing any useful information in the process. Please leave such requests for our moderation team.

migrated

I apologise and won't do it again

Asteraoth

Confirmed for 18w30b

Asteraoth

Confirmed for 18w31a

migrated

Why would this bug need a change in who reported it if it's the same bug i reported 4 1/2 years ago?

qwerty23495

@unknown If you reported a duplicate of this bug, that doesn't mean you can become the reporter.

migrated

IIRC I personally wrote this report 4 1/2 years ago...

It's weird that Asteraoth is mentioned as the reported while David Cady is mentioned as the first active on this issue, I'm quite certain they weren't the ones who reported it.

qwerty23495

Usually a reporter is changed if he or she is inactive for a long period of time. In this case @unknown was inactive for about four years, and @unknown became reporter by confirming versions for the ticket so that it can be updated without the need of a mod or helper. I can't see you as reporter anytime on the log though.

migrated

If this allows someone else to update affected versions, then that makes sense. I'm not really playing Java edition anymore, switched to Bedrock. Can't say I've seen this bug on that version.

migrated

Re-confirmed as a problem in 19w12b.

Brianetta

Still an issue in 1.14

migrated

Still an issue as of 1.14.3.
I am absolutely flabbergasted that this bug has gone unaddressed for five years

migrated

The following is based on yarn 1.15.1 names.

In the method net.minecraft.entity.LightningEntity.tick() where the ENTITY_LIGHTNING_BOLT_THUNDER sound hook is, the volume is set to 10000.0f, which if you set your volume to 1%, results in 100f but from my observations (using 1.12.2 MCP), you only notice change in sound if the assigned volume to the playSound hook is less than 30f.

My suggestion is to lower it to 5f. That's the same volume as the ender dragon wings flapping (which quite loud too) and will lower the volume, of course.

Example

this.world.playSound(null, this.getX(), this.getY(), this.getZ(), SoundEvents.ENTITY_LIGHTNING_BOLT_THUNDER, SoundCategory.WEATHER, 5f, 0.8f + this.random.nextFloat() * 0.2f);
FaRo1

If you set the audio "volume" parameter of "/playsound" higher than a certain value, it becomes related to spatial "volume" in a way. Maybe this was how it was intended here as well?

Reference: https://gaming.stackexchange.com/a/352304/171580 (Yes, I'm quoting myself.)

migrated

@unknown, oh, I didn't know that. The intent is to let the sound travel as far as possible with lightning, but then you get bugs like these. But 10000 as volume for lightning strike seems overkill as the dragon flapping is just 5f, which also needs to be heard from a far.

numeritos

Affects 1.16-rc1

itskieran

Can confirm still present on 1.16.4 - went searching to see which category it was in as the lightning was so much louder than the rest of the game and found this. Turned Weather and Ambient/Environment to OFF and still heard the thunder, so thought I was bad at guessing which audio category it's in.

ampolive

Can confirm in 1.17.1.

migrated

Besides the suggested fix by oval, it's also possible to provide a VERY TINY volume in the sounds.json; I'm talking 0.0001; this should still allow the sound to be played literally everywhere, but be completely responsive to the sound slider, even having 99% affect the volume. The one downside is that /playsound would then need to provide such a high volume (10000) as well in order to make it heard. (This is a little trick I use with custom music so it plays everywhere but isn't making sliders unresponsive.)

Asteraoth

(Unassigned)

Confirmed

Platform

Low

Sound

thunder, volume, weather

Minecraft 1.7.4, Minecraft 14w05a, Minecraft 14w06a, Minecraft 14w06b, Minecraft 14w07a, ..., 1.19, 1.19.2, 23w45a, 1.20.6, 1.21.3

Minecraft 14w26a

Retrieved