Jump to content
Sign in to follow this  
lostom

Check if gameserver is not running/not responding.

Recommended Posts

lostom

Hello,

I've made a script in autoit to restart my gameservers if they shutdown, or when dw20.exe appears, but unfortunately that doesn't cover all crashes.

It's about a modern warfare 2 dedicated server, which looks like this: Posted Image

The gameserver is down when:

  • program is closed
  • When dw20.exe appears
  • sv_running returns "sv_running" is: "0" default: "0" in the console
  • or when it's stuck for over 30 seconds

Now, the first 2 things are covered with my current script, but the other 2 aren't.

Is it possible to make a script which covers those?

sv_running can be checked if sv_running is typed into the server console, and it will directly return 0 or 1 (as stated above), but I don't know how to that, and if that's even possible.

The 4th error shouldn't be such a problem, but the problem is that I don't really understand the current scripts which cover that.

I would really appreciate it if someone could help me out (I'm a kind of "noob" in autoIT)

Share this post


Link to post
Share on other sites
lostom

This might fall under the "no game automation" rule. :)

As far as I can read, that's just about game bots, but I can be wrong.

Share this post


Link to post
Share on other sites
kaotkbliss

The way I see it, you are trying to automate restarting your server in case of crash. Seems legit to me, but I could be wrong as well.

*edit*

Can autoIt's Window info tool read the server console? if you you can use a regex to get the text for #3

for #4 There have been posts in the forums about detecting when a exe has stopped responding, finding those posts may help with that :)

Edited by kaotkbliss

010101000110100001101001011100110010000001101001011100110010000

001101101011110010010000001110011011010010110011100100001

My Android cat and mouse game
https://play.google.com/store/apps/details?id=com.KaosVisions.WhiskersNSqueek

We're gonna need another Timmy!

Share this post


Link to post
Share on other sites
bogQ

only adding additional info

info on page with (ctrl+F) "By May 2010"

http://en.wikipedia.org/wiki/Controversies_surrounding_Call_of_Duty:_Modern_Warfare_2#PC_version

Edited by bogQ

TCP server and client - Learning about TCP servers and clients connection
Au3 oIrrlicht - Irrlicht project
Au3impact - Another 3D DLL game engine for autoit. (3impact 3Drad related)



460px-Thief-4-temp-banner.jpg
There are those that believe that the perfect heist lies in the preparation.
Some say that it’s all in the timing, seizing the right opportunity. Others even say it’s the ability to leave no trace behind, be a ghost.

 

Share this post


Link to post
Share on other sites
lostom

The way I see it, you are trying to automate restarting your server in case of crash. Seems legit to me, but I could be wrong as well.

*edit*

Can autoIt's Window info tool read the server console? if you you can use a regex to get the text for #3

Yes it can. Posted Image

Though, I don't really know what to do with it.

for #4 There have been posts in the forums about detecting when a exe has stopped responding, finding those posts may help with that :)

Ok, I will take another look at it later on.

Share this post


Link to post
Share on other sites
Valik

While your use does seem legitimate, this does fall under the rules and as such will be closed.

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.