Because of following audioplayers exception:
Error: PlatformException(Unexpected error!, null, java.lang.IllegalStateException at android.media.MediaPlayer._setDataSource(Native Method)
at android.media.MediaPlayer.setDataSource(MediaPlayer.java:1305)
at android.media.MediaPlayer.setDataSource(MediaPlayer.java:1288)
at android.media.MediaPlayer.setDataSource(MediaPlayer.java:1242)
at android.media.MediaPlayer.setDataSource(MediaPlayer.java:1218)
at android.media.MediaPlayer.setDataSource(MediaPlayer.java:1185)
at xyz.luan.audioplayers.WrappedMediaPlayer.setUrl(WrappedMediaPlayer.kt:37)
at xyz.luan.audioplayers.AudioplayersPlugin.handleMethodCall(AudioplayersPlugin.kt:62)
at xyz.luan.audioplayers.AudioplayersPlugin.onMethodCall(AudioplayersPlugin.kt:37)
at io.flutter.plugin.common.MethodChannel$IncomingMethodCallHandler.onMessage(MethodChannel.java:233)
at io.flutter.embedding.engine.dart.DartMessenger.handleMessageFromDart(DartMessenger.java:85)
at io.flutter.embedding.engine.FlutterJNI.handlePlatformMessage(FlutterJNI.java:818)
at android.os.MessageQueue.nativePollOnce(Native Method)
at android.os.MessageQueue.next(MessageQueue.java:332)
at android.os.Looper.loop(Looper.java:168)
at android.app.ActivityThread.main(ActivityThread.java:6878)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:547)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:876) , null)
And remove BGM Settings.
Stack trace:
package:flutter/src/services/message_codecs.dart 581:7
StandardMethodCodec.decodeEnvelope package:flutter/src/services/platform_channel.dart 158:18
MethodChannel._invokeMethod
===== asynchronous gap ===========================
dart:async/zone.dart 1294:19
_CustomZone.registerBinaryCallback dart:async-patch/async_patch.dart 51:8
_asyncErrorWrapperHelper package:sanmill/services/audios.dart 79:19
Audios.playTone. package:stack_trace/src/chain.dart 94:24
Chain.capture. dart:async/zone.dart 1354:13 _rootRun dart:async/zone.dart 1258:19
_CustomZone.run dart:async/zone.dart 1789:10 _runZoned dart:async/zone.dart 1711:10
runZoned package:stack_trace/src/chain.dart 92:12 Chain.capture package:sanmill/services/audios.dart 78:11
Audios.playTone