• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Checkers game question

 
Ranch Hand
Posts: 48
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,
I am using to java. I want to implement Checkers game in Java. The idea of the game is that any user can play game with any user who is currently "free". Means say A is playing with B then A and B are not considered to be free but if C is free and D connects. Then C and D both start playing. This way pair of 2 players is made automatically. I don't know how to implement this concept. Can anybody explain it to me in little detail of how to implement this in java?This game is network based means played over internet. 1 year back i implemented checkers but that can only be played by 2 players at a time. now i want to extend it and allow anybody to play the game. My only confusion is how to maintain this kind of queue. Any help would be appreciated.

One approach is to maintain queue and use ip addresses and let the 1st person connect to 2nd, but in that case, if the person is connecting to router it can be a problem. Say suppose 5 persons connect to same router and then each of them request for game. Then how can we know which data to send to which.
Will i have to use web service? and maintain session?or what? I don't have any idea. If anybody could explain me i would be very grateful.
 
Sheriff
Posts: 22783
131
Eclipse IDE Spring VI Editor Chrome Java Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The main issue at the moment is not Swing or user interface related. Moving to Java in General.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic