Raised This Month: $27 Target: $400
 6% 

[ANY] automatic server update (windows)


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
ambn
Veteran Member
Join Date: Feb 2015
Location: Fun servers
Old 02-04-2017 , 13:02   [ANY] automatic server update (windows)
Reply With Quote #1

well, i've been looking for a simple way to make it work, and now i've made something very simple using PTaH extention.
how it works?
this is very simple just follow the steps:
1- make an autoupdate script:
- this is what i use for server crash but it can also used to make your server update it's self on server quit :
Spoiler

2- Server update detection:
- it's also very simple , just use PTaH and The attached plugin so your server will get the first chance to update it's self!
Spoiler

so that's it, your server will update it self each time!
NOTE : i've blocked players from typing MasterRequestRestart , cause it can be used by players to shutdown your server and also your server needs to be empty to get updated ..
this way might look very noobish but at least it's what's possible for windows (or what i know ).
Attached Files
File Type: sp Get Plugin or Get Source (sb.sp - 452 views - 981 Bytes)
File Type: smx sb.smx (4.6 KB, 434 views)
__________________

Last edited by ambn; 02-08-2017 at 08:20.
ambn is offline
psychonic

BAFFLED
Join Date: May 2008
Old 02-04-2017 , 13:10   Re: [ANY] automatic server update (windows)
Reply With Quote #2

With that script above, your server will exit if anyone with "MasterRequestRestart" in their name joins. There are probably others ways to exploit it as well.

Instead, the SteamWorks extension has a hook for the callback from Steam that generates the actual message (although it does not work on all games), or any of the extensions that provide an HTTP API can query the Steam UpToDateCheck Web API with the server version from steam.inf to see if the server requires an update.
psychonic is offline
KyleS
SourceMod Plugin Approver
Join Date: Jul 2009
Location: Segmentation Fault.
Old 02-04-2017 , 16:54   Re: [ANY] automatic server update (windows)
Reply With Quote #3

Quote:
Originally Posted by psychonic View Post
With that script above, your server will exit if anyone with "MasterRequestRestart" in their name joins. There are probably others ways to exploit it as well.

Instead, the SteamWorks extension has a hook for the callback from Steam that generates the actual message (although it does not work on all games), or any of the extensions that provide an HTTP API can query the Steam UpToDateCheck Web API with the server version from steam.inf to see if the server requires an update.
Indeed, I wrote a plugin that does this and should support all Valve games. It's small and all you have to do is drag and drop.
KyleS is offline
ambn
Veteran Member
Join Date: Feb 2015
Location: Fun servers
Old 02-08-2017 , 07:37   Re: [ANY] automatic server update (windows)
Reply With Quote #4

Quote:
Originally Posted by psychonic View Post
With that script above, your server will exit if anyone with "MasterRequestRestart" in their name joins. There are probably others ways to exploit it as well.

Instead, the SteamWorks extension has a hook for the callback from Steam that generates the actual message (although it does not work on all games), or any of the extensions that provide an HTTP API can query the Steam UpToDateCheck Web API with the server version from steam.inf to see if the server requires an update.
Updated .
I Think this is fixed now ...
__________________
ambn is offline
weeeishy
Senior Member
Join Date: Jul 2015
Location: Kuwait
Old 06-08-2017 , 20:36   Re: [ANY] automatic server update (windows)
Reply With Quote #5

Is there a problem with the script? The server just keeps restarting over and over lol, it started happening before the last 2 updates. I'm using sedirector for another server on the same machine and its updating fine.
__________________
weeeishy is offline
ambn
Veteran Member
Join Date: Feb 2015
Location: Fun servers
Old 06-09-2017 , 22:08   Re: [ANY] automatic server update (windows)
Reply With Quote #6

Quote:
Originally Posted by weeeishy View Post
Is there a problem with the script? The server just keeps restarting over and over lol, it started happening before the last 2 updates. I'm using sedirector for another server on the same machine and its updating fine.
I am using this script over 50 servers since i released it.
Maybe you did something wrong, maybe posting your script?
__________________
ambn is offline
Despirator
Senior Member
Join Date: Jun 2011
Location: Kazakhstan ->Shymkent
Old 06-14-2017 , 01:27   Re: [ANY] automatic server update (windows)
Reply With Quote #7

I would rather use the SteamWorks extension to detect update request
Despirator is offline
e54385991
AlliedModders Donor
Join Date: Aug 2013
Old 06-14-2017 , 15:28   Re: [ANY] automatic server update (windows)
Reply With Quote #8

You can just use this https://forums.alliedmods.net/showthread.php?t=298085
__________________

Last edited by e54385991; 06-14-2017 at 15:35.
e54385991 is offline
Send a message via ICQ to e54385991
ambn
Veteran Member
Join Date: Feb 2015
Location: Fun servers
Old 06-14-2017 , 22:03   Re: [ANY] automatic server update (windows)
Reply With Quote #9

This is just a super simple method you can use or not so whatever!
__________________
ambn is offline
Cats869
New Member
Join Date: Apr 2020
Old 04-26-2020 , 14:26   Re: [ANY] automatic server update (windows)
Reply With Quote #10

Quote:
Originally Posted by KyleS View Post
Indeed, I wrote a plugin that does this and should support all Valve games. It's small and all you have to do is drag and drop.

Hello,

I was wondering which specific plugin that does that? Trying to better understand the SteamWorks but still very much unfamiliar.

I'm trying to get this plugin, that ambn wrote, to work but it won't work since the version of PTaH that this plugin requires is an old version (and newer versions of PTaH inc file has changed quite a bit so it's now incompatible with this unmaintained plugin). Also, if I were to load an older version, CSGO crashes so that's a no go as well.

Thank you!

Last edited by Cats869; 04-26-2020 at 14:35.
Cats869 is offline
Reply


Thread Tools
Display Modes

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 15:30.


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