private APIMsgConclusion handleMakeClientMove(JSONObject jObj) { Connect4Command command = new Connect4Command(); command.move = (int)jObj.GetField(Consts.Fields.move).i; return(APIGameLogic.makeClientMove(command)); }
private APIMsgConclusion handleSimulateMove(JSONObject jObj) { Connect4Command command = parseAPICommand(jObj, Consts.Actions.simMove); command.player = (int)jObj.GetField(Consts.Fields.player).i; command.getPossibleMoves = jObj.HasField(Consts.Fields.possibleMoves); command.move = (int)jObj.GetField(Consts.Fields.move).i; return(APIGameLogic.simulateMove(command)); }
private APIMsgConclusion handleEvalBoard(JSONObject jObj) { Connect4Command command = parseAPICommand(jObj, Consts.Actions.evalBoard); return(APIGameLogic.evaluateBoard(command)); }
private APIMsgConclusion handleGetPossibleMoves(JSONObject jObj) { Connect4Command command = parseAPICommand(jObj, Consts.Actions.simMove); return(APIGameLogic.aquirePossibleMoves(command)); }