summaryrefslogtreecommitdiff
path: root/src/testsup.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/testsup.c')
-rw-r--r--src/testsup.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/testsup.c b/src/testsup.c
index 852b6d9..0cbc9a4 100644
--- a/src/testsup.c
+++ b/src/testsup.c
@@ -118,6 +118,7 @@ GenerateRandomLegalPosition(POSITION *pos)
pos->uNonPawnCount[WHITE][0] = 1;
pos->uNonPawnMaterial[WHITE] = VALUE_KING;
pos->bbOccupied |= COOR_TO_BB(c);
+ pos->bbOccupiedSide[WHITE] |= COOR_TO_BB(c);
do
{
@@ -132,6 +133,7 @@ GenerateRandomLegalPosition(POSITION *pos)
pos->uNonPawnCount[BLACK][0] = 1;
pos->uNonPawnMaterial[BLACK] = VALUE_KING;
pos->bbOccupied |= COOR_TO_BB(c1);
+ pos->bbOccupiedSide[BLACK] |= COOR_TO_BB(c1);
//
// Place the rest of the armies
@@ -183,6 +185,7 @@ GenerateRandomLegalPosition(POSITION *pos)
pos->uPawnMaterial[uColor] += VALUE_PAWN;
pos->bbPawns[uColor] |= COOR_TO_BB(c);
pos->bbOccupied |= COOR_TO_BB(c);
+ pos->bbOccupiedSide[uColor] |= COOR_TO_BB(c);
break;
}
else if (!IS_KING(p) &&
@@ -197,6 +200,7 @@ GenerateRandomLegalPosition(POSITION *pos)
pos->uNonPawnMaterial[uColor] += PIECE_VALUE(p);
pos->bbPieces[uColor][PIECE_TYPE(p)] |= COOR_TO_BB(c);
pos->bbOccupied |= COOR_TO_BB(c);
+ pos->bbOccupiedSide[uColor] |= COOR_TO_BB(c);
if (IS_BISHOP(p))
{
if (IS_WHITE_SQUARE_COOR(c))