P2P Online Tic Tac Toe

Summary

  • This project exercises a peer-to-peer communicating program using non-blocking accept (), multiple threads, (specifically saying, the main and the slave threads), and JSCH (Java secure shell).

  • This program uses Java, JFrame, and JSCH Involves two users in the same tic-tac-toe game or allows a single user to play with an automated remote user using Java Socket connections. JFrame is used for the GUI part

  • Limitations:When two users are playing from two different machines using the TCP connection, if any one of the players ends the game in between, then an End of file exception comes up.When the socket breaks down in between the game gets stuck with both players not able to proceed.

  • Future Improvements:We can make the game more competitive by adding features like a timer which can be done using Java Swing.We can use web-based APIs and integrate them with the code to create a live chatbox within the game and can create a lobby where multiple players can play and interact with each other.