From a1289dec3dcec278f9cf6d18a001b3146b11b7b2 Mon Sep 17 00:00:00 2001 From: Loic Guegan Date: Thu, 19 Jan 2023 16:33:44 +0100 Subject: Integrate CMI --- src/game_tab/Game.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/game_tab/Game.cpp') diff --git a/src/game_tab/Game.cpp b/src/game_tab/Game.cpp index c1aa605..ac1f428 100644 --- a/src/game_tab/Game.cpp +++ b/src/game_tab/Game.cpp @@ -53,7 +53,7 @@ bool Game::IsBlackToPlay() { if (current == nullptr) { return (false); } - return (!current->IsBlack); + return (!current->IsBlack()); } void Game::DeleteTag(std::string tagname) { tags.erase(tagname); } @@ -65,7 +65,7 @@ void Game::DeleteMove(HalfMove *m) { delete m; } else { if (m != nullptr) { - current = m->GetParent(); + current = static_cast(m->GetParent()); if (current != nullptr) { current->RemoveChild(m); } @@ -153,7 +153,7 @@ void Game::GetOpening(std::string &name,std::string &eco){ void Game::Previous() { if (current != nullptr) { - current = current->GetParent(); + current = static_cast(current->GetParent()); } } @@ -167,7 +167,7 @@ std::vector Game::ListTags() { void Game::Next() { if (current != nullptr) { - HalfMove *m = current->GetMainline(); + HalfMove *m = static_cast(current->GetMainline()); if (m != nullptr) { current = m; } @@ -178,7 +178,7 @@ void Game::Next() { HalfMove *Game::GetNextMove(){ if(current!=nullptr) - return current->GetMainline(); + return static_cast(current->GetMainline()); return moves; } -- cgit v1.2.3