Project

General

Profile

« Previous | Next » 

Revision 51df47f3

Added by Leszek Koltunski almost 4 years ago

Progress with Megaminx.

View differences:

src/main/java/org/distorted/objects/TwistyMegaminx.java
475 475
    int part    = edge % numCubitsPerEdge;
476 476
    int variant = edge / numCubitsPerEdge;
477 477

  
478
    return (part==0 || cubitface==((part+1)%2)) ? mEdgeMap[variant][cubitface+2] + (part+1)*NUM_FACES : NUM_TEXTURES;
478
    return (part==0 || cubitface==((part+1)%2)) ? mEdgeMap[variant][cubitface+2] + ((part+3)/2)*NUM_FACES : NUM_TEXTURES;
479 479
    }
480 480

  
481 481
///////////////////////////////////////////////////////////////////////////////////////////////////
......
509 509
    }
510 510

  
511 511
///////////////////////////////////////////////////////////////////////////////////////////////////
512
// TODO
513 512

  
514 513
  void createFaceTexture(Canvas canvas, Paint paint, int face, int left, int top)
515 514
    {
......
522 521
    if( variant==0 )
523 522
      {
524 523
      float Y = COS54/(2*SIN54);
525
      R = 0.05f;
526
      S = 0.06f;
524
      R = 0.06f;
525
      S = 0.065f;
527 526
      vertices = new float[] { -0.5f, 0.0f, 0.0f, -Y, 0.5f, 0.0f, 0.0f, Y };
528 527
      }
529 528
    else
......
540 539
        float Y2 = 0.5f*width + W;
541 540

  
542 541
        R = 0.04f;
543
        S = 0.055f;
542
        S = 0.05f;
544 543
        vertices = new float[] { -X1, Y1, -X1, -Y1, X1, -Y2, X1, Y2 };
545 544
        }
546 545
      else

Also available in: Unified diff