What to use to network a simple Battleship game?

C

C-man

Basically I want to create a battleship game that can be played by having
two clients connect to it. I was wonder what the best networking principal
would be. Basically I suppose I would have to pass an int value or something
representing the x,y coordinates of each shot. Should I use some type of
Socket programming or RMI or what else should be used|?

Thanks
 
K

Kevin Henry

C-man said:
Basically I want to create a battleship game that can be played by having
two clients connect to it.

sounds good to me
I was wonder what the best networking principal
would be. Basically I suppose I would have to pass an int value or something
representing the x,y coordinates of each shot. Should I use some type of
Socket programming

socket programming is pretty straight forward.

RMI would work, yet it is somewhat of overkill for such a simple program
(unless you are actually doing more than just a Battle ship game)
or what else should be used|?

JMX or Jini (both more complicated than Sockets, yet more robust too.) are
both nice front ends to RMI (although you don't need to use RMI with Jini)
That's all I've really ever used

You're Welcome

Kevin
 
M

Martin

C-man said:
Basically I want to create a battleship game that can be played by having
two clients connect to it. I was wonder what the best networking principal
would be. Basically I suppose I would have to pass an int value or something
representing the x,y coordinates of each shot. Should I use some type of
Socket programming or RMI or what else should be used|?

Thanks

Unless this is some kind of homework, you could use a toolkit like
SecurePlay --> www.secureplay.com, which has an open source license. I
haven't tried SecurePlay myself, but it sounds promising.

But if you want to (or have to) develop from scratch, I would suggest
using TCP-communication with sockets. IMO things like RMI bring too
much overhead for your needs.

Martin
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,015
Latest member
AmbrosePal

Latest Threads

Top