I'm in a JAM - fullscreen on MacOS and other questions/problems
by Kurt Koller · in Torque Game Builder · 04/27/2007 (2:30 am) · 5 replies
I am having a major problem with the Mac version of 1.1.3 TGB Pro using original code with no source modifications... Any insight would be greatly appreciated.
First up, we are developing this on the PC, but it really has to run on a Mac. This is due to the people involved. Ultimately what we are developing in a little platformer that has to run in a Kiosk on a Mac Mini for an event. We chose Torque Game Builder mainly because of the cross platform ability.
Basically, we cannot get a fullscreen display on the Mac. The Mac Mini has intel graphics, and while this isn't supported by the tool for development (and indeed uses 100%CPU and is virtually impossible to use) the game output runs fine, and never uses more than a few percent CPU.
When we run the game a windows shows up black, then sits a minute, then fades out and fades back in and the game runs. Apple-Enter puts it into some kind of fullscreen mode -- the window fades out, the apple title bar disappears, the app is still running, but I just see the desktop, no game. Hitting Apple-Enter again brings the game back in a window.
This might be related: Every time we load the project into the TGB application on the Mac, it loads a window, fades out, loads up another differently sized window, then fades out again and loads up a third window, finally with the game in it. Only it's ALWAYS in a hugely wide resolution, and we need to change it to something reasonable, like 1280x800. Once we save and quit, it doesn't remember this on load.
Some other issues:
1. When we load a project on the Mac to build it on the Mac, going to the Build window and choosing build does not work, it simply opens a browser window to view the build output, which shows no files in any of the sections. We have to do "analyze" first which takes about 9 minutes on a dual-core 2.33Ghz MacBook pro, and THEN doing a build works.
2. The PC version LOOKS like it will build the Mac version, but fails with an "internal error." Not sure if this is supposed to work, and it's not that big a deal if we can get building working well on the Mac.
3. On the PC version (running under Vista), when we copy the project from another machine onto ours, there appears to be virtually no way to get the project to appear in the project list. On the Mac, we copied it into the games directory in the installed folder and it shows in the Project Open menu. On the PC, we tried that, doesn't work. we ALSO tried copying it to that weird path under C:\Users\[user]\AppData\Local\VirtualStore\Program Files\TorqueGamebuilderPro\games\[game] - this is where new projects we create go and THEY show up in the file menu - but it doesn't show up in the project list. So we can't copy this from our remote developer's machine to ours. We're going to try an XP system to see if it's some weird Vista-ism. Why on earth isn't there a browse dialog?
Any insight into any of these problems would be greatly appreciated.
First up, we are developing this on the PC, but it really has to run on a Mac. This is due to the people involved. Ultimately what we are developing in a little platformer that has to run in a Kiosk on a Mac Mini for an event. We chose Torque Game Builder mainly because of the cross platform ability.
Basically, we cannot get a fullscreen display on the Mac. The Mac Mini has intel graphics, and while this isn't supported by the tool for development (and indeed uses 100%CPU and is virtually impossible to use) the game output runs fine, and never uses more than a few percent CPU.
When we run the game a windows shows up black, then sits a minute, then fades out and fades back in and the game runs. Apple-Enter puts it into some kind of fullscreen mode -- the window fades out, the apple title bar disappears, the app is still running, but I just see the desktop, no game. Hitting Apple-Enter again brings the game back in a window.
This might be related: Every time we load the project into the TGB application on the Mac, it loads a window, fades out, loads up another differently sized window, then fades out again and loads up a third window, finally with the game in it. Only it's ALWAYS in a hugely wide resolution, and we need to change it to something reasonable, like 1280x800. Once we save and quit, it doesn't remember this on load.
Some other issues:
1. When we load a project on the Mac to build it on the Mac, going to the Build window and choosing build does not work, it simply opens a browser window to view the build output, which shows no files in any of the sections. We have to do "analyze" first which takes about 9 minutes on a dual-core 2.33Ghz MacBook pro, and THEN doing a build works.
2. The PC version LOOKS like it will build the Mac version, but fails with an "internal error." Not sure if this is supposed to work, and it's not that big a deal if we can get building working well on the Mac.
3. On the PC version (running under Vista), when we copy the project from another machine onto ours, there appears to be virtually no way to get the project to appear in the project list. On the Mac, we copied it into the games directory in the installed folder and it shows in the Project Open menu. On the PC, we tried that, doesn't work. we ALSO tried copying it to that weird path under C:\Users\[user]\AppData\Local\VirtualStore\Program Files\TorqueGamebuilderPro\games\[game] - this is where new projects we create go and THEY show up in the file menu - but it doesn't show up in the project list. So we can't copy this from our remote developer's machine to ours. We're going to try an XP system to see if it's some weird Vista-ism. Why on earth isn't there a browse dialog?
Any insight into any of these problems would be greatly appreciated.
#2
Paul, thanks for the pointer about multiple screen res settings, I will check into it. If I don't get anywhere I will def take you up on your offer.
04/27/2007 (1:26 pm)
We change the resolution on the PC to a "standard resolution," I think 1280x800. I will double check.Paul, thanks for the pointer about multiple screen res settings, I will check into it. If I don't get anywhere I will def take you up on your offer.
#3
Further, make sure that you check the three main places that your game's resolution gets set:
1) mainscreen.gui. Look for the resolution in that file (this will show up in both the GuiControl(mainScreenGui) and the t2dSceneWindow(SceneWindow2D) object definitions). These are the settings that the game defaults to use.
2) t2dSceneGraph->Camera->Design Resolution (in the Project tab within the editor, click the t2dSceneGraph at the top, then look in the Camera rollout). This is a place where you can quickly change the resolution for a game test (in my experience it also becomes the default when you package a game).
3) In scripts. Look through your scripts' start up to see if anyone is trying to set the resolution. If so, make sure the settings are valid (also check that the fullscreen key combination you specified in Apple+Enter calls the function using the correct resolution values).
Hope that helps!
04/30/2007 (8:59 pm)
@Kurt: Fullscreening is awkward in on the Mac. You MUST specify a resolution that the resolution knows how to handle. Take a look at System Preferences->Displays->Resolutions for a list of valid fullscreen resolutions. If you're going for 1280x800 it must be a standard resolution supported by the computer you are running the program on. My laptop (Powerbook G4) has a max resolution of 1280x854 and would produce the same results as you describe above if I asked it to do a 1280x800 fullscreen game.Further, make sure that you check the three main places that your game's resolution gets set:
1) mainscreen.gui. Look for the resolution in that file (this will show up in both the GuiControl(mainScreenGui) and the t2dSceneWindow(SceneWindow2D) object definitions). These are the settings that the game defaults to use.
2) t2dSceneGraph->Camera->Design Resolution (in the Project tab within the editor, click the t2dSceneGraph at the top, then look in the Camera rollout). This is a place where you can quickly change the resolution for a game test (in my experience it also becomes the default when you package a game).
3) In scripts. Look through your scripts' start up to see if anyone is trying to set the resolution. If so, make sure the settings are valid (also check that the fullscreen key combination you specified in Apple+Enter calls the function using the correct resolution values).
Hope that helps!
#4
Thanks a lot for the information.
In #3 you say check the fullscreen key combination you specified in Apple+Enter... I haven't done anything with this, I thought it was some magic built into Torque. I'll check into this...
I will repackage at the proper res and see what happens.
05/01/2007 (7:42 pm)
Eric,Thanks a lot for the information.
In #3 you say check the fullscreen key combination you specified in Apple+Enter... I haven't done anything with this, I thought it was some magic built into Torque. I'll check into this...
I will repackage at the proper res and see what happens.
#5
05/30/2007 (5:19 pm)
Got this all figured out. game was a hit with the client. thanks for your help.
Torque Owner Paul Scott
Default Studio Name
It further sounds like your game's prefs for fullscreen resolution aren't valid, and that TGB is quitting without saving the prefs out.
The PC version of TGB 1.1.3 cannot build the Mac version, because it doesn't have the mac binary built in, because TGB 1.1.3 for the Mac shipped several weeks after TGB 1.1.3 for win32.
The video problems you're reporting strike me as odd, since I tested TGB on a Mac Mini with Intel graphics, and did not have these problems.
This sounds like a scripts problem, given that you have not modified the TGB source, and given that I've tested TGB on an identical machine. If you'd like to send me a build of your game, I'll take a look at it & see what I can find.
/Paul