int QGtp::set_free_handicap(QList<Point> handicap_stones) { QByteArray message("set_free_handicap"); for ( int i=0; i<handicap_stones.length(); ++i ) { message.append(" ").append(encodeCoors(handicap_stones[i].x,handicap_stones[i].y)); } fflush (message); return waitResponse(); }
/* Function: Play a white stone at the given vertex. * Arguments: vertex * Fails: invalid vertex, illegal move * Returns: nothing */ int QGtp::playwhite (int x, int y) { fflush ("play white "+encodeCoors(x,y)); return waitResponse(); }
/* Function: Play a black stone at the given vertex. * Arguments: vertex * Fails: invalid vertex, illegal move * Returns: nothing */ int QGtp::playblack (int x, int y) { fflush (QByteArray("play black ")+encodeCoors(x,y)); return waitResponse(); }