git repos / blockattack-game

commit ca31a27a

sago007 · 2016-04-16 21:29
ca31a27a71da3eb2c1a111ed9e2cb2849d14d6d3 patch · browse files
parent daa660abf74f9a4993f475a0ecf6c16e769f9c71

Initialized two member variables

Changed files

M source/code/BlockGame.hpp before
diff --git a/source/code/BlockGame.hpp b/source/code/BlockGame.hpp index 990f724..b4778e4 100644 --- a/source/code/BlockGame.hpp +++ b/source/code/BlockGame.hpp
@@ -256,7 +256,7 @@ private:
///////////////////////////////////////////////////////////////////////////
//First the helpet functions:
int nrOfType(int line, int type);
- int AIcolorToClear;
+ int AIcolorToClear = 0;
//See if a combo can be made in this line
int horiInLine(int line);
bool horiClearPossible();
@@ -281,7 +281,7 @@ private:
int closestTo(int line, int type, int place);
//The AI will try to clear blocks vertically
void AI_ClearVertical();
- bool firstLineCreated;
+ bool firstLineCreated = 0;
void AI_Move();
//////////////////////////////////////////////////////////////////
///////////////////////////// AI ends here! //////////////////////