• How to play music.
    14 replies, posted
In my game mode i am devoloping with my team, i cant seem to figure out how to play music. My friend suggested i Face punch it. So i did. Whats the command to play a sound/music
surface.PlaySound If you're looking for a console command, it's 'play'
could you use it in a string for me?
surface.PlaySound("Path/To/My/SoundFile/.SoundFileType") Also, there is a [url=http://wiki.garrysmod.com/?title=Main_Page]lua wiki[/url] for a reason.
I looked, but its my fail wiki skills
[QUOTE=Uberkist;17050474]I looked, but its my fail wiki skills[/QUOTE] I gave you the exact name of the function. If you can't find a wiki page on it using that name, you seriously need to consider if you will cope with learning a programming language.
[QUOTE=|FlapJack|;17050525]I gave you the exact name of the function. If you can't find a wiki page on it using that name, you seriously need to consider if you will cope with learning a programming language.[/QUOTE] Dude, I didn't look at the wiki once you told me the name. i looked before that when i first needed it.
"Hey now I have the function name! Oh shit, Idk what to put, and I already looked at the wiki once. There's NO WAY it'll be there since I already looked under different names!" Am I in the ball park on your thought process?
Hay'ell yea Brother.
[quote=|FlapJack|]surface.PlaySound If you're looking for a console command, it's 'play' [/quote] Is there a server side function?
No you have to code your own system. But one is being released soon. Just keep your eyes open.
Ignorance alert, But once i use that code everyone can hear it right?
Only if you make each person run it. Via datastream, or SendLua
[QUOTE=Skapocalypse;17056333]Only if you make each person run it. Via datastream, or SendLua[/QUOTE] Usermessages.
Sorry, you need to Log In to post a reply to this thread.