Check that the files are definitely on the fastdl and the folders and files on both fastdl server and gmod server have no caps as this can mess with Linux, other than that any errors in server console or client console about not finding the files on the webserver. And although this may seem stupid just check that you have the sv_downloadurl set right.
It does it automatically; look how it adds it with sounds/…/
then it calls them with …/
Make sure your files are in the correct locations; double check they’re being downloaded. If you have fastdl url setup, ensure the folders / files are in correct locations.
Show us what it looks like and we can help further if you’re using fastdl. If not, check my addon, drag and drop it into addons and they should download automatically if you restart the server. Follow the same pattern for your files.
Acecool, I’ve never really spoken to or about you before, but you’re not really helping anyone. Don’t try to “help” by people by advertising your shit and having them go through your somewhat confusing code. You don’t see me or other coders advertising their glorious library everywhere.
Now, to actually help.
This happened to someone else I know. The problem was is that sv_allowdownload wasn’t enabled.
The way your doing resource.AddFile is absolutely fine.
Just asking to rule out other possibilities, where is the lua file saved?
sv_allowdownload should ALWAYS be set to 1, No matter what.
Also, the lua files seem to be in the right place.
What is sv_downloadurl set to? If it’s blank then you’re all good. If it’s not, tell me and I’ll tell you what to do next.
I’m not advertising anything; I post tutorials and things I think will help someone with their current problem. If the OP looks at that addon, it’ll give a good idea of where to put what, when, where and how.
If everything is in the correct location, then we can proceed with other debugging methods to help the OP.
As you said, you’ve never spoken to me, so you don’t know what I’m about; don’t assume what you think you know is right, because it isn’t.
The OP says he has a resources file, but no one downloads it. This can be from the file not being included / not being in the right place, fastdl incorrectly configured ( but it would show the user that it is trying to download each time they connect; doesn’t sound like what the OP described ), serverdl incorrectly configured ( may or may not show the user that it is trying to download, I haven’t tried this scenario so it may either act like fastdl being set up incorrectly or it may not show anything ). I’m trying to establish a direct line of communication to figure the problem out as the OP wasn’t clear with everything.
Did you say it is lua/autorun/resources/resource.lua?
The autorun directory will only automatically run files located in these locations:
lua/autorun/.lua = shared
lua/autorun/client/.lua = client
lua/autorun/server/*.lua = server
addons/<addon_name>/lua/autorun/.lua = shared
addons/<addon_name>/lua/autorun/client/.lua = client
addons/<addon_name>/lua/autorun/server/*.lua = server
If you want to automatically load a file in a sub-folder, such as the current map from an addon:
Whereby the file pasted below is shown here:
And this is what it will include:
[lua] local _folder = “autorun/server/maps/”;
local _file = string.lower( game.GetMap( ) ) … “.lua”;
if ( !file.Exists( _folder … _file, “LUA” ) ) then ErrorNoHalt( "Map File not found : " … _folder … _file … "
" ); return; end
include( _folder … _file );[/lua]
If the map files were simply in addons/<addon_name>/lua/autorun/server/maps/*.lua then they wouldn’t be included; the autorun directories aren’t recursively loaded.
Make sure the file is being included; try adding this to the top of your resources.lua file:
[lua]MsgC( Color( 255, 0, 0, 255 ), string.rep( “*”, 150 ) );[/lua]
Not really, I just want to make sure that the structure is as follows:
lua/autorun/resources.lua , correct?
Again tell me what sv_downloadurl is set to, and make sure that sv_allowdownload is set to 1
[editline]17th June 2014[/editline]
To be honest, looking at your post history for the past day or so, it seems like you posted that addon to other people who wanted help. You gave no real explanation and (somehow) expected people to go through your massive comments and your somewhat confusing code. Instead of giving them what they really want, a simple and clear solution to their problem. You give them a giant wall of text, and an entire addon, and that really does nothing but make the person have to work through shit that was bigger than the problem they had in the first place.
My best guess, is that you wanted people to go through your code to see how awesome it was or some shit…(That will not happen any time soon) and hope people use your glorious end round music…thing. I don’t cough up entire workable versions of ARCBank, ARCLib, Displacement Devices, or other of my pre-made works when someone asks for a simple solution. Neither do any other coders on here.
If someone wants a more in-depth answer, they will ask for it. Just remember that most people who want help want a clear, simple, easy to understand solution, with suggestions being less than 2 sentences.
If someone wants some example code, they will want something that’s straight to the point, easy to read, and not filled with “MADE BY ARITZ (CRACKER) BEOBIDE-CARDINAL HURR” everywhere. I see you didn’t spam your name anywhere in your post, Josh, so it seems like you’re improving.
I’m not hating on you, I just want to tell you why a lot of people here are upset about you whenever you offer your “help”.
Yes, I never spoke to you personally, so I can only guess when it comes to your motivations, but what I know for sure are people’s reactions when it comes to you.