Project

General

Profile

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

distorted-objectlib / src / main / java / org / distorted / objectlib / objects / TwistyDino4.java @ cf93ea4e

1
///////////////////////////////////////////////////////////////////////////////////////////////////
2
// Copyright 2020 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.objects;
11

    
12
import org.distorted.library.type.Static3D;
13
import org.distorted.library.type.Static4D;
14

    
15
import org.distorted.objectlib.helpers.ObjectSignature;
16
import org.distorted.objectlib.main.InitAssets;
17
import org.distorted.objectlib.main.InitData;
18
import org.distorted.objectlib.main.ObjectSignatures;
19
import org.distorted.objectlib.main.ObjectType;
20

    
21
///////////////////////////////////////////////////////////////////////////////////////////////////
22

    
23
public class TwistyDino4 extends TwistyDino
24
{
25
  private int[] mFaceMap;
26

    
27
///////////////////////////////////////////////////////////////////////////////////////////////////
28

    
29
  public TwistyDino4(int meshState, int iconMode, Static4D quat, Static3D move, float scale, InitData data, InitAssets asset)
30
    {
31
    super(meshState, iconMode, quat, move, scale, data, asset);
32
    }
33

    
34
///////////////////////////////////////////////////////////////////////////////////////////////////
35

    
36
  @Override
37
  public int[][] getSolvedQuats()
38
    {
39
    return null;
40
    }
41

    
42
///////////////////////////////////////////////////////////////////////////////////////////////////
43

    
44
  @Override
45
  public int getSolvedFunctionIndex()
46
    {
47
    return 1;
48
    }
49

    
50
///////////////////////////////////////////////////////////////////////////////////////////////////
51

    
52
  @Override
53
  public int getCubitFaceMap(int cubit, int face)
54
    {
55
    if( mFaceMap==null ) mFaceMap = new int[] { 4, 2, 2, 4, 0, 2, 1, 4, 0, 0, 1, 1 };
56
    return face<2 ? mFaceMap[cubit] : -1;
57
    }
58

    
59
///////////////////////////////////////////////////////////////////////////////////////////////////
60

    
61
  @Override
62
  public boolean shouldResetTextureMaps()
63
    {
64
    return true;
65
    }
66

    
67
///////////////////////////////////////////////////////////////////////////////////////////////////
68

    
69
  public int[][] getScrambleEdges()
70
    {
71
    if( mEdges==null )
72
      {
73
      mEdges = new int[][]
74
        {
75
          {          4,1,5,1, 6,7,7,7,            12,6,13,6,                       22,4,23,4 },  // 0
76
          {                            10,2,11,2,            16,3,17,3, 18,5,19,5            },  // 1
77
          {          4,1,5,1,                     12,6,13,6,                       22,4,23,4 },  // 2
78
          {          4,1,5,1, 6,7,7,7,                                             22,4,23,4 },  // 3
79
          { 0,8,1,8,                   10,2,11,2,            16,3,17,3                       },  // 4
80
          {          4,1,5,1, 6,7,7,7,            12,6,13,6                                  },  // 5
81
          { 0,8,1,8,                   10,2,11,2,                       18,5,19,5            },  // 6
82
          { 0,8,1,8,                                         16,3,17,3, 18,5,19,5            },  // 7
83
          {                   6,7,7,7,            12,6,13,6,                       22,4,23,4 },  // 8
84
        };
85
      }
86

    
87
    return mEdges;
88
    }
89

    
90
///////////////////////////////////////////////////////////////////////////////////////////////////
91

    
92
  public String getShortName()
93
    {
94
    return ObjectType.DIN4_3.name();
95
    }
96

    
97
///////////////////////////////////////////////////////////////////////////////////////////////////
98

    
99
  public ObjectSignature getSignature()
100
    {
101
    return new ObjectSignature(ObjectSignatures.DIN4_3);
102
    }
103

    
104
///////////////////////////////////////////////////////////////////////////////////////////////////
105

    
106
  public String getObjectName()
107
    {
108
    return "Dino Cube (4 color)";
109
    }
110

    
111
///////////////////////////////////////////////////////////////////////////////////////////////////
112

    
113
  public String getInventor()
114
    {
115
    return "Robert Webb";
116
    }
117

    
118
///////////////////////////////////////////////////////////////////////////////////////////////////
119

    
120
  public int getYearOfInvention()
121
    {
122
    return 1985;
123
    }
124

    
125
///////////////////////////////////////////////////////////////////////////////////////////////////
126

    
127
  public String[][] getTutorials()
128
    {
129
    return null;
130
    }
131
}
(12-12/41)