commit 185dd0a1f224af877b2c19108faacb59fb556ea8
Author: Leszek Koltunski <leszek@koltunski.pl>
Date:   Mon Mar 6 12:51:30 2023 +0100

    Move corner orientation from SolverPyraminx to TablebasesPyraminx (we'll need it for better-looking tablebases scrambling)

diff --git a/src/main/java/org/distorted/solvers/SolverCuboid232.java b/src/main/java/org/distorted/solvers/SolverCuboid232.java
index f91d5891..0d4703f4 100644
--- a/src/main/java/org/distorted/solvers/SolverCuboid232.java
+++ b/src/main/java/org/distorted/solvers/SolverCuboid232.java
@@ -427,7 +427,7 @@ public class SolverCuboid232 extends SolverTablebase
       mSolver = ImplementedTablebasesList.createPacked(res, ObjectSignatures.CU_232);
       }
 
-    return mSolver!=null ? mSolver.solution(index) : null;
+    return mSolver!=null ? mSolver.solution(index,null) : null;
     }
 }  
 
diff --git a/src/main/java/org/distorted/solvers/SolverIvyCube.java b/src/main/java/org/distorted/solvers/SolverIvyCube.java
index f42b54ce..961c399d 100644
--- a/src/main/java/org/distorted/solvers/SolverIvyCube.java
+++ b/src/main/java/org/distorted/solvers/SolverIvyCube.java
@@ -247,7 +247,7 @@ public class SolverIvyCube extends SolverTablebase
       mSolver = ImplementedTablebasesList.createPacked(res, ObjectSignatures.IVY_2);
       }
 
-    return mSolver!=null ? mSolver.solution(index) : null;
+    return mSolver!=null ? mSolver.solution(index,null) : null;
     }
 }  
 
diff --git a/src/main/java/org/distorted/solvers/SolverPyraminx.java b/src/main/java/org/distorted/solvers/SolverPyraminx.java
index 1c65c120..1b2c9358 100644
--- a/src/main/java/org/distorted/solvers/SolverPyraminx.java
+++ b/src/main/java/org/distorted/solvers/SolverPyraminx.java
@@ -515,40 +515,6 @@ public class SolverPyraminx extends SolverTablebase
     return null;
     }
 
-///////////////////////////////////////////////////////////////////////////////////////////////////
-
-  private void addMove(int[] move, int axis, int twist)
-    {
-    move[0] = axis;
-    move[1] = (1<<2);
-    move[2] = (twist==2 ? -1:twist);
-    }
-
-///////////////////////////////////////////////////////////////////////////////////////////////////
-
-  private int[][] constructTipMoves(int[] twist)
-    {
-    int total = 0;
-
-    for(int i=0; i<4; i++)
-      if( twist[i]!=0 ) total++;
-
-    if( total>0 )
-      {
-      int[][] moves = new int[total][3];
-
-      int index=0;
-      if( twist[0]!=0 ) { addMove(moves[index],1,twist[0]); index++; }
-      if( twist[1]!=0 ) { addMove(moves[index],0,twist[1]); index++; }
-      if( twist[2]!=0 ) { addMove(moves[index],3,twist[2]); index++; }
-      if( twist[3]!=0 ) { addMove(moves[index],2,twist[3]);          }
-
-      return moves;
-      }
-
-    return null;
-    }
-
 ///////////////////////////////////////////////////////////////////////////////////////////////////
 
   public int[][] solution(int index, Resources res)
@@ -558,18 +524,7 @@ public class SolverPyraminx extends SolverTablebase
       mSolver = ImplementedTablebasesList.createPacked(res, ObjectSignatures.PYRA_3);
       }
 
-    int[][] moves1 = mSolver!=null ? mSolver.solution(index) : null;
-    int[][] moves2 = constructTipMoves(mCornerTwist);
-
-    int len1 = (moves1==null ? 0:moves1.length);
-    int len2 = (moves2==null ? 0:moves2.length);
-
-    int[][] moves = new int[len1+len2][3];
-
-    if( len1>0 ) System.arraycopy(moves1, 0, moves,    0, len1);
-    if( len2>0 ) System.arraycopy(moves2, 0, moves, len1, len2);
-
-    return moves;
+    return mSolver!=null ? mSolver.solution(index,mCornerTwist) : null;
     }
 }  
 
diff --git a/src/main/java/org/distorted/solvers/SolverPyraminxDuo.java b/src/main/java/org/distorted/solvers/SolverPyraminxDuo.java
index 9e655117..1276ef1d 100644
--- a/src/main/java/org/distorted/solvers/SolverPyraminxDuo.java
+++ b/src/main/java/org/distorted/solvers/SolverPyraminxDuo.java
@@ -292,7 +292,7 @@ public class SolverPyraminxDuo extends SolverTablebase
       mSolver = ImplementedTablebasesList.createPacked(res, ObjectSignatures.PDUO_2);
       }
 
-    return mSolver!=null ? mSolver.solution(index) : null;
+    return mSolver!=null ? mSolver.solution(index,null) : null;
     }
 }  
 
diff --git a/src/main/java/org/distorted/solvers/SolverSkewbDiamond.java b/src/main/java/org/distorted/solvers/SolverSkewbDiamond.java
index 72a73ddf..ad4b0bb0 100644
--- a/src/main/java/org/distorted/solvers/SolverSkewbDiamond.java
+++ b/src/main/java/org/distorted/solvers/SolverSkewbDiamond.java
@@ -493,7 +493,7 @@ android.util.Log.e("D", "corn twist: "+corners_twist[0]+" "+corners_twist[1]+" "
       mSolver = ImplementedTablebasesList.createPacked(res, ObjectSignatures.DIAM_2);
       }
 
-    return mSolver!=null ? mSolver.solution(index) : null;
+    return mSolver!=null ? mSolver.solution(index,null) : null;
     }
 }  
 
