- Home /
How to set game scene according to iPad and iPhone for 2D game in Unity4.3
Hi, I am new in Unity. I am going to develop 2D game, before that I need to know that how can I set game scene for both iPhone and iPad. I am much curios about sizing of images and orientation of screen because I don't know this. I already set game scene for iPad but this was done by hit and try. I don't know exactly to set game scene according to device. Kindly suggest me on this. Thanks in advance.
Answer by tanoshimi · Jan 07, 2014 at 01:30 PM
You can tell the platform the game is running on using Application.Platform.
You can determine the screen resolution, width, and height, from Screen.currentResolution, Screen.width, and Screen.height.
Thanks @tanoshimi Can't we set scene for specific device and then change objects position on runtime according to device. Like now I set scene for iPad by hit and try method and adjusted according to iPad screen size, don't we have pre defined scene view for iPad so that we don't have to spend much time to set scene according to device by hitting and trying method? Thanks again.
I'm not sure what a "pre-defined" scene view would contain?
I'm making an iPad game too, but I'm pretty certain it won't have anything in common with your iPad game scene other than the screen height, width, and resolution...