Project

General

Profile

« Previous | Next » 

Revision 9224ffd2

Added by Leszek Koltunski about 4 years ago

extend the RubikObject API to make it possible to add rotations of multiple rows simultaneously (all along the same axis of course!)

View differences:

src/main/java/org/distorted/effect/scramble/ScrambleEffect.java
141 141
        mLastVector = (newVector>=mLastVector ? newVector+1 : newVector);
142 142
        }
143 143

  
144
      int row  = mRnd.nextInt(mObject.getSize());
144
      int rowBitmap  = (1<<mRnd.nextInt(mObject.getSize()));
145 145
      int angle= randomizeAngle();
146 146
      int absAngle = (angle<0 ? -angle : angle);
147 147
      long durationMillis =  absAngle*mDurationSingleTurn;
......
154 154
        android.util.Log.e("effect", "ERROR: "+mNumDoubleScramblesLeft);
155 155
        }
156 156

  
157
      mCurrentBaseEffectID = mObject.addNewRotation(mLastVector, row, angle*(360/mBasicAngle), durationMillis, this );
157
      mCurrentBaseEffectID = mObject.addNewRotation(mLastVector, rowBitmap, angle*(360/mBasicAngle), durationMillis, this );
158 158
      }
159 159
    else
160 160
      {

Also available in: Unified diff