• CSoundPatch:SetDSP is a nil value?
    2 replies, posted
According to the wiki, [url=wiki.garrysmod.com/page/CSoundPatch/SetDSP]CSoundPatch:SetDSP()[/url] should be a function that accepts a number as an argument. However, when I try to call SetDSP as shown below, garry's mod reports that SetDSP is a nil value. I know it works fine on the player, so has it just not been implemented yet for CSoundPatch? [lua] local sound1 ... local function xyz() sound1 = CreateSound( LocalPlayer(), "ambient\\atmosphere\\ambience_base.wav" ) hook.Add( "Think", "DoSoundLoop", LoopSound ) timer.Simple( 10, function() sound1:SetDSP(46) end ) --Begin to end the sound with the fadeout end [/lua] Note that the [i]LoopSound[/i] function isn't very important, all it does is check to see if the sound is playing, and if not, plays the sound. If anyone can help me out, that would be great. EDIT: I guess I could use the fadeout function for CSoundPatch, but what if I wanted to use other DSP effects?
it only exists in dev branch for now.
[QUOTE=Robotboy655;45276602]it only exists in dev branch for now.[/QUOTE] Ah, thanks!
Sorry, you need to Log In to post a reply to this thread.