• HTTP failed - ISteamHTTP isn't available!
    17 replies, posted
I had a lua addon made (downloads a file from a web site) that works fine in my windows client, but on my linux server it doesnt work because HTTP downloads aren't working. On server startup, the server log says: [CODE]HTTP failed - ISteamHTTP isn't available![/CODE] EDIT: I got the answer from the coder who made my addon. For anyone else wondering how to fix this error. It occurs because the addon is sending the http request before the server is ready. So it needs to be delayed.
Sorry to revive this old post. But how would you propperly delay this? I need my http request to be run as soon as possible after it becomes possible (making it get data for resource.Add things)
Sorry for old bump but is it possible to fix this? Like for example putting an if-statement around your resource.addfile code: [lua]if ( ISteamHTTP:IsAvailable ) then resource.AddFile(myfile.vmt) end[/lua]
[QUOTE=maximizer39v2;42630494]Sorry for old bump but is it possible to fix this? Like for example putting an if-statement around your resource.addfile code: [lua]if ( ISteamHTTP:IsAvailable ) then resource.AddFile(myfile.vmt) end[/lua][/QUOTE] Just call it after the server is ready? Would probably be in the Initialize or InitPostEntity hook.
But wouldn't that be too late for the clients to still download?
Http isnt started with the server Do a simple timer delay of about 25 seconds
How would I go about doing a timer delay?
Sorry to restart the thread, but does anyone have any idea how to set a delay on your addons? I have quite a few, so delaying them all at once would be a charm, but otherwise, I'll go through one by one... Thanks!
You can't "delay an addon". You'll have to edit all the addons and put a timer where needed on parts you want to delay.
[QUOTE=Robotboy655;44477645]You can't "delay an addon". You'll have to edit all the addons and put a timer where needed on parts you want to delay.[/QUOTE] Http is delayed by a few sec, idk why. Addon shouldnt be so reliant
What directly causes this to occur?
[QUOTE=Baron von Hax;44489922]What directly causes this to occur?[/QUOTE] Trying to use http when it isn't ready.
one cause is the statistics files on coderhire addons
[QUOTE=Baron von Hax;44506219]one cause is the statistics files on coderhire addons[/QUOTE] Because, http isnt initialized yet Just delay it. By like 3-5 seconds
How would I go about doing this?
Timer.Simple(5, function() your code here end)
Can you please put the full code and tell me where to put it thanks :) [highlight](User was banned for this post ("Dumb Bump" - Kiwi))[/highlight]
Sorry, you need to Log In to post a reply to this thread.