• How do I make a swep play a sound when spawned?
    2 replies, posted
What's the code for making an swep play a sound when spawned? I looked everywhere and all I found was this line of code: self:EmitSound(ShootSound) but i have no idea what to do with it. I know directories to type in and the file I want to play, I just don't know HOW to do it. P.S. Sorry for being such a pest and asking tons of shit to the FP community.
If you want your weapon to play a sound when the player pulls it out you want the deploy function. EX. [code] function SWEP:Deploy() self.Owner:EmitSound("file path here.") end[/code]
[QUOTE=residualgrub;41887180]If you want your weapon to play a sound when the player pulls it out you want the deploy function. EX. [code] function SWEP:Deploy() self.Owner:EmitSound("file path here.") end[/code][/QUOTE] Thank you.
Sorry, you need to Log In to post a reply to this thread.