aboutsummaryrefslogtreecommitdiff
path: root/include/graphics.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'include/graphics.hpp')
-rw-r--r--include/graphics.hpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/include/graphics.hpp b/include/graphics.hpp
index ebb596b..6951fc0 100644
--- a/include/graphics.hpp
+++ b/include/graphics.hpp
@@ -11,11 +11,12 @@
#include <SDL2/SDL_ttf.h>
#include "game.hpp"
#include "2048.hpp"
+#include "ai.hpp"
class Graphics
{
public:
- Graphics(Game *g, std::string t, int w, int h);
+ Graphics(Game *g, std::string t, int w, int h, AI *ai = NULL);
~Graphics();
void update();
@@ -34,6 +35,10 @@ class Graphics
SDL_Texture *scoreText;
std::vector< std::pair<int, SDL_Texture*> > numberTexBuf;
std::map< int, SDL_Color > palette;
+ AI *ai;
+ Uint32 aiTimeStep;
+ Uint32 aiNextTime;
+
void drawGame();
void drawCell(int x, int y);