Search Issue Tracker

By Design

Votes

8

Found in

2017.4.7f1

Issue ID

1066018

Regression

No

AudioSource volume doesn't work when AudioSource is a child of gamobject with rigidbody and time scale is set to 0

Audio

-

If an AudioSource is a child of a Rigidbody and Time.timeScale is set to zero, the AudioSource's volume will become stuck at whatever level it was at when the time scale was changed to zero

Steps to reproduce:
1. Open attached project
2. Open "RigidbodyTimescaleAudioTest" scene
3. Hit play in the editor
4. Select the game object "AudioSource_2" (which is a child of Rigidbody game object) and in the inspector assign some value to the volume
-You should hear sound volume increasing/decreasing depending on the value
5. Click on the "Game" window to set the focus there and press the space bar to set the time scale to 0
6. Assign different volume value to "AudioSource_2"
-Sound volume does not change

Actual result: AudioSource volume is stuck at whatever level it was at when the time scale was changed to 0
Expected result: AudioSource should be able to change volume when the time scale is set to 0 regardless if its a child of a rigidbody or not

Reproduced with: 2017.4.9f1, 2018.2.1f1, 2018.3.0a7

  1. Resolution Note:

    This behaviour is by design if you look at the AudioSource (and AudioListener) API:

    https://docs.unity3d.com/ScriptReference/AudioSource-velocityUpdateMode.html
    https://docs.unity3d.com/ScriptReference/AudioListener-velocityUpdateMode.html

    If you set velocityUpdateMode = AudioVelocityUpdateMode.Dynamic on the audio source the sound will play regardless of TimeScale value.

Comments (4)

  1. ilusja

    Dec 03, 2020 11:49

    It wasn't fixed because "By Design", it means there's nothing to fix.

  2. Tortuap

    Aug 09, 2020 09:34

    Yup, still here in 2019.3.11f1.
    Why isn't this fixed already ?

  3. unity2amuzo

    Jan 22, 2020 09:33

    Reproduced in 2019.2.17f1

  4. andrewpey

    Jul 11, 2019 10:53

    Reproduced on 2019.1.9f1.

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.