slight update to structure. going into subbranch now
This commit is contained in:
parent
665ad108d4
commit
e947a8b24f
@ -76,7 +76,7 @@ bool next(vector<LogEntry>& log, vector<PuzzlePiece*>& p_Box, Puzzle& puzzleMat)
|
||||
}
|
||||
}
|
||||
//cout << "next" << endl;
|
||||
if(log.back().myCoor.n>36)
|
||||
if(log.back().myCoor.n>8)
|
||||
{
|
||||
cout << "m: " << log.back().myCoor.m << " n: " << log.back().myCoor.n << endl;
|
||||
status(log,p_Box,puzzleMat);
|
||||
@ -141,6 +141,7 @@ void abstractionlayer1solver(vector<LogEntry>& log, vector<PuzzlePiece*>& p_Box,
|
||||
//remove all that do not fit according to abstraction layer 0
|
||||
for(int i=0;i<(log.back().PieceCollector.size());)
|
||||
{
|
||||
//TODO: change checker from checking every box piece to only checking the simplifyed version ob the box with abstraction layer one
|
||||
if(!(puzzleMat.testRotationPiece(log.back().myCoor.m, log.back().myCoor.n, *(log.back().PieceCollector[i]))))
|
||||
{
|
||||
log.back().PieceCollector.erase(log.back().PieceCollector.begin()+i);
|
||||
|
@ -156,6 +156,14 @@ private:
|
||||
static int randomed;
|
||||
};
|
||||
|
||||
class BoxClassify
|
||||
{
|
||||
vector<PuzzlePiece*> p_Box;
|
||||
vector<vector<PuzzlePiece*>> ab1class;
|
||||
|
||||
|
||||
};
|
||||
|
||||
int LogEntry::randomed(0);
|
||||
unsigned int PuzzlePiece::idcount(0);
|
||||
|
||||
|
@ -9,7 +9,7 @@
|
||||
int main()
|
||||
{
|
||||
|
||||
int cols=40, rows=40;
|
||||
int cols=10, rows=10;
|
||||
//some basic part stuff
|
||||
vector<Part> myFirstPuzzle;
|
||||
Part myFirstPart;
|
||||
@ -23,12 +23,13 @@ int main()
|
||||
|
||||
//undo everything and make this puzzle fucking imba hard!!!
|
||||
//need 40x40 for this, so check your status
|
||||
makehard4040puzzle(myFirstBox);
|
||||
//makehard4040puzzle(myFirstBox);
|
||||
|
||||
//some advanced solver stuff
|
||||
vector<LogEntry> log;
|
||||
vector<PuzzlePiece*> p_myFirstBox;
|
||||
|
||||
//BoxClassify myFirstBox();
|
||||
|
||||
cout << "original puzzle: " << endl;
|
||||
myRandomBox.printPuzzle();
|
||||
@ -37,6 +38,8 @@ int main()
|
||||
p_myFirstBox.push_back(&myFirstBox[i]);
|
||||
Puzzle puzzleMat(cols, rows);
|
||||
|
||||
//vector<vector<PuzzlePiece*>> ab1class = abstractionLayer1classify(log, p_myFirstBox,puzzleMat);
|
||||
|
||||
while(next(log, p_myFirstBox,puzzleMat));
|
||||
|
||||
puzzleMat.printPuzzle();
|
||||
|
Loading…
Reference in New Issue
Block a user