Utility functions for GoGame. More...
Functions | |
bool | GotoBeforeMove (GoGame *game, int moveNumber) |
Goto last node in main variation before move number. |
Utility functions for GoGame.
bool GoGameUtil::GotoBeforeMove | ( | GoGame * | game, | |
int | moveNumber | |||
) |
Goto last node in main variation before move number.
This function can be used for implementing the loadsgf GTP command.
game | (current node must be root) | |
moveNumber | move number (-1 means goto last node in main variation) |
Definition at line 454 of file GoGame.cpp.
References GoGame::CanGoInDirection(), GoGame::CurrentMoveNumber(), GoGame::CurrentNode(), GoGame::GoInDirection(), SgNode::HasProp(), SgNode::LeftMostSon(), SgNode::NEXT, GoGame::Root(), SG_ASSERT, and SG_PROP_MOVE.
Referenced by GoGtpEngine::CmdLoadSgf().