Download

Packaged Android game worked but then started crashing - related to default device profile?

I was able to package my Android game and publish it to Alpha on the Play store via the Developer Console. I was able to successfully push the first few versions to my devices, but then wanted to use a Default Device profile ini to apply mobile content scaling for larger screens and tablets. It would look fine on my Droid Maxx and Droid Ultra phones, but the size and resolution were off on the Galaxy Note II (lost a bit of the outer edges of the game) and Samsung Galaxy Tab A 7 2016 (lost a lot of the outer edges of the game).

I added the DefaultDeviceProfiles.ini file to the Config folder. This was just me trying to figure things out and it had the following content:

[Android DeviceProfile]
+CVars=r.MobileContentScaleFactor=1.0

[Android_Low DeviceProfile]
+CVars=r.MobileContentScaleFactor=1.0

[Android_Mid DeviceProfile]
+CVars=r.MobileContentScaleFactor=1.0

[Android_High DeviceProfile]
+CVars=r.MobileContentScaleFactor=1.0

That actually seemed to work like a charm at first. I was able to update the game on all three of the above devices, and it was scaled properly for each. I went to bed quite pleased to have gotten lucky on that first attempt.

The next day, I made some minor changes in the blueprints to get some UI elements in the corners and added a widget to pop up as a loading screen, yada yada. Nothing that seemed like it would affect much. I uploaded the new APK to the Developer Console and went to work. When I had my co-workers/game testers download the game onto their phones, it crashed on a Moto G and an unidentified LG, and also crashed on my Ultra and Maxx. It loaded on a Samsung Galaxy S4 was but there were some minor graphical glitches.

I started backtracking from there. I undid the minor blueprint changes from that morning and packaged/uploaded a new APK. No go. I removed the custom device profile ini file. New apk. No go. Still crashing. I replaced my entire project folder with a previous backup copy. Still crashing. Went back another version. Still crashing.

Now I am wondering if something got changed in the base Engine. Maybe the Engine/Config/BaseDeviceProfiles.ini. I am going to back that file up and replace it with a fresh copy from my other computer’s instance of the Engine. {Shrug}

Thanks for any insight! I’m on a bit of a deadline and only sort of know what I’m doing. :slight_smile:

Try delete your installed apk in phones, before install newly.
I have a some issues when i modify core elements or properties, and redeploy in my phone, when i delete all in my phone, and re install, all problems are solved D:!

Regards!

I seem to have figured this out. And–as usual–it was probably just another case of me not paying attention to what I was doing.

After trying almost literally everything else, I was reading an old forum thread about a similar (but probably unrelated) crashing issue, and one of the suggestions was to try packaging with Android - All to see if that helped. I shrugged and thought “why not?” I packaged with Android - All. I had avoided that before for fear of pushing my apk size over the 100 MB Android Developer upload limit, but it came in at 99.2 MB. I uploaded that to my Developer console, waited for it to be ready and–frickin eureka, it worked. Rock on.

I just did a few game tweaks and uploaded another Android - All package… Looking good. It even seems to scale correctly on a 7 inch tablet, though I wonder if I can get the resolution better…

I think that I must have been packaging as ETC_2 for the initial apks that worked on my Maxx, and then switched to ETC_1 without realizing, which worked on the Galaxy devices but not on Motorola. And if I can fit all texture types into 100MB, might as well, I suppose.

Anyway, hope this helps randomly spark a solution for someone else the way that other thread did for me!