Project

General

Profile

Download (2.73 KB) Statistics
| Branch: | Revision:

distorted-objectlib / src / main / java / org / distorted / objectlib / shape / ShapeDodecahedron.java @ 33ba467a

1
///////////////////////////////////////////////////////////////////////////////////////////////////
2
// Copyright 2019 Leszek Koltunski                                                               //
3
//                                                                                               //
4
// This file is part of Magic Cube.                                                              //
5
//                                                                                               //
6
// Magic Cube is proprietary software licensed under an EULA which you should have received      //
7
// along with the code. If not, check https://distorted.org/magic/License-Magic-Cube.html        //
8
///////////////////////////////////////////////////////////////////////////////////////////////////
9

    
10
package org.distorted.objectlib.shape;
11

    
12
import org.distorted.library.type.Static3D;
13
import org.distorted.library.type.Static4D;
14
import org.distorted.objectlib.main.InitAssets;
15
import org.distorted.objectlib.main.TwistyObject;
16
import org.distorted.objectlib.metadata.Metadata;
17

    
18
import static org.distorted.objectlib.shape.ShapeColors.*;
19

    
20
///////////////////////////////////////////////////////////////////////////////////////////////////
21

    
22
public abstract class ShapeDodecahedron extends TwistyObject
23
{
24
  public static final Static4D DEFAULT_ROT = new Static4D(-0.63874420f, 0.25712812f, 0.358450060f, 0.63039730f);
25

    
26
  public static final int[] FACE_COLORS = new int[]
27
         {
28
                 COLOR_DYELLO, COLOR_ORANGE, COLOR_RED, COLOR_SANDY,
29
                 COLOR_DBLUE, COLOR_WHITE, COLOR_GREY, COLOR_LBLUE,
30
                 COLOR_LGREEN, COLOR_VIOLET, COLOR_LPINK, COLOR_DGREEN
31
         };
32

    
33
  public static final int NUM_FACES = 12;
34
  public static final int FOV = 30;
35
  public static final float RATIO = 0.35f;
36

    
37
///////////////////////////////////////////////////////////////////////////////////////////////////
38

    
39
  public ShapeDodecahedron(int iconMode, float realSize, Static4D quat, Static3D move, float scale, Metadata meta, InitAssets asset)
40
    {
41
    super(iconMode, realSize, quat, move, scale, meta, asset);
42
    }
43

    
44
///////////////////////////////////////////////////////////////////////////////////////////////////
45

    
46
  public final int getNumPuzzleFaces()
47
    {
48
    return NUM_FACES;
49
    }
50

    
51
///////////////////////////////////////////////////////////////////////////////////////////////////
52

    
53
  public int[] getColorTable()
54
    {
55
    return FACE_COLORS;
56
    }
57

    
58
///////////////////////////////////////////////////////////////////////////////////////////////////
59

    
60
  public int getFOV()
61
    {
62
    return FOV;
63
    }
64

    
65
///////////////////////////////////////////////////////////////////////////////////////////////////
66

    
67
  public float getScreenRatio()
68
    {
69
    return RATIO;
70
    }
71
}
(3-3/7)