void Awake()
    {
        //usarRefereciaDoPlayer_ref = GetComponent<UsarRefereciaDoPlayer>();
        spawnarArmadilhas_ref = GetComponent <SpawnarArmadilhas>();

        spawnarMunicao_ref = GetComponent <SpawnarMunicao>();



        if (singleton != null && singleton != this)
        {
            GameObject.Destroy(this);
        }
        else
        {
            singleton = this;
        }
    }
Example #2
0
 private void Awake()
 {
     spawnarMunicao_ref = GameObject.Find("Game").GetComponent <SpawnarMunicao>();
     referenciaDoPlayerAoInstanciar_ref = GameObject.Find("Game").GetComponent <Game>();
 }
Example #3
0
 private void Awake()
 {
     spawnarMunicao_ref = GetComponent <SpawnarMunicao>();
     vida_ref           = GameObject.Find("Tanque").GetComponent <Vida>();
 }