Beispiel #1
0
    IEnumerator StartGame(float delay)
    {
        yield return(new WaitForSeconds(delay));

        tf.SetActiveAfter(canvasSelect.gameObject, false, 0.85f); //Select UI kapanacak.

        tf.SetActiveAfter(stuffParent.gameObject, true, 0.8f);    //Objeleri Aktif yap.

        //Oyuncuların position degiştirilecek
        //Oyuncuların layer değiştirilecek
        for (int i = 0; i < playerControllers.Length; i++)
        {
            if (playerControllers[i].gameObject.activeSelf)
            {
                playerControllers[i].SetPositionStart();
            }
        }

        scObject.GetComponent <CameraController>().enabled = true;
        scObject.GetComponent <PowerUpManager>().enabled   = true;

        //camera follow active edilecek.
        //power manager active edilecek.

        for (int i = 0; i < goalsMask.Length; i++)
        {
            goalsMask[i].gameObject.SetActive(true);
        }
    }
Beispiel #2
0
 public void Close()
 {
     _transformFunctions.Scale(_spriteRenderer.transform, Vector3.zero, 0, _time, _curve);
     _transformFunctions.SetActiveAfter(_spriteRenderer.gameObject, false, _time);
 }