Game Development Community

Window size in iTGB

by Mark Schmidt · in iTorque 2D · 01/28/2009 (3:54 pm) · 23 replies

I'm either missing something here or it's just broken. I hope its the former and not the latter. I like hitting the "Play" button from within TGB to test a scene. However, I can't seem to figure out how to change that window size so it emulates the iPhone better. I want a Portrait resolution, but changing everything I can find doesn't seem to do anything. It always jumps to 800x600. Any hints?

Page«First 1 2 Next»
#21
02/20/2009 (2:30 pm)
This has been fixed, and is in the GG repository, I think Mich was trying to get a build out soon.

At the moment, the only way around it is to manually edit them yourself using a text editor, and set the file as read-only/locked.
#22
06/08/2009 (12:42 pm)
I bought and downloaded 1.2 yesterday. Exact same problems as Andrew Whittle.

I specified landscape but the simulator orients to portrait, and my game is offcentered and has white bars on the left and bottom.
The cursor on the simulator screen is about 100 pixels south of where the screen cursor actually clicks.
I tried the previously posted suggestions, but no luck.

The only way I could set this to landscape was to hard code in iPhoneWindow.mm around line 175:

platState.portrait = false;

Any other workaround or suggestions would be greatly appreciated. Thanks!

#23
06/08/2009 (6:14 pm)
Okay, I finally figured it out. Someone else posted the solution in a different thread:

http://www.garagegames.com/community/forums/viewthread/80004/2#comments
In case the link is gone:

Comparing my defaultPrefs.cs from my game and a clean project I noticed my game was missing the below:

//platform
if( $platform $= "iphone" ) {
$pref::iPhone::StatusBarType = "BlackTranslucent";
$pref::iPhone::StatusBarHidden = true;

$pref::iPhone::ScreenOrientation = "Landscape";
$pref::iPhone::ScreenUpsideDown = false;
$pref::iPhone::ScreenAutoRotate = true;
$pref::iPhone::UsesNetwork = false;

$iPhoneControls = "Touch";
}
Page«First 1 2 Next»