Shathrem

Villager
Member
Joined
May 9, 2014
Messages
7
Reaction score
2
First Language
English
Primarily Uses
Hello,

So I have successfully used two methods in exporting my game to an APK and install it on my phone, using two methods, Android Studio and Website to APK Builder, however I ran into a weird issue, in which the game screen is black while the music plays, and I have to click on the left side of the screen in order for the game to load in normally.

Surprisingly though it ran better than when I did this with MV, but this issue is very disturbing and discouraging.

Would appreciate if someone can help me with this.

Thanks.
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
33,344
Reaction score
8,388
First Language
German
Primarily Uses
RMMV
that is not enough info to even guess what it could be as there could be too many different causes.

for example if you are using parallax mapping, then the parallax pictures might be too big to be loaded without problems. Or it could be a problem with a plugin not optimized for mobile. Or it could be a problem with that specific phone - on how many different devices have you tested the apk?

and so on...
 

Dev_With_Coffee

Veteran
Veteran
Joined
Jul 20, 2020
Messages
680
Reaction score
321
First Language
PT-BR
Primarily Uses
RM2k3
Hello!
This could be due to some permission not being given in the APK XML.
But if the music started it's because you must be using some plugin that doesn't work with the outdated WebView or your Android version.

Test by the browser (Chrome) of the cell, follow the instructions of the official manual of the RMMV:

Good luck
 

Shathrem

Villager
Member
Joined
May 9, 2014
Messages
7
Reaction score
2
First Language
English
Primarily Uses
that is not enough info to even guess what it could be as there could be too many different causes.

for example if you are using parallax mapping, then the parallax pictures might be too big to be loaded without problems. Or it could be a problem with a plugin not optimized for mobile. Or it could be a problem with that specific phone - on how many different devices have you tested the apk?

and so on...
Hi, I wasn't using any plugin, I Simply wanted to test out to see if the export would work as intended, I have just exported a sample game and when I open it with my Android Phone, The title music Plays out with a dark screen until I left tab on the screen and then the game loads, I have tested this on 2 phones and 5 different Android Studio Emulators.

Hello!
This could be due to some permission not being given in the APK XML.
But if the music started it's because you must be using some plugin that doesn't work with the outdated WebView or your Android version.

Test by the browser (Chrome) of the cell, follow the instructions of the official manual of the RMMV:

Good luck
Hi, Can you elaborate on the APK XML permissions?, I wasn't using any plugin and simply exported a test game to see if the Android version would work as intended, testing it via Chrome works, but my intention is to port it to android as an APP.
 

Dev_With_Coffee

Veteran
Veteran
Joined
Jul 20, 2020
Messages
680
Reaction score
321
First Language
PT-BR
Primarily Uses
RM2k3
During this week I won't have time to access my computer to do the tests and be sure.
I assume that needing to tap the screen to start the game is like when a video or music starts to pause when loading a webpage.

Download some of these games and check if they all have the same problem:

Then tell me if any of them worked. So that together we can find out how to solve this problem and if it really happens on any device or just a few.
 

Shathrem

Villager
Member
Joined
May 9, 2014
Messages
7
Reaction score
2
First Language
English
Primarily Uses
During this week I won't have time to access my computer to do the tests and be sure.
I assume that needing to tap the screen to start the game is like when a video or music starts to pause when loading a webpage.

Download some of these games and check if they all have the same problem:

Then tell me if any of them worked. So that together we can find out how to solve this problem and if it really happens on any device or just a few.
Hi, These have been developed with MV, it works alright and have no issue, I have also tested MV and it works out fine, but somehow MZ is not working as intended with the issue mentioned above.

Thanks!
 

Dev_With_Coffee

Veteran
Veteran
Joined
Jul 20, 2020
Messages
680
Reaction score
321
First Language
PT-BR
Primarily Uses
RM2k3
You were not clear to being developing with RMMZ.
Probably some moderator mobile your topic.

I already know what is leaving your game on hold when starting, RMMZ games are paused when they leave focus, your webview may be concentrating on body body and not on the screen.
So when you click the game Canvas resumes.

I'll Try to Compile Today Later and Test on An Android 7 (7.1.2 with Virtual Machine) and later I'll try in a 5.0 (Fisical Device).

Sorry for my possible English mistakes, it's not my first language.

Edit 1:
I used the site for WebSite APK Builder (Free Version), I tested on Android 7 and it worked normal, remembering that I did not put any plugin and made no modification in HTML.

Try this, include the following attribute on Body Tag:
onload="window.focus()"

Thus:
HTML:
<body style="background-color: black" onload="window.focus()">
 
Last edited:

Shathrem

Villager
Member
Joined
May 9, 2014
Messages
7
Reaction score
2
First Language
English
Primarily Uses
You were not clear to being developing with RMMZ.
Probably some moderator mobile your topic.

I already know what is leaving your game on hold when starting, RMMZ games are paused when they leave focus, your webview may be concentrating on body body and not on the screen.
So when you click the game Canvas resumes.

I'll Try to Compile Today Later and Test on An Android 7 (7.1.2 with Virtual Machine) and later I'll try in a 5.0 (Fisical Device).

Sorry for my possible English mistakes, it's not my first language.

Edit 1:
I used the site for WebSite APK Builder (Free Version), I tested on Android 7 and it worked normal, remembering that I did not put any plugin and made no modification in HTML.

Try this, include the following attribute on Body Tag:
onload="window.focus()"

Thus:
HTML:
<body style="background-color: black" onload="window.focus()">
Hello,

Im sorry that I thought I specified it when I mentioned that I tried exporting in MV and it works, I have added the HTML tag you have mentioned, however it did not work, my phone in Red Magic 5G, I tried with other emulators and the same result came :(.

BTW, your English is great! :).
 

Dev_With_Coffee

Veteran
Veteran
Joined
Jul 20, 2020
Messages
680
Reaction score
321
First Language
PT-BR
Primarily Uses
RM2k3
If the game is not too heavy, could you send me already compiled in the APK via private message?

My only Android 5 (5.1) smartphone is still charging due to a battery issue. I have to wait to reach at least 80%

Edit:
I tested it on Android 5 and it worked, it's probably some function of the Core version you're using.
 
Last edited:

Shathrem

Villager
Member
Joined
May 9, 2014
Messages
7
Reaction score
2
First Language
English
Primarily Uses
If the game is not too heavy, could you send me already compiled in the APK via private message?

My only Android 5 (5.1) smartphone is still charging due to a battery issue. I have to wait to reach at least 80%

Edit:
I tested it on Android 5 and it worked, it's probably some function of the Core version you're using.
Hey, I couldn't attach the APK as it was big for some reason even though It was just a basic game, I didn't do anything in that game, I just edited the file mentioned in the link I have attached above and it magically worked.
 

Dev_With_Coffee

Veteran
Veteran
Joined
Jul 20, 2020
Messages
680
Reaction score
321
First Language
PT-BR
Primarily Uses
RM2k3
What weighs the game are not maps and data, but the RTP itself, mainly because of the audio files.
I don't understand how you solved it, I haven't found any links before.
 

Latest Threads

Latest Profile Posts



Here's Azrael sprite with the fire weapon, hope it came out good.
A13774F4-298B-4F4D-B639-E6921E49FCC2.jpeg
Art test for a victory title screen change
illuminatigirl.png
Illuminati may be just a cover-up for the actual secret society of Illuminaughty. :kaojoy:
Got distracted... again. So now I'm on project.... 5? 6? I can't even remember off the top of my head how many plugins I have in the works. Though I blame the latest two on a coding youtuber I watch occasionally. He codes in C++ but walks through the process well enough that it inspires me to do similar things for JS plugins. So... blame him for my lack of activity. lol

Forum statistics

Threads
113,760
Messages
1,077,246
Members
147,795
Latest member
AppleCider
Top