Godot Engine crash when Export with custom build template for Android

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By pengyou

I was following a tutorial of setting up a custom build for Android in Godot from this link. I am very sure that I have followed all the instructions, but godot engine always crash (white screen) without showing any error message, when i tried to use one-click deploy. The screen stuck at here:


I am using Godot 3.2.2. Anyone please help.

Have you tried waiting for a long time ?
It takes me almost 15 minutes to finish exporting.

scribbleboy | 2020-08-10 10:24

Releases · Shin-NiL/Godot-Android-Admob-Plugin · GitHub

version 3.0.1 of this plugin worked on Godot version 3.2.3 and 3.2.2. The game is no longer crashing. test ad appeared. I hope there will be no problems with original ads. The game crashes in versions 4.0 or 4.1.1. still in every version the program gives the following error:

Unicode error: invalid utf8

maxiproduksiyon | 2020-11-05 19:44

:bust_in_silhouette: Reply From: 2bits

I also had the same issue, but I got over that part by connecting to the internet while compiling, however after exporting my game to an android device it just crashes on startup. This happens only when I have something under “modules” admob or GodotGooglePlayBilling it’s all the same it crashes. If you find a solution around this please come back and share.

Hi , I am currently facing the same problem. I am trying to use the google admob plugin from [1]: GitHub - Shin-NiL/Godot-Android-Admob-Plugin: Android AdMob plugin for Godot Game Engine 3.2 or higher

I can export the game through the one click deploy but it just quits after opening.
Have you found a solution yet?

scribbleboy | 2020-08-10 09:55

Unfortunately I couldn’t resolve the issue so I downgraded to Godot 3.2 where I used Shin-Nil’s plugin from earlier this year. Everything works on 3.2. I think the issue with 3.2.2 is with the custom Template when it comes to the inclusion of modules. I was interested in using the new plugin system because I noticed Game Analytics has a Godot plugin targeting 3.2.2+. I guess I will wait for the release of Godot 3.2.3 soon, perhaps the issue will be resolved there.

2bits | 2020-08-10 15:43

Could you please tell me the version of the plugin you used for 3.2?

scribbleboy | 2020-08-10 15:50

So I downloaded the plugin on the 1st of march so that should be version 2.0.0. I had issues implementing it initially so I used this example https://godotlearn.com/godot-3-2-how-to-integrate-google-ads-admob-for-android/ , it work perfectly for my project.

2bits | 2020-08-10 16:29

Thank you , 2.0.0 worked in the demo. I need to check if it works in my project.
So thanks :heart:

scribbleboy | 2020-08-11 04:46

Alright the test ads work, but how do you use real ads?
I am planning to upload it to the playstore. So what should I do for that
I have already setup the export template , release keystore and all that.

scribbleboy | 2020-08-11 18:04

If you are using Shin-Nil’s example simply turn on “Is Real”, it’s a property of the Admob node. However if you are using this example "https://godotlearn.com/godot-3-2-how-to-integrate-google-ads-admob-for-android/ ", open the admanager.gd autoload script, at the top of that script find ‘var useTestAds = true’ and change that to ‘var useTestAds = false’

2bits | 2020-08-11 18:38

I am using Shin Nils plugin 2.0.0 just as you said. Also there is no admanager.gd. There is only a node (admob.gd) In the properties , there’s a variable isreal. I tried setting it to true and running the game. I had provided the the ad IDs from my admin account. But still test ads appear in the game. What should I do?

I read somewhere that you need to edit the AndroidManifest.xml file. Should I do that?

scribbleboy | 2020-08-12 04:52

Yeah perhaps try that. I have never edited the AndroidManifest for that version, only the recent versions because they require an App ID now, so you will probably have to include that as well. The admanager.gd is on the other example you won’t find it on Shin-Nil’s example

2bits | 2020-08-12 09:58

Same happened to me but I corrected by editing the manifest file

Deepak Jogi | 2020-09-06 17:13

Releases · Shin-NiL/Godot-Android-Admob-Plugin · GitHub

version 3.0.1 of this plugin worked on Godot version 3.2.3 and 3.2.2. The game is no longer crashing. test ad appeared. I hope there will be no problems with original ads. The game crashes in versions 4.0 or 4.1.1. still in every version the program gives the following error:

Unicode error: invalid utf8

Try this too. report to me.

maxiproduksiyon | 2020-11-05 20:06

:bust_in_silhouette: Reply From: pengyou

After help from mohazargo from here, I managed to custom export my game in android after waiting of 3 hours white screen (due to wifi speed not very good) which only happens at first built. My game does not encounter any issue while running in my phone.

If you having issue while running the game in phone, i would suggest run this command in cmd to start debug the game in yout android device
adb -d logcat GodotFan:V FAN:V godot:V *:S
*ps : not very understand what this command does, but it do help me debug my android game well in my phone.

Good luck guys.