Search Unity

Audio Changing sounds to multiple objects

Discussion in 'Audio & Video' started by Itay_O, Oct 15, 2019.

  1. Itay_O

    Itay_O

    Joined:
    May 15, 2019
    Posts:
    10
    I think this is the right forum. If not, tell me where it would fit and I shall close this thread.
    Hello!

    I'm currently replacing all sound fx in the Unity template project "The Explorer 3D".
    I'm not using any middleware for the project.
    Recently, I made an attack growling sound for one of the enemies in the game.

    However, there are dozens of that specific enemy type in the game, and changing the sound only does so for one of them.
    Is there a way to globally change the sound to ALL of them? instead of just going one by one and manually changing the sound?

    Thanks in advance!
     
  2. JLF

    JLF

    Joined:
    Feb 25, 2013
    Posts:
    139
    Possibly stating the obvious here, so apologies if that's the case.

    Is the enemy you want to change a Prefab? i.e. A blue object in the Scene Hierarchy? If so you can change all of them by changing the Prefab itself. Select one of them and click Open to edit the prefab.

    Better explanation of Prefabs here: https://docs.unity3d.com/Manual/Prefabs.html

    If not, you might still be able to change all of the Audio Source clips by CMD / CTRL selecting all of them and then change the clip. It may be able to change all of the Audio SourceComponents at once.
     
    Itay_O likes this.
  3. Itay_O

    Itay_O

    Joined:
    May 15, 2019
    Posts:
    10

    It worked! the first method you suggested.

    It's alright you're stating the obvious because it wasn't for me :) i'm still a bit new to unity, and I didn't learm much beyond audio implentation.
    Thanks again! Now I realise it would be helpful to all the other objects in the game.
     
    JLF likes this.