The AudioContext was not allowed to start

In my app i have button for sound start but if i click on it the mute button of babylonjs comes.
Is there any possiblity to make audio directly start if i click on the button?

      case "engine":

let audioContext = new (window.AudioContext || window.webkitAudioContext)();
function resumeAudio() {
  if (audioContext.state === 'suspended') {
      audioContext.resume().then(() => {
          console.log('AudioContext resumed');

You have to disable the default unlock and call audioEngine.unlock() from your button/user interaction

1 Like