Example #1
0
    void Start()
    {
        groundLayerMask      = ((1 << groundLayer)) | ((1 << breakableFloorsLayer));
        startPos             = gameObject.transform.position;
        rb2D                 = GetComponent <Rigidbody2D>();
        rollingSource        = GetComponent <AudioSource>();
        rollingSource.clip   = rollingSound;
        rollingSource.volume = rollingVolume;

        AM = Toolbox.GetInstance().GetAudioManager();
        AM.AddAudioSources(rollingSource);
    }