Game Development Community

iT2D 1.4 - Universal Apps that run on iTouch, iPhone and iPad

by Brian Szatkowski · in iTorque 2D · 07/15/2010 (3:48 pm) · 22 replies

OK...now that I've got your attention, I must break the bad news that I am simply fishing to fill this thread. I had made a similar thread several weeks ago to try and ascertain how the community is creating universal apps. However, that thread got sidetracked and my original request was never addressed.

So, for those of you who have successfully developed universal apps with iTorque 2D 2009, please list the specific steps/requirements so that the rest of us can benefit from your experience. Specifically, please list:


  1. What settings must be made in the iTorque 2D editor (if used)
  2. What settings/changes must be made in your XCode project
  3. Any other pertinent "gotchas" or things for which to look out

Thank you in advance for all of the beneficial feedback!
Page «Previous 1 2
#1
07/15/2010 (6:26 pm)
what the heck is iTorque 2D 2009, there is no such thing.

also ipad was not supported until this years version (1.3, fixed in 1.4).

without that version you can not even get resolutions higher than the iphone one
#2
07/15/2010 (8:42 pm)
@Marc -- Read Eric's blog or the newest docs for 1.4. iTorque 2D 2009 is now what this product is called.

At any rate, if you have answers for the questions based on the latest (1.4) release, I'd appreciate it.
#3
07/16/2010 (3:07 am)
I was also puzzled by the 2009 designation:

static.torquepowered.com/static/upload/blogs/19959.jpg?
#4
07/18/2010 (5:34 am)
@Brian

I have been working on Universal Applications for iphone/ipad. I have it almost working, but the ipad version does not go full screen.

I have the two icons for iphone/ipad working, just have to figure out the resolution part for ipad.

I am just working on having two mainwindows.xib.
#5
07/18/2010 (7:19 am)
Brian, what do you mean when you say universal apps? Are you talking about apps than run on iPhone and iPad, or are you talking about breaking it down to an smaller granularity, such as a specific iPhone model, for example. Given that there are now several verions of the iPhone/iPod, that have very differnt abilities, (even different screen resolutions now that we have the iPhone4) I think a univeral app means taking into account not just the device type, bust also the device generation. What is it that you are talking about?
#6
07/18/2010 (8:09 am)
Apple's definition for Universal Applications: One application that will run on iTouch, iPhone and iPad.
#7
07/18/2010 (2:50 pm)
@Dean - Any chance of posting snippets on the parts you have accomplished (getting the icons to work, etc.)? I had thought about simply doing two separate nibs as you stated but assumed I'd run into the exact problem you eluded to of being stuck in the iPhone resolution. I tried setting different targets in iT2D (scene 1 at iPhone; scene 2 at iPad) but it seems that this is ignored by the editor and just defaults to the last one set (i.e. it appears that the app is tied to one resolutiuon). What we need is to find a way to generate the OpenGL ES screen after the device is detected.

I've sent a support email to the iTorque address since no one seems to have found a solution. Once they respond, hopefully with a solution, I will post it for all to use.

@Mark - Dean is correct: I am using Apple's definition of Universal app in the context of this thread. The nuances between the various models are easy enough to deal with by determining if certain calls can be made. I just want to be able to create a single app (Universal) that runs at native resolutions on the iPod Touch/iPhone and iPad. Without some hack, this doesn't currently seem possible. With iPhone 4, it is simple to include higher resolution graphics to accommodate the increase screen size.

Any other insights from anyone else?
#8
07/18/2010 (6:37 pm)
@Brian

I have create a version with with two mainwindow.xib files, one for the iphone and one for the ipad. I have it working with different resolutions but I am trying to get the 480x320 on the ipad.

It works, but the ipad is in 1024x768 so, the game is running in the lower left hand corner.

When I get closer to fixing this, I will post the info. If I get stuck, I will post what I have.
#9
07/18/2010 (10:01 pm)
Ok, I see what you mean. Thanks for the clarification. Has anyone tried using the new iPhone4?
#10
07/18/2010 (10:41 pm)
I have 3 iPhones already and an iPod Touch, really can't justify an iPhone 4 at the moment :(
#11
07/18/2010 (10:45 pm)
Same, here. I've got 3 iPod Touches, but I don't have any iPhones. I wouldn't mind having the new iPhone, and an iPad, but I can't afford those right now. I'm hoping there will be a new iPod with similar specs to the iPhone4, and it would be awesome if it has a VGA output port like the iPad. I will probably purchase the next version of the iPod when it comes out.
#12
07/19/2010 (3:56 am)
PREFACE:
- This guide might be a little complex for most beginners.
- This guid has been written using Apple iPhone iOS 4.0.1 update and iTGB 1.4 RC.
- This is a work in progress and could be changed often to fix problems or add updates.

When you create a universal application it requires two different sized icons. One for the iPhone and one for the iPad. If you don't do this and upload your application to Apple website, you will get this error:

Quote:"The binary you uploaded was invalid. The bundle did not contain both an icon for iPad of exactly 72x72 pixels, and an icon for iPhone and iPod of exactly 57x57 pixels, in .png format."

How to fix this...

Create the following icons and save them in your project.
Example: C:/iTorque 2D 1.4/MyProjects/*your game folder*/buildFiles/XCode_iPhone

- iPhone icon should be called Icon.png, sized 57x57.
- iPad icon should be called Icon-iPad.png, sized 72x72.

You need to add an entry CFBundleIconFiles with Type String to your Info_device.plist (string should be default) and type the value Icon-iPad.png

Right click the Target -> build tab and change value from iTorque2D_icon.png to Icon.png

NOTES:
- I will try to get some screen shots to make it purdy.
- Keep in mind that the MainWindow.xib that is included with iTGB 1.4 is configured for iOS 2.0.
- Things get a little confusing on configuring iTGB, there are three different files that need to changed.
- Next part will show how to configure nib files (I wouldn't necessarily go through each nib file), create and configure multi view controllers.
#13
07/19/2010 (6:28 am)
Just a quick question regarding the iPhone4. If I continue to develop using the older 1.3.1 iTGB, will the screen size automatically scale from 480x320 to 960x640 if the exact same app is run on the iPhone 4, without me having to do anything specific?

I can see that guys are having a hard time with iTGB v1.4, and I would like to avoid using that version for the forseable future. It doesn't bother me too much if I don't support the iPad. I'm only concerned with iPods and iPhones.

#14
07/19/2010 (6:30 am)
@Mark

I will be adding a version for old SDK's.

The Universal Applications are a new thing and it's not the developers of iTGB fault. It will take a bit to get up to speed with it. Some of the errors have been PICNIC problems. (person in chair not in computer)

I haven't seen an iPhone 4 in Canada yet and don't know the answer. I am sure they will run without any changes.

Splash screens info for each model:

Default.png 320 x 480 iTouch, iPhone/iPod 2, 3.
Default-iPad.png 768 x 1004 iPad.
Default4.png 640 x 960 iPhone 4 hi-res launch image.
#15
07/19/2010 (7:42 am)
Ok, thanks for the feedback Dean. I haven't seen an iPhone 4 yet either. I'm just hoping it will work transparently, and hopefully the screen will get upscaled to 960x640 automatically.
#16
07/19/2010 (3:51 pm)
I'm sure most folks know this but just in case. The universal apps are the ones that have the little plus on the price.
A universal app can be quite handy. I have actually seen apple go as far as to reject a game because it was the exact same as the iphone version other than resolution.
The email noted that since there was no differences a universal app would be required.
Of course given apples consistency the easier solution was to wait a day or two and submit again lol

I've seen so many various rejections that make no sense.

In short though learning how to make a universal app is important I think. Apple seems to be cracking down more on smaller debs for releasing the same game twice.
#17
07/19/2010 (9:34 pm)
@ Mark -

Quote:
I haven't seen an iPhone 4 yet either. I'm just hoping it will work transparently, and hopefully the screen will get upscaled to 960x640 automatically.

You are correct in your assumption here. I have the iPhone 4. All apps generated for the 480x320 resolution are upscaled to fit the new Retina display (960x640) of iPhone 4. You do not have to modify your code because Apple addressed how objects are mapped by also scaling the "point" coordinate value so that anything you positioned in your code stays in the same location on screen--it's just displayed at four times its normal size.

A point in pre-iPhone 4 devices is at a 1:1 ratio whereas the new device as a 4:1 ratio. That is, for every pixel on the old devices, the new device as a grid of 4 pixels that represent that same "point" in space.

However, it should be noted that although your apps will work fine and dandy on the new device without modification, it is highly suggested that you add higher-resolution images to your app to accommodate users of this fantastic new display.

Apple was kind enough to add a quick/easy solution to addressing the increased resolution--you simply create two versions of each of your images, one with the regular name and one with an @2x suffixed to it, as in: image_name.png -and- image_name@2x.png. The app will automatically search for the higher-res images and default to the low-res if not found (or not needed).

Now, all of this comes with the caveat that the OpenGL ES context is handled differently. If IA has not implemented the steps provided here Drawing High-Resolution Content Using OpenGL ES (of which I'm fearful to know the answer), then all of our apps are going to look "blocky" on the iPhone 4 as it gets scaled up.

I have not tried to get anything into my iPhone 4 yet to see (as I'm focusing on getting basic Universal app functionality working), I cannot give accurate feedback.

@ James - Apple has been very clear that, in order to be approved as a separate app, an iPad (or conversely) app cannot simply be a higher-resolution version of an equivalent iPhone/iTouch app. The reasoning behind this is that consumers who have multiple iDevices (such as myself, having an iPad, iPod'ified-1st-gen-iPhone, and the iPhone 4) shouldn't be charged for the same app to be installed on all of those devices. What we, as consumers, license is the right to install that app on all of our devices. Therefore, there must be significant enough differences between an iPhone/iTouch version of an app and its iPad counterpart to warrant a separate fee. Otherwise, you're bilking your customer for the same product (albeit in a prettier package) twice (and often at a higher price for the iPad version).

This is specifically why Apple created the Universal build "option". You create/update an app to work on all iDevices once, providing the necessary modifications per platform, and then decide on one price to cover them all.

@ Dean - Thanks for the snippets/tips and I look forward to your Universal build resource.

Thread title change suggestion--duly noted.
#18
07/19/2010 (9:41 pm)
Brian, thanks for your detailed response. I was hoping that was the case regarding the iPhone 4.
#19
07/19/2010 (10:18 pm)
@Brian


Yes, I am certainly aware of the the apples requirements on that issue. More than anything i was just agreeing that knowing how to make a universal app is a good idea because of this.

I just find it funny how inconsistent they are with approvals.
There are tons of games that don't have universal.
They seem to approve plenty games that are identical with the "hd" added to them.
I have been rejected and just turned right around and submitted again with no changes and gotten approved.

Maybe they are a little more fussy when the app is more than .99
Plus I hardly consider is "bilking" my customer if someone wants to pay .99 twice for one of my apps.
At the end of the day they are only spending 2 bucks which, is less than one buying Angry Birds HD once for 4.99

Ultimately I would prefer to have universal.
It will be nice when torque has a similar feature to Unity in that you just select target and base SDK and hit build. If you select Ipad and iphone a universal is created.
However i am not trying to start a game engine debate lol... EVery engine has its ups and downs.
#20
09/20/2010 (7:57 pm)
Edit.
ignore.
thanks.

:))(((


Page «Previous 1 2