Jump to content
  • Advertisement
Sign in to follow this  
pulsar

Two Player Pong game implemented in network,but too slow.

This topic is 5085 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, First of all thanks to everyone for there right suggestions. I have implemented Pong game in network,Which can be played by two player in the network.But it is too slow to be played, rather we can say it can'nt be played.But it(ball and the two paddles) runs smoothly on the same computer,in which one window is server and the other is client.Data transfer is okay .I'm using thread to accept connection and the data. I'm not understanding why it's runs smoothly on the same computer. But creating problem when run from other. It will be better if you kindly suggest a way to be out from this. If possible just tell me how should I tranfer paddle(y position )and ball(xpos and ypos). And Tell me how the multiple send and receive works.

Share this post


Link to post
Share on other sites
Advertisement
If you are using TCP for your networking, you might want to look into the TCP_NODELAY socket option, to turn off Nagle's algorithm. (How's that for a bunch of words you can Google? :-)

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!