Download

Android Build Fails - Crashes on startup

Hello - I’m currently in the process of building my game for Android. I recently finished getting iOS all setup.

I have once in the past (on 4.9.2) compiled a build for android - I’m now on 4.10.1 and compiling it.

I’m running into an error on development and shipping; the game simply crashes at startup.

Heres the log from logcat when starting the game: AndroidLog.txt (34 KB)

In particular, I think it might be these two errors that pop up is making the game crash (more of an assumption but not entirely sure):


12-16 23:41:45.067: E/MediaPlayer(32319): stop called in state 1
12-16 23:41:45.067: E/MediaPlayer(32319): error (-38, 0)

What should I be doing? Is there something else in the log that is brought up that needs to be fixed? If there’s any other information I can provide, I surely will as well! :slight_smile:

Thanks!

  • Lucas Govatos

You need to call mediaPlayer.start() in the onPrepared method by using a listener. You are getting this error because you are calling mediaPlayer.start() before it has reached the prepared state.

Hey there,

Could you please explain how to do this? I’m assuming that requires C++ unless its some other file? I’m currently doing a blueprint only project. I should mention I didn’t even think I was using the media player for anything - what is it used for exactly?