Revision b3da2f16
Added by Leszek Koltunski about 4 years ago
src/main/java/org/distorted/objects/ObjectList.java | ||
---|---|---|
105 | 105 |
SKEW ( |
106 | 106 |
new int[][] { |
107 | 107 |
{2 , 11, R.raw.skewb, R.drawable.ui_small_skewb, R.drawable.ui_medium_skewb, R.drawable.ui_big_skewb, R.drawable.ui_huge_skewb} , |
108 |
{3 , 15, R.raw.skewb, R.drawable.ui_small_skewb, R.drawable.ui_medium_skewb, R.drawable.ui_big_skewb, R.drawable.ui_huge_skewb} , |
|
109 |
{4 , 20, R.raw.skewb, R.drawable.ui_small_skewb, R.drawable.ui_medium_skewb, R.drawable.ui_big_skewb, R.drawable.ui_huge_skewb} , |
|
108 |
{3 , 17, R.raw.skewb, R.drawable.ui_small_skewm, R.drawable.ui_medium_skewm, R.drawable.ui_big_skewm, R.drawable.ui_huge_skewm} , |
|
110 | 109 |
}, |
111 | 110 |
TwistySkewb.class, |
112 | 111 |
new MovementSkewb(), |
src/main/java/org/distorted/objects/TwistySkewb.java | ||
---|---|---|
507 | 507 |
int numLayers = getNumLayers(); |
508 | 508 |
float[] chances = new float[numLayers]; |
509 | 509 |
|
510 |
for(int i=0; i<numLayers; i++)
|
|
510 |
switch(numLayers)
|
|
511 | 511 |
{ |
512 |
chances[i] = (float)(i+1)/numLayers; |
|
512 |
case 2: chances[0] = 0.5f; |
|
513 |
chances[1] = 1.0f; |
|
514 |
break; |
|
515 |
case 3: chances[0] = 0.5f; |
|
516 |
chances[1] = 0.5f; |
|
517 |
chances[2] = 1.0f; |
|
518 |
break; |
|
519 |
default:for(int i=0; i<numLayers; i++) |
|
520 |
{ |
|
521 |
chances[i] = (float)(i+1)/numLayers; |
|
522 |
} |
|
513 | 523 |
} |
514 | 524 |
|
515 | 525 |
return chances; |
Also available in: Unified diff
Icons for the Skewb Master.