Author Topic: Connecting a client to another server?  (Read 3422 times)

But then if someone uses the password, they can screw everything up and connect
And kick them out if they shouldn't be there and then act like they never joined?
Besides if they take a peek at the client code, they could join the servers if they were hidden anyways.

As Destiny said in his first post, this crashes. That's because he probably forgot to make the client leave the server first before entering the other one.
The only way to force a client to disconnect is to delete it. But once you do that, you can't call the connect function on it.
stopid nub

maybe if you sent the client a command that would schedule a connect then kick them...

That would then be two connections, then it would disconnect the "freshest" one, but it would still crash.

An external non Blockland server for storing user information. PHP connected to MySQL, or something else?
Not necessarily, one Blockland server can directly talk to another Blockland server on an as-needed basis thus completely eliminating the un-necessary load associated with constantly accessing a database to store data and then overwrite data before it is even used.

It is possible and rather easy to implement as-well.

Here's the gist of it:
BL Server A With Your Data:
tcpObject::listen()

tcpObject::onConnectRequest( ,  , %sock)
   new tcpObject( , %sock)

BL Server B Accessing Your Other Server A:
tcpObject::connect()

Or you can just make your own system for authentication for getting into the server... so the servers would show up on the list but when someone tried to join it just told them there current location was somewhere else. Whipped up a quick map about how the servers could work in relativity to the zones,

(these are actually plans for a project of mine)




The purple areas are the parts that the servers cover, with the purple one being the most powerful, and blue and maroon be on slower computers.

(purple would have to be the fasted because it contains the main city, a zone, and the PVP area.)

There could be things like, inns and when a player leaves the game, (like, away from the whole thing) it checks which inn they are closest too and sets their location there, or it actually sets their location to where they are. It would be ideal to have the code that allows access to the servers to be serverside, so that people cannot hack into the servers with the client code they DLed.
« Last Edit: November 14, 2009, 12:39:26 PM by Zenthos »

Authenticate with the database server that data for their Bl_id indicates that their location is on that server, and if it's not then disconnect them.

On a side note
Here's the gist of it:
-win here-
I love you so very much right now. No homo.
« Last Edit: November 14, 2009, 02:42:58 PM by M »

The data would be like, "<server> X Y Z"

and it would send them to that location when they connected to the main server.

How to you host multiple servers on the same IP anyway? I've seen one person hosting two servers before.

Would leveling up be possible by makign a player called RPG player and making health, this

Code: [Select]
   maxDamage = %RPHeath;

I already have a mod for health and damage stats...

I already have a mod for health and damage stats...
Does it use the variable like how I did it? I wouldn't see any other way for health.

well, it uses VCE variables, but I'd also have to figure out a way to transfer those.

Ok, I have gotten to the point where I would like to know if this works, so I'm bumping. Could I get a little explanation of how to use tcpObjects? Actually, right now just how to connect clients to other servers, I saw a function called gameConnection::ConnectArranged();, which I thought may be what we're looking for.

bump.
« Last Edit: November 26, 2009, 01:55:09 AM by Zenthos »

well, it uses VCE variables, but I'd also have to figure out a way to transfer those.
I've never USED it, but perhaps "vCE_SaveVariable" and "VCE_LoadVariable"? They save to notepads.. .

I've never USED it, but perhaps "vCE_SaveVariable" and "VCE_LoadVariable"? They save to notepads.. .

Lolwut? They save to notepad?

haha, but I'm not using VCE anymore, or even events really for this system, I just wanna know how to connect someone to another server.