Raised This Month: $ Target: $400
 0% 

Updater


Post New Thread Reply   
 
Thread Tools Display Modes
legend2360
Junior Member
Join Date: Aug 2012
Location: Vladimir, Russia
Old 08-15-2012 , 15:52   Re: Updater
Reply With Quote #181

Hm... I'm confused ... I've watched so many sources codes that I can not remember. And something like that it's your code.
Sorry =(.
P.S. Help me with my plugin,please ...
__________________
Oh... my bad english =(

Last edited by legend2360; 08-15-2012 at 15:55.
legend2360 is offline
Dr. McKay
Sir Dr. SourceMod Plugin Approver Esq. Ltd. M.D. PhD
Join Date: Aug 2011
Location: Atlantis
Old 08-15-2012 , 16:18   Re: Updater
Reply With Quote #182

Try this.

Code:
#include <sourcemod> 

#undef REQUIRE_PLUGIN 
#include <updater> 

#define UPDATE_URL "http://mywebsait.ru/plgname/plgname.txt" 
#define PLUGIN_VERSION "1.1" 

public OnAllPluginsLoaded() 
{ 
   if(LibraryExists("updater")) { 
    Updater_AddPlugin(UPDATE_URL); 
   }
} 

public OnLibraryAdded(const String:name[]) 
{ 
        if (StrEqual(name, "updater")) 
        { 
              Updater_AddPlugin(UPDATE_URL); 
        } 
} 

public Updater_OnPluginUpdated() 
{ 
         Updater_Log("Plugin PlgName is successful downloading and updating!"); 
         CPrintToChatAll("Плагин {lightgreen}PlgName{default} был успешно обновлен!"); 
} 

Updater_Log(const String:format[], any:...) 
{ 
         decl String:buffer[256], String:path[PLATFORM_MAX_PATH]; 
         VFormat(buffer, sizeof(buffer), format, 2); 
         BuildPath(Path_SM, path, sizeof(path), "logs/plugin_plgname_Update.log"); 
         LogToFileEx(path, "%s", buffer); 
}
__________________
Dr. McKay is offline
legend2360
Junior Member
Join Date: Aug 2012
Location: Vladimir, Russia
Old 08-15-2012 , 16:37   Re: Updater
Reply With Quote #183

Not working... =( May need socket?

No... Socket is enabled, but plugin not update...
__________________
Oh... my bad english =(

Last edited by legend2360; 08-15-2012 at 16:41. Reason: Socket is enabled.
legend2360 is offline
legend2360
Junior Member
Join Date: Aug 2012
Location: Vladimir, Russia
Old 08-17-2012 , 05:06   Re: Updater
Reply With Quote #184

Heelp, plz! =(
__________________
Oh... my bad english =(
legend2360 is offline
GoD-Tony
Veteran Member
Join Date: Jul 2005
Old 08-17-2012 , 05:09   Re: Updater
Reply With Quote #185

Quote:
Originally Posted by legend2360 View Post
Not working... =( May need socket?

No... Socket is enabled, but plugin not update...
Compile Updater with debug features enabled and see what kind of output you get when your plugin tries to update.
__________________

Last edited by GoD-Tony; 08-17-2012 at 05:09.
GoD-Tony is offline
snelvuur
Veteran Member
Join Date: Jun 2008
Location: Netherlands
Old 08-17-2012 , 05:12   Re: Updater
Reply With Quote #186

Dont you have socket extensions or any of the other options to actually download the file? Is that what you mean?
__________________
Arguing with a fool only proves there are two

Last edited by snelvuur; 08-17-2012 at 05:13.
snelvuur is offline
legend2360
Junior Member
Join Date: Aug 2012
Location: Vladimir, Russia
Old 08-17-2012 , 06:16   Re: Updater
Reply With Quote #187

Quote:
Originally Posted by GoD-Tony View Post
Compile Updater with debug features enabled and see what kind of output you get when your plugin tries to update.
But DEBUG is enabled in my plugin.
#define DEBUG - so?
__________________
Oh... my bad english =(
legend2360 is offline
GoD-Tony
Veteran Member
Join Date: Jul 2005
Old 08-17-2012 , 06:19   Re: Updater
Reply With Quote #188

Quote:
Originally Posted by legend2360 View Post
But DEBUG is enabled in my plugin.
#define DEBUG - so?
And what is shown in the Updater_Debug.log file?

Edit: I meant to enable it in Updater itself, not your plugin.
__________________

Last edited by GoD-Tony; 08-17-2012 at 06:21.
GoD-Tony is offline
legend2360
Junior Member
Join Date: Aug 2012
Location: Vladimir, Russia
Old 08-17-2012 , 07:27   Re: Updater
Reply With Quote #189

Stop. After updater.smx(after sm_updater_check) it updated. Automatically - no (no plugin).
__________________
Oh... my bad english =(

Last edited by legend2360; 08-17-2012 at 07:28.
legend2360 is offline
asherkin
SourceMod Developer
Join Date: Aug 2009
Location: OnGameFrame()
Old 08-17-2012 , 07:32   Re: Updater
Reply With Quote #190

Quote:
Originally Posted by legend2360 View Post
Stop. After updater.smx(after sm_updater_check) it updated. Automatically - no (no plugin).
updater.smx is what handles the actual updating, you need to have it installed.
__________________
asherkin is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 06:42.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode