Game Development Community

Best set up for developing for the iphone

by Robert Nash · in Torque Game Builder · 08/23/2008 (11:43 am) · 11 replies

Hey, I am working on a game that I plan to release on the iphone. Right now I am working on it with the standard TGB. So my question is: what would be the best camera set up to best simulate what the game will look like on the Iphone. Since, it doesn't seem like you can get the Design Resolution any lower than 640X480.

#1
08/23/2008 (11:52 am)
You can get it lower by manually calling setScreenMode, search for it in your scripts and you will find how to use it.
#2
08/23/2008 (12:12 pm)
That did it thanks for the info
#3
08/26/2008 (11:14 pm)
Robert - do you know if Torque iPhone will run Torque Script?
#4
08/26/2008 (11:18 pm)
Conor, it will be exactly the same as Toque, except optimised for the iPhone (rendering, input, etc).
#5
08/26/2008 (11:20 pm)
Thanks Phillip - that's just what I wanted to hear!!!
#6
08/31/2008 (4:28 pm)
Hi,

I was wondering if someone could tell this noob where to find setscreenmode? Hopefully it IS in the scripts somewher and I will be able to see the usage. I've looked for it, but have not been able to find it. I'm trying to set the screen to 320 by 480, for the iphone. Any help would be appreciated.


Louie
#7
08/31/2008 (5:22 pm)
I'm not at my computer with TGB installed atm, but you should be do a find-in-files search within your game folder to quickly find it. I am literally doing this all the time, in Torsion its ctrl-shift-f.
#8
08/31/2008 (5:35 pm)
Louie, I think it is something like this:

// Example: setScreenMode(320, 480, 32, true);
setScreenMode(%resWidth, %resHeight, %bitDepth [, %fullScreen = false]);

I can't remember off to top of my head whether or not the fullScreen arguement is required or not.
#9
08/31/2008 (9:30 pm)
Thanks a bunch James and Phillip. I tried it without the fullscreen and it worked. It probably works with the fullscreen as well, just didn't try it. I must suck at searching for stuff on TDN, I couldn't find any reference!
#10
08/31/2008 (10:03 pm)
For future reference, Michael Perry has recently uploaded some much needed updates to the documentation section of the site: www.garagegames.com/developer/torque/tgb/
#11
09/07/2008 (2:26 pm)
Hey,
I tried setting the res using the above command and got this error:

OpenGLDevice::setScreenMode -- can't go smaller than 640*480!

Any ideas?
Thanks
Eyal.