Game Development Community

Fixing the Optionsmenu (Graphics)

by Florian Ross · in Torque Game Engine Advanced · 10/18/2005 (2:14 pm) · 6 replies

Hi guys,

For the project i'm working on i had to fix the graphics menu and thought that i should share this fix:

all modifications have to be done on demo\client\scripts\optionsDlg.cs

1.
in function function OptGraphicsDriverMenu::onSelect( %this, %id, %text ) you have to change

// Check if this device is full-screen only:
if ( isDeviceFullScreenOnly( %this.getText() ) )
{
	OptGraphicsFullscreenToggle.setValue( true );
	OptGraphicsFullscreenToggle.setActive( false );
	OptGraphicsFullscreenToggle.onAction();
}
else
	OptGraphicsFullscreenToggle.setActive( true );

to

OptGraphicsFullscreenToggle.setActive( true );

2.
in function OptGraphicsResolutionMenu::init( %this, %device, %fullScreen )
and function OptGraphicsBPPMenu::init( %this, %device ) you have to change

%resList = getResolutionList( %device );

to

%resList = getResolutionList();

hope that helps :)


Florian

#1
10/18/2005 (2:44 pm)
Looks good, but could you give a bit more info on what this fix actually does, and what target release it's for? I'm guessing 1.4RC2, but not sure which issue this fix is associated with.
#2
10/18/2005 (2:51 pm)
This is for TSE as i posted it in the TSE forum ;)

if you try to change the resolution in current TSE HEAD then the application crashes.
This is because platformVideo.cpp has been replaced by GFXDevice.cpp in TSE but the graphic options havent been updated accordingly.
#3
10/18/2005 (2:59 pm)
Duh, my bad, lol. Thanks for doing it anyway :)
#4
10/20/2005 (4:55 pm)
This fix has been checked into our local TSE SVN. Thanks Florian.
#5
11/01/2005 (11:32 pm)
Thanks a lot Florian Ross, you saved me a lot of time trying to figure out this one.
#6
02/12/2006 (10:57 am)
Florian,

Thank you for posting this fix. It works great for me.

Aaron E.