Project

General

Profile

« Previous | Next » 

Revision ebb64a1d

Added by Leszek Koltunski over 4 years ago

RubikCube: add skeleton WinEffects (for now only one effect - 'Spin' copied from Solve)

View differences:

src/main/java/org/distorted/magic/RubikCube.java
53 53
    private static final Static3D VectY = new Static3D(0,1,0);
54 54
    private static final Static3D VectZ = new Static3D(0,0,1);
55 55

  
56
    private static final float SQ2 = 0.5f*((float)Math.sqrt(2));
57
    private static final float[] LEGAL = { 0.0f , 0.5f , -0.5f , 1.0f , -1.0f , SQ2 , -SQ2 };
58

  
59 56
    public static final int VECTX = 0;  //
60 57
    public static final int VECTY = 1;  // don't change this
61 58
    public static final int VECTZ = 2;  //
......
548 545
// We also have to remember that the group of unit quaternions is a double-cover of rotations
549 546
// in 3D ( q represents the same rotation as -q ) - so invert if needed.
550 547

  
548
    private static final float SQ2 = 0.5f*((float)Math.sqrt(2));
549
    private static final float[] LEGAL = { 0.0f , 0.5f , -0.5f , 1.0f , -1.0f , SQ2 , -SQ2 };
550

  
551 551
    private void normalizeScrambleQuat(int i, int j, int k)
552 552
      {
553 553
      Static4D quat = mQuatScramble[i][j][k];

Also available in: Unified diff