| 247 * @param move the move to apply |
247 * @param move the move to apply |
| 248 */ |
248 */ |
| 249 void apply_move(GameState *gamestate, Move *move); |
249 void apply_move(GameState *gamestate, Move *move); |
| 250 |
250 |
| 251 /** |
251 /** |
| |
252 * Copies the state of the game at the specified move number. |
| |
253 * |
| |
254 * This function is helpful to generate a game state for reviewing past moves. |
| |
255 * |
| |
256 * @param gamestate the current game state |
| |
257 * @param move_number the half-move that would now be played |
| |
258 * @param replay the struct to populate with the state at the specified move |
| |
259 */ |
| |
260 void gamestate_at_move(GameState *gamestate, |
| |
261 unsigned move_number, GameState *replay); |
| |
262 |
| |
263 /** |
| 252 * Returns the remaining time on the clock for the specified |
264 * Returns the remaining time on the clock for the specified |
| 253 * half-move number. |
265 * half-move number. |
| 254 * |
266 * |
| 255 * @param gameinfo the information about the game |
267 * @param gameinfo the information about the game |
| 256 * @param gamestate the current game state |
268 * @param gamestate the current game state |