- Home /
Question by
stuthemoo · Mar 07, 2012 at 10:05 PM ·
iosplatformconverting
Converting game to iOS (noob question)
Hi There,
I downloaded Unity iOS today and I want to convert one of my old web based games to run on the iPad. Will I need to duplicate my project folder for iOS or can I build for both platforms using one project folder?
Because I don't want to see all the iOS Gui controls on the web platform etc.
Thanks!
Comment
Answer by benni05 · Mar 07, 2012 at 10:16 PM
You don't have to duplicate your project folder and I wouldn't do so in order not to duplicate your code etc. and end up mainting 2 projects at the same time. You can switch your project via File/Build Settings any time to the preferred platform.
In order to maintain one code base make use of
#if UNITY_IPHONE
#endif
directives or
if (Application.platform == RuntimePlatform.IPhonePlayer) {
}
wherever necessary.
Ben
You're welcome, feel free to accept this as the correct answer :)
Your answer
![](https://koobas.hobune.stream/wayback/20220613064853im_/https://answers.unity.com/themes/thub/images/avi.jpg)