mojira.dev
MCPE-164935

Noteblocks volume drop-off with distance is too steep

Problem: The volume of a sounding noteblock drops off very steeply (with player distance) in Bedrock edition, compared with Java. In Java, the drop-off rate seems to be less steep for the first 30 or so blocks than it is for 31-48 blocks' distance. The scaling in Bedrock should be adjusted to match that in Java. 

Impact of issue: This severely limits the possible length of a song crafted with noteblocks in Bedrock edition, as the full tune cannot be heard clearly from one player position if the circuit exceeds one chunk radius (from the player) - the volume of the tune will also fluctuate greatly depending on each block's distance from the player. 

Steps to reproduce:

  1. Create a clock to repeatedly sound a noteblock

  2. Move away from the noteblock

  3. Notice the drop-off in volume while moving away (I don't know of a way to accurately measure it)

(Note - previously reported in MCPE-47833 which was closed due to inactivity.)

Linked issues

Attachments

Comments

tryashtar

All Bedrock sounds, except those that use max_distance*, have an exponential volume falloff, visible here: https://www.desmos.com/calculator/k2ykwuijru

This differs from Java, which has linear attenuation, visible here: https://www.desmos.com/calculator/hrj7zevxdw

As a result, Bedrock sounds get extremely quiet in a very short distance (80% volume reduction in just 5 blocks), and are never fully inaudible. Only sounds that are "too far away" (varies, but is usually 16 blocks) are simply not played at all.

*(This includes all music discs, many warden and bee noises, raid horns, and a couple other random sounds)

Regarding note blocks specifically, Java is hardcoded to play them with volume 3, which (as visible in the graph linked above), results in a linear audible range of 48 blocks.

Bedrock uses sounds.json to play them with volume 3, which has no effect besides increasing the "cutoff" range to 48 blocks.

Therefore, here is how Java note block volume is affected by distance:

[media]

And here is Bedrock:

[media]

Players who are beyond the gray line (48 blocks away) when the sound starts will not hear it at all.

The fix for noteblocks is very simple: set max_distance to 48 in sound_definitions.json. However, I think it's worth re-evaluating whether the exponential falloff is a preferable default for Bedrock sounds, and the purpose of volume in sounds.json since it does not affect attenuation in Bedrock like it does in Java.

Squ1rrelicious

Confirming the changes made in 1.19.70.20 Preview. File sound_definitions.json updated with max_distance=48 added for all noteblock sounds. Noteblock volume now attenuates linearly.

migrated

Per ADO closing as fixed.

Squ1rrelicious

(Unassigned)

942017

Confirmed

Windows

Windows 11

Java-parity

1.19.60.27 Preview, 1.19.60.23 Preview, 1.19.60.22 Preview, 1.19.50

1.19.70.20 Preview

Retrieved