Ive developed a simple game with unity which has an airplane (https://www.assetstore.unity3d.com/en/#!/content/28663) with bolts coming out of it to represent some firing. Ive added a simple nebula background to the main camera (skybox). Ive reduced the resolution of all my textures to 1024 for iOS. Ive tried to use mobile shaders mostly but the background has a skybox(6 sided) shader attached to it to enable tint colours. I added a cube around the screen which has a collider and destroys everything that is not in the game view. The game runs fine in Unity Play mode with around 302 fps with draw calls around 15 (Ive a 2011 macbook pro and 302 is a lot). The game runs fine on the iOS simulator in Xcode. But when i try to run it on my iPhone 5 (8.4.1) it just shows a black screen with nothing on it and eventually crashes (Terminated due to memory error). I then used the instruments in Xcode to see what was happening. The game starts with 250mb on memory. Yikes!! Then slowly goes up to 450mb then crashes. Im sure the kernel just terminates it because the app is using more memory then there is available. Can someone please help me what is wrong with Unity. Im using Unity 5.1.1 free edition and there is not even a single array or anything of that sort in my game. To begin with 250 mb is a lot and then going up to 450mb is truly not acceptable. Ive tried to Build with both Mono2x and Illcp2 but the problem occurs on both. What am i doing wrong? Any help would be greatly appreciated.
↧