MetaSounds RandomGet WaveAsset Array No Repeat Issues

I was hoping to get some feedback on a potential bug with the RandomGet WaveAsset:Array.

I’m trying to have a random footstep to playback from an array of 5 footstep sounds. I have seen the footsteps guides and have made a MetaSound with RandomGet functionality, and I have placed it in my MetaSoundSource with the Waves, but I noticed I was getting a lot of repeats in editor. To be safe I recorded myself saying numbers from 1-5 and put them in a Wave Array. I quite regularly get the same number triggering one after another. I’ve tried increasing the No Repeats from 1 to 2, and even up to 3, but it doesn’t stop the repeating issue.

I’ve attached a video of this happening to help debug.

Any help on the matter would be really useful :slight_smile:

It may be worth checking this at runtime, as i believe there was a bug a while back where in MSS it did this but not when played.

Another option is to use shuffle instead of random get, which offers different behaviour but may work for what you are after

Thanks for the suggestion Steve, and sorry for the slow reply. It’s been a busy couple of weeks and I only just got round to giving this all a try. Sadly, I was still coming across the same issue with Shuffle. There is the check box for ‘Enable Shared State’ on the Random Get that I hadn’t used before. Ticking this solved the issue and everything is working fine now.

I also encountered this problem ,RandomGet And Shuffle Cannot be repeated

There is also a different solution if you want to use Random Get. Try to use the Weights Input Array of RandomGet. Here I leave you a video I made about it:

Sadly this issue is still recurring in Ue 5.2. The solution of setting “Enable Shared State” to True did not work for me. I am setting up the random get in a metasounds patch. Also trying to use shuffle did not work either. I think this is a bug that needs to get looked at.

1 Like

For me the problem came from running the client and server under one process in the editor. Disabling run under one process in the multiplayer options and launching a separate server did the trick. Thanks for the replies!

Looks like Enable shared state works only in runtime, if you preview the sound in Metasound itself it doesn’t help.