So, I updated Unity iOS to 3.4.1. My app runs fine in the editor, and when I ran my app on my device it looked fine on the title screen, but when it loaded the first level scene the game only showed up, in shrunken form, down in the bottom-left quarter of the screen:
The rest of the screen flickers around with bits of the game image, flashing between being visible and non-visible… what has happened and how can I fix it?
Oh nice, I’m glad to have a diagnosis! Now. How do I code for resolution independence? I didn’t even realise I had to, as I stated this was not a problem before I updated Unity, my app worked perfectly on the device before 3.4.1
Bizarre problem, just experiment til you see whats causing it. Set the unity game viewport to = the device dimensions (use the drop down menu on the left). Thats a good start.
Thanks for the input, the “Game” window is already set to “iPhone 4G Wide (960x640)”, which it does fill in the editor on the mac, but on the device it must be doing half that, like the old iPhone res before the Retina display. The device is an iPod Touch 4G. The 1st scene which loads (the titlescreen) works perfectly and fills the entire screen. This weirdness only starts once the 2nd scene (the first level) is loaded
I agree, it is what it sounds like, but I’ve been into the Unity PlayerSettings\OtherSettings\Configuration and changed the Target Platform to arm7 with no luck. I also tried setting the Target resolution in the same area to HD (Highest available resolution), but no dice there either.
I mentioned earlier that the title screen scene opens in full screen but I’ve now realised that when the game level is finished and the app reloads the titlescreen it only shows in the quarter res too… really confused as to what’s going on. I havent looked into Xcode settings yet though…
update: actually Xcode looks to be set to arm7 too with a deployment target of iOS4.3 the problem persists
There is nothing we can do to help you. This isn’t a known problem as far as I can see, it looks like you are doing something fairly wrong, so can you please make an example project which reproduces this behaviour which is as small as possible so we can load it up, run it and solve it for you.
Unless you can do that, I can’t help further. It has to be as small as possible if we are able to help you reproduce it.
Hey, I’ve narrowed it down to the GameObject that I have my Touch control script attached to so I should be able to figure it out soon. I’ll make sure to pop in an update once I’ve found the root.
Thanks for taking the time to throw some suggestions at me
Ahhh… turns out I still had the PlayerControls script from the Unity giro controls example (with the flying craft and the pyramids) attached to my Touch controls game object. It was deactivated with the tick box in the editor but it was still affecting the app as it has Screen.SetResolution code in the Awake function!
There is no emoticon on this forum to express how my face looks right now.
well whatever the reason I’m actually really happy that I took the time to upgrade to 3.4.1 and run through the source files with #pragma strict as now the app runs at a much higher framerate than it did before!