Project

General

Profile

Download (17.6 KB) Statistics
| Branch: | Tag: | Revision:

magiccube / src / main / java / org / distorted / objects / TwistyHelicopter.java @ 588ace55

1 ee35e63c Leszek Koltunski
///////////////////////////////////////////////////////////////////////////////////////////////////
2
// Copyright 2020 Leszek Koltunski                                                               //
3
//                                                                                               //
4
// This file is part of Magic Cube.                                                              //
5
//                                                                                               //
6
// Magic Cube is free software: you can redistribute it and/or modify                            //
7
// it under the terms of the GNU General Public License as published by                          //
8
// the Free Software Foundation, either version 2 of the License, or                             //
9
// (at your option) any later version.                                                           //
10
//                                                                                               //
11
// Magic Cube is distributed in the hope that it will be useful,                                 //
12
// but WITHOUT ANY WARRANTY; without even the implied warranty of                                //
13
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the                                 //
14
// GNU General Public License for more details.                                                  //
15
//                                                                                               //
16
// You should have received a copy of the GNU General Public License                             //
17
// along with Magic Cube.  If not, see <http://www.gnu.org/licenses/>.                           //
18
///////////////////////////////////////////////////////////////////////////////////////////////////
19
20
package org.distorted.objects;
21
22 588ace55 Leszek Koltunski
import static org.distorted.objectlib.Movement.TYPE_SPLIT_EDGE;
23 967c1d17 Leszek Koltunski
24 ee35e63c Leszek Koltunski
import android.content.res.Resources;
25
26 588ace55 Leszek Koltunski
import org.distorted.objectlib.ObjectShape;
27
import org.distorted.objectlib.ObjectSticker;
28
import org.distorted.objectlib.ScrambleState;
29 ee35e63c Leszek Koltunski
import org.distorted.library.main.DistortedEffects;
30
import org.distorted.library.main.DistortedTexture;
31
import org.distorted.library.mesh.MeshSquare;
32
import org.distorted.library.type.Static3D;
33
import org.distorted.library.type.Static4D;
34 6fd4a72c Leszek Koltunski
import org.distorted.main.R;
35 588ace55 Leszek Koltunski
import org.distorted.objectlib.Movement;
36
import org.distorted.objectlib.Movement6;
37
import org.distorted.objectlib.ObjectList;
38
import org.distorted.objectlib.Twisty6;
39 ee35e63c Leszek Koltunski
40
///////////////////////////////////////////////////////////////////////////////////////////////////
41
42 efa81f0c Leszek Koltunski
public class TwistyHelicopter extends Twisty6
43 ee35e63c Leszek Koltunski
{
44
  // the six rotation axis of a Helicopter. Must be normalized.
45
  static final Static3D[] ROT_AXIS = new Static3D[]
46
         {
47
           new Static3D(     0, +SQ2/2, -SQ2/2),
48
           new Static3D(     0, -SQ2/2, -SQ2/2),
49
           new Static3D(+SQ2/2,      0, -SQ2/2),
50
           new Static3D(-SQ2/2,      0, -SQ2/2),
51
           new Static3D(+SQ2/2, -SQ2/2,      0),
52
           new Static3D(-SQ2/2, -SQ2/2,      0)
53
         };
54
55 967c1d17 Leszek Koltunski
  private static final int[][][] ENABLED = new int[][][]
56
      {
57
          {{2,5},{2,4},{3,4},{3,5}},
58
          {{2,4},{2,5},{3,5},{3,4}},
59
          {{0,5},{1,5},{1,4},{0,4}},
60
          {{0,4},{1,4},{1,5},{0,5}},
61
          {{1,3},{0,3},{0,2},{1,2}},
62
          {{0,3},{1,3},{1,2},{0,2}},
63
      };
64
65 91792184 Leszek Koltunski
  private ScrambleState[] mStates;
66 85449b44 Leszek Koltunski
  private int[] mBasicAngle;
67
  private Static4D[] mQuats;
68 ef018c1b Leszek Koltunski
  private float[][] mCuts;
69
  private boolean[][] mLayerRotatable;
70 85449b44 Leszek Koltunski
  private float[][] mCenters;
71
  private int[] mQuatIndices;
72
  private int[][] mFaceMap;
73
  private ObjectSticker[] mStickers;
74 e9a87113 Leszek Koltunski
  private Movement mMovement;
75 486b3417 Leszek Koltunski
76 ee35e63c Leszek Koltunski
///////////////////////////////////////////////////////////////////////////////////////////////////
77
78 bdbbb4c5 Leszek Koltunski
  public TwistyHelicopter(int size, Static4D quat, DistortedTexture texture, MeshSquare mesh,
79
                          DistortedEffects effects, int[][] moves, Resources res, int scrWidth)
80 ee35e63c Leszek Koltunski
    {
81 db875721 Leszek Koltunski
    super(size, size, quat, texture, mesh, effects, moves, ObjectList.HELI, res, scrWidth);
82 91792184 Leszek Koltunski
    }
83
84
///////////////////////////////////////////////////////////////////////////////////////////////////
85 486b3417 Leszek Koltunski
86 bdbbb4c5 Leszek Koltunski
  protected ScrambleState[] getScrambleStates()
87 91792184 Leszek Koltunski
    {
88
    if( mStates==null )
89 486b3417 Leszek Koltunski
      {
90 91792184 Leszek Koltunski
      mStates = new ScrambleState[]
91
        {
92
        new ScrambleState( new int[][] { {0,1,1,2,1,2},{0,1,3,2,1,4},{0,1,5,2,1,6},{0,1,7,2,1,8},{0,1,9,2,1,10},{0,1,11,2,1,12} } ),
93
        new ScrambleState( new int[][] { {           },{           },{0,1,5      },{0,1,7      },{      2,1,10},{       2,1,12} } ),
94
        new ScrambleState( new int[][] { {           },{           },{      2,1,6},{      2,1,8},{0,1,9       },{0,1,11       } } ),
95
        new ScrambleState( new int[][] { {           },{           },{0,1,5      },{0,1,7      },{0,1,9       },{0,1,11       } } ),
96
        new ScrambleState( new int[][] { {           },{           },{      2,1,6},{      2,1,8},{      2,1,10},{       2,1,12} } ),
97
        new ScrambleState( new int[][] { {0,1,1      },{0,1,3      },{           },{           },{0,1,9       },{       2,1,12} } ),
98
        new ScrambleState( new int[][] { {      2,1,2},{      2,1,4},{           },{           },{      2,1,10},{0,1,11       } } ),
99
        new ScrambleState( new int[][] { {0,1,1      },{0,1,3      },{           },{           },{      2,1,10},{0,1,11       } } ),
100
        new ScrambleState( new int[][] { {      2,1,2},{      2,1,4},{           },{           },{0,1,9       },{       2,1,12} } ),
101
        new ScrambleState( new int[][] { {      2,1,2},{0,1,3      },{0,1,5      },{      2,1,8},{            },{             } } ),
102
        new ScrambleState( new int[][] { {0,1,1      },{      2,1,4},{      2,1,6},{0,1,7      },{            },{             } } ),
103
        new ScrambleState( new int[][] { {      2,1,2},{0,1,3      },{      2,1,6},{0,1,7      },{            },{             } } ),
104
        new ScrambleState( new int[][] { {0,1,1      },{      2,1,4},{0,1,5      },{      2,1,8},{            },{             } } ),
105
        };
106
      }
107
108
    return mStates;
109 b1f2ccf5 Leszek Koltunski
    }
110
111 85449b44 Leszek Koltunski
///////////////////////////////////////////////////////////////////////////////////////////////////
112
113
  private void initializeQuats()
114
    {
115
    mQuats = new Static4D[]
116
         {
117
         new Static4D( 0.00f,  0.00f,  0.00f,  1.00f ),
118
         new Static4D( 1.00f,  0.00f,  0.00f,  0.00f ),
119
         new Static4D( 0.00f,  1.00f,  0.00f,  0.00f ),
120
         new Static4D( 0.00f,  0.00f,  1.00f,  0.00f ),
121
122
         new Static4D( SQ2/2,  SQ2/2,  0.00f,  0.00f ),
123
         new Static4D( SQ2/2, -SQ2/2,  0.00f,  0.00f ),
124
         new Static4D( SQ2/2,  0.00f,  SQ2/2,  0.00f ),
125
         new Static4D( SQ2/2,  0.00f, -SQ2/2,  0.00f ),
126
         new Static4D( SQ2/2,  0.00f,  0.00f,  SQ2/2 ),
127
         new Static4D( SQ2/2,  0.00f,  0.00f, -SQ2/2 ),
128
         new Static4D( 0.00f,  SQ2/2,  SQ2/2,  0.00f ),
129
         new Static4D( 0.00f,  SQ2/2, -SQ2/2,  0.00f ),
130
         new Static4D( 0.00f,  SQ2/2,  0.00f,  SQ2/2 ),
131
         new Static4D( 0.00f,  SQ2/2,  0.00f, -SQ2/2 ),
132
         new Static4D( 0.00f,  0.00f,  SQ2/2,  SQ2/2 ),
133
         new Static4D( 0.00f,  0.00f,  SQ2/2, -SQ2/2 ),
134
135
         new Static4D( 0.50f,  0.50f,  0.50f,  0.50f ),
136
         new Static4D( 0.50f,  0.50f,  0.50f, -0.50f ),
137
         new Static4D( 0.50f,  0.50f, -0.50f,  0.50f ),
138
         new Static4D( 0.50f,  0.50f, -0.50f, -0.50f ),
139
         new Static4D( 0.50f, -0.50f,  0.50f,  0.50f ),
140
         new Static4D( 0.50f, -0.50f,  0.50f, -0.50f ),
141
         new Static4D( 0.50f, -0.50f, -0.50f,  0.50f ),
142
         new Static4D( 0.50f, -0.50f, -0.50f, -0.50f )
143
         };
144
    }
145
146 a480ee80 Leszek Koltunski
///////////////////////////////////////////////////////////////////////////////////////////////////
147
148 bdbbb4c5 Leszek Koltunski
  protected int[] getSolvedQuats(int cubit, int numLayers)
149 a480ee80 Leszek Koltunski
    {
150 85449b44 Leszek Koltunski
    if( mQuats==null ) initializeQuats();
151 a480ee80 Leszek Koltunski
    int status = retCubitSolvedStatus(cubit,numLayers);
152 967c1d17 Leszek Koltunski
    return status<0 ? null : buildSolvedQuats(Movement6.FACE_AXIS[status],mQuats);
153 a480ee80 Leszek Koltunski
    }
154
155 ee35e63c Leszek Koltunski
///////////////////////////////////////////////////////////////////////////////////////////////////
156
157 bdbbb4c5 Leszek Koltunski
  protected Static4D[] getQuats()
158 ee35e63c Leszek Koltunski
    {
159 85449b44 Leszek Koltunski
    if( mQuats==null ) initializeQuats();
160
    return mQuats;
161 ee35e63c Leszek Koltunski
    }
162
163 169219a7 Leszek Koltunski
///////////////////////////////////////////////////////////////////////////////////////////////////
164
165 bdbbb4c5 Leszek Koltunski
  protected int getSolvedFunctionIndex()
166 169219a7 Leszek Koltunski
    {
167
    return 0;
168
    }
169
170 ee35e63c Leszek Koltunski
///////////////////////////////////////////////////////////////////////////////////////////////////
171
172 bdbbb4c5 Leszek Koltunski
  protected int getNumStickerTypes(int numLayers)
173 ee35e63c Leszek Koltunski
    {
174 85449b44 Leszek Koltunski
    return 1;
175 ee35e63c Leszek Koltunski
    }
176
177 7403cdfa Leszek Koltunski
///////////////////////////////////////////////////////////////////////////////////////////////////
178
179 bdbbb4c5 Leszek Koltunski
  protected float[][] getCuts(int size)
180 7403cdfa Leszek Koltunski
    {
181 ef018c1b Leszek Koltunski
    if( mCuts==null )
182
      {
183
      float[] cut = new float[] { -3*SQ2/4, +3*SQ2/4 };
184
      mCuts = new float[][] { cut,cut,cut,cut,cut,cut };
185
      }
186
187
    return mCuts;
188
    }
189
190
///////////////////////////////////////////////////////////////////////////////////////////////////
191
192
  private void getLayerRotatable(int numLayers)
193
    {
194
    if( mLayerRotatable==null )
195
      {
196
      int numAxis = ROT_AXIS.length;
197
      boolean[] tmp = new boolean[] {true,false,true};
198
      mLayerRotatable = new boolean[numAxis][];
199
      for(int i=0; i<numAxis; i++) mLayerRotatable[i] = tmp;
200
      }
201 7403cdfa Leszek Koltunski
    }
202
203 ee35e63c Leszek Koltunski
///////////////////////////////////////////////////////////////////////////////////////////////////
204
205 bdbbb4c5 Leszek Koltunski
  protected int getNumCubitFaces()
206 ee35e63c Leszek Koltunski
    {
207 efa81f0c Leszek Koltunski
    return 4;
208 ee35e63c Leszek Koltunski
    }
209
210
///////////////////////////////////////////////////////////////////////////////////////////////////
211
212 bdbbb4c5 Leszek Koltunski
  protected float[][] getCubitPositions(int size)
213 ee35e63c Leszek Koltunski
    {
214 85449b44 Leszek Koltunski
    if( mCenters==null )
215
      {
216 41c8d4d8 Leszek Koltunski
      float DIST_CORNER = 1.50f;
217
      float DIST_CENTER = 1.50f;
218 85449b44 Leszek Koltunski
      float XY_CENTER = DIST_CORNER/3;
219
220
      mCenters = new float[][]
221
         {
222
             {   DIST_CORNER,   DIST_CORNER,   DIST_CORNER },
223
             {   DIST_CORNER,   DIST_CORNER,  -DIST_CORNER },
224
             {   DIST_CORNER,  -DIST_CORNER,   DIST_CORNER },
225
             {   DIST_CORNER,  -DIST_CORNER,  -DIST_CORNER },
226
             {  -DIST_CORNER,   DIST_CORNER,   DIST_CORNER },
227
             {  -DIST_CORNER,   DIST_CORNER,  -DIST_CORNER },
228
             {  -DIST_CORNER,  -DIST_CORNER,   DIST_CORNER },
229
             {  -DIST_CORNER,  -DIST_CORNER,  -DIST_CORNER },
230
231
             {   DIST_CENTER,     XY_CENTER,     XY_CENTER },
232
             {   DIST_CENTER,     XY_CENTER,    -XY_CENTER },
233
             {   DIST_CENTER,    -XY_CENTER,     XY_CENTER },
234
             {   DIST_CENTER,    -XY_CENTER,    -XY_CENTER },
235
236
             {  -DIST_CENTER,     XY_CENTER,     XY_CENTER },
237
             {  -DIST_CENTER,     XY_CENTER,    -XY_CENTER },
238
             {  -DIST_CENTER,    -XY_CENTER,     XY_CENTER },
239
             {  -DIST_CENTER,    -XY_CENTER,    -XY_CENTER },
240
241
             {   XY_CENTER  ,   DIST_CENTER,     XY_CENTER },
242
             {   XY_CENTER  ,   DIST_CENTER,    -XY_CENTER },
243
             {  -XY_CENTER  ,   DIST_CENTER,     XY_CENTER },
244
             {  -XY_CENTER  ,   DIST_CENTER,    -XY_CENTER },
245
246
             {   XY_CENTER  ,  -DIST_CENTER,     XY_CENTER },
247
             {   XY_CENTER  ,  -DIST_CENTER,    -XY_CENTER },
248
             {  -XY_CENTER  ,  -DIST_CENTER,     XY_CENTER },
249
             {  -XY_CENTER  ,  -DIST_CENTER,    -XY_CENTER },
250
251
             {   XY_CENTER  ,     XY_CENTER,   DIST_CENTER },
252
             {   XY_CENTER  ,    -XY_CENTER,   DIST_CENTER },
253
             {  -XY_CENTER  ,     XY_CENTER,   DIST_CENTER },
254
             {  -XY_CENTER  ,    -XY_CENTER,   DIST_CENTER },
255
256
             {   XY_CENTER  ,     XY_CENTER,  -DIST_CENTER },
257
             {   XY_CENTER  ,    -XY_CENTER,  -DIST_CENTER },
258
             {  -XY_CENTER  ,     XY_CENTER,  -DIST_CENTER },
259
             {  -XY_CENTER  ,    -XY_CENTER,  -DIST_CENTER },
260
         };
261
      }
262
263
    return mCenters;
264 ee35e63c Leszek Koltunski
    }
265
266 a2a4df1b Leszek Koltunski
///////////////////////////////////////////////////////////////////////////////////////////////////
267
268 bdbbb4c5 Leszek Koltunski
  protected ObjectShape getObjectShape(int cubit, int numLayers)
269 a2a4df1b Leszek Koltunski
    {
270
    int variant = getCubitVariant(cubit,numLayers);
271
272
    if( variant==0 )
273
      {
274 85449b44 Leszek Koltunski
      double[][] vertices = new double[][]
275
          {
276 41c8d4d8 Leszek Koltunski
            {-1.50f, 0.00f, 0.00f},
277
            { 0.00f,-1.50f, 0.00f},
278
            { 0.00f, 0.00f,-1.50f},
279
            {-0.75f,-0.75f,-0.75f},
280 85449b44 Leszek Koltunski
            { 0.00f, 0.00f, 0.00f}
281
          };
282
283
      int[][] vert_indices = new int[][]
284
          {
285
            {0,1,4},
286
            {2,0,4},
287
            {1,2,4},
288
            {3,1,0},
289
            {3,2,1},
290
            {3,0,2}
291
          };
292
293 3e605536 Leszek Koltunski
      float[][] bands     = new float[][] { {0.028f,35,0.16f,0.7f,7,3,3}, {0.000f, 0,1.00f,0.0f,3,1,5} };
294 a2a4df1b Leszek Koltunski
      int[] bandIndices   = new int[] { 0,0,0,1,1,1 };
295 41c8d4d8 Leszek Koltunski
      float[][] corners   = new float[][] { {0.08f,0.20f} };
296
      int[] cornerIndices = new int[] { 0,0,0,0,0 };
297
      float[][] centers   = new float[][] { {-0.75f, -0.75f, -0.75f} };
298 a2a4df1b Leszek Koltunski
      int[] centerIndices = new int[] { 0,0,0,-1,0 };
299 85449b44 Leszek Koltunski
      return new ObjectShape(vertices,vert_indices,bands,bandIndices,corners,cornerIndices,centers,centerIndices,getNumCubitFaces(), null);
300 a2a4df1b Leszek Koltunski
      }
301
    else
302
      {
303 85449b44 Leszek Koltunski
      double[][] vertices = new double[][]
304
          {
305 41c8d4d8 Leszek Koltunski
            { 0.50f, 0.50f, 0.00f },
306
            {-1.00f, 0.50f, 0.00f },
307
            { 0.50f,-1.00f, 0.00f },
308
            {-0.25f,-0.25f,-0.75f },
309 85449b44 Leszek Koltunski
          };
310
311
      int[][] vert_indices = new int[][]
312
          {
313
            { 0,1,2 },
314
            { 2,1,3 },
315
            { 0,1,3 },
316
            { 2,0,3 }
317
          };
318
319 3e605536 Leszek Koltunski
      float[][] bands     = new float[][] { {0.028f,35,0.16f,0.7f,7,3,3}, {0.000f, 0,1.00f,0.0f,3,1,3} };
320 a2a4df1b Leszek Koltunski
      int[] bandIndices   = new int[] { 0,1,1,1 };
321 41c8d4d8 Leszek Koltunski
      float[][] corners   = new float[][] { {0.06f,0.20f} };
322
      int[] cornerIndices = new int[] { 0,0,0,-1 };
323
      float[][] centers   = new float[][] { {-0.25f, -0.25f, -0.75f} };
324 a2a4df1b Leszek Koltunski
      int[] centerIndices = new int[] { 0,0,0,-1 };
325 85449b44 Leszek Koltunski
      return new ObjectShape(vertices,vert_indices,bands,bandIndices,corners,cornerIndices,centers,centerIndices,getNumCubitFaces(), null);
326 a2a4df1b Leszek Koltunski
      }
327
    }
328
329
///////////////////////////////////////////////////////////////////////////////////////////////////
330
331 bdbbb4c5 Leszek Koltunski
  protected Static4D getQuat(int cubit, int numLayers)
332 a2a4df1b Leszek Koltunski
    {
333 85449b44 Leszek Koltunski
    if( mQuats==null ) initializeQuats();
334
    if( mQuatIndices==null ) mQuatIndices = new int[] { 0,13,14,1,12,2,3,7,20,6,13,17,7,23,18,12,22,10,8,16,11,21,19,9,3,15,14,0,5,2,1,4 };
335
    return mQuats[mQuatIndices[cubit]];
336 a2a4df1b Leszek Koltunski
    }
337
338
///////////////////////////////////////////////////////////////////////////////////////////////////
339
340 bdbbb4c5 Leszek Koltunski
  protected int getNumCubitVariants(int numLayers)
341 a2a4df1b Leszek Koltunski
    {
342
    return 2;
343
    }
344
345
///////////////////////////////////////////////////////////////////////////////////////////////////
346
347 bdbbb4c5 Leszek Koltunski
  protected int getCubitVariant(int cubit, int numLayers)
348 a2a4df1b Leszek Koltunski
    {
349
    return cubit<8 ? 0:1;
350
    }
351
352 ee35e63c Leszek Koltunski
///////////////////////////////////////////////////////////////////////////////////////////////////
353
354 bdbbb4c5 Leszek Koltunski
  protected int getFaceColor(int cubit, int cubitface, int size)
355 ee35e63c Leszek Koltunski
    {
356 85449b44 Leszek Koltunski
    if( mFaceMap==null )
357
      {
358
      mFaceMap = new int[][]
359
         {
360
           { 4,2,0, 6,6,6 },
361
           { 0,2,5, 6,6,6 },
362
           { 4,0,3, 6,6,6 },
363
           { 5,3,0, 6,6,6 },
364
           { 1,2,4, 6,6,6 },
365
           { 5,2,1, 6,6,6 },
366
           { 4,3,1, 6,6,6 },
367
           { 1,3,5, 6,6,6 },
368
369
           { 0 , 6,6,6,6,6 },
370
           { 0 , 6,6,6,6,6 },
371
           { 0 , 6,6,6,6,6 },
372
           { 0 , 6,6,6,6,6 },
373
374
           { 1 , 6,6,6,6,6 },
375
           { 1 , 6,6,6,6,6 },
376
           { 1 , 6,6,6,6,6 },
377
           { 1 , 6,6,6,6,6 },
378
379
           { 2 , 6,6,6,6,6 },
380
           { 2 , 6,6,6,6,6 },
381
           { 2 , 6,6,6,6,6 },
382
           { 2 , 6,6,6,6,6 },
383
384
           { 3 , 6,6,6,6,6 },
385
           { 3 , 6,6,6,6,6 },
386
           { 3 , 6,6,6,6,6 },
387
           { 3 , 6,6,6,6,6 },
388
389
           { 4 , 6,6,6,6,6 },
390
           { 4 , 6,6,6,6,6 },
391
           { 4 , 6,6,6,6,6 },
392
           { 4 , 6,6,6,6,6 },
393
394
           { 5 , 6,6,6,6,6 },
395
           { 5 , 6,6,6,6,6 },
396
           { 5 , 6,6,6,6,6 },
397
           { 5 , 6,6,6,6,6 },
398
         };
399
      }
400
401 ee35e63c Leszek Koltunski
    return mFaceMap[cubit][cubitface];
402
    }
403
404 9c06394a Leszek Koltunski
///////////////////////////////////////////////////////////////////////////////////////////////////
405
406 bdbbb4c5 Leszek Koltunski
  protected ObjectSticker retSticker(int face)
407 9c06394a Leszek Koltunski
    {
408 85449b44 Leszek Koltunski
    if( mStickers==null )
409
      {
410
      float[][] STICKERS = new float[][] { { -0.5f, 0.25f, 0.25f, -0.5f, 0.25f, 0.25f } };
411
      float radius = 0.03f;
412
      float stroke = 0.05f;
413
      float[] radii = new float[] {radius,radius,radius};
414
      mStickers = new ObjectSticker[STICKERS.length];
415
      mStickers[0] = new ObjectSticker(STICKERS[0],null,radii,stroke);
416
      }
417
418 abf36986 Leszek Koltunski
    return mStickers[face/NUM_FACE_COLORS];
419 ee35e63c Leszek Koltunski
    }
420
421
///////////////////////////////////////////////////////////////////////////////////////////////////
422 e1dc3366 Leszek Koltunski
// PUBLIC API
423 ee35e63c Leszek Koltunski
424 e1dc3366 Leszek Koltunski
  public Static3D[] getRotationAxis()
425
    {
426
    return ROT_AXIS;
427
    }
428
429 e9a87113 Leszek Koltunski
///////////////////////////////////////////////////////////////////////////////////////////////////
430
431
  public Movement getMovement()
432
    {
433 ef018c1b Leszek Koltunski
    if( mMovement==null )
434
      {
435
      int numLayers = getNumLayers();
436
      if( mCuts==null ) getCuts(numLayers);
437
      getLayerRotatable(numLayers);
438 7ee89540 Leszek Koltunski
      mMovement = new Movement6(ROT_AXIS,mCuts,mLayerRotatable,numLayers,TYPE_SPLIT_EDGE,ENABLED);
439 ef018c1b Leszek Koltunski
      }
440 e9a87113 Leszek Koltunski
    return mMovement;
441
    }
442
443 e1dc3366 Leszek Koltunski
///////////////////////////////////////////////////////////////////////////////////////////////////
444
445
  public int[] getBasicAngle()
446
    {
447 85449b44 Leszek Koltunski
    if( mBasicAngle ==null ) mBasicAngle = new int[] { 2,2,2,2,2,2 };
448
    return mBasicAngle;
449 e1dc3366 Leszek Koltunski
    }
450
451 6fd4a72c Leszek Koltunski
///////////////////////////////////////////////////////////////////////////////////////////////////
452
453
  public int getObjectName(int numLayers)
454
    {
455
    return R.string.heli3;
456
    }
457
458
///////////////////////////////////////////////////////////////////////////////////////////////////
459
460
  public int getInventor(int numLayers)
461
    {
462
    return R.string.heli3_inventor;
463
    }
464
465
///////////////////////////////////////////////////////////////////////////////////////////////////
466
467
  public int getComplexity(int numLayers)
468
    {
469
    return 8;
470
    }
471 ee35e63c Leszek Koltunski
}