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. Dreamcube017

    Dreamcube017

    Joined:
    Dec 20, 2009
    Posts:
    252
    Thanks for the response!

    Darn, hmm. Alright I will ask over there. I just wanted to make sure I didn't have a wrong setting checked or something. I will do a few more tests to see what's going on. Thanks.
     
    jerotas likes this.
  2. BrianND

    BrianND

    Joined:
    May 14, 2015
    Posts:
    79
  3. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    Which dictionary are you referring to? And which problem are you trying to solve? I'm unaware of the problem. Continue in IM or email please.
     
  4. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    The performance improvement has been done for the next update :)
     
  5. BrianND

    BrianND

    Joined:
    May 14, 2015
    Posts:
    79
    Awesome thanks so much jerotas.
     
  6. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    No problem.
     
  7. cloudcamaleoniv

    cloudcamaleoniv

    Joined:
    May 17, 2013
    Posts:
    57
    I'm getting this error in my Visual Studio Community 2015 with Resharper 9.

    The compilation works just fine, even the auto completion is working, but Visual Studio / Resharper complains nevertheless

    What can I do?
     

    Attached Files:

  8. cloudcamaleoniv

    cloudcamaleoniv

    Joined:
    May 17, 2013
    Posts:
    57
    Restarted Visual Studio, Restarted Unity, Cleared Resharper Cache. Nothing was working. Went to the kitchen, got a cup of coffee, returned, the issue disapeared. Don't know what the hell fixed it. But it is now fixed.

    Anyway, do you know what was causing the issue? In case it happens again. Thanks.
     
  9. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    I think it wasn't loading all the projects in the VS solution. Probably didn't load "plugins". Most likely restarting VS fixed it.
     
  10. MythicalCity

    MythicalCity

    Joined:
    Feb 10, 2011
    Posts:
    413
    Hi, I'm encountering an issue where the Event Sounds script will sometimes not play the sound but the green bar shows the clip playing and in the console when I log sounds it shows up as MasterAudio Cueing only child of ButtonSound. The sound is attached to ugui buttons. It works about 75% of the time but sometimes there is just no audio played. I think this also only happens when I am clicking on buttons that are deactivated right after they are clicked (ie: switching to a different menu). For buttons that do not get deactivated the sounds work reliably all the time. This used to work okay with an earlier version of Master Audio from around Feb of this year.

    Here are my settings:
    https://www.evernote.com/l/AAMaLbQdr1JBhp1fwkEXt1YIrFMTwYeLMOw
    https://www.evernote.com/l/AAPIKC2Fic1CGLsomUpCwoncHdOh38epiQ4
     
  11. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    Check your "Caller Despawned Mode" for the Sound Group. If it's set to anything except "None", that may be why (which is intended behavior). If you don't want it to do that, set it to "None", which is the default.

    If that's not the problem, then...

    I just fixed a bug for things saying they're playing and they're not. It happened when the random pool for a Sound Group refilled but at least one Variation was still playing. After that sometimes it wouldn't try all remaining Variations correctly. This may be what you're seeing. If you want to send me an email I'll send you the latest beta and you can see if it's fixed or not.
     
    Last edited: Sep 2, 2016
  12. f1ac

    f1ac

    Joined:
    May 23, 2016
    Posts:
    65
    My impressions the moment I imported the asset: cluttered, I don't know where to start.
    My impressions after an hour has passed: surprisingly great stuff :)

    And a few feature requests:
    - To add multiple files to a group/playlist I need to lock the inspector. It would be great to be able to add whole folders to avoid this.
    - It's a pain to change settings for playlist songs/group sounds individually. It would be great to have 'bulk edit' functionality, like in the 'group mixer' -> 'group control' section.
    - Occlusion needs an 'offset hit point towards listener' slider. Let's take a common case of sounds emitted from two objects colliding, like footsteps. Usually one wants to pass the hit point to the MasterAudio.Play() method. And most of the time MasterAudio occludes these sounds, because raycasts hit the ground. It would be great if MasterAudio had an option to offset this hit point towards the listener.
     
  13. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    Sorry to hear that you thought it was cluttered. We were adhering to the "where to store your editor extensions" sticky on this forum whereas most plugin authors do not. i.e. Gizmos, Editor Default Resources and Plugins folders should be used, and most certainly not the main Assets folder since that's bad for compilation times (we include source code so this is especially important). If you have any suggestions aside from that, we are listening.

    1) Add a whole folder: I don't think there's an easy way to do this, whereas I can detect files you have actually selected rather easily.
    2) I believe you've missed the "Bulk Group Changes" checkbox just above the first row of the Group Mixer. Turn that on, select any number of rows in the mixer and bulk make changes such as volume / mute / bus change etc. For songs, I don't see a good way to allow that and have the UI still look good unfortunately, since each song's fields take up many rows. You can always clone the song then change the clip assigned, which may be faster.
    3) Offset towards listener sounds like a good idea, I'll add that as a global option.
     
  14. f1ac

    f1ac

    Joined:
    May 23, 2016
    Posts:
    65
    Well, I meant the inspector interface is overwhelming at first, you know, like when you open an audio software with hundreds of controls. But that's just first impressions, it goes away quickly :)

    1) About the folders - yep, just tried it, it seems folders are represented with 'DefaultAsset' type, which have just the folder name among properties, and not the path. Will look into it further.

    2) I have actually mentioned "Bulk Group Changes" checkbox as an example of the functionality. I meant bulk edit sounds within "Master Audio Group" script (and music within the playlist settings). But I see what you mean, too many rows. However, usually one wants to change settings for all the items at once. For example make them loop or enable events. How about making a virtual song/sound, which will represent whole playlist/group? Or 'override individual settings' panel with basically the same content. Or just buttons '(un)loop all', 'set origin for all', 'fire xx event for all' etc.

    3) Thanks!
     
  15. f1ac

    f1ac

    Joined:
    May 23, 2016
    Posts:
    65
    Ok, found a way to get all the AudioClips from a folder dragged to inspector.

    For example in MasterAudioInspector.cs line 1361:
    Code (CSharp):
    1. foreach (var dragged in DragAndDrop.objectReferences) {
    2.                                 if (dragged is DefaultAsset)
    3.                                 {
    4.                                     string[] assetPaths = AssetDatabase.FindAssets("t:AudioClip", DragAndDrop.paths);
    5.                                     foreach(string assetPath in assetPaths)
    6.                                     {
    7.                                         Debug.Log(AssetDatabase.LoadAssetAtPath<AudioClip>(AssetDatabase.GUIDToAssetPath(assetPath)).name);
    8.                                     }
    9.                                 }
    Works like a charm and prints all the AudioClip names :)
     
    Tinjaw likes this.
  16. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    Cool, have added #1 to roadmap then with your example code below.
    #2, added to roadmap for songs. Groups already have a bunch of copy buttons you can use for this when you're on the Sound Group (expand the Copy Settings section).
     
    Tinjaw likes this.
  17. SteveJ

    SteveJ

    Joined:
    Mar 26, 2010
    Posts:
    3,046
    I've just spent the evening switching The Deep Paths over from SoundManagerPro to Master Audio. I've run into an issue though that's baffling me. Hoping someone can help.

    Check out the video for a demo.

    I'm finding that some sounds just don't play. Or at least, they DO play, but you can't hear them.

    You can see here in the video that the chest sound is "playing" when I open and close the chest, but you can't actually hear it. The code I'm using to fire it is:

    Code (csharp):
    1.  
    2. MasterAudio.PlaySound3DAtVector3AndForget("ChestMetal", MyTransform.position);
    3.  
    (MyTransform is the chest's Transform component, set in Awake())

    This is also happening on some other objects, but not ALL of them. Very odd.

    Thoughts?

     
    Last edited: Sep 15, 2016
  18. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    Welcome!

    To see if it really is playing or not, make the sound loop so you can watch the active voice count on the mixer.

    If it's not playing, turn on Log Sounds for that Sound Group and it will tell you why in the Console (voice limit reached, etc).

    If it is playing, I would check the volume field on the actual Audio Source that is playing. Is it what you expect it to be? Which should be:

    Volume Percentage * Sound Group volume * Bus volume * Master Mixer Volume.

    If not, then you may have set a persistent volume or other volume control without realizing it?

    If it is what you expect, I'd check the max distance on the Audio Source.

    If that's fine, I'd set the sound to loop so you can move the Audio Listener around in the Scene while it's playing and see if that has effect.

    Let me know if you don't figure it out! I'm sure it's some small detail.
     
  19. SteveJ

    SteveJ

    Joined:
    Mar 26, 2010
    Posts:
    3,046
    Alright - I'll take a look tonight and see what I can figure out. I'm pretty much running out-of-the-box though. I didn't do anything other than drag a bunch of sounds over, set the bus name on them, and then add the code to play them.
     
  20. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    Then I'd suspect it's voice limit stuff and they're not playing because of it. Sound Groups will default to only having a max of 1 voice per Sound Group. You need to set the field for that, the Console will tell you.
     
  21. SteveJ

    SteveJ

    Joined:
    Mar 26, 2010
    Posts:
    3,046
    Each individual "sound" essentially becomes a sound group, right? At least when you just drag them all in like I did?

    There are some where I've brought in variations, but this chest sound is just one sound. And if that's it's own group, you would never need more than one voice unless you were opening two chests at once... is that right?
     
  22. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    With completely stock settings, you are correct. Unless you had set it up to loop or something.

    I gave you a couple other things to check as well. I'm sure we'll figure it out.
     
  23. SteveJ

    SteveJ

    Joined:
    Mar 26, 2010
    Posts:
    3,046
    Okay - the plot thickens. It works fine when I turn off "Use Occlusion"...
     
  24. SteveJ

    SteveJ

    Joined:
    Mar 26, 2010
    Posts:
    3,046
    I think I'm all good. I set the layer mask to my environment layer (which includes all the walls) etc and it's now playing the sounds for those objects. Guessing some Player collider was getting in the way or something and making it think it was blocked.

    In other news though... since installing Master Audio, I'm getting these constantly when exiting play mode. Has NEVER happened previously. Have you had any similar reports?

     
  25. SteveJ

    SteveJ

    Joined:
    Mar 26, 2010
    Posts:
    3,046
    Sorry to be spammy - it just helps me to post things as I come across them. So occlusion is definitely doing something weird. For me the "Environment" layer is the walls, roof, floor, etc.

    See this video for a weird example. Can't figure out why the audio plays on one of the buttons but not the other when occlusion is enabled.

    EDIT: Sorry I'm an idiot - recorded that without audio :) Will do a new video and edit the post.

     
    Last edited: Sep 16, 2016
  26. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    Crashing: In all honesty, I think once about a year ago, but it was never proved, only suspected. Never heard if it resolved itself or what. You'll need to go through the crash logs if you want to find out what it is for sure. We of course use Master Audio on all our games and this never happens...

    Now, occluded sounds shouldn't be completely inaudible, just rolled off on the high end.
     
    Last edited: Sep 16, 2016
  27. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    You know that in Scene view you can see the actual occluded and non-occluded ray casts as they happen right? That's key in solving things like this. Green is non-occluded, red is occluded.
     
  28. SteveJ

    SteveJ

    Joined:
    Mar 26, 2010
    Posts:
    3,046
    Video including the scene view. It's a bit weird huh?

     
  29. SteveJ

    SteveJ

    Joined:
    Mar 26, 2010
    Posts:
    3,046
    Sorry - one more. There was some other debug raycasting enabled in that last one.

    This is a 3 button set that opens the door. Once resolved, the buttons play the "Negative" sound (indicating they're disabled). What's interesting is that the problem button works playing the Negative sound, but not the PushButton sound.

     
  30. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    I'm really not sure what you think you showed me in that video...I saw zero red (occluded) lines and I hear nothing that sounded occluded either. Working properly?
     
  31. SteveJ

    SteveJ

    Joined:
    Mar 26, 2010
    Posts:
    3,046
    Nevermind. I'm rolling back to SoundManagerPro for this one. Master Audio into the new games. I think I made a mistake trying to make a change this late in the project.
     
  32. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    Ok, sorry to hear that. You of course won't get any occlusion and tons of other features, but maybe you don't need them right now.

    Really the visible raycasts for occlusion should be able to help you troubleshoot any problem especially if you set the sounds to loop so you can tweak objects in the Scene. We were able to get things working perfectly for our next game
     
  33. silentneedle

    silentneedle

    Joined:
    Mar 14, 2013
    Posts:
    280
    Hey jerotas,

    what is the preffered way to load sounds/music through an asset bundle? We currently have an "Audio" scene which includes the Master Audio GO, this scene gets loaded additive as streamed scene asset bundle. So far this works fine, but it feels a little bit hacky because the usual approach would be to load an prefab from an normal asset bundle (no streamed scene).

    Could the Dynamic SGC's used for that?
     
  34. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    We actually don't have any support for Asset Bundles, and since I've never used them myself, I can't really offer any advice. I understand that some of our users have written their own code for them, but I haven't looked at that code.

    So you're basically on your own there, sorry.
     
  35. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    Missed this part. Could the DSGC's be used for what exactly? Describe in more detail what you mean.
     
  36. gypsycamp

    gypsycamp

    Joined:
    Sep 2, 2015
    Posts:
    9
    Hey, I have question why fade out all of sound only fades one variation i a looped chain group with many clips, next time a variation play it will do that with default volume of group, I don't really want to use stop of all of sound since it ends the group straight of without fade. I have tried having global fade settings set to stop as well. Will not work i this case.
     
  37. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    Please describe more fully what you are trying to do. Fade out all of sound only fades currently playing clips, nothing that hasn't started playing yet.
     
  38. gypsycamp

    gypsycamp

    Joined:
    Sep 2, 2015
    Posts:
    9
    Ok, If I run Fade out all of sound on a group that is set to looped chain, I expect the currently playing sound to fade and then the group to stop, not play the next clip un faded so to speak, and continue looping. Stop of all of sound will do this but without the fade, and i do need the fade to make it sound pretty!
     
  39. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    2 days to do it:

    1) Open Advanced Settings / Fading and check the Variations box. That means that whenever a Variation fades to 0 volume, it will stop playing, although it may not work if during the fade the Looped Chain starts another clip because the previous one is over.

    2) Instead use this code:

    Code (csharp):
    1.  
    2. MasterAudio.FadeSoundGroupToVolume("SoundGroupName", 0f, 1f, delegate {
    3.       MasterAudio.StopAllOfSound("SoundGroupName");
    4. });
    5.  
    6.  
     
  40. gypsycamp

    gypsycamp

    Joined:
    Sep 2, 2015
    Posts:
    9
    Much obliged, will try it!
     
    jerotas likes this.
  41. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    Add a "silence" Variation with no Audio Clip and give it an appropriate Weight for the percentage you want.

    There's also a Sound Group Template called "50% chance play" (and 25% one too) you can use when creating the Sound Group which will set up the silence variation for you. Then you just tweak the weights.

    Then you can set up a Linked Group if you want the one Sound Group to play whenever the other is requested. Linked Group Mode defaults to "None" on each Sound Group but you can add however many links you like.
     
  42. gypsycamp

    gypsycamp

    Joined:
    Sep 2, 2015
    Posts:
    9
    Hello, will it be possible to have groups in folders in new versions of master audio, I am running fairly large projects and especially with lots of dialogue, it would be great to have everything more neat and organized.
     
    Last edited: Oct 20, 2016
  43. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    You can of course create folders in Project View, but Hierarchy and the Inspector will not show the folders. This is not going to change. However, to make it easiser to work with a lot of Sound Groups these features were added years ago:

    1) Filter by Bus. If you are assigning many groups to a bus, this is invaluable. If you're not using buses, you should just for this feature if not others.
    2) Text Group Filter. Type a partial name here and it will filter out all Sound Groups that don't match what you type. You can consider naming Groups in your "folders" with a common prefix or other naming scheme that makes it easy to use this filter.
     
  44. Exbleative

    Exbleative

    Joined:
    Jan 26, 2014
    Posts:
    211
    Hi, I'm having an issue where Dynamic Sound Groups are adding events to the main Master Audio object, but then not removing them properly. I have Master Audio set to persist, and on the Dynamic SGC I've set auto removal of items. Does item = an event?

    I'm playing the game in-editor, watching the Master Audio game object, where I can see my custom events from the DynamicSGC get added, and then when I press stop, I see them removed briefly before they reappear.

    When I go to play the game again, of course, I get the duplicate event error.
     
  45. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    I've never seen that happen, but I don't use the "Save Runtime Changes" option. Are you using that?

    Items are everything. Playlists, Sound Groups, Custom Events, and Duck Sounds.
     
  46. Exbleative

    Exbleative

    Joined:
    Jan 26, 2014
    Posts:
    211
    Yeah I am - I guess it's saving the fact that the events have added to the MA object, makes sense. Just turned it off and the problem is solved. Cheers!
     
  47. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    Yeah it makes sense...but it sucks. I'll put it on the roadmap to see if there's a clever way to fix this, but it will be awhile before I get to it.
     
    Exbleative likes this.
  48. Exbleative

    Exbleative

    Joined:
    Jan 26, 2014
    Posts:
    211
    Great, sounds good.

    Somewhat related, I'm trying to do a simple "Group Played Event" using a custom event on a sound group within my DSGC. My problem is, I'd like this custom event to be on my DSGC, however I can't find it in the drop down, and directly entering the name in that field just results in "Custom event found no match". The only way I can fix this is to create that custom event on the main Master Audio game object.

    Couldn't see any limitations explained anywhere in the docs or in forums. Have I missed something?

    Thanks!

    *edit just noticed that while I get a 'not found' error, if I just hit play, the DSGC does find it and use it, and the custom events do appear in the drop down during play
     
    Last edited: Oct 24, 2016
  49. jerotas

    jerotas

    Joined:
    Sep 4, 2011
    Posts:
    5,350
    Where do you get the error from? Which script? Please paste the stack trace here from the Console.

    Yes, EventSounds can only find Custom Events in DGSC's that are in the Scene. But you can paste a name of any others and they will work.
     
  50. Exbleative

    Exbleative

    Joined:
    Jan 26, 2014
    Posts:
    211
    From both DynamicSoundGroupCreator and DynamicSoundGroup.

    I don't mean an error logged in the console, I'm talking about the red ! icon in:
    "Fire 'Items Created' Event" in DynamicSoundGroupCreator and "Group Played Event" on DynamicSoundGroup, which shows red ! error icon + text of "Custom event found no match, type in or choose one".

    It makes it seem (to me at least) that typing text in won't work. I've entered text and there's a red error icon, so that won't work. Not sure why this can't look in the DSGC custom events and see it there. Regardless it's all working so I'm not too fussed.
     
unityunity