Search Unity

Master Audio - AAA Sound Solution. #1 audio plugin on Asset Store!

Discussion in 'Assets and Asset Store' started by dark_tonic, Jan 28, 2013.

  1. snowcult

    snowcult

    Joined:
    Feb 6, 2014
    Posts:
    295
    Ok so I set up a group with 4 sounds. Clicking the group preview shows that it works, playing a new sound on each preview click.

    I attach a EventSounds script to an empty cube (testing, I ideally want it on my AI), set to Caller Location. Event to Activate is Start, and sound group is set to my group. Launch the scene and... there'es a really high pitched "glitchy" sound, and that's it. It doesn't do anything else, no sounds playing.
     
  2. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    Very weird. Haven't heard of this problem before. What happens when you click preview while in play mode?
     
  3. NickHVenden

    NickHVenden

    Joined:
    Aug 3, 2013
    Posts:
    33
    Brian,
    Thank you again,
    I'm now trying to recover my project by packaging things and re-importing them into a new UnityProject.
    I had deleted the older Master Audio from my project, reimported your update from the AssetStore package, and everything seemed fine.

    However, this is showing up as errors in MA:
    $errorScreenShot_00.jpg
    AudioLocation and ChainedLoopLoopMode do not exist.

    Some script compiling error associated with MasterAudio. I do not have the skills to track this down.
    Your help is needed here.
    Thanks,
    Nick Venden
     
  4. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    Those classes definitely exist and are in the Asset Store package. Please delete the old AND the new folder (Dark Tonic and Master Audio folders) and reimport again. You only mentioned that you deleted the old one.
     
  5. NickHVenden

    NickHVenden

    Joined:
    Aug 3, 2013
    Posts:
    33
    Brian,
    I deleted all, reimported and things are compiling.
    If there any other issues I'll be in touch, but you've been great handling my problems.
    Again, thanks!
    Nick V
     
  6. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    As I suspected :). Good to hear, thanks Nick!
     
  7. snowcult

    snowcult

    Joined:
    Feb 6, 2014
    Posts:
    295
    In play mode, clicking preview for the group plays the sounds as normal. :/

    I should add, there's no 3D gizmo on the object for some reason.

    --

    Edit: It just randomly started working. Wew!
     
    Last edited: Mar 25, 2014
  8. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    What's the file type of those audio files? Do you get any messages in the console when it plays? If none of that is weird, you can try sending me a small project that reproduces the problem. Use filemail.com and send to jerotas2005@yahoo.com

    Thanks.
     
  9. wightwhale

    wightwhale

    Joined:
    Jul 28, 2011
    Posts:
    397
    Not sure if my package was outdated or you forgot to update the tk2d package but I ran into an issue in tk2duisounditemeditor.cs where GUIHelper doesn't exist, if you change it to DTGUIHelper it works fine.
     
  10. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    Ok, I'll take a look. We haven't used tk2d for a little while, it's probably been changed.
     
  11. wightwhale

    wightwhale

    Joined:
    Jul 28, 2011
    Posts:
    397
    I'm also getting an error with NGUI script button clicker and that one doesn't look like as easy of a fix. The error pops up when I put my master audio prefab into my gui scene. No error if the master audio prefab isn't in the scene.

    NullReferenceException: Object reference not set to an instance of an object
    DTGUIHelper.ShowHeaderTexture (UnityEngine.Texture tex) (at Assets/DarkTonic/MasterAudio/Editor/GUIHelper.cs:36)
    ButtonClickerInspector.OnInspectorGUI () (at Assets/DarkTonic/MasterAudio/Editor/ButtonClickerInspector.cs:20)
    UnityEditor.InspectorWindow.DrawEditors (Boolean isRepaintEvent, UnityEditor.Editor[] editors, Boolean eyeDropperDirty) (at C:/BuildAgent/work/d3d49558e4d408f4/Editor/Mono/Inspector/InspectorWindow.cs:850)
    UnityEditor.DockArea:OnGUI()
     
  12. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    Looks like you don't have the Editor Default Resources/Master Audio folder. Please re-download the package from the Asset Store. It is in the package there.
     
  13. wightwhale

    wightwhale

    Joined:
    Jul 28, 2011
    Posts:
    397
    I re-downloaded and imported the package for 2nd time today and I just have the Editor Default Resources / MasterAudio folder but nothing in that folder.
     
  14. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    The images are there in the package, you can actually see them on the Asset Store page where it lists the files. You may want to try deleting the entire Dark Tonic folder and the Master Audio folder, then reimporting afterward. Maybe you have those icons in a different folder from a previous installation? That can mess up the import process, where it just leaves them where they are.
     
  15. wightwhale

    wightwhale

    Joined:
    Jul 28, 2011
    Posts:
    397
    Yep that fixed it thanks for you quick response!
     
  16. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    No problem!
     
  17. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    Master Audio V3.4.4 will be live in about 20 minutes. Changelog:

    • Added RemoveItems method to Dynamic Sound Group Creator script. You can manually call this if you don't want to wait before the end of the Scene (or when the Dynamic SGC is disabled) to remove all the temporary items.
    • Fixed bug: Dragging songs into playlist clip section in Resource File mode didn't populate their folder name.
    • Fixed bug: Dragging clips into Variation Inspector in Resource File mode didn't populate their folder name.
    • Fixed bug: Dragging clips into Sound Group Inspector in Resource File mode didn't populate their folder name.
    • Fixed bug: An all resource file Playlist gives errors when playing tracks from it.
    • Fixed bug: Playlist fading had divide by zero error if already at zero volume.
    • Redid Hierarchy "M" renderer for much better performance. Thanks to user Bryan Wilkins for sending me the fix!
    • Updated 2D Toolkit integration package to work with latest 2DTK. It was broken.
    • Made resource file playlist clip "names" able to play them without specifying the resource folder name. Just the clip name.

    And a big thank you goes out to KingsIsle for becoming our first customer to purchase a Master Audio unlimited site license!
     
  18. haim96

    haim96

    Joined:
    May 24, 2013
    Posts:
    107
    Hi,

    i using the latest 3.4 MasterAudio and it seems there is a bug with the "persist between scenes"
    i start the audio with my menu scene and is persist to the game scene. but when i load back the menu scene all MasterAudio objects
    are duplicated (the main controller and playlist controller) i also have this error:

    "You have more than 1 Playlist Controller with the name 'PlaylistController'. You must name them all uniquely. Ducking and other functions will not function properly until you fix this. UnityEngine.Debug:LogError...."

    is this a bug or what?


    thanks,
     
  19. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    Doesn't sound like a bug. I think it's a problem in your setup. You need to use a "bootstrapper scene" as described in the documentation, or you'll have extra Playlist Controllers and Master Audio prefabs every time you go back to the scene they are in (the persistant one plus the one in the Scene). Basically you can never return to the Bootstrapper Scene. That's the only way to get persist to work properly.
     
  20. haim96

    haim96

    Joined:
    May 24, 2013
    Posts:
    107
    OK, i will do that, thanks for reply!
    by the way, your documentation not available since you ran out of google docs bandwidth... :)
     
  21. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    Last edited: Mar 28, 2014
  22. haim96

    haim96

    Joined:
    May 24, 2013
    Posts:
    107
    OK... for some reason it opened with google docs. any way it works again...
    i added the Master Audio controller to the preload screen and now it work fine. thanks for the tip!

    now, i have these warnings and i'm not sure way:
    ---------------------------------------------------------------------------------------------------------------------------------------------------
    T: 6.680751 - MasterAudio Cueing child named 'machine-gun' of SoundFX
    UnityEngine.Debug:LogWarning(Object)
    MasterAudio:LogIfLoggingEnabled(String, String) (at Assets/DarkTonic/MasterAudio/Scripts/Singleton/MasterAudio.cs:3675)
    MasterAudio:playSoundAtVolume(String, Single, Vector3, Nullable`1, Transform, String, Boolean, Single, Boolean, Boolean, Boolean) (at Assets/DarkTonic/MasterAudio/Scripts/Singleton/MasterAudio.cs:1141)
    MasterAudio:playSound(String, Single, Nullable`1, Single, String, Boolean) (at Assets/DarkTonic/MasterAudio/Scripts/Singleton/MasterAudio.cs:684)
    EventSounds:playSound(AudioEvent, EventType, Boolean) (at Assets/DarkTonic/MasterAudio/Scripts/Events/EventSounds.cs:357)
    EventSounds:Start() (at Assets/DarkTonic/MasterAudio/Scripts/Events/EventSounds.cs:113)
    --------------------------------------------------------------------------------------------------------------------------------------------------------
    : 18.22 - MasterAudio Can't find non-busy variation {bullet-hit} of SoundFX
    UnityEngine.Debug:LogWarning(Object)
    MasterAudio:LogIfLoggingEnabled(String, String) (at Assets/DarkTonic/MasterAudio/Scripts/Singleton/MasterAudio.cs:3675)
    MasterAudio:playSoundAtVolume(String, Single, Vector3, Nullable`1, Transform, String, Boolean, Single, Boolean, Boolean, Boolean) (at Assets/DarkTonic/MasterAudio/Scripts/Singleton/MasterAudio.cs:1135)
    MasterAudio:playSound(String, Single, Nullable`1, Single, String, Boolean) (at Assets/DarkTonic/MasterAudio/Scripts/Singleton/MasterAudio.cs:684)
    EventSounds:playSound(AudioEvent, EventType, Boolean) (at Assets/DarkTonic/MasterAudio/Scripts/Events/EventSounds.cs:357)
    EventSounds:Start() (at Assets/DarkTonic/MasterAudio/Scripts/Events/EventSounds.cs:113)
    -------------------------------------------------------------------------------------------------------------------------------------------------------------------

    the sound does play so i not sure what should i do with these and what they mean. any advice?
     
  23. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    You have "log all sounds" checked in the Master Audio prefab. That's why you're getting these messages. Turn it off, as it's for troubleshooting only. It will tell you things like the many reasons why sounds aren't played (voice limit, busy, etc).

    The sound plays the first time, and not the second time because it's busy and you've probably kept the default "weight" of your bullet-hit Variation at 1, which means that only 1 can be played at a time. If you want 4 to be able to be played at a time, change the weight property to 4.
     
  24. haim96

    haim96

    Joined:
    May 24, 2013
    Posts:
    107
    any reason to have these warnings? if every thing is fine i would expect getting info messages not warnings of any kind...
     
  25. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    They are for troubleshooting. Normally you would turn these off with the checkbox I mentioned above. There are about 7 reasons why a sound won't play in Master Audio, so it will tell you which one was a factor so that you can adjust it. Very helpful in those situations. It will also tell you which variations are getting chosen randomly, which can be useful. I leave that setting off 99% of the time though. Was it on by default?
     
  26. haim96

    haim96

    Joined:
    May 24, 2013
    Posts:
    107
    it was off, but i turned it on and saw all these warining and thought that something is wrong...
    so i can ignore these "MasterAudio Cueing child named 'machine-gun' of SoundFX" ?
     
  27. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    Yes, that's just telling you which sound was chosen to play, before any of the 7 "don't play it" checks are done.

    If something is / was wrong, we log a red error, not a warning. And those get logged even if you turn off "log all sounds".
     
  28. haim96

    haim96

    Joined:
    May 24, 2013
    Posts:
    107
    good to know, thank you so far!
     
  29. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    No problem!
     
  30. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    Master Audio V3.4.5 will be live in 20 minutes. Changelog:

    • Fixed bug: Removal of a new bus Dynamic SGC threw an error.
    • Fixed bug: When changing to a different Playlist, the first song should always start at the beginning. It did not, depending on Song Transition Type.
    • Added per-Scene Playlist creation to Dynamic Sound Group Creator prefab. You cannot add to an existing Playlist though, must create new.
     
  31. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    I misread your comment. Info message are white or something instead of yellow, correct? I've never used those before. I could easily change these to info's if that's preferred. Let me know.
     
  32. PrisonerOfLies

    PrisonerOfLies

    Joined:
    Dec 6, 2013
    Posts:
    105
    is there a tutorial on how to properly setup playlist controller ?
    i am having an issue where the music bgm sounds different when using masteraudio, from playing it from raw audio clip...
    some music bgm become strangely softer, or louder than the original
     
  33. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    There's nothing to it. No need for a tutorial. If your volume is different, it's from 3d settings, period. I always put all my music as 2d (turn off 3d settings in the Audio Clip itself). Or you can adjust the 3d settings if you want it 3d. But it has nothing to do with Master Audio. One thing of note is: if your Audio Listener moves, just put the Playlist Controller as a sub-prefab at the same location. I believe that's mentioned in the docs.
     
    Last edited: Mar 29, 2014
  34. PrisonerOfLies

    PrisonerOfLies

    Joined:
    Dec 6, 2013
    Posts:
    105
    Yeah I realised the issue lies in the 3d setting where my 2nd audio component has different value for min distance
     
  35. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    Cool, then you're good.
     
  36. Chris_Webb

    Chris_Webb

    Joined:
    Mar 18, 2014
    Posts:
    128
    Just wanted to say thanks for the Dynamic playlist addition!
     
  37. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    You're welcome, it was a good idea :)

    I'm just finishing up a feature I put off for a long time, which lets you put multiple actions into each event in Event Sounds. In other words, you can specify that when a collision occurs, do the following:

    1) Play a SFX.
    2) Fade the Playlist to .5
    3) Mute a bus.

    In that order.

    Before this wasn't possible even by adding multiple Event Sounds components to an object because you couldn't be sure what order they executed in. This is pretty powerful and will eliminate a lot of scripting. Here's a screenshot. Not quite finished though.

    $Capture.PNG

    Unfortunately when upgrading to the next version with this feature, all existing EventSounds settings will be lost and need to be recreated. I couldn't really get around that.
     
  38. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    Master Audio V3.4.6 will be live in about 20 minutes! Changelog:

    • Note: Please delete the Master Audio folder before upgrading to this version or some files may not be in the right place.
    • Breaking change: Added the ability to specify multiple actions to trigger in Event Sounds script for each event, which get executed in order when the event occurs. By "breaking change" I mean that any EventSounds settings you had set up before will be lost after upgrading. You'll need to set them up again. This was unavoidable. So take note of what you have before upgrading.
    • Fixed bug: SoundFinished callback in Variation didn't clear the subscription when calling it. This caused bugs when loading a Scene from the callback (3 callbacks occurred).
    • Added MutePlaylist, UnmutePlaylist and ToggleMutePlaylist methods to PlaylistController and MasterAudio.
    • Added Playlist Mute, Playlist Unmute and Playlist Toggle Mute Playmaker Custom Actions.
    • Added Playlist Mute, Playlist Unmute and Playlist Toggle Mute to EventSounds.
    • Changed normal logging of sounds (diagnostics) to info instead of warnings (white text).
    • Moved icon back to top-level Gizmos folder because it wasn't working for the EventSounds components.
     
  39. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    Hello users, I want to add a big feature to MA, and so far can't figure out how to do it. See my thread here, and let me know if you have anything helpful? I couldn't find anything at all on Google.

    http://forum.unity3d.com/threads/237422-How-would-I-get-a-list-of-all-AudioClips-in-the-project

    Actually that plugin I linked to in that post is basically what I'd like to add to Master Audio. But first I need to be able to get a list of all Audio Clips in the project. Thanks!
     
  40. PrisonerOfLies

    PrisonerOfLies

    Joined:
    Dec 6, 2013
    Posts:
    105
    hi jerotas, i wrote a script that sets the masterAudio mixer volume and playlist volume, the slider moved in the inspector but the audio volume is not affected, until i click on the inspector to refresh it. Does it have anything to do with setting the editor dirty everytime the volume is changed ?
     
  41. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    That's because you're modifying the public variables. That has no effect - they have to be public for the custom inspector to work unfortunately. You're the 3rd person to do this by the way. You need to modify the properties. The properties you want are: MasterVolumeLevel and PlaylistMasterVolume.

    Note: if it's not listed on the API website, don't use it :)
     
    Last edited: Mar 31, 2014
  42. PrisonerOfLies

    PrisonerOfLies

    Joined:
    Dec 6, 2013
    Posts:
    105
    ok solved it. thanks for immediate reply. :)
     
  43. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    No problem. It helps having seen it before a couple times :)
     
  44. deskinscraig

    deskinscraig

    Joined:
    Apr 1, 2014
    Posts:
    2
    Just beginning to learn Master Audio for a game I am doing the sound design for. Very impressed with its functionality so far. The things I would like to see more of are basically advancements on already existing features. For music ducking, it would be nice to have control over the length and curve of the attenuation. More in line with settings that exist on an actual compressor. I personally found the attack to be a little aggressive. Would also like to see min/max settings for randomized pitch, and volume.
     
  45. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    Good to hear. Unfortunately, at this point we are unlikely to change anything about bus and ducking features, since those will both be native once Unity 5 comes out. At that point we will remove our code for these, and add whatever's missing on top of it (like bus voice limits we anticipate). That's the plan. We'll retain a pre-U5 build for bug fixes.

    I'll take a look at min/max settings for randomized pitch and volume.
    Thank you for the feedback.
     
  46. deskinscraig

    deskinscraig

    Joined:
    Apr 1, 2014
    Posts:
    2
    Awesome thanks! Continuing to play with this, heres another request. Negative clip change delay time for looped chain groups. This is cool when you want to play multiple sounds in sequence, but you want one sound to play before the previous sound is complete. Im basically just digging through this thing so I may have more requests as I come across them.
     
  47. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    That one isn't feasible unfortunately. The code for chained loop is super complex and it relies on non-polyphony within the group. Also, you could get into weird deadlocks if I tried to code that, where the 2nd sound would finish before the first if it was really short.

    It doesn't mean we can't create some sort of stand alone script that could essentially do this. Actually a playlist controller can do this, but with crossfade. So maybe just use a Playlist Controller?
     
    Last edited: Apr 4, 2014
  48. Korindian

    Korindian

    Joined:
    Jun 25, 2013
    Posts:
    584
    Hi jerotas,

    Is it possible to get the Bus, Group, and Playlist Fade (and any other fade) Playmaker actions to fade in realtime, even when timescale = 0, by having a "Real Time" toggle?

    For example, the default Camera Fade Out Playmaker action has a "Real Time" checkbox which allows you to fade the screen while timescale = 0 by calculating the deltaTime from Time.realtimeSinceStartup for the fade.

    Am I correct that the fade caclulation is done in Master Audio's code, and not the Playmaker action?
     
  49. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,572
    Yes, none of the calculation is done in the Playmaker action. I'll take a look and see if this is possible.
     
  50. Korindian

    Korindian

    Joined:
    Jun 25, 2013
    Posts:
    584
    Thank you, it would be very much appreciated if it's possible to add that.