Exemplo n.º 1
0
 // Use this for initialization
 void Start()
 {
     m_animator     = GetComponent <Animator>();
     m_body2d       = GetComponent <Rigidbody2D>();
     m_audioSource  = GetComponent <AudioSource>();
     m_audioManager = AudioManager_PrototypeHero.instance;
     m_groundSensor = transform.Find("GroundSensor").GetComponent <Sensor_Prototype>();
 }
Exemplo n.º 2
0
 private void Awake()
 {
     if (instance != null)
     {
         Debug.LogError("More than one AudioManger in scene");
     }
     else
     {
         instance = this;
     }
 }
Exemplo n.º 3
0
    // Use this for initialization que pasa WApo

    void Start()
    {
        m_animator     = GetComponent <Animator>();
        m_body2d       = GetComponent <Rigidbody2D>();
        m_audioSource  = GetComponent <AudioSource>();
        m_audioManager = AudioManager_PrototypeHero.instance;

        //Crouching get values of collider
        colSizeY   = this.GetComponent <BoxCollider2D>().size.y;
        colOffsetY = this.GetComponent <BoxCollider2D>().offset.y;
    }
Exemplo n.º 4
0
 // Start is called before the first frame update
 void Start()
 {
     m_player       = GetComponentInParent <PrototypeHero>();
     m_audioManager = AudioManager_PrototypeHero.instance;
 }