I've recently made a server and i've put the addons inside the addons folder but for whatever reason nothing is downloading when I or my friend joins the server.
You have to use [URL="http://wiki.garrysmod.com/page/resource/AddFile"]resource.AddFile[/URL] to force clients to download custom models, materials, sounds. NOT lua files though.
[QUOTE=Svenskunganka;44565477]You have to use [URL="http://wiki.garrysmod.com/page/resource/AddFile"]resource.AddFile[/URL] to force clients to download custom models, materials, sounds. NOT lua files though.[/QUOTE]
Alright, what folder/file would I put this in?
[QUOTE=ZakkerDoodle;44565488]Alright, what folder/file would I put this in?[/QUOTE]
For example, if you have a model in [B]/addons/some_addon/models/model.mdl[/B] you would put [B]resource.AddFile("models/model.mdl")[/B] inside a file called [B]/addons/some_addon/lua/autorun/server/something.lua[/B]
[QUOTE=Svenskunganka;44565891]For example, if you have a model in [B]/addons/some_addon/models/model.mdl[/B] you would put [B]resource.AddFile("models/model.mdl")[/B] inside a file called [B]/addons/some_addon/lua/autorun/server/something.lua[/B][/QUOTE]
okay, I did it, and it did download. However the playermodels are still errors.
You have to force the materials for the model aswell. This has been discussed 1,000,000 of times here, so just do a search on resource.AddFile and you will find [B][U]LOTS[/U][/B] of results.
[QUOTE=Svenskunganka;44566127]You have to force the materials for the model aswell. This has been discussed 1,000,000 of times here, so just do a search on resource.AddFile and you will find [B][U]LOTS[/U][/B] of results.[/QUOTE]
Okay, before I do, im not sure if my playermodel may have bugs or whatever, but I found the .lua folder in autorun, Materials and Models dont have one.
[QUOTE=ZakkerDoodle;44566217]Okay, before I do, im not sure if my playermodel may have bugs or whatever, but I found the .lua folder in autorun, Materials and Models dont have one.[/QUOTE]
Just search, I'm not going to go over this for the 2,000th time.
If they're on the workshop use this. [URL="http://wiki.garrysmod.com/page/resource/AddWorkshop"]http://wiki.garrysmod.com/page/resource/AddWorkshop[/URL]
Sorry, you need to Log In to post a reply to this thread.