コード例 #1
0
    IEnumerator ChamaFuncaoTransition()
    {
        yield return(new WaitForSeconds(3f));

        _TC.cena = "gamePlay";
        _TC.CallFadeout();
    }
コード例 #2
0
 void LateUpdate()
 {
     //Vector3 posicaoDestinoCamera = new Vector3(mainCamera.transform.position.x, posFinalCamera.transform.position.y,-10);
     //mainCamera.transform.position = Vector3.MoveTowards(mainCamera.transform.position,posicaoDestinoCamera,velocidadeVerticalCamera*Time.deltaTime);
     //controlePosicaoCamera();
     atualizaBarraVidaPlayer();
     if (qtdBoss == 4)
     {
         _TC.cena = "MissionSuccessful";
         _TC.CallFadeout();
     }
 }
コード例 #3
0
    void explodir()
    {
        _GC.isPlayerAlive = false;
        _GC.playOneShot(_GC.FxExplosao);
        GameObject temp = Instantiate(_GC.prefabExplosao, transform.position, transform.rotation);

        Destroy(temp.gameObject, 0.5f);
        Destroy(this.gameObject);
        if (_GC.vidas > 0)
        {
            _GC.chamaAguardaRespawn();
        }
        else
        {
            _TC.cena = "gameOver";
            _TC.CallFadeout();
        }
    }
コード例 #4
0
 // Use this for initialization
 public void carregaScene(string nomeScene)
 {
     _TC.cena = nomeScene;
     _TC.CallFadeout();
 }