OreCruncher / DynamicSurroundings

Dynamic Surroundings mod for Minecraft 1.10.x+
MIT License
120 stars 35 forks source link

Rain Volume #77

Closed DrakeEldridge closed 7 years ago

DrakeEldridge commented 7 years ago

DynamicSurroundings-1.10.2-3.3.6.1

1.10.2-12.18.3.2272

Link to crash log (if applicable):

Unable to adjust the volume of the Rain. I have gone through all the options, changed so many things. I just can't seem to get the rain volume to go up. Tried to post this on the forum cause I don't think its an issue, just need some help. But the FTB Forum would not let me make an account to post on the forum.

OreCruncher commented 7 years ago

The volume is tied to how strong the rainfall is - the stronger the fall the louder it is. There is an overall setting, however, that lets you adjust the rain volume scaling. You can get to that setting via the Forge configuration system (Rain Options -> Rain Sound Level), or by pressing V while in game. By default it is set to 1.0/100% meaning full volume.

DrakeEldridge commented 7 years ago

Even 1.0 100% isn't very loud. Going above that doesn't seem to effect anything.

spraaq commented 7 years ago

There is a noticable difference in rain and thunder volumes between a flatworld and a normal world. In my normal worlds rain sounds are extremely quite (for months now, actually), in flatworlds they are ok.

OreCruncher commented 7 years ago

@DrakeEldridge @spraaq I find that interesting - rain splash rendering/sound is the same regardless of whether it is flat or normal Overworld. Thunder as well, unless you changed the thunder volume setting. Can you both post a link to your dsurround.cfg file?

spraaq commented 7 years ago

I'am probably wrong, I just realised that /weather rain create different weather every time. However the volumes can be really low, especially without headphones.

OreCruncher commented 7 years ago

If you are in creative mode you can use the /ds command to change the rain strength (ex. /ds setstr rain 100).

OreCruncher commented 7 years ago

The things that affect the rain volume:

EDIT: Another factor - fancy vs. fast graphics. Fast graphics cuts the splash particle quantity in half.

DrakeEldridge commented 7 years ago

I will go over these settings and try and get it to be louder. If I can't I will send my config for you

DrakeEldridge commented 7 years ago

Still really quiet. I put the rain level all the way up, increased the particles. Still really low sound for the rain. Every other sound is great, just the rain is far too quiet. Light rain you see the rain but no sounds, makes you feel deaf, and highest rain can still barely be heard. :( hope my config has something you can tell me to change to fix it. dsurround.zip

DrakeEldridge commented 7 years ago

I am having another issue with this mod, it seems to effect music volume, so when i set the music volume to like 20% it lowers the volume, but as soon as the next song come on its back up to 100%. Since sending that config I have changed the individual sound settings for the music files to around 15% but it still blasts the music on full.

OreCruncher commented 7 years ago

Nothing stands out as strange in the config file. Next BETA will have additional logging for the rain sound generation when DEBUG logging is enabled. My hope is that it will tell me something. Do you have a list of mods in your pack?

EDIT: I turn my music slider down to something like 4% and I have not seen it jump around.

OreCruncher commented 7 years ago

@DrakeEldridge Try out this dev release I posted to GitHub. It has some additional logging and what not. Make sure you turn on the DEBUG logging in the DS config to get a trace. It will record the individual sound plays to the log while raining. Need about a minute of play time while raining. Please post the client log. :)

DrakeEldridge commented 7 years ago

alright will download that and turn on debugging. will also try turning my sound down to 4% and seeing if it jumps

DrakeEldridge commented 7 years ago

logs.zip Here is the log. I downloaded the new mod, turned on debugging. it showed the debug window. So hopefully it worked and logged everything.

Forge Version: forge-1.10.2-12.18.3.2272-universal

Mods in my pack: 3DManeuverGear-1.10.2-0.4.0 AppleCore-mc1.10.2-2.1.2 Baubles-1.10.2-1.3.9 BedBugs-1.10.2-1.1.6 BetterQuesting-2.3.225 bqautoreload-1.5.0 cfm-4.1.2-mc1.10.2 chiselsandbits-12.12 CodeChickenCore-1.10.2-2.4.0.101-universal CodeChickenLib-1.10.2-2.5.6.233-universal ConquestReforged-2.0.1-RC1-mc.1.10.2 Currency-1.10.2-1.0.3 CustomMainMenu-MC1.10.2-2.0.2 CustomNPCs_1.10.2(17mar17) Decocraft-2.4_1.10.2 DynamicSurroundings-1.10.2-3.3.7.0 EnhancedVisuals v1.0.12 mc1.9-1.10 expandableBackpacks1.1.10-1.10.2 extrautils2-1.10.2-1.3.3 foamfix-0.6.2-beta4-anarchy ForgeMultipart-1.10.2-2.0.0.31-universal FTBLib-1.10.2-3.4.4 FTBUtilities-1.10.2-3.4.3 Harvest-Festival-1.10.2-0.5.26 iChunUtil-1.10.2-6.3.0 ImmersiveEngineering-0.10-57 infinitylib-0.4.0 journeymap-1.10.2-5.2.4-unlimited malisiscore-1.10.2-4.4.0 malisisdoors-1.10.2-5.2.0 MCA-1.10.2-5.2.3-universal MCMultiPart-1.4.0-universal MoarSigns-1.10.2-4.2.2.8 More-Player-Models-Mod-1.10.2 Morpheus-1.10.2-3.1.13 MrTJPCore-1.10.2-2.0.0.14-universal Neat 1.3-12 NPCIntegration-2.3.21 OptiFine_1.10.2_HD_U_D7 Pam's HarvestCraft 1.9.4-1.10.2h ProjectRed-1.10.2-4.8.1.25-Base ProjectRed-1.10.2-4.8.1.25-integration ProjectRed-1.10.2-4.8.1.25-mechanical RadixCore-1.10.2-2.1.3-universal ResourceLoader-MC1.9.4-1.5.1 soundphysics-mc1.10.2-v1.0.0 SpiceOfLife-mc1.9.4-1.3.8 thutcore-3.12.2 thuttech-4.0.10.b ToughAsNails-1.9.4-1.1.1 Valkyrien Warfare 0.8.999 Stable

OreCruncher commented 7 years ago

DS is passing the sound at expected volumes given your config:

PLAYING: [dsurround:rain(), v:0.9121321, p:0.9950335, t:SPOT, w:10]

When it gets into the sound engine the sound volume will increase to 1 based on the volume scale factors.

What does the sound play like if you click the "Play" button in the Individual Sound Configuration dialog? The sound should play at a volume of 1 and have the volume scale set based on what the slider shows.

EDIT: Also, have you tried removing Sound Physics?

DrakeEldridge commented 7 years ago

Yes I tried removing sound physics, it didn't change anything. When I clicked the rain sound it didn't play anything but the music ones play and so do others.

OreCruncher commented 7 years ago

OK - something it futzing with that sound. Noticed this in the log:

[17:13:45] [Client thread/INFO]: Not hooking weather renderer for dimension [Overworld]

This means that another mod is providing weather rendering for Overworld. Not sure which one though. Need to add more logging to see if I can find it. It could be the source.

OreCruncher commented 7 years ago

Try out an updated JAR. It has additional logging in hopes of tracking down the mod that is hooking the weather renderer. May give me clues of where to look. I need the logs from a run similar to what you did above.

DrakeEldridge commented 7 years ago

Might be Harvest Festival or Tough as Nails. (They both add seasons)

OreCruncher commented 7 years ago

I use TaN during development, so it may be Harvest Festival.

OreCruncher commented 7 years ago

Took a look at Harvest Festival. It does hook weather rendernig, and it also hooks rain splash particle processing. Try removing it to see if the problem corrects.

OreCruncher commented 7 years ago

More data - it does some strange things. I do a /toggledownfall, and it starts raining client wise. Server side, though, the world does not report any rainfall thus DS will not render storm splashes or sound. If I force rain strength using /ds setstr rain 50 DS server side gets that info and the client starts generating splash particles and sound.

DrakeEldridge commented 7 years ago

Ok I will try removing it. But if that is the problem is there a way for you to fix it with a mod update? I wud love to keep both mods

DrakeEldridge commented 7 years ago

I am getting these 'found a missing id from world dsurround' messages coming up on tlhe fml server console.

OreCruncher commented 7 years ago

Post a snip of the log so I can see the messages. As for compat I need to look at it. Main issue is that Harvest Festival wants to own some of the logic paths Dynamic Surroundings does and that creates a problem. You can turn off the DS ASM for rain so that DS no longer does the rain rendering.

DrakeEldridge commented 7 years ago

will post log from server with debugging on

DrakeEldridge commented 7 years ago

logs.zip

(fyi: I disabled sponge for this server run cause I am having conflict with sponge and Thutstech. So thats why it isn't present in this log. But even with Sponge disabled it still shows the same errors for dsurrounds in the fml console.)

DrakeEldridge commented 7 years ago

And I like the look of the rain in DS. Its just the sound thats too quiet. I don't want to give up the look of the rain. Will it effect the look if I change the setting DS ASM to false :(

OreCruncher commented 7 years ago

RE: the entries in the log I think are noise. I sometimes get them, too, and haven't noticed any ill effects. It's on my list of things to poke at so I can better understand what the message means.

Disabling ASM will cause several things to happen:

DrakeEldridge commented 7 years ago

i disabled ASM, didnt seem to effect the rain noise. Maybe its a resource pack sound making it so low?

OreCruncher commented 7 years ago

The sound I play for rain is dsurround:rain. That sound gets generated during rain splash particle rendering. You indicate above that when you click "Play" in the config dialog you heard nothing? Only thing I can conclude is that something is killing the sound somewhere along the way. I am working on another build that has more detailed logging and does a double check after requesting a sound play to ensure the sound actually got queued rather than blocked by an event handler.

BTW, have you created a basic Minecraft install with just Forge and DS to see if the rain sound plays?

DrakeEldridge commented 7 years ago

im getting rain sounds, its just really quiet. I just tested it with no resource packs and no mods. Rain seems fine. Put dsurrounds in, rain is quite quiet (Though not as bad as it was with the other mods in.) hmmm

OreCruncher commented 7 years ago

The rain sound from DS (dsurround:rain) is softer than the ones in Vanilla (minecraft:weather.rain and minecraft:weather.rain.above). Are you using headphones or speakers?

DrakeEldridge commented 7 years ago

headphones, but they are not the problem, i got better sound with them then my speakers.

OreCruncher commented 7 years ago

Then I am really baffled. I use headphones and I hear the sound fine. I am adding additional debug trace and checks and maybe that will tell me something.

DrakeEldridge commented 7 years ago

as i said, i hear the sound, its just very quiet. Is there a way to make it so i can go above the 1.0 for the rain sound to just boost it. its the only sound that is too quiet (though I still got a few issues with music being too loud even then when i edit the volume up and down it goes to the right level. Like if i got it set to 4% for music, when i start up MC it plays very loud, def not 4%, but as soon as i move the music volume up and then back down to 4% it goes to the right volume level.)

OreCruncher commented 7 years ago

I guess "very quiet" is subjective. Like you I set my music slider to about 4% but I can hear the rain quite fine at the normal volumes. And I have tinnitus. :)

Sound volume control is a bit convoluted in Minecraft. The maximum effective volume is 1. Volumes > 1 still play at 1, but have a longer roll-off distance (you can hear them when they are further away). For example, thunder plays at a volume of 10000. The actual volume is 1, but since it is 10000 it can be heard from a couple thousand blocks away. Typically a volume of 1 rolls off at 16 blocks meaning its the max range at which you would normally hear a sound.

All this being said other mods could be altering the volume before the sound gets submitted into the Paul's Code sound engine. The extra logging I am adding will interrogate the Paul's code sound engine to see what the actual player is doing with regards to the volume.

Another thing you can do is try playing the OGG sound file in an external player like Audacity. This would help me understand whether the actual OGG file has the sound encoded at too low a volume. The sound files can be found here.

OreCruncher commented 7 years ago

@DrakeEldridge I pushed an official v3.3.7.0 build to CurseForge. If you could run the same test with debug enabled and post the log it will tell me something.

DrakeEldridge commented 7 years ago

logs.zip

There u go. For some reason when I do /ds setmin rain 80 it doesnt do anything. I can set it to 100 and to 80 using /ds setstr rain 80 and it works. but if I toggle rain on and off. It ignores the minimum and is always really low. I have to use /ds setstr rain 80 to get it back up to 80.

Also I went start up my game the music is still quite loud, as soon as i go into music settings and move it from 10% to like, 11% it drops to the level its suppose to be and i can move it to be 10% and its fine. But only until the song ends and the next song starts and its back to being way more then 10%

OreCruncher commented 7 years ago

@DrakeEldridge Noticed that the zip did not contain the client log - its where the sound trace would be.

As for the /ds stuff its Harvest Festival interference. When a /toggledownfall occurs it does not update the WorldInfo data for the dimension with the fact that it is raining. WorldInfo is used by Dynamic Surroundings to do some of the various things it needs - like determining if it is logically raining. (I noticed this in my local testing as well.)

The music one is strange. One thing you can do is disable Dynamic Surroundings auto-mute (Sound Options -> Mute when in Background). The current implementation sets the master sound to a very low number when Minecraft does not have the desktop focus, and puts it back when it does. Something may be going awry in your configuration.

DrakeEldridge commented 7 years ago

I have Harvest Festival Disabled all the time at the moment.

For this test I disabled mute when in backgound option and I also disabled soundPhysics and conquest reforged mod and I removed all resource packs. The music issue seemed to disappear, very low volume for music which is good cause it was set to 10%, I raise it and lowered it and many songs played, it stayed the same level which is good.

But the rain issue still persists. In this test I was happy with the sound level at 80-100 strength but the same issues with /ds setstr rain. When I do /weather rain on the server or in singleplayer, it rains but its way below the 80 level. When I set it back to 80 using the /ds setstr rain 80 command it goes up to a that level. (Harvest festival still disabled) I would like to keep the rain around 60-100 but it seems to keep ignoring the /ds setmin command and be much lower.

Here are the logs from server and client side. From test 1: Test1.zip

Config is included in test1.zip

For a second test, I put the resource packs back in but kept the soundphysics and coquest reforged mod disabled. I was happy with the rain volume again and music was working well. But same issues with the /ds setstr and /ds setmin. How it ignores the minimum level and it rains way bellow 80 when I toggle rain.

Test2.zip

Third Test: Re-enabled the Soundphysics mod and Conquest Reforged. Still no harvest festival mod.

Music issue is back. Same as it was before. So seems like the mute when in background did not fix it but it is soundphysics or conquest reforged mod.

Rain volume seems to be quieter at 80-100. So I think soundphysics or conquest reforged mod might be causing that to be quieter than without those mods.

And the same issue with /ds setmin not working and it raining below the minimum.

Logs: Test3.zip

OreCruncher commented 7 years ago

Thanks for the info!

From Test1:

[20:08:45] [Server thread/INFO]: dim 0 rain intensity set to 0.123380, duration 17810 ticks
[20:08:45] [Client thread/INFO]: [CHAT] Changing to rainy weather
[20:08:45] [Client thread/INFO]: FADE: PlayerTrackingSound{dsurround:forest, AMBIENT, volume=1.0, pitch=1.0, attenuation=NONE, x=-31.173372, y=104.0, z=-287.75247}
[20:08:46] [Client thread/INFO]: > QUEUED: [AdhocSound{dsurround:rain, WEATHER, volume=0.1469973, pitch=1.0414783, attenuation=LINEAR, x=-36.5, y=71.5, z=-288.5}]; v: 0.293995, p: 1.041478

It starts to rain with an intensity of 12 (0.123380). This is low intensity rainfall which would have a low volume. DS queues rain sounds at a volume of 0.146, and when the sound engine gets it it goes up to v0.2939 because of individual sound scaling.

From Test2:

[20:38:47] [Server thread/INFO]: dim 0 rain intensity set to 0.137608, duration 13323 ticks
[20:38:47] [Client thread/INFO]: [CHAT] Toggled downfall
[20:38:48] [Client thread/INFO]: > QUEUED: [AdhocSound{dsurround:rain, WEATHER, volume=0.145, pitch=1.0179892, attenuation=LINEAR, x=-14.5, y=65.5, z=-249.5}]; v: 0.290000, p: 1.017989

Looks to be a mirror of Test1 thuoght with a slightly different initial intensity.

From Test3:

[20:59:55] [Server thread/INFO]: dim 0 rain intensity set to 0.134779, duration 16844 ticks
[20:59:55] [Client thread/INFO]: FADE: PlayerTrackingSound{dsurround:forest, AMBIENT, volume=1.0, pitch=1.0, attenuation=NONE, x=-0.11650677, y=106.0, z=-211.5649}
[20:59:56] [Client thread/INFO]: > QUEUED: [AdhocSound{dsurround:rain, WEATHER, volume=0.20499998, pitch=1.0382769, attenuation=LINEAR, x=-0.5, y=73.5, z=-210.5}]; v: 1.000000, p: 1.038277

This one looks to be similar to 1 and 2, but the difference is the actual volume in the sound engine. It is 1, or full volume.

I will take a look at the rain min/max code. As you indicate something does not appear right. It may be the source of the issue (i.e. you expecting a higher intensity rain/volume and the reality is something lower). I find it interesting that in all 3 tests the rain intensity is that low - I would have expected to see a higher variation.

DrakeEldridge commented 7 years ago

cool, keep me updated and if u need anything else lemme know

OreCruncher commented 7 years ago

@DrakeEldridge OK - found the potential issue. Looks to be old. The key to finding was the lack of variation in the intensity. The fix will be in the next update.

Essentially the logic was randomizing the difference of the min/max intensity correctly, but forgot to add back in the minimum intensity:

Bug: result = random(max - min)

Fix: result = min + random(max - min)

DrakeEldridge commented 7 years ago

Are you able to fix the issue with soundphysics or conquest reforged mods causing that music issue?

OreCruncher commented 7 years ago

I am putting in a change as to how DS does sound muting. In the version you have it manipulates the master sound channel volume. It would be possible that the config could save with the low setting thus causing some of the issue you are experiencing.

In the next version I set the master gain directly in the sound engine (PaulsCode) without messing with the Minecraft setting. So the Minecraft config winds up being saved it will have the correct value.

Will this change fix the sound issue? Not entirely sure until you try it.

(I have tested with Sound Physics before and I do not think that is the issue. Main challenge with Sound Physics is that is uses the sound name (i.e. "minecraft:weather.rain") to determine what effects to apply to a sound. Works well with Minecraft sounds because those names are well known. Modded sounds are a challenge since Sound Physics isn't prescient.)

OreCruncher commented 7 years ago

@DrakeEldridge Pushed a v3.3.8.0 version that has the fix for the rain min/max setting. After installing and it is raining you will need to toggle the rain fall cycle at least once (or let it finish raining). Let me know how this works for you.

DrakeEldridge commented 7 years ago

Seems like the Min Max Settings is working. But I have done some more testing and it is the Sound Physics mod that is conflicting with Dynamic Sounds. It's causing volume issues and it is making that music issue.

soundphysics-mc1.10.2-v1.0.0

OreCruncher commented 7 years ago

Good to know about sound physics. I use Sound Filters because it takes a different approach and is "less invasive" in terms of hooking the sound manager.

DrakeEldridge commented 7 years ago

is there a fix for the conflict? I like te echo that sound physics adds when in caves or large rooms. Very atmospheric