16-12-2006, 09:15 PM
Difficulty 1/5
![[Image: ssSS.gif]](http://www.flawsin.com/ssSS.gif)
This is pretty simple and works best with mysql since you can have multiple servers share a database but it can also be used with the other versions. You can have multiple servers if one cant support your player base but with other versions each must have their own databases. Anyways its pretty simple but might as well post it here if anyone wants to use it.
Everything done here is CLIENT SIDE
Go to modClientTCP.
Find
Under it add
Find
Change that to
Now go to frmLogin
Make X Option Buttons (where X is the number of servers you want to have.)
Name them something easy such as ... opt1, opt2, opt3 so on.
Now make the same amount of labels. Name each whatever the servers are called and place them with the option buttons.
[You can do this with buttons or listbox or whatever you like... I chose option buttons.]
Now Find
Under it add
Add more for each server you have... if you have 2 servers you would also add
If opt2.Value = True Then
GAME_IP = "127.0.0.1"
Call TcpInit
End If
Also remember to change the IPs to the IPs of the servers you want it to connect to.
Thats pretty much it. You choose a server and when you connect it connects to that server.
You may also want to have one of the option buttons set to True when you make it so that 1 will always be checked at least.
Any questions or anything let me know.
![[Image: ssSS.gif]](http://www.flawsin.com/ssSS.gif)
This is pretty simple and works best with mysql since you can have multiple servers share a database but it can also be used with the other versions. You can have multiple servers if one cant support your player base but with other versions each must have their own databases. Anyways its pretty simple but might as well post it here if anyone wants to use it.
Everything done here is CLIENT SIDE
Go to modClientTCP.
Find
Code:
Public InGame As Boolean
Under it add
Code:
Public GAME_IP As String
Find
Code:
ServerIP = Decrypt(DBKEY, "C489347322B38A4C1924B3A662A201AE98464DCA3FA926872A8A0C92212D8919") 'localip
Change that to
Code:
ServerIP = GAME_IP
Now go to frmLogin
Make X Option Buttons (where X is the number of servers you want to have.)
Name them something easy such as ... opt1, opt2, opt3 so on.
Now make the same amount of labels. Name each whatever the servers are called and place them with the option buttons.
[You can do this with buttons or listbox or whatever you like... I chose option buttons.]
Now Find
Code:
Dim Password As String
Under it add
Code:
If opt1.Value = True Then
GAME_IP = "127.0.0.1"
Call TcpInit
End If
Add more for each server you have... if you have 2 servers you would also add
If opt2.Value = True Then
GAME_IP = "127.0.0.1"
Call TcpInit
End If
Also remember to change the IPs to the IPs of the servers you want it to connect to.
Thats pretty much it. You choose a server and when you connect it connects to that server.
You may also want to have one of the option buttons set to True when you make it so that 1 will always be checked at least.
Any questions or anything let me know.