fix audio engine onPause crash; random patch generation