Exemplo n.º 1
0
 // Start is called before the first frame update
 void Awake()
 {
     fadeAnim = GameObject.Find("FadeGame").GetComponent <Animator>();
     StartCoroutine(desativarFade());
     botoes       = GameObject.Find("CanvasBotoes").GetComponent <Canvas>();
     somGeralJogo = GameObject.FindGameObjectWithTag("ControladorInicial").GetComponent <MusicaForaDoJogo>();
     //buscarObjetosToggle
     toque           = GameObject.Find("Toque").GetComponent <Toggle>();
     som             = GameObject.Find("Audio").GetComponent <Toggle>();
     auxilio         = GameObject.Find("Ajuda").GetComponent <Toggle>();
     textoAuxiliador = GameObject.Find("AuxiliadorTEXT");
     painel_Pause    = GameObject.Find("PauseGame");
 }
Exemplo n.º 2
0
    void Start()
    {
        BotaoBullet.pressing = false;

        fb           = GameObject.Find("feedback").GetComponent <feedback>();
        somGeralJogo = GameObject.FindGameObjectWithTag("ControladorInicial").GetComponent <MusicaForaDoJogo>();

        somGeralJogo.tocarMusicaAleatoriaFase(); //muda de musica ao iniciar, pega uma musica aleatoria
        setEnergy(8);
        anim.SetBool("nochao", true);
        anim.SetBool("movendo", false);
        anim.SetBool("morte", false);
        anim.SetBool("ataque", false);
    }