b. Suppose you are developing a tic-tac-toe game to be played by two users on separate computers that are interconnected through a network. Throughout a game, the players should see the same game board displayed, and should take turns to update the game board until the game is over. Choose any two of the following distributed computing communication paradigm and describe how you can make use of each in the implementation of your software. Focus your description on (i) how data is shared and communicated between the two users, and (ii) how the player sequencing is controlled (that is, how the players are controlled so that
they take turns to update the game board.)
I. In tic tac game there are several factors to consider wen it comes to sharing between the two players. First, we should establish a c connection using connection-oriented protocol (TCP) that means the data send by a player to the other player using another computer will not be lost and also if it gets lost the data can be resend by the player. Secondly, when we use TCP the sequence in which the game is played will not be lost since it will be in order.
II. In this game we need to have rules so that the players keep on playing and update the game board. First, we start capturing the moves by the player so that the game goes on. Changing the rules of the game if the opponent does not play then it may be called he/she loses and this makes the players to continue updating the game board.
Comments
Leave a comment