-
+#ifdef BUILD_GRAPHICS
Piece::TextureManager Piece::textures;
-
-
-
Piece::TextureManager::~TextureManager()
{
Array<Texture*>::Iterator i(*this);
}
return *(Array<Texture*>::operator[](at));
}
-
+#endif //BUILD_GRAPHICS
/**
* Gets the type of a piece, based off a character token
}
-
+#ifdef BUILD_GRAPHICS
/**
* Draw the board state to graphics
* @param reveal - Pieces matching this colour will be revealed. If Piece::BOTH, all pieces will be revealed
*/
void Board::Draw(const Piece::Colour & reveal, bool showRevealed)
{
+
if (!Graphics::Initialised())
{
fprintf(stderr, "ERROR - Board::Draw called whilst graphics disabled!!!\n");
Graphics::UpdateScreen();
}
+#endif //BUILD_GRAPHICS
/**
* Adds a piece to the board