Fix various issues with sound movement and attenuation - #21
Open
Tisawesomeness wants to merge 7 commits into
Open
Fix various issues with sound movement and attenuation#21Tisawesomeness wants to merge 7 commits into
Tisawesomeness wants to merge 7 commits into
Conversation
Also allows range setting to be used with locational sounds, fixes issues where note blocks cannot be heard but other sounds (portal wooshes) can
Jukebox volume 100 (should) allow all instruments to be heard inside the entire range
Fixes issues where boosting sound volume causes quiet instruments to be too loud. No auditory artifacts even at elytra speed.
Contributor
Author
|
Boosting all instrument volume means quiet notes in a song are just as loud as other notes when players are close to the jukebox. To fix this issue, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
If a sound is playing at the player's position, moving quickly or turning your head can cause the sound to lag behind you, which is especially noticeable with long sounds such as portal wooshes. Sounds can instead follow the player as they move with
Sound.Emitter.self(). However, since stereo works by modifying the location sound plays from, there is no easy way to let stereo sounds follow the player. So, this PR:If a sound is playing at a jukebox (location jukebox sounds enabled), differences in attenuation distance (defined client-side in sounds.json) mean players far away from the jukebox can hear some instruments but not others. For example, note blocks can only be heard close to the jukebox, while portal wooshes can be heard far away, giving the illusion of "random" portal noises. To fix this issue, this PR:
1 + (range - 16) * 0.06(same formula NBS datapack export uses) so quieter instruments can be heard across the entire jukebox range. Volume > 1 does not make the instrument any louder, but it does increase the attenuation distance.These changes fix several issues I've received from players and make the listening experience much more pleasant.