-
-
Notifications
You must be signed in to change notification settings - Fork 21.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Splash Image on Android not showing #62863
Comments
This could have something to do with your screen resolution or Android version. |
i am on android 13 and splash screen don't show up |
I also have this problem with Godot 4.1, it is just a black screen, what is the solution? :) |
Don't use splash screen from project setting, make your splash screen as a new scene and load it as a main scene, attach a script to your splash screen scene and also add timer() node, put as much second as you want to show your splash screen on timer properties and use timer node timeout() signal in the splash screen scene script to change the scene to game menu, get_tree().change_scene_to_file("res://scenes/main.tscn") |
Even though I have a custom splash, the problem is that the built in project settings splash will appear faster than a custom one. In the end this just needs to be fixed. I need an instant picture to display at startup, then, the animated splash begins right after. |
No, the problem is that, the black screen appears for let's say 5 second even before any scene is loaded. I had a Start.tscn instead of Main.tscn, and I did get_tree().change_scene_to_file("res://scenes/main.tscn"), for your information. |
My game shows a screen with the launch icon for about 3s then briefly flashes a completely black screen for about 0.5s before showing my first scene. I'm not sure which of my project settings gave me this behavior, but it's good enough for Google to approve the app. |
What Godot version are you using, buddy? Is that Godot 4.x that requires Vulkan support? Just wondering. And did you simply export AAB file from Godot, or you had any additional steps like this for example: https://github.com/MiqueiasDevGames/Godot-SplashScreen-Android-12#splash-screen-godot-android-solution (the sample Godot code in for Godot3.x so I am lazy to try) or https://github.com/MiqueiasDevGames/export-godot-to-android-without-gradle-32bits-and-64bits? |
Godot 4.0.3 with the mobile renderer. I didn't do anything after adding the build templates for Android besides setting my singing key, min_sdk=29, and the main launcher icon (no adaptive). I export to aab using the Godot export menu, upload that Google Play and they usually approve new builds within 3 hours. My very first build took about 2 days to be approved. I only build for "arm64-v8a". I don't know if that makes a difference. |
Oh ok, thanks for your info, that is what I did but I got the black screen for 5s, so :( Luck was with you lol. |
It might be that my first scene is really simple, no shaders or particles or anything. It's just a screen with a background and a few buttons. The game really starts when tapping on the "Start" button and there is a bit of a pause there on mobile (it's really fast on desktop), probably as shaders get compiled and stuff. I want to play with async preloads to see if I can reduce that pause. |
Godot 4.x doesn't support asynchronous shader compilation yet, so you have to show elements that cause shader compilation for 1 frame before gameplay occurs. (This can be done behind a solid ColorRect.) |
Google has now approved my app. I resubmitted it and it seems like a different person reviewed it this time, and they were able to wait for 5 seconds :) I also tried creating a simple 3D game in Godot to test it, and saw that it loaded much faster (the black screen only appeared for 1 or 2 seconds, instead of 5 seconds). So, it looks like Godot had to load something in my ‘true’ game, which I haven’t figured out yet, even though my Start.tscn is empty as it will load Login.tscn or Main.tscn later. I hope Godot can solve this problem to make it simpler for everyone. UPDATED (2023-Aug-12): I have now noticed that right after I downloaded and installed my game from Google Play and ran it for the first time, the black screen was there for 5 seconds before the UI started to show. However, if I killed the game (app) and ran it again, it only took 2 seconds to start seeing UI screens. I have no clue what happened. :) |
UPDATED (2024-Jan-01): I found the right code to solve this problem: The Start.tscn with only one TextureRect (to display a splash image) is used as the first scene instead of Main.tscn, then this start scene will load Main.tscn with the following code: func _ready():
Start.tscn is loaded very quickly, and regardless of how resource-intensive Main.tscn is, the first scene (Start.tscn) will remain until Main.tscn is fully loaded and switched to. I used this technique for some of my Godot games, like this: A 2D game The same technique is applied when there is a Login scene. While the Main.tscn is loading, the Login scene remains visible with a "Loading game…" message, like this: A 3D game |
AFAICT this issue report refers to the built-in splash image functionality. Your suggestion is a workaround but does not affect the actual problem. |
Godot version
3.5 rc6
System information
Windows 11
Issue description
For some reason the splash image has stopped showing on android. I have included a simple project that should show the Godot Icon at start. It will on windows and will not on Android.
BTW, The "just show a background color" does work.
I don't know how far back this problem started but it was broken back in 3.4.4 official as well. Hopefully there is an easy fix.
Steps to reproduce
Run the included project. No splash screen image on Android.
Minimal reproduction project
SpashAndroid.zip
The text was updated successfully, but these errors were encountered: