How to develop multiplayer web based board game in java?

I want develop a multiplayer web based board game in Java (like chess possibly using applet) that can be played in browser. I have no problem with the logic of game. My only concern is how to make the game multiplyer(or multibrowser support). For example, suppose the game is hosted in any web server and two player is playing the game using their own browser. Now, any move given by player1 should be visible to player2 and vice-versa. How to achieve this type of functionality in Java?
Any help or suggestion is welcome.

I think you should first look at server programming.

There are 2 types or methods for sending data: TCP and UDP. TCP ensures that every single bit of data you send is delivered to the other side. However if you get dc just for 1 moment, you will need to reconnect. UDP doesn’t do that. You can disconnect, but the data would still be sent to you, even if you are not receiving it.

You should just look at UDP programming, because it is best suited for games.

Take a look at this tutorial. It has some stuff with UDP. There are a lot more tutorials on the web :stuck_out_tongue:

Thanks for your suggestion.
Can it be possible using applet?

It doesn’t matter what you’re using… Applet is just a way of drawing stuff. (In some sense)

Ummm… There was a huge legacy page on it.

UDP vs. TCP

It is a very long read but the verdict was TCP was better than UDP. Look at that link for all you practically need to know regarding the subject. :slight_smile:

I really don’t think either one is better. Sure, UDP has its faults, but so does TCP. If I were more advanced in networking, I’d use both in tandem. Of course, that introduces many issues.