Player.SetDSP

From GMod Wiki

Jump to: navigation, search
Function
Syntax Player:SetDSP( Integer effect_id, Boolean quickreset )
Description:
Adds an effect to the specified player's sound that modifies their sound according to the effect id given.
Returns: nil
In Object: Player
Realm: NewerShared.png
BBCode Link: [b][url=http://wiki.garrysmod.com/?title=Player.SetDSP]Player.SetDSP [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b]


Examples

DescriptionModify the local player's sound to muffle all sounds and play a screech sound as if an explosion had just occoured.
Used onNewerClient.png
Code
LocalPlayer():SetDSP(34, false )
OutputModified sound
DescriptionModify the all players' sound to sound as if it is been synthesized
Used onNewerServer.png
Code
for _,ply in pairs(player.GetAll()) do
	ply:SetDSP( 23, false )
end
OutputModified sound for all players


Additional Notes

Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox