TGE fullscreen
by Eric Wendorf · in Game Design and Creative Issues · 03/05/2009 (9:08 am) · 5 replies
With TGB i used this code togglefullscreen(); to make it full screen. I want to do the same with TGE. does anyone know if this code will work or if i have to have a different code and where i would put it in my code?
About the author
#2
$Pref::Video::Fullscreen = 1; make sure you put it in defaults.cs and not prefs.cs. You'll delete the prefs and let the game re-generate another prefs file. That will make your game always start in fullscreen.
The actual command if you want to change it through script is:
setScreenMode(%hRes, %vRes, %colorDepth, %fullscreenToggle);
* hRes = horizontal resolution
* vRes = vertical resolution
* colorDepth = 16 bpp or 32 pbb (bits per pixel)
* fullscreenToggle = 1 for true (fullscreen), 0 for false(windowed)
EXAMPLE: setScreenMode(1280, 800, 32, 1);
03/06/2009 (11:04 am)
The above post only maximizes the window. All you have to do is set a pref for fullscreen to true in defaults.cs. By default it uses windowed mode, unless you toggle it in the options screen. $Pref::Video::Fullscreen = 1; make sure you put it in defaults.cs and not prefs.cs. You'll delete the prefs and let the game re-generate another prefs file. That will make your game always start in fullscreen.
The actual command if you want to change it through script is:
setScreenMode(%hRes, %vRes, %colorDepth, %fullscreenToggle);
* hRes = horizontal resolution
* vRes = vertical resolution
* colorDepth = 16 bpp or 32 pbb (bits per pixel)
* fullscreenToggle = 1 for true (fullscreen), 0 for false(windowed)
EXAMPLE: setScreenMode(1280, 800, 32, 1);
#3
03/06/2009 (4:58 pm)
and if we have meters that count down time or health will that get all screwed up?
#4
03/06/2009 (5:03 pm)
or will it screw up the gui in any way?
#5
Sometimes changing resolutions can be tricky -- you'll just have to test and pay special attention to HorizSizing & VertSizing when designing your gui. Those two fields are rather un-intuitive and will take you a bit of experimentation to use them properly. The gui editor lets view your gui at several different resolutions, so it will quickly become evident which controls you'll need to tweak for correct placement.
03/06/2009 (5:24 pm)
Shouldn't be a problem, not if your gui elements are set up correctly. Keeping the same resolution from windowed to fullscreen will simply move the controls to their relative positions on the screen.Sometimes changing resolutions can be tricky -- you'll just have to test and pay special attention to HorizSizing & VertSizing when designing your gui. Those two fields are rather un-intuitive and will take you a bit of experimentation to use them properly. The gui editor lets view your gui at several different resolutions, so it will quickly become evident which controls you'll need to tweak for correct placement.
Torque Owner Shane09
For Mac:
Click the green button (on the top left of the window)
For Windows:
Click the square button (on the top right of the window)