Jump to content
  • Advertisement
Sign in to follow this  
brechtjah

Online gaming

This topic is 3761 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi I was just wondering, like all types of online games, do they get your x,y,z position then send it to a database update it so that other computers can download that information and view the other player on their computer? How does it work? Like if I'm moving towards you in an online game does it store my position every somewhat miliseconds and your computer downloads that information and renders me?

Share this post


Link to post
Share on other sites
Advertisement
That really depends entirely on the game. Some games, like FPSs, need a high frequency update of positions. Other games, like RPGs, are primarily statistics-based and you actual visible position is updated less frequently. Client side predictions and the like also factor in to smooth out the movement.

In client/server games the client generally only sends the input from the player (not the new positions) because the client is exploitable and should not be trusted. The server will generally process the input, update the positions, and send that position back to the client so the client knows where to draw everything.

You have the basic gist of things more or less on target, but the details vary widely and are highly sensitive to the nature of the game.

Share this post


Link to post
Share on other sites
The biggest problem with online games is coping with lag. It takes time for information to be sent from one computer to another.

There are various ways to combat this, but it's a very big field, and a big problem.

To try to answer your questions simplistically, there are two main methods of communication. Client-server or peer-to-peer. Which works best will depend on a lot of factors, such as data size, number of players, server architecture and so on.

Share this post


Link to post
Share on other sites
Not the only way or the best way. It all depends on your game.

e.g. a simple two player version of pong would certainly not need a database, wheres a WOW wannabe would almost certainly use one.

Share this post


Link to post
Share on other sites
Quote:
Original post by OldProgie2
Not the only way or the best way. It all depends on your game.

e.g. a simple two player version of pong would certainly not need a database, wheres a WOW wannabe would almost certainly use one.


It's really a online game with much players so I'll have to go for the database, ok thanks for all the replies!

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!