ULX

Author Topic: Having problems with client scripts on dedicated server?  (Read 7264 times)

0 Members and 1 Guest are viewing this topic.

Offline spbogie

  • Ulysses Team Member
  • Sr. Member
  • *****
  • Posts: 456
  • Karma: 41
Having problems with client scripts on dedicated server?
« on: January 18, 2008, 07:57:46 AM »
GMod is now using the default download system for Lua files along with everything else. So, if you are running a dedicated server with sv_downloadurl set, you will need to place your clientside Lua scripts on the sv_downloadurl server as well, or they will not download.
I have not failed. I've just found 10,000 ways that won't work. - Thomas A. Edison
I reject your reality and substitute my own. - Adam Savage

Offline atomicspark

  • Full Member
  • ***
  • Posts: 196
  • Karma: 12
Re: Having problems with client scripts on dedicated server?
« Reply #1 on: January 18, 2008, 08:57:48 AM »
D:!

This is AWESOME.

I LOVE GARRY.

(and you for telling me).

Offline MrPresident

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 2728
  • Karma: 430
    • |G4P| Gman4President
Re: Having problems with client scripts on dedicated server?
« Reply #2 on: January 18, 2008, 11:14:17 AM »
OOOOOOOHHHH boy... this is just going to cause way more trouble than it's worth. I can see all the questions now....

Offline Avien

  • Full Member
  • ***
  • Posts: 168
  • Karma: 4
Re: Having problems with client scripts on dedicated server?
« Reply #3 on: January 18, 2008, 11:48:11 AM »
So if it is in an addon you place it in garrysmod/addons/ on your downloadurl?

Offline Megiddo

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 6214
  • Karma: 394
  • Project Lead
Re: Having problems with client scripts on dedicated server?
« Reply #4 on: January 18, 2008, 11:53:36 AM »
No, it won't read from addons.
Experiencing God's grace one day at a time.

Offline Avien

  • Full Member
  • ***
  • Posts: 168
  • Karma: 4
Re: Having problems with client scripts on dedicated server?
« Reply #5 on: January 18, 2008, 12:08:14 PM »
So just make it so they are in the correct folders?

IE:
addons/phx/lua ====> garrysmod/lua

Like that?

Offline atomicspark

  • Full Member
  • ***
  • Posts: 196
  • Karma: 12
Re: Having problems with client scripts on dedicated server?
« Reply #6 on: January 18, 2008, 01:04:46 PM »
This is not as good as I thought it would be. My webhost is pissed at me right now. Calling it a DoS attack. :\

Offline Banyon

  • Jr. Member
  • **
  • Posts: 52
  • Karma: 12
    • Kill 'a' Byte
Re: Having problems with client scripts on dedicated server?
« Reply #7 on: January 18, 2008, 01:18:33 PM »
I can see many problems with this in the future considering many webserver admins STILL don't know how to use sv_downloadurl

Offline atomicspark

  • Full Member
  • ***
  • Posts: 196
  • Karma: 12
Re: Having problems with client scripts on dedicated server?
« Reply #8 on: January 18, 2008, 01:39:30 PM »
I just got in touch with them. They said I had 1500 active connections from one IP address. I'm disabling sv_downloadurl for now. :\

Offline Avien

  • Full Member
  • ***
  • Posts: 168
  • Karma: 4
Re: Having problems with client scripts on dedicated server?
« Reply #9 on: January 18, 2008, 05:38:22 PM »
I'm a little confused.  What all do we put in our downloadurl and what should it look like?  I already have a maps folder, but i am not sure what you mean by clientside lua files.  Can you give me an example please?

Offline MulleDK13

  • Newbie
  • *
  • Posts: 13
  • Karma: 0
Re: Having problems with client scripts on dedicated server?
« Reply #10 on: January 18, 2008, 06:01:29 PM »
Argh! This has been bugging me since the release of the crappy update...

My sv_downloadurl = ""
And clients still does not download the files!

How does it work!?!!????

Offline Megiddo

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 6214
  • Karma: 394
  • Project Lead
Re: Having problems with client scripts on dedicated server?
« Reply #11 on: January 18, 2008, 06:40:07 PM »
Okay, it does try to download the lua scripts from your fast dl server, but not how you think it does. It's looking for files like this... "<root>/cache/dua/3499012667.dua".

Yes, that means if you want to use your fast dl server, you'll have to upload the server lua cache.
Experiencing God's grace one day at a time.

Offline atomicspark

  • Full Member
  • ***
  • Posts: 196
  • Karma: 12
Re: Having problems with client scripts on dedicated server?
« Reply #12 on: January 18, 2008, 07:02:19 PM »
Will this cache only change when the Lua files are updated/added?

Offline Megiddo

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 6214
  • Karma: 394
  • Project Lead
Re: Having problems with client scripts on dedicated server?
« Reply #13 on: January 18, 2008, 07:04:50 PM »
Correct spark.
Experiencing God's grace one day at a time.

Offline Avien

  • Full Member
  • ***
  • Posts: 168
  • Karma: 4
Re: Having problems with client scripts on dedicated server?
« Reply #14 on: January 19, 2008, 09:30:39 AM »
Okay, it does try to download the lua scripts from your fast dl server, but not how you think it does. It's looking for files like this... "<root>/cache/dua/3499012667.dua".

Yes, that means if you want to use your fast dl server, you'll have to upload the server lua cache.


Thanks for that.  I tried like 15 different variations for the new thruster,(gmod_tool/stools/thrusters.lua), but no matter what i tried i could not seem to download the little bugger and my thruster would be broken.  I even tried making my own game to get the lua files correctly, but with no go on multiplayer servers.


If i upload this cache to my downloadurl, will it get downloaded all the time, or only when something changes that the client doesn't have?