void World::GetBlocks(int x, int z) { mutexes[x][z].lock(); if (!IsGenerated(x, z)) GenBlocks(x, z); mutexes[x][z].unlock(); }
void GoRegionBoard::GenBlocksRegions() { if (UpToDate()) return; Clear(); GenBlocks(); for (SgBWIterator it; it; ++it) { SgBlackWhite color(*it); for (SgConnCompIterator it(AllPoints() - All(color), Board().Size()); it; ++it) GenRegion(*it, color); } FindBlocksWithEye(); m_code = Board().GetHashCode(); m_invalid = false; if (HEAVYCHECK) CheckConsistency(); }