In this final piece of the project we adapt the model component of HW5 so that it chooses the next move to be made. Your model contacts a server to obtain a game to be played. The server then periodically contacts your model component to ask for its next move, which must be supplied promptly. Because finding a good move in limited real time is a constraint, your search for moves should be multi-threaded.
{ "action" : "mymove", "teamname" : "our team", "gameinstance" : { ...}, "move" : {... }, "movesevaluated" : 1234 }
The move field looks like:
"move": { "row" : 3, "column":5, "direction": 0 }(The directions are 0 though 3 for left, right, down, and up respectively.) The movesevaluated field is an integer indicating how many moves were examined in deciding on the move being provided.
You can view a list of best scores on each game by each team (that has connected to the servers) at this page. (All your game results are recorded, but only the best result on each game for each team is shown.)
Q: How do I find a good move?
Q: What happens if I return a move that isn't legal?
A: You should expect to be disqualified.
Q: What happens if I don't respond quickly enough?
A: You should expect to be disqualified.