Sign in to follow this  
theironpaperclip

Question about server location relitive to clients in online games and ip adresses

Recommended Posts

Curently I am in the process of building a simple online game, since I am still in school, it is likly going to be anouther 4 or 5 years until I am finnished. Since this is just a one man project at the moment, I don't exspect to purchase several servers arround the world rather I just want to use my home computers. How much does the server's location affect lag in a game, is it a large issue or does the population affect the lag more? If the lag is noticible, could I implant a small amount of the physics code into the client? Also I was wondering how safe it would be to give the client's ip adress to anouther in the area. How much do I need to wory about DOS atacks on them? If I distrubute my client over the Internet, could I include a torrent like feature to download the texture files for other active clients? I figure that the textures will consume the largest portion of the file size and if they are modified, will be the easiest to corect with the least amount the damage. Summary; How much does server location affect lag on clients? Will a client 10,000 miles away exsperience consideribly more lag than one 100 miles away. Is it safe to give client's ip adresses to other clients? Could I use a torrent like system to transfer texture files between clients during install? Note; The only infomation that I want the clients to transmit between themselves is the textures and the client's appearence. Player locations and the game engine will be controled by the server so even if the player mods the client a character will still be displayed.

Share this post


Link to post
Share on other sites
Ezbez    1164
Quote:
Original post by theironpaperclip
How much does server location affect lag on clients? Will a client 10,000 miles away exsperience consideribly more lag than one 100 miles away.


Very much so. I've been playing a lot of BaboViolent 2 (made by soemone else on this forum, search for it!), and most of the servers are near me. I get good ping (<100 ms), so does my friend who also lives near them. Everyone from other continents gets really bad ping (400+ ms). It makes a big difference.

Quote:
Is it safe to give client's ip adresses to other clients?


Safe for your game, or the player? Regardless, that would almost certainly be considered rude to do; IPs can be used to find out location and sometimes a lot more. However, most games let the server know the IP address of all the players so that they can do an IP ban if needed.

Quote:
Could I use a torrent like system to transfer texture files between clients during install?


Why don't you just let the user download the whole game at once with a torrent? It would have to be pretty darn big for this too take a large enough time to make a big difference.



Quote:
Note; The only infomation that I want the clients to transmit between themselves is the textures and the client's appearence.


Sorry, but what do you mean by "client's appearance"? The player's appearance? If so, wouldn't that, well, entice people to put... erm... inappropriate models instead of their character? Surely this should be done by the server, too. Besides, shouldn't the client come with the player models?

Share this post


Link to post
Share on other sites
hplus0603    11347
World of Warcraft uses bittorrent-like client-to-client distribution, and thus gives out the IP address of other players. You can choose to opt out, but the default is to be opted in.

However, given the number of random sniffs, probes, scans and attacks any IP address gets just by being on the web, I wouldn't consider that as being particularly bad.

Share this post


Link to post
Share on other sites
Nice Coder    366
Quote:
Original post by theironpaperclip
Thank you for the reply.

What did you mean when you stated this however, I was under the impression that ips could only identify location.
"IPs can be used to find out location and sometimes a lot more."


They can be used to find your isp easily (from the host name), and by checking you can find out what services they are running, if they have a firewall, etc.

for example. adsl-065-005-251-x.sip.bgk.bellsouth.net (65.5.251.x)
Isp is bellsouth, they are american, and have adsl. With a bit more digging i find out that they are (or should be in), miami florida.

Another quick check shows that they respond to icmp ping packets. (showing that the address is valid).

I then check it with nmap to find open ports, which this comp doesn't seem to have. If they did (which quite a few computers have), you would then know quite a bit about the comp (ie. if it had port 135 open it is a windows box, if it had port 80 open then its running a web server, which you can interogate, etc).

From what i can see, they are running a firewall which is filtering all ports other then 113 (auth) and that itself is closed.

You can find quite a bit from an ip. :)

More on topic, the reason that latencies are greater as things get further away is simply that. They are further away, packets need to go through more routers before they get to you, as well as more cable.

Have a play with netstat for various domains (hosted in different countries), to see just how things change. (have a look at the changes in ping as you move further away).

Share this post


Link to post
Share on other sites
Bob Janova    769
Intercontinental delay (one way) between the US and Europe is typically 250-400ms, from my experience with online gaming. For a turn-based or slow paced game that isn't a problem, but for an action game it would be. This is unavoidable (it just takes that long for the signal to get across the sea).

Share this post


Link to post
Share on other sites
hplus0603    11347
I think the inter-continental delay is lower than that. The two-way ping time can be as low as 150 milliseconds from California to Europe (I've seen it in Planetside, for example).

The math is simple: 9 timezones (CA -> EUR) times 40000 kilometers divided by 24 timezones (world) divided by 300,000 kilometers per second equals 50 milliseconds one-way transmission delay.

Share this post


Link to post
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

Sign in to follow this