code now functional

This commit is contained in:
Raphael Maenle
2018-01-07 20:08:50 +01:00
parent fc9743a77a
commit c78518b1e9
8 changed files with 127 additions and 167 deletions

View File

@ -14,7 +14,7 @@ class LayerContainer;
class Part
{
public:
Part() : m_partID(0), m_numOfRotations(0)
Part() : m_partID(0), m_numOfRotations(0), set(false)
{}
~Part() = default;
@ -40,8 +40,8 @@ public:
void print(){m_a1.print();}
bool set;
AbstractionLayer_1_Properties m_a1;
DestructionPower_Properties m_destruction;
private:
int32_t m_partID;
uint8_t m_numOfRotations;

View File

@ -39,13 +39,13 @@ class Puzzle
{
public:
Puzzle(unsigned int newcols,unsigned int newrows):rows(newrows),cols(newcols) {}
Puzzle(unsigned int newcols,unsigned int newrows):cols(newcols),rows(newrows) {}
bool PreProcessing()
{
createBox(); createp_box();
dp.PreProcessing({rows,cols}, nullptr);
a1.PreProcessing({rows,cols}, &p_myBox);
dp.PreProcessing({cols,rows}, nullptr);
a1.PreProcessing({cols,rows}, &p_myBox);
return true;
}
@ -55,6 +55,7 @@ public:
AbstractionLayer_1 a1;
void removeConstrains(coor removeCoordinates);
void setConstraints(coor setConstraints, Part *constraintPiece);
void printPuzzle();
void printBox();
@ -74,8 +75,8 @@ public:
private:
unsigned int rows;
unsigned int cols;
unsigned int rows;
};
bool next(vector<LogEntry>& log,Puzzle& puzzleMat);