Example #1
0
 // Use this for initialization
 void Start()
 {
     PlayerSettings.CameraDisable = true;
     PlayerSettings.CubeRotation  = false;
     this.cameraPivot             = this.transform.parent;
     bigCube = FindObjectOfType <BigCube>();
     offset  = PlayerSettings.CubeSize * 0.5f - 0.5f;
 }
Example #2
0
 private void BeginGame()
 {
     PlayerSettings.SettingsOn          = false;
     PlayerSettings.GameWon             = false;
     PlayerSettings.FaceRotation        = false;
     PlayerSettings.CubeRotation        = false;
     PlayerSettings.Scrambling          = false;
     bigCubeInstance                    = Instantiate(bigCubePrefab) as BigCube;
     bigCubeInstance.transform.position = transform.position;
     bigCubeInstance.GenerateCube();
     Invoke("ScrambleCube", 0.5f);
 }
Example #3
0
 void TimeCal()
 {
     if (!BigCube.isGameClear())
     {
         time += 1;
     }
     else
     {
         BestTime.BestTimeRecord(time);
         CancelInvoke("TimeCal");
         ClearText.S.ClearGame();
     }
     this.gameObject.GetComponent <Text>().text = "Time : " + time.ToString();
 }