I’ve got a problem with screen loading issue in iOS build, It works well in Android but the same build is not working properly in iOS.
While loading to the other screen sometimes it takes time to load and sometimes it may crash with an error in Xcode console.
iOS Console Error: "Execution of the command buffer was aborted due to an error during execution. Ignored (for causing prior/excessive GPU errors) (IOAF code 4)".
I wrote this code in my game manager script for loading the screen.
AsyncOperation asyncOperationScene = SceneManager.LoadSceneAsync("level"+ (DataManager.levelNumber + 1), LoadSceneMode.Additive);
loadingPanel.GetComponent<LoadingLevels>().async = asyncOperationScene;
loadingPanel.SetActive(true);
asyncOperationScene.completed += AsyncOperationScene_completed;
If someone could enlighten me I would really appreciate it!
Thanks for your time!
2
Answers
Thanks for your response, In my script I added some other functions as well like clear cache memories once I commented those code for cache memory then the scene loading issues resolved.
Let me show you my codes, Someone please go through it and do let me know whether it is correct or having some mistakes on it.
After search some on the internet, maybe your problem is not related to the loading way of the scene, but the scene has some problems with lighting or shader, I have read about some other guys have a similar problem and is related to some drivers of new phones that have changed and then unity it’s working with it, but it also has to do with custom shader things that need to be different, so maybe your error doesn’t come from the loading way of the scene, but from some material, I have read that it can be something about ambient lighting and exr. files, wish to help more but that’s was what I can share with you.
Anyways would be nice for all of us that you share here the debug log where we can see what’s going on and particular to you make sure that is not about loading the scene but something that the scene you try to load had something that its not well for this new phones and their driver related to lightmapping shaders etc.