Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

What is the best way to design a multiplayer game syncronization for 2 to 4 players?

Posted on 2007-11-21
6
Medium Priority
?
363 Views
Last Modified: 2010-04-07
What is the best way to design a multiplayer game syncronization for 2 to 4 players?

I am develoving a 2d game, and i  need to developed the multyplayer system and i dont have idea tabout how to create the game syncronization for 2-4 players.

what is the best method to create a server-clients syncronization system?

any help with describinb the steps with only using winsockets.?
0
Comment
Question by:becoolnike
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
6 Comments
 
LVL 11

Expert Comment

by:jgordos
ID: 20361912
You don't really give any background.

Do you know how these four players will play the game?

Is it a fat client? Browser based?  Network?  Internet?

Do you know how to send and receive messages over the internet? Over the LAN?

Is it real-time?  Is it turn based?  

These things all matter.

-john
0
 

Author Comment

by:becoolnike
ID: 20365468
I have tcp and udp knowloge. i have coded app using winsocks.
it is a fat client.
it is over lan.
it is a 2d fighting game.
it is real time but all happens in the same screee.

i dont have expericence about syncronization events.


0
 

Author Comment

by:becoolnike
ID: 20365539
I was thinking a system where the server proccess all the events and physics and onlly send all the screen modications to the clients. the clients will only send the input data and recieve the screen updates but they wont procece any physics or events.

But i dont know if this is the best method.

0
 
LVL 11

Accepted Solution

by:
jgordos earned 2000 total points
ID: 20367363
that's about your only choice, really.

and, when you ask about sync, the really important part is that you have only one source of key information, such as the score, or the health of each player.

That information can be sent out periodically, on a heartbeat.

And, if you're keying the animation so it plays "right" between the two players, then you need to include a few timers... time for animation, time for the "fight clock", time since you last heard from each client... etc.

But yes, you're thinking the right way.

If you're on a lan, just use UDP .. it's faster, and if you do miss a packet for some reason, you'll just pick it up again on the next heartbeat.

-j
0
 
LVL 1

Expert Comment

by:Computer101
ID: 20658033
Forced accept.

Computer101
EE Admin
0

Featured Post

How to Use the Help Bell

Need to boost the visibility of your question for solutions? Use the Experts Exchange Help Bell to confirm priority levels and contact subject-matter experts for question attention.  Check out this how-to article for more information.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

What is RenderMan: RenderMan is a not any particular piece of software. RenderMan is an industry standard, defining set of rules that any rendering software should use, to be RenderMan-compliant. Pixar's RenderMan is a flagship implementation of …
Performance in games development is paramount: every microsecond counts to be able to do everything in less than 33ms (aiming at 16ms). C# foreach statement is one of the worst performance killers, and here I explain why.
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…
In response to a need for security and privacy, and to continue fostering an environment members can turn to for support, solutions, and education, Experts Exchange has created anonymous question capabilities. This new feature is available to our Pr…
Suggested Courses

609 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question