wiremod / wire

Garry's Mod add-on that allows users to wire up components in order to make more elaborate automatic and user-controlled contraptions.
http://www.wiremod.com
Apache License 2.0
554 stars 330 forks source link

sound error #3109

Open deathking61 opened 3 months ago

deathking61 commented 3 months ago

so im working on an engine e2 (its working but there are some issues with the new wiremod)

the main issue is sound i have the base sound volume set to 0.5 and when i boost the sound volume goes to 0.80 but when i let go of the boost function the part that changes the volume it will randomly go from the 0.5 volume to 1 and its loud later on if you need it i can post the full sound code for it.

thegrb93 commented 3 months ago

Code or a dupe to test with would help

deltamolfar commented 3 months ago

Give us means to reproduce this, as it may be e2 logic flow, not internal error

unknao commented 3 months ago

I don't know if its the same error that the OP is having but the "Recharge2" sound on this stops playing after a few plays. v1_001.txt

deathking61 commented 3 months ago

here is what im using for sound:

MAX_RPM = 12000 #for the sound volume / pitch  
Sound_Volume1 = 0.30 #sound normal
Sound_Volume2 = 0.40 #boosted 
 Sound_main = "@acf_engines/v10_petrolmedium.wav"
 Sound_main2 = "@acf_engines/v10_petrolmedium.wav"

    function void loadSounds() {
       E:soundPlay("On", 0, Engine_SoundOn:lower())
        E:soundPlay("Off", 0, Engine_SoundOff:lower())
         if (Turbo) {
        }
    }

    loadSounds()

    runOnLast(1)
}

soundPitch("On", (Engine_RPM / MAX_RPM) * 155 + (80 * Engine_Active))
soundVolume("On",(Engine_Active / 2 + Engine_Volume * 1) * (Key_Alt ? Sound_Volume2 : Sound_Volume1))

soundPitch("Off", (Engine_RPM / MAX_RPM) * 155 + (80 * Engine_Active))
soundVolume("Off",(Engine_Active / 2 + Engine_Volume * 1) * (Key_Alt ? Sound_Volume2 : Sound_Volume1))

this is what im using for my engine sounds when i do it like this with the new wiremod it messes up hard. when i revert back to the one im on now the issue is just gone.

thegrb93 commented 3 months ago

Which version are you on now?

deathking61 commented 3 months ago

where would i find the version?

deltamolfar commented 2 months ago

where would i find the version?

print(_WIREVERSION) in e2