Garry's Mod
PlaySound Improved
ƝiƵ 18 ABR 2022 a las 10:23
Custom sounds
How do i add my own music
< >
Mostrando 1-15 de 20 comentarios
Støng  [desarrollador] 27 ABR 2022 a las 6:29 
First, get your music tracks that you wanted to play, then make a new TXT file and rename it to "play_music_<soundtracknamehere>.lua".

Once you're done with that, open the LUA file with an editor of your choice, I recommend Notepad++[notepad-plus-plus.org]. After that, copy and paste this into your LUA file.

-- Setup menu parameters local function PlayMusicMenu(panel) local params = {} params.Text = "Stop all Music" params.Command = "playsound stop" panel:AddControl("Button",params) params.Text = "---------------- [<Soundtrack Name Here>] ----------------" panel:AddControl("Label",params) params.Text = "Tracks" panel:AddControl("Label",params) params.Text = "<Music Name Here>" params.Command = "playsound music/<filenamehere>.mp3" panel:AddControl("Button",params) params.Text = "---------------------------------------------------------------" panel:AddControl("Label",params) params.Text = "Stop all Music" params.Command = "playsound stop" panel:AddControl("Button",params) end -- Create the menu itself local function NewMenu() spawnmenu.AddToolMenuOption( "Options", "Music", "<Soundtrack Name Here> Music Menu", "<Soundtrack Name Here>", "", "", PlayMusicMenu ) end hook.Add( "PopulateToolMenu", "PlayMusicMenu_<Soundtrack Name's Shortform>", NewMenu )

Change the angled brackets with the name of the soundtrack and you probably know the rest...

If you're done with adding the tracks, you need to make sure these files including the LUA file are in their correct file paths otherwise it will not work.

<Your Folder>/lua/autorun/client/play_music_<soundtracknamehere>.lua <Your Folder>/sound/music/<filenamehere>.mp3

Then, put it in your addons folder and it should probably work now.

If this is too complicated for you then I apologize (I'm not good at explaining things).
Or you can follow my other guide which is quite simple.
Última edición por Støng; 11 DIC 2024 a las 21:01
heavyfortress0195 20 AGO 2022 a las 6:54 
What do you mean by "put it in your addons folder"? What do i put in? It doesnt work.
Støng  [desarrollador] 20 AGO 2022 a las 7:23 
Publicado originalmente por super brain:
What do you mean by "put it in your addons folder"? What do i put in? It doesnt work.
It's your Garry's Mod addons folder, located in
(Steam\steamapps\common\GarrysMod\garrysmod).

Like I said before, I will eventually update this addon and include the tracks y'all wanted the most. Please just be patient.
Última edición por Støng; 11 DIC 2024 a las 21:01
heavyfortress0195 20 AGO 2022 a las 7:29 
I know but i want it as soon as possible so i am trying to make my own while you work on it. Also i know its my gmod addons folder. But WHAT do i put there in? What do i put inside the addons folder? Lua? Txt?
av.a. 20 AGO 2022 a las 7:59 
Stong already stated this but these are the folders you need to make.[imgur.com]

I assume you know what to do now, so follow his tutorial.
heavyfortress0195 20 AGO 2022 a las 8:52 
Publicado originalmente por Frostbite:
Stong already stated this but these are the folders you need to make.[imgur.com]

I assume you know what to do now, so follow his tutorial.
I thought i did when i made a foldier with lua, and all the stuff with the sounds.

When i put it all together like it said, put it in the addons and then i tried.

t h e r e was not any option for Portal 2 Action 1 that i have made.

How do i fix it now? Can you make an video?
heavyfortress0195 20 AGO 2022 a las 9:32 
Publicado originalmente por Frostbite:
Stong already stated this but these are the folders you need to make.[imgur.com]

I assume you know what to do now, so follow his tutorial.
Please answer!
heavyfortress0195 20 AGO 2022 a las 10:19 
Publicado originalmente por Stong:
Publicado originalmente por super brain:
What do you mean by "put it in your addons folder"? What do i put in? It doesnt work.
Foolishness... It's your Garry's Mod addons folder, located in
(Steam\steamapps\common\GarrysMod\garrysmod).

Like I said before, I will eventually update this addon and include the tracks y'all wanted the most. Please just be patient.
I am patient, but is it possible if you please make an video how to make ur own soundtracks? PLEASE i really need help beacause mine doesnt show up on the MUSIC'S list on garry's mod.
Støng  [desarrollador] 20 AGO 2022 a las 10:39 
Publicado originalmente por super brain:
I am patient, but is it possible if you please make an video how to make ur own soundtracks? PLEASE i really need help beacause mine doesnt show up on the MUSIC'S list on garry's mod.
Buddy, we don't have that much time to explain it all to you. If you're really desperate to get it to work, just try this simple method.
heavyfortress0195 20 AGO 2022 a las 11:00 
Like i said, it doesnt work and it said something about sample rate 4800.
heavyfortress0195 20 AGO 2022 a las 11:05 
Publicado originalmente por Stong:
Publicado originalmente por super brain:
I am patient, but is it possible if you please make an video how to make ur own soundtracks? PLEASE i really need help beacause mine doesnt show up on the MUSIC'S list on garry's mod.
Buddy, we don't have that much time to explain it all to you. If you're really desperate to get it to work, just try this simple method.
Im just gonna make another discussion hoping someone else can help, so i dont need to bother you anymore. But uhm yeah, im desperate for it bescause i have been searching 6 days for portal 2 musics.
av.a. 20 AGO 2022 a las 11:31 
Publicado originalmente por super brain:
Like i said, it doesnt work and it said something about sample rate 4800.

You need to change the sample rate into 44100 hertz. I recommend using Audacity.
Última edición por av.a.; 20 AGO 2022 a las 11:33
heavyfortress0195 20 AGO 2022 a las 11:35 
Publicado originalmente por Frostbite:
Publicado originalmente por super brain:
Like i said, it doesnt work and it said something about sample rate 4800.

You need to change the sample rate into 44100 hertz. I recommend using Audacity.
I would rarely use it anyway, since i need quick switching since im only gonna use action music usually.
heavyfortress0195 28 SEP 2022 a las 3:32 
Publicado originalmente por Stong:
First, get your music tracks that you wanted to play, then make a new TXT file and rename it to "play_music_<soundtracknamehere>.lua".

Once you're done with that, open the LUA file with an editor of your choice, I recommend Notepad++[notepad-plus-plus.org]. After that, copy and paste this into your LUA file.

// Setup menu parameters local function PlayMusicMenu_D2K(Panel) local params = {} params.Text = "Stop all Music" params.Command = "playsound stop" Panel:AddControl("Button",params) params.Text = "---------------- [<Soundtrack Name Here>] ----------------" Panel:AddControl("Label",params) params.Text = "Tracks" Panel:AddControl("Label",params) params.Text = "<Music Name Here>" params.Command = "playsound music/<filenamehere>.mp3" Panel:AddControl("Button",params) params.Text = "---------------------------------------------------------------" Panel:AddControl("Label",params) params.Text = "Stop all Music" params.Command = "playsound stop" Panel:AddControl("Button",params) end // Create the menu itself local function NewMenu_D2K() spawnmenu.AddToolMenuOption( "Options", "Music", "<Soundtrack Name Here> Music Menu", "<Soundtrack Name Here>", "", "", PlayMusicMenu_D2K ) end hook.Add( "PopulateToolMenu", "PlayMusicMenu_<Soundtrack Name's Shortform>", NewMenu_D2K )

Change the angled brackets with the name of the soundtrack and you probably know the rest...

If you're done with adding the tracks, you need to make sure these files including the LUA file are in their correct file paths otherwise it will not work.

<Your Folder>/lua/autorun/client/play_music_<soundtracknamehere>.lua <Your Folder>/sound/music/<filenamehere>.mp3

Then, put it in your addons folder and it should probably work now.

If this is too complicated for you then I apologize (I'm not good at explaining things).
Or you can follow my other guide which is quite simple.
After waiting for a very long time, theres no sound tracks added yet. I dont know whats the problem and i would like to know how to actually do it.

I H A V E done all the instructions you said, i changed some stuff on the lua files, put correct file paths in the folder, and put it in the addons file.

However, it does look like it does not work.
The problem: Theres no menu for "Portal 2 Action".
I am desperate for this. I couldnt find anything else, and people refuse to do it.
Please, your my only chance..
Versus 24 ENE 2023 a las 7:29 
Maybe you need the base addon for it to work..? :/
< >
Mostrando 1-15 de 20 comentarios
Por página: 1530 50