I think I have about 5 MetaSound tutorials on UE Hub at this point, including the Using Presets one . Ironically I think the one thatâs most help you is still in review.
Okay, so like, I actually think itâs worth backing up and making sure you understand what all those nodes are doing. Usually when I work with stuff Iâm less familiar with, I start with âdoes this simple usage do what I expect.â So like, I actually think it would be worth trying to get steps like âloop one sound 20 timesâ working before trying to tackle the giant picture, because those are easier to build off of. MetaSounds can do a lot more things than Sound Cues can, but partly because it offers so much more control, it takes a bit more effort to explain to MetaSounds what exactly you want it to do.
That said, I am 90% certain putting ArrayIndex in RandomGet is not doing what you want. Thatâs not an Array Index input youâre connecting it to, itâs a Seed input, which you probably donât need to worry about at the moment. Nor is the way youâre using the Shuffle command - you arenât ever telling it to actually Shuffle. I really recommend putting nodes like this in the simplest context possible, until you are sure you understand what they do. And read the tooltips! There should be tooltips both on the node as a whole and on each input and output: theyâre sort of like internal documentation, and in fact a lot of node-specific documentation is pretty much just copying and pasting the tooltips.
(As a very brief summary of Random Get - itâll pick a new random number each time itâs triggered. So, if you want the Wave Player to play the same sound it did last time, you can just not trigger Random Get again. I.e., this will play you ten of the same random sound in a row:
But I strongly recommend not just copying and pasting it, but trying to spend time to understand why itâs behaving the way it is. I.e., move things around, take things out, make sure itâs still behaving the way youâd expect it to. In particular, Iâd pay attention to the difference between the âOn Triggerâ connection and the âOn Resetâ connection.)
Thank you so much for your advice, it helped tremendously!
Ebuch was able to help me with the random elements, this was the other part of the solution. Randomized Loops - #6 by ebuch
Here are a few minutes of output from the procedural percussion generator. There are a total of 531,441 possible combinations.
Itâs mostly the way Iâd like it, just gonna start playing with metasounds more and seeing what can be done. Plan on adding some electronic elements with built-in sound generation.
Since this thread is pretty fresh, I just wanted to chime in here to say that @lantz.anna_1 you have been tremendously helpful for me as well! I just made a procedural song player using some of the help you gave here
Hereâs what I have, Iâm curious if you have any thoughts / comments / anything Iâm doing here that I could be doing better/worse
I am having trouble loading new SoundWaves into my metasound. I am succesfully changing floats/ints using this method. But maybe the Set Wave Parameter is not functioning? Is anybody else able to dynamically load soundwaves into their metasound?
The reason it canât be in a preset array is that I am using SoundWaves recorded by the player in game.
Turns out Set Wave Parameter is only for SoundCues. So donât use it with MetaSounds. Instead use Set Object Parameter. And donât forget to also re-trigger the metasound after loading the new wave. Phew!
For any future visitors to this threadâSet Wave Parameter does in fact work with MetaSounds. Iâm not sure why it doesnât work in @Bradicalâs setup, but I have had no issues using it for mine.
I believe your MetaSound has to be triggered before using Set Wave Parameter (or any other âSet Parameterâ function, for that matter).
Edit: Adding more to this post for additional clarity and helpfulness.
I have been trying to get this example to work but the Play Wave trigger wont connect , it says it will cause a loop! lolâŚvery frustrating when a loop is precisely what i want
update: NM⌠it was the delayed get âŚnow i get it got a nice 3-layer music piece i had prepped running great now! thx!
I assume you created the MetaSoundSource variable and set you metasound asset as the default value. But you need to add an âaudio componentâ to your blueprint or run the a function like âSpawn Sound At Locationâ to create an instance of an audio component that is using your meta sound asset.
When you drag off from the audio component reference variable the search should give you proper nodes. Also be sure to have the âcontext sensitiveâ checkbox activated next to the search bar.
before you fall into that trap: you canât call the default OnPlay trigger in the meta sound, use the âplayâ function for the audio component. Only input triggers you created can be used with the âExecute Trigger Parameterâ.
Just for clarification:
Look into Blueprint Interfaces. The envelopes indicate that the node is an interface message function. You can throw any object in the Target input and it will try to find the needed interface class on that object. If your target object doesnât have the interface added, nothing will happen.
The Yellow input demands an object that is guaranteed to have the right interface class added. So you canât even put an object reference in there that doesnât have the interface.
My understanding is that a message function just tries to cast the object to the interface class and calls the function. You can do the same with a âcast toâ node and executing the function with the yellow input node.