COMP90015-ScableGame COMP90015-Assignment2-ScrableGame
This distributed game used multithread and socket programming, and it achieved good performance in concurrency and robustness
to run this project
two commond lines:
- java -jar GameServer.jar 1234 (1234 is the port number)
- java -jar Client.jar localhost 1234 (localhost could be specified to any IP address, and 1234 is the port number)
hint: you should run server first, and you can run several clients to play this game
sequence diagram
functions
after you logs in, the server will record the logging information:
let's have three players, and two of them play this game:
the correctness of word is determined by all players:
if we choose agree:
then another player want to watch this game:
the watcher cannot play this game:
after one player logs out, the game is over, and will declare the winner:
all game information is stored in server's log system: