Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Server status check in client


Saitonashi
 Share

Recommended Posts

Hi I would like to ask if there's a script for a message to the login screen before logging into the game, or registration, on the corner was saying that the server status is 'Online' or 'Offline'. Thanks in advance for your response.
Link to comment
Share on other sites

@Saitonashi:

> I want to when you see the login window, it automatically connected to the server to check the availability and status of the window was a picture speaks of this status.
>
> @: HELP ME PLEASE

If you would've actually searched the answers, you could've found your answer a long time ago quite frankly.

[From this:](http://www.touchofdeathforums.com/smf/index.php?topic=75653.0)
@Athagekin:

> Hey Kocho, it's Jed. I've done this for my game as well.
>
> Go to frmMainMenu and create a new label somewhere. I left my label's name Label1 by default, but if you decide to rename it, then be sure to update the code so that it works. Now, go into your frmMainMenu code and add this:
>
> ```
> Private Sub Form_Activate()
>     If ConnectToServer(1) Then
>         Label1.Caption = "Server Status: Online"
>         Label1.ForeColor = &HFF00&
>     ElseIf ConnectToServer(0) Then
>         Label1.Caption = "Server Status: Offline"
>         Label1.ForeColor = &HFF&
>     End If
> End Sub
> ```
> Then you're done.
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...