Skip to content
Snippets Groups Projects
Commit 582e055f authored by Gaste Adrien's avatar Gaste Adrien
Browse files
parents 6998c1ca def0b7f0
No related branches found
No related tags found
No related merge requests found
...@@ -173,9 +173,22 @@ namespace game ...@@ -173,9 +173,22 @@ namespace game
string morpion::to_string() const string morpion::to_string() const
{ {
//for (int i = 0 string result = "";
//TODO PAR ROMAIN for (int row = 2; row >= 0; row--)
return ""; {
result += "|"
for (int col = 2; col >= 0; col--)
{
if(((state.cross_bitboard >> 3*row) >> col) & 1)
result += player_to_string(CROSS)+"|";
else if (((state.circle_bitboard >> 3*row) >> col) & 1)
result += player_to_string(CIRCLE)+"|";
else
result += " |";
}
result += "\n-------\n";
}
return result;
} }
void morpion::playout(mt19937& engine, int max_depth) void morpion::playout(mt19937& engine, int max_depth)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment