PlayCanvas game not working on Tablets anymore

Dear Play Canvas Developers.

I am currently developing a bigger game (Currently around 240MB, probably going to end up around the 1GB mark). Now before developing as far as I have now, I’ve developed a stress test to test the boundaries of what PlayCanvas can process before crashing. Tested this on iOS aswell as Android Tablets. Everything worked fine. Now I have developed further but mostly I just added lots of code. I added a few new FBX models but not many. On Android Tablets aswell as the iOS tablet I can’t run the applications anymore. Both give me:

“Failed to Compile Fragment Shader”

. The iOS debugging also gives me:

ERROR Too many uniforms.

I’ve read that it can be caused if models have “too many bones”. I have added 2-3 mixamo characters to the game, but I’ve used 2 before and it worked fine, so I don’t see why these new characters would cause that problem.

Loading the level selection works fine on both (Well I had to have an IPad pro to get it running on iOS at all, all other IPads resulted in: “there was a problem the page needed to be reloaded” , I’m guessing has something to do with RAM) :

I don’t know what is causing this issue. The android Tablet doesn’t start the level at all.

On the iOS Tablet, the level loads, but ALL Models are gone. Only Images are loaded

For reference this is how it should look, running on a Google Chrome Web-Browser:

I have no idea how I can attempt to fix this issue and it needs to run on Tablets to as per specification of the customer. It did run with the Stress test I did so we thought we could proceed developing the real deal…

PS: I can’t share a link to the Project, seeing as this is a Project of the company I work at.

Thank you for helping

When you see just certain models fail to render, it’s normally because the shaders compiled for the materials on those objects have not successfully compiled/linked. There should be errors about this printed to the JavaScript console.

I’m not sure why you’d just see a black screen on Android. But with any problems on either Android or iOS, the first thing you should do is check the JavaScript console. In other words, you need to follow the instructions to enable remote debugging for either OS/browser. For example, on Android:

For iOS, you need a Mac to connect to the target device and you use Safari on your desktop to debug and view the JS console.

As for why you get “there was a problem the page needed to be reloaded”, yes, it’s because the tab runs out of memory. The best things you can do to avoid this are:

  • Use PVR texture compression for iOS.
  • Avoid using the physics engine (which can use a lot of memory that can cause problems on low end iOS devices)

Hey thank you very much for your Response!

I’ve managed to get it running on my Android Tablet. I edited some of the Textures I had, to be lower Res. Some of them were wayyyyyyyyy to high. It now runs more or less smoothly on the Samsung Tablet. I did it with remote Debugging and the Error Output was just about 100 lines of Code from playcanvas-stable-debug. So I don’t know where it was hanging.

The iOS problem consists, but I will try to follow your advice. I am not using any physics right now. I did before, but got rid of them seeing as sometimes they would produce different results.

1 Like

Feel free to paste JS console output if you’re ever unsure what it’s telling you.