EOSERV Forum > Lounge > GUI Server Auto Restarter
Topic is locked.
Page: << 1 2 >>
GUI Server Auto Restarter
Author Message
Post #88099 GUI Server Auto Restarter

Basically mocked this up real quick in visual basic, it doesn't look that pretty and I haven't exactly what you'd call "tested" this so if someone could use it and let me know if it works ;) that would be lovely XD! Seems to work from what I've tested of it though... 
if anyone would like to make me some pretty images that I can use instead of these buttons I would be greatful, y'know just to give it that little extra "EOSERV" Feel ;)
Screenshot:

Download Link Click Me!
Usage:
to set the name of your server .exe click settings then change 'eoserv' to whatever your executable is called
To set how often the server auto restarter checks change the 1 in the settings, enjoy

Oh and you need to put this application in the same directory as your eoserv executable, sorry, forgot to mention that ;p

---
If money doesn't grow on trees, then why do banks have branches?
13 years, 42 weeks ago
Post #88101 Re: GUI Server Auto Restarter

If you could create this in 10 minutes I doubt it's hard to program. :P It looks good.

13 years, 42 weeks ago
Post #88102 Re: GUI Server Auto Restarter

It really isn't that difficult at all xD.. I don't really think VB was designed to be complex being totally honest with you, but it entertained me for 10 minutes, so I'm not complaining :P and if people use it then hey, we're all winners :D If there's any bugs with it, can someone kindly let me know and I'll do my best to fix them but from what I can see, I can't see any issues with it :)

---
If money doesn't grow on trees, then why do banks have branches?
13 years, 42 weeks ago
Post #88103 Re: GUI Server Auto Restarter
DanScott posted: (15th Jul 2011 07:13 pm)

It really isn't that difficult at all xD.. I don't really think VB was designed to be complex being totally honest with you, but it entertained me for 10 minutes, so I'm not complaining :P and if people use it then hey, we're all winners :D If there's any bugs with it, can someone kindly let meknow and I'll do my best to fix them but from what I can see, I can't see any issues with it :)

Lol VB was designed to be totally laid out for you :p. You don't have to create forms by yourself etc only tell what the "OK" button has to do in one line of code.

13 years, 42 weeks ago
Post #88104 Re: GUI Server Auto Restarter

That's why it was my 3rd? language to learn when I wanted to make applications for Windows :D

---
I am an alien and not crazy!
13 years, 42 weeks ago
Post #88105 Re: GUI Server Auto Restarter

@Kaylinz Well this was a bit more than one line of code ;) but yes, there really isn't much skill involved in visual basic xD! Which I guess is good for programmers, simplify's things a great deal :) especially if what they're developing involves a GUI

@Desmond aha, this was my second. Only because it's what we're learning in computing at the moment ;p my first was pascal, hence the ASCII games I post here xD!

---
If money doesn't grow on trees, then why do banks have branches?
13 years, 42 weeks ago
Post #88106 Re: GUI Server Auto Restarter

haha, yeah visual basic is pretty simple for some stuff, but sometimes it gets really complicated because of how simple VB is. This program is basicly starting the process of the server and tracking it. 

E.G , here are some components. Good job on it!

Dim Proc = New ProcessStartInfo

Proc.FileName = Path.GetDirectoryName(Application.ExecutablePath) & "\server.exe"


Dim Manual = false

Proce = Process.Start(Proc)


function KillServer()

if not Proc = nothing then

Manual = true

Proce.Kill()

end if

end function


function CheckServer()

if not Proce = Nothing then

if Proce.HasExited = false and then

return false

else

if Manual then

return false

else

Proce = Process.Start(Proc)

return Proce

'Now you might wanna check for errors in it or else it would just keep 'popping up and popping up because of crashes.

end if

end if

end function

---
Andrewbob - I would be on the fucking copter of rofls

Programmer, Web Developer, and Graphics Designer
13 years, 42 weeks ago
Post #88108 Re: GUI Server Auto Restarter

it's actually EndIf ;) But yeah XD! and I didn't bother with that whole get directory stuff I just did sExeName = "./eoserv.exe" 
to modify it the only code is this 

Private Sub saveCmd_Click()

MsgBox ("Settings Saved")

Form1.Height = 1485 'hides settings

sExeName = exeName.Text

sExePath = "./" + sExeName + ".exe"

Timer1.interval = Val(interval.Text) * 1000 'Used to turn ms into s

End Sub

:P

---
If money doesn't grow on trees, then why do banks have branches?
13 years, 42 weeks ago
Post #88109 Re: GUI Server Auto Restarter

Haha, yeah sorry bout that. I got off from programming in lua where it's end <:o mhm pretty simple stuff though (: nice job. You might wanna check if the directory exists too, nasty errors and such.

---
Andrewbob - I would be on the fucking copter of rofls

Programmer, Web Developer, and Graphics Designer
13 years, 42 weeks ago
Post #88112 Re: GUI Server Auto Restarter
Wildsurvival posted: (15th Jul 2011 07:37 pm)

Haha, yeah sorry bout that. I got off from programming in lua where it's end <:o mhm pretty simple stuff though (: nice job. You might wanna check if the directory exists too, nasty errors and such.


Well, the directory should exist if it's user is putting it in the same directory as their EOSERV file because that's only how it's going to work at the moment, don't see any reason why I'd need to change it, if they want to run this application from anywhere else they should just create a shortcut for it :p but I could add the ability for the program to check to see if the executable exists :) I'll have a play with that one :P Thanks
---
If money doesn't grow on trees, then why do banks have branches?
13 years, 42 weeks ago
Post #88113 Re: GUI Server Auto Restarter

Np (: its pretty simple as well. File.Exists()

---
Andrewbob - I would be on the fucking copter of rofls

Programmer, Web Developer, and Graphics Designer
13 years, 42 weeks ago
Post #88118 Re: GUI Server Auto Restarter

You sure it's that? it says variable 'File' not defined ;p tried a few other suggestions for VB6 online, can't really find one that seems to work :S

---
If money doesn't grow on trees, then why do banks have branches?
13 years, 42 weeks ago
Post #88119 Re: GUI Server Auto Restarter

VB was my first language to use, you don't see me using it now. Upgrade kids.

---
http://www.addipop.com
13 years, 42 weeks ago
Post #88122 Re: GUI Server Auto Restarter
Addison posted: (15th Jul 2011 08:26 pm)

VB was my first language to use, you don't see me using it now. Upgrade kids.


But VB is easy, why over complicate something that can be done simply? :p
---
If money doesn't grow on trees, then why do banks have branches?
13 years, 42 weeks ago
Post #88124 Re: GUI Server Auto Restarter

I use more languages along with VB :P this topic just happened to be a program made in VB. :P


@Dan i think you gotta include System.IO Then it should work. File.Exists() is what im using in this other program i have.
---
Andrewbob - I would be on the fucking copter of rofls

Programmer, Web Developer, and Graphics Designer
13 years, 42 weeks ago
Page: << 1 2 >>
Topic is locked.
EOSERV Forum > Lounge > GUI Server Auto Restarter