Revision bdbbb4c5
Added by Leszek Koltunski over 2 years ago
src/main/java/org/distorted/objects/TwistyBandagedAbstract.java | ||
---|---|---|
19 | 19 |
|
20 | 20 |
package org.distorted.objects; |
21 | 21 |
|
22 |
import static org.distorted.objects.Movement.TYPE_NOT_SPLIT;
|
|
22 |
import static org.distorted.objectlb.Movement.TYPE_NOT_SPLIT;
|
|
23 | 23 |
|
24 | 24 |
import android.content.res.Resources; |
25 | 25 |
|
26 |
import org.distorted.helpers.ObjectShape;
|
|
27 |
import org.distorted.helpers.ObjectSticker;
|
|
28 |
import org.distorted.helpers.ScrambleState;
|
|
26 |
import org.distorted.objectlb.ObjectShape;
|
|
27 |
import org.distorted.objectlb.ObjectSticker;
|
|
28 |
import org.distorted.objectlb.ScrambleState;
|
|
29 | 29 |
import org.distorted.library.main.DistortedEffects; |
30 | 30 |
import org.distorted.library.main.DistortedTexture; |
31 | 31 |
import org.distorted.library.mesh.MeshSquare; |
32 | 32 |
import org.distorted.library.type.Static3D; |
33 | 33 |
import org.distorted.library.type.Static4D; |
34 |
import org.distorted.objectlb.Movement; |
|
35 |
import org.distorted.objectlb.Movement6; |
|
36 |
import org.distorted.objectlb.ObjectList; |
|
37 |
import org.distorted.objectlb.Twisty6; |
|
34 | 38 |
|
35 | 39 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
36 | 40 |
|
... | ... | |
123 | 127 |
|
124 | 128 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
125 | 129 |
|
126 |
int[] getSolvedQuats(int cubit, int numLayers) |
|
130 |
protected int[] getSolvedQuats(int cubit, int numLayers)
|
|
127 | 131 |
{ |
128 | 132 |
if( mQuats==null ) initializeQuats(); |
129 | 133 |
int status = retCubitSolvedStatus(cubit,numLayers); |
... | ... | |
156 | 160 |
|
157 | 161 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
158 | 162 |
|
159 |
ObjectShape getObjectShape(int cubit, int numLayers) |
|
163 |
protected ObjectShape getObjectShape(int cubit, int numLayers)
|
|
160 | 164 |
{ |
161 | 165 |
int variant = getCubitVariant(cubit,numLayers); |
162 | 166 |
|
... | ... | |
220 | 224 |
|
221 | 225 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
222 | 226 |
|
223 |
Static4D getQuat(int cubit, int numLayers) |
|
227 |
protected Static4D getQuat(int cubit, int numLayers)
|
|
224 | 228 |
{ |
225 | 229 |
if( mInitQuats ==null ) |
226 | 230 |
{ |
... | ... | |
240 | 244 |
|
241 | 245 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
242 | 246 |
|
243 |
int getNumCubitVariants(int numLayers) |
|
247 |
protected int getNumCubitVariants(int numLayers)
|
|
244 | 248 |
{ |
245 | 249 |
return mDimensions.length; |
246 | 250 |
} |
247 | 251 |
|
248 | 252 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
249 | 253 |
|
250 |
int getCubitVariant(int cubit, int numLayers) |
|
254 |
protected int getCubitVariant(int cubit, int numLayers)
|
|
251 | 255 |
{ |
252 | 256 |
float[][] pos = getPositions(); |
253 | 257 |
|
... | ... | |
262 | 266 |
|
263 | 267 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
264 | 268 |
|
265 |
ObjectSticker retSticker(int face) |
|
269 |
protected ObjectSticker retSticker(int face)
|
|
266 | 270 |
{ |
267 | 271 |
if( mStickers==null ) |
268 | 272 |
{ |
... | ... | |
297 | 301 |
|
298 | 302 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
299 | 303 |
|
300 |
float[][] getCubitPositions(int size) |
|
304 |
protected float[][] getCubitPositions(int size)
|
|
301 | 305 |
{ |
302 | 306 |
int numCubits = getNumCubits(); |
303 | 307 |
float[][] tmp = new float[numCubits][]; |
... | ... | |
312 | 316 |
|
313 | 317 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
314 | 318 |
|
315 |
Static4D[] getQuats() |
|
319 |
protected Static4D[] getQuats()
|
|
316 | 320 |
{ |
317 | 321 |
if( mQuats==null ) initializeQuats(); |
318 | 322 |
return mQuats; |
... | ... | |
320 | 324 |
|
321 | 325 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
322 | 326 |
|
323 |
float[][] getCuts(int numLayers) |
|
327 |
protected float[][] getCuts(int numLayers)
|
|
324 | 328 |
{ |
325 | 329 |
if( numLayers<2 ) return null; |
326 | 330 |
|
... | ... | |
356 | 360 |
|
357 | 361 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
358 | 362 |
|
359 |
int getSolvedFunctionIndex() |
|
363 |
protected int getSolvedFunctionIndex()
|
|
360 | 364 |
{ |
361 | 365 |
return 0; |
362 | 366 |
} |
363 | 367 |
|
364 | 368 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
365 | 369 |
|
366 |
int getNumStickerTypes(int numLayers) |
|
370 |
protected int getNumStickerTypes(int numLayers)
|
|
367 | 371 |
{ |
368 | 372 |
return NUM_STICKERS; |
369 | 373 |
} |
370 | 374 |
|
371 | 375 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
372 | 376 |
|
373 |
int getNumCubitFaces() |
|
377 |
protected int getNumCubitFaces()
|
|
374 | 378 |
{ |
375 | 379 |
return 6; |
376 | 380 |
} |
... | ... | |
405 | 409 |
|
406 | 410 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
407 | 411 |
|
408 |
int getFaceColor(int cubit, int cubitface, int numLayers) |
|
412 |
protected int getFaceColor(int cubit, int cubitface, int numLayers)
|
|
409 | 413 |
{ |
410 | 414 |
if( mFaceMap==null ) |
411 | 415 |
{ |
Also available in: Unified diff
Refactoring: split the 'objects' package into two, 'objects' and 'objectlib'.
The point: we're going to need to move the 'objectlib' stuff into its own library module, and that's because we're going to create a new app module which needs access to it.