Ran importer on UI module to ensure guis and images are converted to latest standards
Updated all UI module controls to utilize a more standard structure with stack controls instead of the GameMenu ctrls, as well as more standardization of gamepad input handling
|
|
@ -81,6 +81,7 @@ function ExampleModule::initClient(%this)
|
||||||
exec(%prefPath @ "/keybinds." @ $TorqueScriptFileExtension);
|
exec(%prefPath @ "/keybinds." @ $TorqueScriptFileExtension);
|
||||||
|
|
||||||
%this.queueExec("./scripts/inputCommands");
|
%this.queueExec("./scripts/inputCommands");
|
||||||
|
addOptionsMenuCategory("Example Options", "testExampleOptions();");
|
||||||
}
|
}
|
||||||
|
|
||||||
//This is called when a game session client successfuly connects to a game server.
|
//This is called when a game session client successfuly connects to a game server.
|
||||||
|
|
@ -105,4 +106,9 @@ function ExampleModule::onDestroyClientConnection(%this)
|
||||||
{
|
{
|
||||||
//This will pop the keybind, cleaning it up from the input stack, as it no longer applies
|
//This will pop the keybind, cleaning it up from the input stack, as it no longer applies
|
||||||
ExampleMoveMap.pop();
|
ExampleMoveMap.pop();
|
||||||
|
}
|
||||||
|
|
||||||
|
function testExampleOptions()
|
||||||
|
{
|
||||||
|
addListOption("Test Option", "This is a test option", $testOptionValue, "OptionA\tOptionB");
|
||||||
}
|
}
|
||||||
|
|
@ -11,4 +11,4 @@
|
||||||
canSaveDynamicFields="true"
|
canSaveDynamicFields="true"
|
||||||
Extension="asset.taml"
|
Extension="asset.taml"
|
||||||
Recurse="true" />
|
Recurse="true" />
|
||||||
</ModuleDefinition>
|
</ModuleDefinition>
|
||||||
|
|
|
||||||
|
|
@ -83,4 +83,4 @@ function UI::initClient(%this)
|
||||||
|
|
||||||
function UI::onCreateClientConnection(%this){}
|
function UI::onCreateClientConnection(%this){}
|
||||||
|
|
||||||
function UI::onDestroyClientConnection(%this){}
|
function UI::onDestroyClientConnection(%this){}
|
||||||
|
|
|
||||||
|
|
@ -2,5 +2,5 @@
|
||||||
canSave="true"
|
canSave="true"
|
||||||
canSaveDynamicFields="true"
|
canSaveDynamicFields="true"
|
||||||
AssetName="guiSounds"
|
AssetName="guiSounds"
|
||||||
scriptFile="@assetFile=guiSounds.cs"
|
scriptFile="@assetFile=guiSounds"
|
||||||
VersionId="1" />
|
VersionId="1" />
|
||||||
|
|
|
||||||
|
|
@ -31,4 +31,4 @@ singleton SFXProfile(menuButtonHover)
|
||||||
preload = true;
|
preload = true;
|
||||||
description = AudioGui;
|
description = AudioGui;
|
||||||
fileName = "data/ui/sounds/buttonHover";
|
fileName = "data/ui/sounds/buttonHover";
|
||||||
};
|
};
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,5 @@
|
||||||
<GUIAsset
|
<GUIAsset
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="true"
|
|
||||||
AssetName="ChooseLevelDlg"
|
AssetName="ChooseLevelDlg"
|
||||||
scriptFile="@assetFile=chooseLevelDlg.gui"
|
scriptFile="@assetFile=chooseLevelDlg"
|
||||||
GUIFile="@assetFile=chooseLevelDlg.gui"
|
GUIFile="@assetFile=chooseLevelDlg.gui"
|
||||||
VersionId="1" />
|
VersionId="1"/>
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,5 @@
|
||||||
<GUIAsset
|
<GUIAsset
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="true"
|
|
||||||
AssetName="GuiMusicPlayer"
|
AssetName="GuiMusicPlayer"
|
||||||
scriptFile="@assetFile=guiMusicPlayer.gui"
|
scriptFile="@assetFile=guiMusicPlayer"
|
||||||
GUIFile="@assetFile=guiMusicPlayer.gui"
|
GUIFile="@assetFile=guiMusicPlayer.gui"
|
||||||
VersionId="1" />
|
VersionId="1"/>
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,4 @@
|
||||||
<GUIAsset
|
<GUIAsset
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="true"
|
|
||||||
AssetName="IODropdownDlg"
|
AssetName="IODropdownDlg"
|
||||||
scriptFile="@assetFile=IODropdownDlg.ed.gui"
|
|
||||||
GUIFile="@assetFile=IODropdownDlg.ed.gui"
|
GUIFile="@assetFile=IODropdownDlg.ed.gui"
|
||||||
VersionId="1" />
|
VersionId="1"/>
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,5 @@
|
||||||
<GUIAsset
|
<GUIAsset
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="true"
|
|
||||||
AssetName="JoinServerMenu"
|
AssetName="JoinServerMenu"
|
||||||
scriptFile="@assetFile=joinServerMenu.gui"
|
scriptFile="@assetFile=joinServerMenu"
|
||||||
GUIFile="@assetFile=joinServerMenu.gui"
|
GUIFile="@assetFile=joinServerMenu.gui"
|
||||||
VersionId="1" />
|
VersionId="1"/>
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,4 @@
|
||||||
<GUIAsset
|
<GUIAsset
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="true"
|
|
||||||
AssetName="LoadingGui"
|
AssetName="LoadingGui"
|
||||||
scriptFile="@assetFile=loadingGui.gui"
|
|
||||||
GUIFile="@assetFile=loadingGui.gui"
|
GUIFile="@assetFile=loadingGui.gui"
|
||||||
VersionId="1" />
|
VersionId="1"/>
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,5 @@
|
||||||
<GUIAsset
|
<GUIAsset
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="true"
|
|
||||||
AssetName="MainMenuGui"
|
AssetName="MainMenuGui"
|
||||||
scriptFile="@assetFile=mainMenu.gui"
|
scriptFile="@assetFile=mainMenu"
|
||||||
GUIFile="@assetFile=mainMenu.gui"
|
GUIFile="@assetFile=mainMenu.gui"
|
||||||
VersionId="1" />
|
VersionId="1"/>
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,4 @@
|
||||||
<GUIAsset
|
<GUIAsset
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="true"
|
|
||||||
AssetName="MessageBoxDlg"
|
AssetName="MessageBoxDlg"
|
||||||
scriptFile="@assetFile=messageBoxDlg.gui"
|
|
||||||
GUIFile="@assetFile=messageBoxDlg.gui"
|
GUIFile="@assetFile=messageBoxDlg.gui"
|
||||||
VersionId="1" />
|
VersionId="1"/>
|
||||||
|
|
|
||||||
|
|
@ -1,7 +0,0 @@
|
||||||
<GUIAsset
|
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="true"
|
|
||||||
AssetName="NetGraphProfile"
|
|
||||||
scriptFile="@assetFile=netGraphGui.gui"
|
|
||||||
GUIFile="@assetFile=netGraphGui.gui"
|
|
||||||
VersionId="1" />
|
|
||||||
|
|
@ -1,7 +1,5 @@
|
||||||
<GUIAsset
|
<GUIAsset
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="true"
|
|
||||||
AssetName="OptionsMenu"
|
AssetName="OptionsMenu"
|
||||||
scriptFile="@assetFile=optionsMenu.gui"
|
scriptFile="@assetFile=optionsMenu"
|
||||||
GUIFile="@assetFile=optionsMenu.gui"
|
GUIFile="@assetFile=optionsMenu.gui"
|
||||||
VersionId="1" />
|
VersionId="1"/>
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,5 @@
|
||||||
<GUIAsset
|
<GUIAsset
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="true"
|
|
||||||
AssetName="PauseMenu"
|
AssetName="PauseMenu"
|
||||||
scriptFile="@assetFile=pauseMenu.gui"
|
scriptFile="@assetFile=pauseMenu"
|
||||||
GUIFile="@assetFile=pauseMenu.gui"
|
GUIFile="@assetFile=pauseMenu.gui"
|
||||||
VersionId="1" />
|
VersionId="1"/>
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,5 @@
|
||||||
<GUIAsset
|
<GUIAsset
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="true"
|
|
||||||
AssetName="ProfilerGui"
|
AssetName="ProfilerGui"
|
||||||
scriptFile="@assetFile=profiler.gui"
|
scriptFile="@assetFile=profiler"
|
||||||
GUIFile="@assetFile=profiler.gui"
|
GUIFile="@assetFile=profiler.gui"
|
||||||
VersionId="1" />
|
VersionId="1"/>
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,4 @@
|
||||||
<GUIAsset
|
<GUIAsset
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="true"
|
|
||||||
AssetName="RemapConfirmDlg"
|
AssetName="RemapConfirmDlg"
|
||||||
scriptFile="@assetFile=remapConfirmDlg.gui"
|
|
||||||
GUIFile="@assetFile=remapConfirmDlg.gui"
|
GUIFile="@assetFile=remapConfirmDlg.gui"
|
||||||
VersionId="1" />
|
VersionId="1"/>
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,4 @@
|
||||||
<GUIAsset
|
<GUIAsset
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="true"
|
|
||||||
AssetName="RemapDlg"
|
AssetName="RemapDlg"
|
||||||
scriptFile="@assetFile=remapDlg.gui"
|
|
||||||
GUIFile="@assetFile=remapDlg.gui"
|
GUIFile="@assetFile=remapDlg.gui"
|
||||||
VersionId="1" />
|
VersionId="1"/>
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,5 @@
|
||||||
<GUIAsset
|
<GUIAsset
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="true"
|
|
||||||
AssetName="StartupGui"
|
AssetName="StartupGui"
|
||||||
scriptFile="@assetFile=startupGui.gui"
|
scriptFile="@assetFile=startupGui"
|
||||||
GUIFile="@assetFile=startupGui.gui"
|
GUIFile="@assetFile=startupGui.gui"
|
||||||
VersionId="1" />
|
VersionId="1"/>
|
||||||
|
|
|
||||||
|
|
@ -36,7 +36,7 @@ $guiContent = new GuiControl(ChooseLevelDlg) {
|
||||||
percent = "100";
|
percent = "100";
|
||||||
vertical = "0";
|
vertical = "0";
|
||||||
flipClip = "0";
|
flipClip = "0";
|
||||||
bitmap = "data/ui/images/panel.png";
|
bitmapAsset = "UI:panel_image";
|
||||||
color = "255 255 255 255";
|
color = "255 255 255 255";
|
||||||
position = "0 0";
|
position = "0 0";
|
||||||
extent = "927 40";
|
extent = "927 40";
|
||||||
|
|
@ -79,7 +79,7 @@ $guiContent = new GuiControl(ChooseLevelDlg) {
|
||||||
percent = "100";
|
percent = "100";
|
||||||
vertical = "0";
|
vertical = "0";
|
||||||
flipClip = "0";
|
flipClip = "0";
|
||||||
bitmap = "data/ui/images/panel_low.png";
|
bitmapAsset = "UI:panel_low_image";
|
||||||
color = "255 255 255 255";
|
color = "255 255 255 255";
|
||||||
position = "0 40";
|
position = "0 40";
|
||||||
extent = "927 618";
|
extent = "927 618";
|
||||||
|
|
|
||||||
|
|
@ -1,102 +0,0 @@
|
||||||
<GuiContainer
|
|
||||||
margin="0 0 0 0"
|
|
||||||
padding="0 0 0 0"
|
|
||||||
anchorTop="true"
|
|
||||||
anchorBottom="false"
|
|
||||||
anchorLeft="true"
|
|
||||||
anchorRight="false"
|
|
||||||
position="0 0"
|
|
||||||
extent="700 35"
|
|
||||||
minExtent="8 2"
|
|
||||||
horizSizing="right"
|
|
||||||
vertSizing="bottom"
|
|
||||||
profile="GuiDefaultProfile"
|
|
||||||
visible="true"
|
|
||||||
active="true"
|
|
||||||
tooltipProfile="GuiToolTipProfile"
|
|
||||||
hovertime="1000"
|
|
||||||
isContainer="true"
|
|
||||||
class="GraphicsMenuSetting"
|
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="false">
|
|
||||||
<GuiBitmapCtrl
|
|
||||||
bitmap="data/ui/images/hudfill.png"
|
|
||||||
wrap="false"
|
|
||||||
position="0 0"
|
|
||||||
extent="550 35"
|
|
||||||
minExtent="8 2"
|
|
||||||
horizSizing="right"
|
|
||||||
vertSizing="bottom"
|
|
||||||
profile="GuiDefaultProfile"
|
|
||||||
visible="true"
|
|
||||||
active="true"
|
|
||||||
tooltipProfile="GuiToolTipProfile"
|
|
||||||
hovertime="1000"
|
|
||||||
isContainer="false"
|
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="false" />
|
|
||||||
<GuiTextCtrl
|
|
||||||
text="Move Forward"
|
|
||||||
maxLength="1024"
|
|
||||||
margin="0 0 0 0"
|
|
||||||
padding="0 0 0 0"
|
|
||||||
anchorTop="true"
|
|
||||||
anchorBottom="false"
|
|
||||||
anchorLeft="true"
|
|
||||||
anchorRight="false"
|
|
||||||
position="0 0"
|
|
||||||
extent="550 35"
|
|
||||||
minExtent="8 2"
|
|
||||||
horizSizing="right"
|
|
||||||
vertSizing="bottom"
|
|
||||||
profile="GuiMenuButtonProfile"
|
|
||||||
visible="true"
|
|
||||||
active="true"
|
|
||||||
tooltipProfile="GuiToolTipProfile"
|
|
||||||
hovertime="1000"
|
|
||||||
isContainer="true"
|
|
||||||
internalName="nameText"
|
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="false" />
|
|
||||||
<GuiContainer
|
|
||||||
margin="0 0 0 0"
|
|
||||||
padding="0 0 0 0"
|
|
||||||
anchorTop="true"
|
|
||||||
anchorBottom="false"
|
|
||||||
anchorLeft="true"
|
|
||||||
anchorRight="false"
|
|
||||||
position="550 0"
|
|
||||||
extent="150 35"
|
|
||||||
minExtent="8 2"
|
|
||||||
horizSizing="right"
|
|
||||||
vertSizing="bottom"
|
|
||||||
profile="GuiDefaultProfile"
|
|
||||||
visible="true"
|
|
||||||
active="true"
|
|
||||||
tooltipProfile="GuiToolTipProfile"
|
|
||||||
hovertime="1000"
|
|
||||||
isContainer="true"
|
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="false">
|
|
||||||
<GuiButtonCtrl
|
|
||||||
text="W"
|
|
||||||
groupNum="-1"
|
|
||||||
buttonType="PushButton"
|
|
||||||
useMouseEvents="true"
|
|
||||||
position="0 0"
|
|
||||||
extent="150 35"
|
|
||||||
minExtent="8 8"
|
|
||||||
horizSizing="relative"
|
|
||||||
vertSizing="bottom"
|
|
||||||
profile="GuiMenuButtonProfile"
|
|
||||||
visible="true"
|
|
||||||
active="true"
|
|
||||||
tooltipProfile="GuiToolTipProfile"
|
|
||||||
hovertime="1000"
|
|
||||||
isContainer="false"
|
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="false"
|
|
||||||
internalName="rebindButton"
|
|
||||||
className="ControlsMenuRebindButton"/>
|
|
||||||
</GuiContainer>
|
|
||||||
</GuiContainer>
|
|
||||||
|
|
@ -425,7 +425,7 @@ $guiContent = new GuiControl(JoinServerMenu) {
|
||||||
vertSizing = "bottom";
|
vertSizing = "bottom";
|
||||||
profile = "GuiMenuButtonProfile";
|
profile = "GuiMenuButtonProfile";
|
||||||
visible = "1";
|
visible = "1";
|
||||||
active = "1";
|
active = "0";
|
||||||
command = "JoinServerMenu.join();";
|
command = "JoinServerMenu.join();";
|
||||||
tooltipProfile = "GuiToolTipProfile";
|
tooltipProfile = "GuiToolTipProfile";
|
||||||
hovertime = "1000";
|
hovertime = "1000";
|
||||||
|
|
|
||||||
|
|
@ -1,10 +1,6 @@
|
||||||
|
|
||||||
function JoinServerMenu::onWake()
|
function JoinServerMenu::onWake(%this)
|
||||||
{
|
{
|
||||||
// Double check the status. Tried setting this the control
|
|
||||||
// inactive to start with, but that didn't seem to work.
|
|
||||||
JoinServerJoinBtn.setActive(JoinServerList.getCount() > 0);
|
|
||||||
|
|
||||||
JoinServerButtonHolder.setActive();
|
JoinServerButtonHolder.setActive();
|
||||||
|
|
||||||
JoinServerList.setAsActiveMenuList();
|
JoinServerList.setAsActiveMenuList();
|
||||||
|
|
@ -128,7 +124,7 @@ function JoinServerMenu::update(%this)
|
||||||
JoinServerList.add(%serverBtn);
|
JoinServerList.add(%serverBtn);
|
||||||
}
|
}
|
||||||
|
|
||||||
JoinServerJoinBtn.setActive(JoinServerList.getCount() > 0);
|
JoinServerButtonHolder-->joinButton.setActive(JoinServerList.getCount() > 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
//----------------------------------------
|
//----------------------------------------
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
//--- OBJECT WRITE BEGIN ---
|
//--- OBJECT WRITE BEGIN ---
|
||||||
$guiContent = new GuiChunkedBitmapCtrl(MainMenuGui) {
|
$guiContent = new GuiChunkedBitmapCtrl(MainMenuGui) {
|
||||||
BitmapAsset = "UI:background_dark_image";
|
BitmapAsset = "UI:backgrounddark_image";
|
||||||
useVariable = "0";
|
useVariable = "0";
|
||||||
tile = "0";
|
tile = "0";
|
||||||
position = "0 0";
|
position = "0 0";
|
||||||
|
|
@ -203,7 +203,7 @@ $guiContent = new GuiChunkedBitmapCtrl(MainMenuGui) {
|
||||||
profile = "GuiMenuButtonProfile";
|
profile = "GuiMenuButtonProfile";
|
||||||
visible = "1";
|
visible = "1";
|
||||||
active = "1";
|
active = "1";
|
||||||
command = "exit();";
|
command = "quit();";
|
||||||
tooltipProfile = "GuiToolTipProfile";
|
tooltipProfile = "GuiToolTipProfile";
|
||||||
hovertime = "1000";
|
hovertime = "1000";
|
||||||
isContainer = "0";
|
isContainer = "0";
|
||||||
|
|
|
||||||
|
|
@ -66,4 +66,5 @@ function MainMenuGui::onReturnTo(%this)
|
||||||
MainMenuButtonList.hidden = false;
|
MainMenuButtonList.hidden = false;
|
||||||
MainMenuButtonList.setFirstResponder();
|
MainMenuButtonList.setFirstResponder();
|
||||||
MainMenuButtonHolder.setActive();
|
MainMenuButtonHolder.setActive();
|
||||||
}
|
MainMenuButtonList.setAsActiveMenuList();
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -34,7 +34,7 @@ $guiContent = new GuiControl(MessageBoxDlg) {
|
||||||
percent = "100";
|
percent = "100";
|
||||||
vertical = "0";
|
vertical = "0";
|
||||||
flipClip = "0";
|
flipClip = "0";
|
||||||
bitmap = "data/ui/images/panel.png";
|
bitmapAsset = "UI:panel_image";
|
||||||
color = "255 255 255 255";
|
color = "255 255 255 255";
|
||||||
position = "0 0";
|
position = "0 0";
|
||||||
extent = "641 40";
|
extent = "641 40";
|
||||||
|
|
@ -77,7 +77,7 @@ $guiContent = new GuiControl(MessageBoxDlg) {
|
||||||
percent = "100";
|
percent = "100";
|
||||||
vertical = "0";
|
vertical = "0";
|
||||||
flipClip = "0";
|
flipClip = "0";
|
||||||
bitmap = "data/ui/images/panel_low.png";
|
bitmapAsset = "UI:panel_low_image";
|
||||||
color = "255 255 255 255";
|
color = "255 255 255 255";
|
||||||
position = "0 40";
|
position = "0 40";
|
||||||
extent = "641 341";
|
extent = "641 341";
|
||||||
|
|
|
||||||
|
|
@ -554,4 +554,4 @@ function NetGraph::updateNetworkSimulation(%this)
|
||||||
}
|
}
|
||||||
|
|
||||||
netSimulateLag( %latency, %packetLoss );
|
netSimulateLag( %latency, %packetLoss );
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -213,127 +213,6 @@ $guiContent = new GuiControl(OptionsMenu) {
|
||||||
class = "MenuList";
|
class = "MenuList";
|
||||||
canSave = "1";
|
canSave = "1";
|
||||||
canSaveDynamicFields = "0";
|
canSaveDynamicFields = "0";
|
||||||
|
|
||||||
new GuiButtonCtrl(OptionsMenuDisplayBtn) {
|
|
||||||
text = "Display";
|
|
||||||
groupNum = "-1";
|
|
||||||
buttonType = "PushButton";
|
|
||||||
useMouseEvents = "0";
|
|
||||||
position = "0 0";
|
|
||||||
extent = "248 35";
|
|
||||||
minExtent = "8 2";
|
|
||||||
horizSizing = "right";
|
|
||||||
vertSizing = "bottom";
|
|
||||||
profile = "GuiMenuButtonProfile";
|
|
||||||
visible = "1";
|
|
||||||
active = "1";
|
|
||||||
command = "populateDisplaySettingsList();";
|
|
||||||
tooltipProfile = "GuiToolTipProfile";
|
|
||||||
hovertime = "1000";
|
|
||||||
isContainer = "0";
|
|
||||||
canSave = "1";
|
|
||||||
canSaveDynamicFields = "0";
|
|
||||||
};
|
|
||||||
new GuiButtonCtrl(OptionsMenuGraphicsBtn) {
|
|
||||||
text = "Graphics";
|
|
||||||
groupNum = "-1";
|
|
||||||
buttonType = "PushButton";
|
|
||||||
useMouseEvents = "0";
|
|
||||||
position = "0 45";
|
|
||||||
extent = "248 35";
|
|
||||||
minExtent = "8 2";
|
|
||||||
horizSizing = "right";
|
|
||||||
vertSizing = "bottom";
|
|
||||||
profile = "GuiMenuButtonProfile";
|
|
||||||
visible = "1";
|
|
||||||
active = "1";
|
|
||||||
command = "populateGraphicsSettingsList();";
|
|
||||||
tooltipProfile = "GuiToolTipProfile";
|
|
||||||
hovertime = "1000";
|
|
||||||
isContainer = "0";
|
|
||||||
canSave = "1";
|
|
||||||
canSaveDynamicFields = "0";
|
|
||||||
};
|
|
||||||
new GuiButtonCtrl(OptionsMenuAudioBtn) {
|
|
||||||
text = "Audio";
|
|
||||||
groupNum = "-1";
|
|
||||||
buttonType = "PushButton";
|
|
||||||
useMouseEvents = "0";
|
|
||||||
position = "0 90";
|
|
||||||
extent = "248 35";
|
|
||||||
minExtent = "8 2";
|
|
||||||
horizSizing = "right";
|
|
||||||
vertSizing = "bottom";
|
|
||||||
profile = "GuiMenuButtonProfile";
|
|
||||||
visible = "1";
|
|
||||||
active = "1";
|
|
||||||
command = "populateAudioSettingsList();";
|
|
||||||
tooltipProfile = "GuiToolTipProfile";
|
|
||||||
hovertime = "1000";
|
|
||||||
isContainer = "0";
|
|
||||||
canSave = "1";
|
|
||||||
canSaveDynamicFields = "0";
|
|
||||||
};
|
|
||||||
new GuiButtonCtrl(OptionsMenuKBMBtn) {
|
|
||||||
text = "Keyboard & Mouse";
|
|
||||||
groupNum = "-1";
|
|
||||||
buttonType = "PushButton";
|
|
||||||
useMouseEvents = "0";
|
|
||||||
position = "0 135";
|
|
||||||
extent = "248 35";
|
|
||||||
minExtent = "8 2";
|
|
||||||
horizSizing = "right";
|
|
||||||
vertSizing = "bottom";
|
|
||||||
profile = "GuiMenuButtonProfile";
|
|
||||||
visible = "1";
|
|
||||||
active = "1";
|
|
||||||
command = "populateKeyboardMouseSettingsList();";
|
|
||||||
tooltipProfile = "GuiToolTipProfile";
|
|
||||||
hovertime = "1000";
|
|
||||||
isContainer = "0";
|
|
||||||
canSave = "1";
|
|
||||||
canSaveDynamicFields = "0";
|
|
||||||
};
|
|
||||||
new GuiButtonCtrl(OptionsMenuGamepadBtn) {
|
|
||||||
text = "Gamepad";
|
|
||||||
groupNum = "-1";
|
|
||||||
buttonType = "PushButton";
|
|
||||||
useMouseEvents = "0";
|
|
||||||
position = "0 180";
|
|
||||||
extent = "248 35";
|
|
||||||
minExtent = "8 2";
|
|
||||||
horizSizing = "right";
|
|
||||||
vertSizing = "bottom";
|
|
||||||
profile = "GuiMenuButtonProfile";
|
|
||||||
visible = "1";
|
|
||||||
active = "1";
|
|
||||||
command = "populateGamepadSettingsList();";
|
|
||||||
tooltipProfile = "GuiToolTipProfile";
|
|
||||||
hovertime = "1000";
|
|
||||||
isContainer = "0";
|
|
||||||
canSave = "1";
|
|
||||||
canSaveDynamicFields = "0";
|
|
||||||
};
|
|
||||||
new GuiButtonCtrl(OptionsMenuProfileBtn) {
|
|
||||||
text = "Profile";
|
|
||||||
groupNum = "-1";
|
|
||||||
buttonType = "PushButton";
|
|
||||||
useMouseEvents = "0";
|
|
||||||
position = "0 225";
|
|
||||||
extent = "248 35";
|
|
||||||
minExtent = "8 2";
|
|
||||||
horizSizing = "right";
|
|
||||||
vertSizing = "bottom";
|
|
||||||
profile = "GuiMenuButtonProfile";
|
|
||||||
visible = "1";
|
|
||||||
active = "1";
|
|
||||||
command = "populateProfileSettingsList();";
|
|
||||||
tooltipProfile = "GuiToolTipProfile";
|
|
||||||
hovertime = "1000";
|
|
||||||
isContainer = "0";
|
|
||||||
canSave = "1";
|
|
||||||
canSaveDynamicFields = "0";
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
new GuiPanel() {
|
new GuiPanel() {
|
||||||
|
|
@ -493,68 +372,6 @@ $guiContent = new GuiControl(OptionsMenu) {
|
||||||
canSave = "1";
|
canSave = "1";
|
||||||
canSaveDynamicFields = "0";
|
canSaveDynamicFields = "0";
|
||||||
};
|
};
|
||||||
new GuiIconButtonCtrl() {
|
|
||||||
buttonMargin = "4 4";
|
|
||||||
BitmapAsset = "UI:Switch_LB_image";
|
|
||||||
iconLocation = "Left";
|
|
||||||
sizeIconToButton = "1";
|
|
||||||
makeIconSquare = "1";
|
|
||||||
textLocation = "Right";
|
|
||||||
textMargin = "4";
|
|
||||||
autoSize = "0";
|
|
||||||
text = "Prev Tab";
|
|
||||||
groupNum = "-1";
|
|
||||||
buttonType = "PushButton";
|
|
||||||
useMouseEvents = "0";
|
|
||||||
position = "0 0";
|
|
||||||
extent = "140 40";
|
|
||||||
minExtent = "8 2";
|
|
||||||
horizSizing = "right";
|
|
||||||
vertSizing = "bottom";
|
|
||||||
profile = "GuiMenuButtonProfile";
|
|
||||||
visible = "0";
|
|
||||||
active = "0";
|
|
||||||
command = "OptionsMenu.prevTab();";
|
|
||||||
tooltipProfile = "GuiToolTipProfile";
|
|
||||||
hovertime = "1000";
|
|
||||||
isContainer = "0";
|
|
||||||
internalName = "prevTabButton";
|
|
||||||
class = "MenuInputButton";
|
|
||||||
hidden = "1";
|
|
||||||
canSave = "1";
|
|
||||||
canSaveDynamicFields = "0";
|
|
||||||
};
|
|
||||||
new GuiIconButtonCtrl() {
|
|
||||||
buttonMargin = "4 4";
|
|
||||||
BitmapAsset = "UI:Switch_RB_image";
|
|
||||||
iconLocation = "Left";
|
|
||||||
sizeIconToButton = "1";
|
|
||||||
makeIconSquare = "1";
|
|
||||||
textLocation = "Right";
|
|
||||||
textMargin = "4";
|
|
||||||
autoSize = "0";
|
|
||||||
text = "Next Tab";
|
|
||||||
groupNum = "-1";
|
|
||||||
buttonType = "PushButton";
|
|
||||||
useMouseEvents = "0";
|
|
||||||
position = "144 0";
|
|
||||||
extent = "140 40";
|
|
||||||
minExtent = "8 2";
|
|
||||||
horizSizing = "right";
|
|
||||||
vertSizing = "bottom";
|
|
||||||
profile = "GuiMenuButtonProfile";
|
|
||||||
visible = "0";
|
|
||||||
active = "0";
|
|
||||||
command = "OptionsMenu.nextTab();";
|
|
||||||
tooltipProfile = "GuiToolTipProfile";
|
|
||||||
hovertime = "1000";
|
|
||||||
isContainer = "0";
|
|
||||||
internalName = "nextTabButton";
|
|
||||||
class = "MenuInputButton";
|
|
||||||
hidden = "1";
|
|
||||||
canSave = "1";
|
|
||||||
canSaveDynamicFields = "0";
|
|
||||||
};
|
|
||||||
new GuiIconButtonCtrl() {
|
new GuiIconButtonCtrl() {
|
||||||
buttonMargin = "4 4";
|
buttonMargin = "4 4";
|
||||||
BitmapAsset = "UI:Keyboard_Black_R_image";
|
BitmapAsset = "UI:Keyboard_Black_R_image";
|
||||||
|
|
|
||||||
|
|
@ -46,12 +46,67 @@
|
||||||
//headbob
|
//headbob
|
||||||
//FOV
|
//FOV
|
||||||
|
|
||||||
|
function OptionsMenu::onAdd(%this)
|
||||||
|
{
|
||||||
|
if(!isObject(%this.optionsCategories))
|
||||||
|
{
|
||||||
|
%this.optionsCategories = new ArrayObject();
|
||||||
|
}
|
||||||
|
|
||||||
|
if(!isObject(%this.unappliedChanges))
|
||||||
|
{
|
||||||
|
%this.unappliedChanges = new ArrayObject();
|
||||||
|
}
|
||||||
|
|
||||||
|
addOptionsMenuCategory("Display", "populateDisplaySettingsList();");
|
||||||
|
addOptionsMenuCategory("Graphics", "populateGraphicsSettingsList();");
|
||||||
|
addOptionsMenuCategory("Audio", "populateAudioSettingsList();");
|
||||||
|
addOptionsMenuCategory("Keyboard & Mouse", "populateKeyboardMouseSettingsList();");
|
||||||
|
addOptionsMenuCategory("Gamepad", "populateGamepadSettingsList();");
|
||||||
|
}
|
||||||
|
|
||||||
function OptionsMenuSettingsList::onAdd(%this)
|
function OptionsMenuSettingsList::onAdd(%this)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function OptionsMenuSettingsList::getOptionsList(%this, %index)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
function OptionsMenu::onWake(%this)
|
function OptionsMenu::onWake(%this)
|
||||||
{
|
{
|
||||||
|
for(%i=0; %i < %this.optionsCategories.count(); %i++)
|
||||||
|
{
|
||||||
|
%catName = %this.optionsCategories.getKey(%i);
|
||||||
|
%callback = %this.optionsCategories.getValue(%i);
|
||||||
|
|
||||||
|
%newCatButton = new GuiButtonCtrl() {
|
||||||
|
text = %catName;
|
||||||
|
groupNum = "-1";
|
||||||
|
buttonType = "PushButton";
|
||||||
|
useMouseEvents = "0";
|
||||||
|
position = "0 180";
|
||||||
|
extent = "248 35";
|
||||||
|
minExtent = "8 2";
|
||||||
|
horizSizing = "right";
|
||||||
|
vertSizing = "bottom";
|
||||||
|
profile = "GuiMenuButtonProfile";
|
||||||
|
visible = "1";
|
||||||
|
active = "1";
|
||||||
|
command = %callback;
|
||||||
|
tooltipProfile = "GuiToolTipProfile";
|
||||||
|
hovertime = "1000";
|
||||||
|
isContainer = "0";
|
||||||
|
canSave = "1";
|
||||||
|
canSaveDynamicFields = "0";
|
||||||
|
};
|
||||||
|
|
||||||
|
OptionsMenuCategoryList.add(%newCatButton);
|
||||||
|
}
|
||||||
|
|
||||||
|
%this.unappliedChanges.empty();
|
||||||
|
|
||||||
MainMenuButtonList.hidden = true;
|
MainMenuButtonList.hidden = true;
|
||||||
|
|
||||||
OptionsMenuCategoryList.setAsActiveMenuList();
|
OptionsMenuCategoryList.setAsActiveMenuList();
|
||||||
|
|
@ -63,8 +118,6 @@ function OptionsMenu::onWake(%this)
|
||||||
|
|
||||||
function OptionsButtonHolder::onWake(%this)
|
function OptionsButtonHolder::onWake(%this)
|
||||||
{
|
{
|
||||||
//%this-->prevTabButton.set("btn_l", "", "Prev Tab", "OptionsMenu.prevTab();", true);
|
|
||||||
%this-->nextTabButton.set("btn_a", "", "Select", "OptionsMenuList.activate();", true);
|
|
||||||
%this-->resetButton.set("btn_back", "R", "Reset", "OptionsMenu.resetToDefaults();");
|
%this-->resetButton.set("btn_back", "R", "Reset", "OptionsMenu.resetToDefaults();");
|
||||||
%this-->applyButton.set("btn_start", "Return", "Apply", "OptionsMenu.apply();");
|
%this-->applyButton.set("btn_start", "Return", "Apply", "OptionsMenu.apply();");
|
||||||
%this-->backButton.set("btn_b", "Escape", "Back", "OptionsMenu.backOut();");
|
%this-->backButton.set("btn_b", "Escape", "Back", "OptionsMenu.backOut();");
|
||||||
|
|
@ -74,19 +127,81 @@ function OptionsButtonHolder::onWake(%this)
|
||||||
|
|
||||||
function OptionsMenu::apply(%this)
|
function OptionsMenu::apply(%this)
|
||||||
{
|
{
|
||||||
if(%this.pageTabIndex == 0)
|
//Now we run through our list of unapplied changes and... apply them.
|
||||||
|
%hasKeybindChanges = false;
|
||||||
|
%hasVideoChanges = false;
|
||||||
|
%hasPostFXChanges = false;
|
||||||
|
%hasAudioChanges = false;
|
||||||
|
for(%i=0; %i < %this.unappliedChanges.count(); %i++)
|
||||||
{
|
{
|
||||||
%this.applyDisplaySettings();
|
%targetVar = %this.unappliedChanges.getKey(%i);
|
||||||
|
%newValue = %this.unappliedChanges.getValue(%i);
|
||||||
|
|
||||||
|
//First, lets just check through our action map names, see if any match
|
||||||
|
%wasKeybind = false;
|
||||||
|
for(%am=0; %am < ActionMapGroup.getCount(); %am++)
|
||||||
|
{
|
||||||
|
%actionMap = ActionMapGroup.getObject(%am);
|
||||||
|
|
||||||
|
if(%actionMap == GlobalActionMap.getId())
|
||||||
|
continue;
|
||||||
|
|
||||||
|
%actionMapName = %actionMap.humanReadableName $= "" ? %actionMap.getName() : %actionMap.humanReadableName;
|
||||||
|
if(%actionMapName $= %targetVar)
|
||||||
|
{
|
||||||
|
%hasKeybindChanges = true;
|
||||||
|
%wasKeybind = true;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if(!%wasKeybind)
|
||||||
|
{
|
||||||
|
%currentValue = getVariable(%targetVar);
|
||||||
|
if(%currentValue !$= %newValue)
|
||||||
|
{
|
||||||
|
setVariable(%targetVar, %newValue);
|
||||||
|
|
||||||
|
//now, lets check for special cases that need additional handling
|
||||||
|
//for updates
|
||||||
|
if ( %targetVar $= "$pref::Video::displayDevice" )
|
||||||
|
{
|
||||||
|
MessageBoxOK( "Change requires restart", "Please restart the game for a display device change to take effect." );
|
||||||
|
}
|
||||||
|
else if(startsWith(%targetVar, "$pref::Graphics::"))
|
||||||
|
{
|
||||||
|
//isolate the quality group name, like $pref::Graphics::LightingQuality
|
||||||
|
//we grab LightingQuality
|
||||||
|
%qualityGroupName = getSubStr(%targetVar, 17);
|
||||||
|
if(isObject(%qualityGroupName @ "List"))
|
||||||
|
{
|
||||||
|
//yep, it's a quality group, so apply it
|
||||||
|
(%qualityGroupName @ "List").applySetting(%newValue);
|
||||||
|
}
|
||||||
|
|
||||||
|
if(%qualityGroupName $= "TextureQuality")
|
||||||
|
{
|
||||||
|
reloadTextures();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if(startsWith(%targetVar, "$pref::PostFX::"))
|
||||||
|
{
|
||||||
|
%hasPostFXChanges = true;
|
||||||
|
}
|
||||||
|
else if(startsWith(%targetVar, "$pref::Video::"))
|
||||||
|
{
|
||||||
|
%hasVideoChanges = true;
|
||||||
|
}
|
||||||
|
else if(startsWith(%targetVar, "$pref::SFX::"))
|
||||||
|
{
|
||||||
|
%hasAudioChanges = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if(%this.pageTabIndex == 1)
|
|
||||||
{
|
//If we had keybind changes, go ahead and save those out
|
||||||
%this.applyGraphicsSettings();
|
if(%hasKeybindChanges)
|
||||||
}
|
|
||||||
else if(%this.pageTabIndex == 2)
|
|
||||||
{
|
|
||||||
%this.applyAudioSettings();
|
|
||||||
}
|
|
||||||
else if(%this.pageTabIndex == 3 || %this.pageTabIndex == 4)
|
|
||||||
{
|
{
|
||||||
%prefPath = getPrefpath();
|
%prefPath = getPrefpath();
|
||||||
|
|
||||||
|
|
@ -108,8 +223,26 @@ function OptionsMenu::apply(%this)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(%hasPostFXChanges)
|
||||||
|
{
|
||||||
|
updatePostFXSettings();
|
||||||
|
}
|
||||||
|
|
||||||
|
if(%hasVideoChanges)
|
||||||
|
{
|
||||||
|
updateDisplaySettings();
|
||||||
|
}
|
||||||
|
|
||||||
|
if(%hasAudioChanges)
|
||||||
|
{
|
||||||
|
updateAudioSettings();
|
||||||
|
}
|
||||||
|
|
||||||
|
//Finally, write our prefs to file
|
||||||
%prefPath = getPrefpath();
|
%prefPath = getPrefpath();
|
||||||
export("$pref::*", %prefPath @ "/clientPrefs." @ $TorqueScriptFileExtension, false);
|
export("$pref::*", %prefPath @ "/clientPrefs." @ $TorqueScriptFileExtension, false);
|
||||||
|
|
||||||
|
OptionsMenu.unappliedChanges.empty();
|
||||||
}
|
}
|
||||||
|
|
||||||
function OptionsMenu::resetToDefaults(%this)
|
function OptionsMenu::resetToDefaults(%this)
|
||||||
|
|
@ -117,77 +250,9 @@ function OptionsMenu::resetToDefaults(%this)
|
||||||
MessageBoxOKCancel("", "This will set the graphical settings back to the auto-detected defaults. Do you wish to continue?", "AutodetectGraphics();", "");
|
MessageBoxOKCancel("", "This will set the graphical settings back to the auto-detected defaults. Do you wish to continue?", "AutodetectGraphics();", "");
|
||||||
}
|
}
|
||||||
|
|
||||||
function OptionsMenuSettingsList::onChange(%this)
|
//
|
||||||
{
|
//
|
||||||
%optionName = %this.getRowLabel(%this.getSelectedRow());
|
//
|
||||||
%tooltipText = %this.getTooltip(%this.getSelectedRow());
|
|
||||||
|
|
||||||
OptionName.setText(%optionName);
|
|
||||||
OptionDescription.setText(%tooltipText);
|
|
||||||
return;
|
|
||||||
|
|
||||||
OptionsMenuSettingsList.clearOptions();
|
|
||||||
|
|
||||||
%currentRowText = %this.getRowLabel(%this.getSelectedRow());
|
|
||||||
|
|
||||||
if(%currentRowText $= "Display")
|
|
||||||
{
|
|
||||||
populateDisplaySettingsList();
|
|
||||||
}
|
|
||||||
else if(%currentRowText $= "Graphics")
|
|
||||||
{
|
|
||||||
populateGraphicsSettingsList();
|
|
||||||
}
|
|
||||||
else if(%currentRowText $= "Audio")
|
|
||||||
{
|
|
||||||
populateAudioSettingsList();
|
|
||||||
}
|
|
||||||
else if(%currentRowText $= "Keyboard + Mouse")
|
|
||||||
{
|
|
||||||
populateKeyboardMouseSettingsList();
|
|
||||||
}
|
|
||||||
else if(%currentRowText $= "Gamepad")
|
|
||||||
{
|
|
||||||
populateGamepadSettingsList();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function OptionsMenu::prevTab(%this)
|
|
||||||
{
|
|
||||||
%this.pageTabIndex--;
|
|
||||||
if(%this.pageTabIndex < 0)
|
|
||||||
%this.pageTabIndex = 4;
|
|
||||||
|
|
||||||
%tabBtn = %this.getTab();
|
|
||||||
%tabBtn.performClick();
|
|
||||||
}
|
|
||||||
|
|
||||||
function OptionsMenu::nextTab(%this)
|
|
||||||
{
|
|
||||||
%this.pageTabIndex++;
|
|
||||||
if(%this.pageTabIndex > 4)
|
|
||||||
%this.pageTabIndex = 0;
|
|
||||||
|
|
||||||
%tabBtn = %this.getTab();
|
|
||||||
%tabBtn.performClick();
|
|
||||||
}
|
|
||||||
|
|
||||||
function OptionsMenu::getTab(%this)
|
|
||||||
{
|
|
||||||
if(%this.pageTabIndex == 0)
|
|
||||||
return %this-->DisplayButton;
|
|
||||||
else if(%this.pageTabIndex == 1)
|
|
||||||
return %this-->GraphicsButton;
|
|
||||||
else if(%this.pageTabIndex == 2)
|
|
||||||
return %this-->AudioButton;
|
|
||||||
else if(%this.pageTabIndex == 3)
|
|
||||||
return %this-->KBMButton;
|
|
||||||
else if(%this.pageTabIndex == 4)
|
|
||||||
return %this-->GamepadButton;
|
|
||||||
else
|
|
||||||
return %this-->DisplayButton;
|
|
||||||
}
|
|
||||||
|
|
||||||
function populateDisplaySettingsList()
|
function populateDisplaySettingsList()
|
||||||
{
|
{
|
||||||
OptionsMenuSettingsList.clear();
|
OptionsMenuSettingsList.clear();
|
||||||
|
|
@ -220,7 +285,7 @@ function populateDisplaySettingsList()
|
||||||
|
|
||||||
trim(%apiList);
|
trim(%apiList);
|
||||||
|
|
||||||
OptionsMenuSettingsList.addOptionRow("Display API", %apiList, false, "", true, "The display API used for rendering.", %displayDevice);
|
OptionsMenuSettingsList.addOptionRow("Display API", "$pref::Video::DisplayAPI", %apiList, false, "", true, "The display API used for rendering.", %displayDevice);
|
||||||
|
|
||||||
%numDevices = Canvas.getMonitorCount();
|
%numDevices = Canvas.getMonitorCount();
|
||||||
%devicesList = "";
|
%devicesList = "";
|
||||||
|
|
@ -234,7 +299,7 @@ function populateDisplaySettingsList()
|
||||||
}
|
}
|
||||||
|
|
||||||
%selectedDevice = getField(%devicesList, $pref::Video::deviceId);
|
%selectedDevice = getField(%devicesList, $pref::Video::deviceId);
|
||||||
OptionsMenuSettingsList.addOptionRow("Display Device", %devicesList, false, "onDisplayModeChange", true, "The display devices the window should be on.", %selectedDevice);
|
OptionsMenuSettingsList.addOptionRow("Display Device", "$pref::Video::deviceId", %devicesList, false, "", true, "The display devices the window should be on.", %selectedDevice);
|
||||||
|
|
||||||
if (%numDevices > 1)
|
if (%numDevices > 1)
|
||||||
OptionsMenuSettingsList.setRowEnabled(1, true);
|
OptionsMenuSettingsList.setRowEnabled(1, true);
|
||||||
|
|
@ -242,10 +307,10 @@ function populateDisplaySettingsList()
|
||||||
OptionsMenuSettingsList.setRowEnabled(1, false);
|
OptionsMenuSettingsList.setRowEnabled(1, false);
|
||||||
|
|
||||||
%mode = getField($Video::ModeTags, $pref::Video::deviceMode);
|
%mode = getField($Video::ModeTags, $pref::Video::deviceMode);
|
||||||
OptionsMenuSettingsList.addOptionRow("Window Mode", $Video::ModeTags, false, "onDisplayModeChange", true, "", %mode);
|
OptionsMenuSettingsList.addOptionRow("Window Mode", "$pref::Video::deviceMode", $Video::ModeTags, false, "", true, "", %mode);
|
||||||
|
|
||||||
%resolutionList = getScreenResolutionList($pref::Video::deviceId, $pref::Video::deviceMode);
|
%resolutionList = getScreenResolutionList($pref::Video::deviceId, $pref::Video::deviceMode);
|
||||||
OptionsMenuSettingsList.addOptionRow("Resolution", %resolutionList, false, "onDisplayResChange", true, "Resolution of the game window", _makePrettyResString( $pref::Video::mode ));
|
OptionsMenuSettingsList.addOptionRow("Resolution", "$pref::Video::Resolution", %resolutionList, false, "onDisplayResChange", true, "Resolution of the game window", _makePrettyResString( $pref::Video::mode ));
|
||||||
|
|
||||||
//If they're doing borderless, the window resolution must match the display resolution
|
//If they're doing borderless, the window resolution must match the display resolution
|
||||||
if(%mode !$= "Borderless")
|
if(%mode !$= "Borderless")
|
||||||
|
|
@ -253,20 +318,20 @@ function populateDisplaySettingsList()
|
||||||
else
|
else
|
||||||
OptionsMenuSettingsList.setRowEnabled(3, false);
|
OptionsMenuSettingsList.setRowEnabled(3, false);
|
||||||
|
|
||||||
OptionsMenuSettingsList.addOptionRow("VSync", "No\tYes", false, "", true, "", convertBoolToYesNo(!$pref::Video::disableVerticalSync));
|
OptionsMenuSettingsList.addOptionRow("VSync", "$pref::Video::disableVerticalSync", "No\tYes", false, "", true, "", convertBoolToYesNo(!$pref::Video::disableVerticalSync));
|
||||||
|
|
||||||
|
|
||||||
%refreshList = getScreenRefreshList($pref::Video::mode);
|
%refreshList = getScreenRefreshList($pref::Video::mode);
|
||||||
OptionsMenuSettingsList.addOptionRow("Refresh Rate", %refreshList, false, "", true, "", $pref::Video::RefreshRate);
|
OptionsMenuSettingsList.addOptionRow("Refresh Rate", "$pref::Video::RefreshRate", %refreshList, false, "", true, "", $pref::Video::RefreshRate);
|
||||||
|
|
||||||
//move to gameplay tab
|
//move to gameplay tab
|
||||||
OptionsMenuSettingsList.addSliderRow("Field of View", 75, 5, "65 100", "");
|
OptionsMenuSettingsList.addSliderRow("Field of View", "", 75, 5, "65 100", "");
|
||||||
|
|
||||||
OptionsMenuSettingsList.addSliderRow("Brightness", 0.5, 0.1, "0 1", "");
|
OptionsMenuSettingsList.addSliderRow("Brightness", "", 0.5, 0.1, "0 1", "");
|
||||||
OptionsMenuSettingsList.addSliderRow("Contrast", 0.5, 0.1, "0 1", "");
|
OptionsMenuSettingsList.addSliderRow("Contrast", "", 0.5, 0.1, "0 1", "");
|
||||||
}
|
}
|
||||||
|
|
||||||
function OptionsMenu::applyDisplaySettings(%this)
|
/*function OptionsMenu::applyDisplaySettings(%this)
|
||||||
{
|
{
|
||||||
%newDevice = OptionsMenuSettingsList.getCurrentOption(0);
|
%newDevice = OptionsMenuSettingsList.getCurrentOption(0);
|
||||||
|
|
||||||
|
|
@ -285,9 +350,12 @@ function OptionsMenu::applyDisplaySettings(%this)
|
||||||
echo("Exporting client prefs");
|
echo("Exporting client prefs");
|
||||||
%prefPath = getPrefpath();
|
%prefPath = getPrefpath();
|
||||||
export("$pref::*", %prefPath @ "/clientPrefs." @ $TorqueScriptFileExtension, false);
|
export("$pref::*", %prefPath @ "/clientPrefs." @ $TorqueScriptFileExtension, false);
|
||||||
}
|
}*/
|
||||||
|
|
||||||
function populateGraphicsSettingsList(%this)
|
//
|
||||||
|
//
|
||||||
|
//
|
||||||
|
function populateGraphicsSettingsList()
|
||||||
{
|
{
|
||||||
OptionsMenuSettingsList.clear();
|
OptionsMenuSettingsList.clear();
|
||||||
|
|
||||||
|
|
@ -299,90 +367,32 @@ function populateGraphicsSettingsList(%this)
|
||||||
%highMedLow = "Low\tMedium\tHigh";
|
%highMedLow = "Low\tMedium\tHigh";
|
||||||
%anisoFilter = "Off\t4\t8\t16";
|
%anisoFilter = "Off\t4\t8\t16";
|
||||||
%aaFilter = "Off\t1\t2\t4";
|
%aaFilter = "Off\t1\t2\t4";
|
||||||
OptionsMenuSettingsList.addOptionRow("Lighting Quality", getQualityLevels(LightingQualityList), false, "", true, "Amount and drawdistance of local lights", getCurrentQualityLevel(LightingQualityList));
|
OptionsMenuSettingsList.addOptionRow("Lighting Quality", "$pref::Graphics::LightingQuality", getQualityLevels(LightingQualityList), false, "", true, "Amount and drawdistance of local lights", getCurrentQualityLevel(LightingQualityList));
|
||||||
OptionsMenuSettingsList.addOptionRow("Shadow Quality", getQualityLevels(ShadowQualityList), false, "", true, "Shadow revolution quality", getCurrentQualityLevel(ShadowQualityList));
|
OptionsMenuSettingsList.addOptionRow("Shadow Quality", "$pref::Graphics::ShadowQuality", getQualityLevels(ShadowQualityList), false, "", true, "Shadow revolution quality", getCurrentQualityLevel(ShadowQualityList));
|
||||||
OptionsMenuSettingsList.addOptionRow("Soft Shadow Quality", getQualityLevels(SoftShadowList), false, "", true, "Amount of softening applied to shadowmaps", getCurrentQualityLevel(SoftShadowList));
|
OptionsMenuSettingsList.addOptionRow("Soft Shadow Quality", "$pref::Graphics::SoftShadowQuality", getQualityLevels(SoftShadowList), false, "", true, "Amount of softening applied to shadowmaps", getCurrentQualityLevel(SoftShadowList));
|
||||||
OptionsMenuSettingsList.addOptionRow("Mesh Quality", getQualityLevels(MeshQualityGroup), false, "", true, "Fidelity of rendering of mesh objects", getCurrentQualityLevel(MeshQualityGroup));
|
OptionsMenuSettingsList.addOptionRow("Mesh Quality", "$pref::Graphics::MeshQuality", getQualityLevels(MeshQualityGroup), false, "", true, "Fidelity of rendering of mesh objects", getCurrentQualityLevel(MeshQualityGroup));
|
||||||
OptionsMenuSettingsList.addOptionRow("Object Draw Distance", getQualityLevels(MeshDrawDistQualityGroup), false, "", true, "Dictates if and when static objects fade out in the distance", getCurrentQualityLevel(MeshDrawDistQualityGroup));
|
OptionsMenuSettingsList.addOptionRow("Object Draw Distance", "$pref::Graphics::ObjectDrawDistance", getQualityLevels(MeshDrawDistQualityGroup), false, "", true, "Dictates if and when static objects fade out in the distance", getCurrentQualityLevel(MeshDrawDistQualityGroup));
|
||||||
OptionsMenuSettingsList.addOptionRow("Texture Quality", getQualityLevels(TextureQualityGroup), false, "", true, "Fidelity of textures", getCurrentQualityLevel(TextureQualityGroup));
|
OptionsMenuSettingsList.addOptionRow("Texture Quality", "$pref::Graphics::TextureQuality", getQualityLevels(TextureQualityGroup), false, "", true, "Fidelity of textures", getCurrentQualityLevel(TextureQualityGroup));
|
||||||
OptionsMenuSettingsList.addOptionRow("Terrain Quality", getQualityLevels(TerrainQualityGroup), false, "", true, "Quality level of terrain objects", getCurrentQualityLevel(TerrainQualityGroup));
|
OptionsMenuSettingsList.addOptionRow("Terrain Quality", "$pref::Graphics::TerrainQuality", getQualityLevels(TerrainQualityGroup), false, "", true, "Quality level of terrain objects", getCurrentQualityLevel(TerrainQualityGroup));
|
||||||
OptionsMenuSettingsList.addOptionRow("Decal Lifetime", getQualityLevels(DecalLifetimeGroup), false, "", true, "How long decals are rendered", getCurrentQualityLevel(DecalLifetimeGroup));
|
OptionsMenuSettingsList.addOptionRow("Decal Lifetime", "$pref::Graphics::DecalLifetime", getQualityLevels(DecalLifetimeGroup), false, "", true, "How long decals are rendered", getCurrentQualityLevel(DecalLifetimeGroup));
|
||||||
OptionsMenuSettingsList.addOptionRow("Ground Cover Density", getQualityLevels(GroundCoverDensityGroup), false, "", true, "Density of ground cover items, such as grass", getCurrentQualityLevel(GroundCoverDensityGroup));
|
OptionsMenuSettingsList.addOptionRow("Ground Cover Density", "$pref::Graphics::GroundCoverDensity", getQualityLevels(GroundCoverDensityGroup), false, "", true, "Density of ground cover items, such as grass", getCurrentQualityLevel(GroundCoverDensityGroup));
|
||||||
OptionsMenuSettingsList.addOptionRow("Shader Quality", getQualityLevels(ShaderQualityGroup), false, "", true, "Dictates the overall shader quality level, adjusting what features are enabled.", getCurrentQualityLevel(ShaderQualityGroup));
|
OptionsMenuSettingsList.addOptionRow("Shader Quality", "$pref::Graphics::ShaderQuality", getQualityLevels(ShaderQualityGroup), false, "", true, "Dictates the overall shader quality level, adjusting what features are enabled.", getCurrentQualityLevel(ShaderQualityGroup));
|
||||||
OptionsMenuSettingsList.addOptionRow("Anisotropic Filtering", %anisoFilter, false, "", true, "Amount of Anisotropic Filtering on textures, which dictates their sharpness at a distance", $pref::Video::defaultAnisotropy);
|
OptionsMenuSettingsList.addOptionRow("Anisotropic Filtering", "$pref::Video::defaultAnisotropy", %anisoFilter, false, "", true, "Amount of Anisotropic Filtering on textures, which dictates their sharpness at a distance", $pref::Video::defaultAnisotropy);
|
||||||
OptionsMenuSettingsList.addOptionRow("Anti-Aliasing", %aaFilter, false, "", true, "Amount of Post-Processing Anti-Aliasing applied to rendering", $pref::Video::AA);
|
OptionsMenuSettingsList.addOptionRow("Anti-Aliasing", "$pref::Video::AA", %aaFilter, false, "", true, "Amount of Post-Processing Anti-Aliasing applied to rendering", $pref::Video::AA);
|
||||||
OptionsMenuSettingsList.addOptionRow("Parallax", %onOffList, false, "", true, "Whether the surface parallax shader effect is enabled", convertBoolToOnOff(!$pref::Video::disableParallaxMapping));
|
OptionsMenuSettingsList.addOptionRow("Parallax", "$pref::Video::disableParallaxMapping", %onOffList, false, "", true, "Whether the surface parallax shader effect is enabled", convertBoolToOnOff(!$pref::Video::disableParallaxMapping));
|
||||||
OptionsMenuSettingsList.addOptionRow("Water Reflections", %onOffList, false, "", true, "Whether water reflections are enabled", convertBoolToOnOff(!$pref::Water::disableTrueReflections));
|
OptionsMenuSettingsList.addOptionRow("Water Reflections", "$pref::Water::disableTrueReflections", %onOffList, false, "", true, "Whether water reflections are enabled", convertBoolToOnOff(!$pref::Water::disableTrueReflections));
|
||||||
OptionsMenuSettingsList.addOptionRow("SSAO", %onOffList, false, "", true, "Whether Screen-Space Ambient Occlusion is enabled", convertBoolToOnOff($pref::PostFX::EnableSSAO));
|
OptionsMenuSettingsList.addOptionRow("SSAO", "$pref::PostFX::EnableSSAO", %onOffList, false, "", true, "Whether Screen-Space Ambient Occlusion is enabled", convertBoolToOnOff($pref::PostFX::EnableSSAO));
|
||||||
OptionsMenuSettingsList.addOptionRow("Depth of Field", %onOffList, false, "", true, "Whether the Depth of Field effect is enabled", convertBoolToOnOff($pref::PostFX::EnableDOF));
|
OptionsMenuSettingsList.addOptionRow("Depth of Field", "$pref::PostFX::EnableDOF", %onOffList, false, "", true, "Whether the Depth of Field effect is enabled", convertBoolToOnOff($pref::PostFX::EnableDOF));
|
||||||
OptionsMenuSettingsList.addOptionRow("Vignette", %onOffList, false, "", true, "Whether the vignette effect is enabled", convertBoolToOnOff($pref::PostFX::EnableVignette));
|
OptionsMenuSettingsList.addOptionRow("Vignette", "$pref::PostFX::EnableVignette", %onOffList, false, "", true, "Whether the vignette effect is enabled", convertBoolToOnOff($pref::PostFX::EnableVignette));
|
||||||
OptionsMenuSettingsList.addOptionRow("Light Rays", %onOffList, false, "", true, "Whether the light rays effect is enabled", convertBoolToOnOff($pref::PostFX::EnableLightRays));
|
OptionsMenuSettingsList.addOptionRow("Light Rays", "$pref::PostFX::EnableLightRays", %onOffList, false, "", true, "Whether the light rays effect is enabled", convertBoolToOnOff($pref::PostFX::EnableLightRays));
|
||||||
}
|
}
|
||||||
|
|
||||||
function OptionsMenu::applyGraphicsSettings(%this)
|
|
||||||
{
|
|
||||||
LightingQualityList.applySetting(OptionsMenuSettingsList.getCurrentOption(0));
|
|
||||||
ShadowQualityList.applySetting(OptionsMenuSettingsList.getCurrentOption(1));
|
|
||||||
SoftShadowList.applySetting(OptionsMenuSettingsList.getCurrentOption(2));
|
|
||||||
|
|
||||||
MeshQualityGroup.applySetting(OptionsMenuSettingsList.getCurrentOption(3));
|
|
||||||
MeshDrawDistQualityGroup.applySetting(OptionsMenuSettingsList.getCurrentOption(4));
|
|
||||||
TextureQualityGroup.applySetting(OptionsMenuSettingsList.getCurrentOption(5));
|
|
||||||
TerrainQualityGroup.applySetting(OptionsMenuSettingsList.getCurrentOption(6));
|
|
||||||
DecalLifetimeGroup.applySetting(OptionsMenuSettingsList.getCurrentOption(7));
|
|
||||||
GroundCoverDensityGroup.applySetting(OptionsMenuSettingsList.getCurrentOption(8));
|
|
||||||
ShaderQualityGroup.applySetting(OptionsMenuSettingsList.getCurrentOption(9));
|
|
||||||
|
|
||||||
//Update Textures
|
|
||||||
reloadTextures();
|
|
||||||
|
|
||||||
//Update lighting
|
|
||||||
// Set the light manager. This should do nothing
|
|
||||||
// if its already set or if its not compatible.
|
|
||||||
//setLightManager( $pref::lightManager );
|
|
||||||
|
|
||||||
$pref::PostFX::EnableSSAO = convertOptionToBool(OptionsMenuSettingsList.getCurrentOption(14));
|
|
||||||
$pref::PostFX::EnableDOF = convertOptionToBool(OptionsMenuSettingsList.getCurrentOption(15));
|
|
||||||
$pref::PostFX::EnableVignette = convertOptionToBool(OptionsMenuSettingsList.getCurrentOption(16));
|
|
||||||
$pref::PostFX::EnableLightRays = convertOptionToBool(OptionsMenuSettingsList.getCurrentOption(17));
|
|
||||||
|
|
||||||
PostFXManager.settingsEffectSetEnabled(SSAOPostFx, $pref::PostFX::EnableSSAO);
|
|
||||||
PostFXManager.settingsEffectSetEnabled(DOFPostEffect, $pref::PostFX::EnableDOF);
|
|
||||||
PostFXManager.settingsEffectSetEnabled(LightRayPostFX, $pref::PostFX::EnableLightRays);
|
|
||||||
PostFXManager.settingsEffectSetEnabled(vignettePostFX, $pref::PostFX::EnableVignette);
|
|
||||||
|
|
||||||
$pref::Video::disableParallaxMapping = !convertOptionToBool(OptionsMenuSettingsList.getCurrentOption(12));
|
|
||||||
|
|
||||||
//water reflections
|
|
||||||
$pref::Water::disableTrueReflections = !convertOptionToBool(OptionsMenuSettingsList.getCurrentOption(13));
|
|
||||||
|
|
||||||
// Check the anisotropic filtering.
|
|
||||||
%level = OptionsMenuSettingsList.getCurrentOption(10);
|
|
||||||
if ( %level != $pref::Video::defaultAnisotropy )
|
|
||||||
{
|
|
||||||
$pref::Video::defaultAnisotropy = %level;
|
|
||||||
}
|
|
||||||
|
|
||||||
%newFSAA = OptionsMenuSettingsList.getCurrentOption(11);
|
|
||||||
if (%newFSAA $= "off")
|
|
||||||
%newFSAA = 0;
|
|
||||||
if (%newFSAA !$= $pref::Video::AA)
|
|
||||||
{
|
|
||||||
$pref::Video::AA = %newFSAA;
|
|
||||||
configureCanvas();
|
|
||||||
}
|
|
||||||
|
|
||||||
echo("Exporting client prefs");
|
|
||||||
%prefPath = getPrefpath();
|
|
||||||
export("$pref::*", %prefPath @ "/clientPrefs." @ $TorqueScriptFileExtension, false);
|
|
||||||
}
|
|
||||||
|
|
||||||
function updateDisplaySettings()
|
function updateDisplaySettings()
|
||||||
{
|
{
|
||||||
//Update the display settings now
|
//Update the display settings now
|
||||||
%deviceName = OptionsMenuSettingsList.getCurrentOption(1);
|
%deviceName = getDisplayDeviceName();
|
||||||
%newDeviceID = getWord(%deviceName, 0) - 1;
|
%newDeviceID = getWord(%deviceName, 0) - 1;
|
||||||
%deviceModeName = OptionsMenuSettingsList.getCurrentOption(2);
|
%deviceModeName = getField($Video::ModeTags, $pref::Video::deviceMode);
|
||||||
%newDeviceMode = 0;
|
%newDeviceMode = 0;
|
||||||
foreach$(%modeName in $Video::ModeTags)
|
foreach$(%modeName in $Video::ModeTags)
|
||||||
{
|
{
|
||||||
|
|
@ -392,15 +402,15 @@ function updateDisplaySettings()
|
||||||
%newDeviceMode++;
|
%newDeviceMode++;
|
||||||
}
|
}
|
||||||
|
|
||||||
%newRes = getWord(OptionsMenuSettingsList.getCurrentOption(3), 0) SPC getWord(OptionsMenuSettingsList.getCurrentOption(3), 2);
|
%newRes = $pref::Video::Resolution;
|
||||||
%newBpp = 32; // ... its not 1997 anymore.
|
%newBpp = 32; // ... its not 1997 anymore.
|
||||||
%newFullScreen = %deviceModeName $= "Fullscreen" ? true : false;
|
%newFullScreen = %deviceModeName $= "Fullscreen" ? true : false;
|
||||||
%newRefresh = OptionsMenuSettingsList.getCurrentOption(5);
|
%newRefresh = $pref::Video::RefreshRate;
|
||||||
%newVsync = !convertOptionToBool(OptionsMenuSettingsList.getCurrentOption(4));
|
%newVsync = !$pref::Video::disableVerticalSync;
|
||||||
%newFSAA = $pref::Video::AA;
|
%newFSAA = $pref::Video::AA;
|
||||||
|
|
||||||
// Build the final mode string.
|
// Build the final mode string.
|
||||||
%newMode = %newRes SPC %newFullScreen SPC %newBpp SPC %newRefresh SPC %newFSAA;
|
%newMode = $pref::Video::Resolution SPC %newFullScreen SPC %newBpp SPC %newRefresh SPC %newFSAA;
|
||||||
|
|
||||||
// Change the video mode.
|
// Change the video mode.
|
||||||
if ( %newMode !$= $pref::Video::mode || %newDeviceID != $pref::Video::deviceId ||
|
if ( %newMode !$= $pref::Video::mode || %newDeviceID != $pref::Video::deviceId ||
|
||||||
|
|
@ -433,7 +443,18 @@ function updateDisplaySettings()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function populateAudioSettingsList(%this)
|
function updatePostFXSettings()
|
||||||
|
{
|
||||||
|
PostFXManager.settingsEffectSetEnabled(SSAOPostFx, $pref::PostFX::EnableSSAO);
|
||||||
|
PostFXManager.settingsEffectSetEnabled(DOFPostEffect, $pref::PostFX::EnableDOF);
|
||||||
|
PostFXManager.settingsEffectSetEnabled(LightRayPostFX, $pref::PostFX::EnableLightRays);
|
||||||
|
PostFXManager.settingsEffectSetEnabled(vignettePostFX, $pref::PostFX::EnableVignette);
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
//
|
||||||
|
//
|
||||||
|
function populateAudioSettingsList()
|
||||||
{
|
{
|
||||||
OptionsMenuSettingsList.clear();
|
OptionsMenuSettingsList.clear();
|
||||||
|
|
||||||
|
|
@ -472,13 +493,13 @@ function populateAudioSettingsList(%this)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
OptionsMenuSettingsList.addOptionRow("Audio Provider", %audioProviderList, false, "audioProviderChanged", true, "", $currentAudioProvider);
|
OptionsMenuSettingsList.addOptionRow("Audio Provider", "$pref::SFX::AudioProvider", %audioProviderList, false, "audioProviderChanged", true, "", $currentAudioProvider);
|
||||||
OptionsMenuSettingsList.addOptionRow("Audio Device", %audioDeviceList, false, "", true, $pref::SFX::device);
|
OptionsMenuSettingsList.addOptionRow("Audio Device", "$pref::SFX::device", %audioDeviceList, false, "", true, $pref::SFX::device);
|
||||||
|
|
||||||
OptionsMenuSettingsList.addSliderRow("Master Volume", $pref::SFX::masterVolume, 0.1, "0 1", "");
|
OptionsMenuSettingsList.addSliderRow("Master Volume", "$pref::SFX::masterVolume", $pref::SFX::masterVolume, 0.1, "0 1", "");
|
||||||
OptionsMenuSettingsList.addSliderRow("GUI Volume", $pref::SFX::channelVolume[ $GuiAudioType], 0.1, "0 1", "");
|
OptionsMenuSettingsList.addSliderRow("GUI Volume", "$pref::SFX::channelVolume[ $GuiAudioType]", $pref::SFX::channelVolume[ $GuiAudioType], 0.1, "0 1", "");
|
||||||
OptionsMenuSettingsList.addSliderRow("Effects Volume", $pref::SFX::channelVolume[ $SimAudioType ], 0.1, "0 1", "");
|
OptionsMenuSettingsList.addSliderRow("Effects Volume", "$pref::SFX::channelVolume[ $SimAudioType ]", $pref::SFX::channelVolume[ $SimAudioType ], 0.1, "0 1", "");
|
||||||
OptionsMenuSettingsList.addSliderRow("Music Volume", $pref::SFX::channelVolume[ $MusicAudioType ], 0.1, "0 1", "");
|
OptionsMenuSettingsList.addSliderRow("Music Volume", "$pref::SFX::channelVolume[ $MusicAudioType ]", $pref::SFX::channelVolume[ $MusicAudioType ], 0.1, "0 1", "");
|
||||||
}
|
}
|
||||||
|
|
||||||
function audioProviderChanged()
|
function audioProviderChanged()
|
||||||
|
|
@ -491,21 +512,21 @@ function audioProviderChanged()
|
||||||
populateAudioSettingsList();
|
populateAudioSettingsList();
|
||||||
}
|
}
|
||||||
|
|
||||||
function OptionsMenu::applyAudioSettings(%this)
|
function updateAudioSettings()
|
||||||
{
|
{
|
||||||
$pref::SFX::masterVolume = OptionsMenuSettingsList.getValue(2);
|
//$pref::SFX::masterVolume = OptionsMenuSettingsList.getValue(2);
|
||||||
sfxSetMasterVolume( $pref::SFX::masterVolume );
|
sfxSetMasterVolume( $pref::SFX::masterVolume );
|
||||||
|
|
||||||
$pref::SFX::channelVolume[ $GuiAudioType ] = OptionsMenuSettingsList.getValue(3);
|
//$pref::SFX::channelVolume[ $GuiAudioType ] = OptionsMenuSettingsList.getValue(3);
|
||||||
$pref::SFX::channelVolume[ $SimAudioType ] = OptionsMenuSettingsList.getValue(4);
|
//$pref::SFX::channelVolume[ $SimAudioType ] = OptionsMenuSettingsList.getValue(4);
|
||||||
$pref::SFX::channelVolume[ $MusicAudioType ] = OptionsMenuSettingsList.getValue(5);
|
//$pref::SFX::channelVolume[ $MusicAudioType ] = OptionsMenuSettingsList.getValue(5);
|
||||||
|
|
||||||
sfxSetChannelVolume( $GuiAudioType, $pref::SFX::channelVolume[ $GuiAudioType ] );
|
sfxSetChannelVolume( $GuiAudioType, $pref::SFX::channelVolume[ $GuiAudioType ] );
|
||||||
sfxSetChannelVolume( $SimAudioType, $pref::SFX::channelVolume[ $SimAudioType ] );
|
sfxSetChannelVolume( $SimAudioType, $pref::SFX::channelVolume[ $SimAudioType ] );
|
||||||
sfxSetChannelVolume( $MusicAudioType, $pref::SFX::channelVolume[ $MusicAudioType ] );
|
sfxSetChannelVolume( $MusicAudioType, $pref::SFX::channelVolume[ $MusicAudioType ] );
|
||||||
|
|
||||||
$pref::SFX::provider = OptionsMenuSettingsList.getCurrentOption(0);
|
//$pref::SFX::provider = OptionsMenuSettingsList.getCurrentOption(0);
|
||||||
$pref::SFX::device = OptionsMenuSettingsList.getCurrentOption(1);
|
//$pref::SFX::device = OptionsMenuSettingsList.getCurrentOption(1);
|
||||||
|
|
||||||
if ( !sfxCreateDevice( $pref::SFX::provider,
|
if ( !sfxCreateDevice( $pref::SFX::provider,
|
||||||
$pref::SFX::device,
|
$pref::SFX::device,
|
||||||
|
|
@ -521,7 +542,10 @@ function OptionsMenu::applyAudioSettings(%this)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function populateKeyboardMouseSettingsList(%this)
|
//
|
||||||
|
//
|
||||||
|
//
|
||||||
|
function populateKeyboardMouseSettingsList()
|
||||||
{
|
{
|
||||||
OptionsMenuSettingsList.clear();
|
OptionsMenuSettingsList.clear();
|
||||||
|
|
||||||
|
|
@ -534,7 +558,7 @@ function populateKeyboardMouseSettingsList(%this)
|
||||||
//OptionsMenuSettingsList.refresh();
|
//OptionsMenuSettingsList.refresh();
|
||||||
}
|
}
|
||||||
|
|
||||||
function populateGamepadSettingsList(%this)
|
function populateGamepadSettingsList()
|
||||||
{
|
{
|
||||||
OptionsMenuSettingsList.clear();
|
OptionsMenuSettingsList.clear();
|
||||||
|
|
||||||
|
|
@ -544,15 +568,30 @@ function populateGamepadSettingsList(%this)
|
||||||
$remapListDevice = "gamepad";
|
$remapListDevice = "gamepad";
|
||||||
fillRemapList();
|
fillRemapList();
|
||||||
|
|
||||||
OptionsMenuSettingsList.refresh();
|
OptionsMenuSettingsList.updateStack();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
//
|
||||||
|
//
|
||||||
function OptionsMenuList::activateRow(%this)
|
function OptionsMenuList::activateRow(%this)
|
||||||
{
|
{
|
||||||
OptionsMenuSettingsList.setFirstResponder();
|
OptionsMenuSettingsList.setFirstResponder();
|
||||||
}
|
}
|
||||||
|
|
||||||
function OptionsMenu::backOut(%this)
|
function OptionsMenu::backOut(%this)
|
||||||
|
{
|
||||||
|
if(%this.unappliedChanges.count() != 0)
|
||||||
|
{
|
||||||
|
MessageBoxOKCancel("Discard Changes?", "You have unapplied changes to your settings, do you wish to continue?", "OptionsMenu.doOptionsMenuBackOut();", "");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
%this.doOptionsMenuBackOut();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function OptionsMenu::doOptionsMenuBackOut(%this)
|
||||||
{
|
{
|
||||||
//save the settings and then back out
|
//save the settings and then back out
|
||||||
if(OptionsMain.hidden == false)
|
if(OptionsMain.hidden == false)
|
||||||
|
|
@ -583,7 +622,7 @@ function OptionsMenuSettingsList::setRowEnabled(%this, %row, %status)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function OptionsMenuSettingsList::addOptionRow(%this, %label, %optionsList, %wrapOptions, %callback, %enabled, %description, %defaultValue)
|
function OptionsMenuSettingsList::addOptionRow(%this, %label, %targetPrefVar, %optionsList, %wrapOptions, %callback, %enabled, %description, %defaultValue)
|
||||||
{
|
{
|
||||||
if(%enabled $= "")
|
if(%enabled $= "")
|
||||||
%enabled = true;
|
%enabled = true;
|
||||||
|
|
@ -600,14 +639,27 @@ function OptionsMenuSettingsList::addOptionRow(%this, %label, %optionsList, %wra
|
||||||
extent = %this.extent.x SPC %optionsRowSize;
|
extent = %this.extent.x SPC %optionsRowSize;
|
||||||
columnSplit = %optionColumnWidth;
|
columnSplit = %optionColumnWidth;
|
||||||
useMouseEvents = true;
|
useMouseEvents = true;
|
||||||
|
previousBitmapAsset = "UI:previousOption_n_image";
|
||||||
|
nextBitmapAsset = "UI:nextOption_n_image";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
%option.targetPrefVar = %targetPrefVar; //create a var-option association
|
||||||
|
|
||||||
|
//now some override trickery, if we have a value cached for unapplied changes, swapsies the defaultValue out
|
||||||
|
//with the unapplied, allowing us to change options categories without losing changes
|
||||||
|
%unappliedPrefIndex = OptionsMenu.unappliedChanges.getIndexFromValue(%targetPrefVar);
|
||||||
|
if(%unappliedPrefIndex != -1)
|
||||||
|
{
|
||||||
|
%unappliedValue = OptionsMenu.unappliedChanges.getValue(%unappliedPrefIndex);
|
||||||
|
%defaultValue = %unappliedValue;
|
||||||
|
}
|
||||||
|
|
||||||
%option.setListSetting(%label, %optionsList, %wrapOptions, %callback, %enabled, %description, %defaultValue);
|
%option.setListSetting(%label, %optionsList, %wrapOptions, %callback, %enabled, %description, %defaultValue);
|
||||||
|
|
||||||
%this.add(%option);
|
%this.add(%option);
|
||||||
}
|
}
|
||||||
|
|
||||||
function OptionsMenuSettingsList::addSliderRow(%this, %label, %defaultValue, %increment, %range, %callback, %enabled, %description)
|
function OptionsMenuSettingsList::addSliderRow(%this, %label, %targetPrefVar, %defaultValue, %increment, %range, %callback, %enabled, %description)
|
||||||
{
|
{
|
||||||
if(%enabled $= "")
|
if(%enabled $= "")
|
||||||
%enabled = true;
|
%enabled = true;
|
||||||
|
|
@ -626,11 +678,46 @@ function OptionsMenuSettingsList::addSliderRow(%this, %label, %defaultValue, %in
|
||||||
useMouseEvents = true;
|
useMouseEvents = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
%option.targetPrefVar = %targetPrefVar; //create a var-option association
|
||||||
|
|
||||||
|
//now some override trickery, if we have a value cached for unapplied changes, swapsies the defaultValue out
|
||||||
|
//with the unapplied, allowing us to change options categories without losing changes
|
||||||
|
%unappliedPrefIndex = OptionsMenu.unappliedChanges.getIndexFromValue(%targetPrefVar);
|
||||||
|
if(%unappliedPrefIndex != -1)
|
||||||
|
{
|
||||||
|
%unappliedValue = OptionsMenu.unappliedChanges.getValue(%unappliedPrefIndex);
|
||||||
|
%defaultValue = %unappliedValue;
|
||||||
|
}
|
||||||
|
|
||||||
%option.setSliderSetting(%label, %defaultValue, %increment, %range, %callback, %enabled, %description);
|
%option.setSliderSetting(%label, %defaultValue, %increment, %range, %callback, %enabled, %description);
|
||||||
|
|
||||||
%this.add(%option);
|
%this.add(%option);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function OptionsMenuSettingsList::addKeybindRow(%this, %label, %bitmapName, %callback, %enabled, %description)
|
||||||
|
{
|
||||||
|
if(%enabled $= "")
|
||||||
|
%enabled = true;
|
||||||
|
|
||||||
|
%optionsRowSize = 40;
|
||||||
|
%optionColumnWidth = %this.extent.x - 450;
|
||||||
|
|
||||||
|
%option = new GuiGameSettingsCtrl() {
|
||||||
|
class = "MenuOptionsButton";
|
||||||
|
profile = "GuiMenuButtonProfile";
|
||||||
|
horizSizing = "width";
|
||||||
|
vertSizing = "bottom";
|
||||||
|
position = "0 0";
|
||||||
|
extent = %this.extent.x SPC %optionsRowSize;
|
||||||
|
columnSplit = %optionColumnWidth;
|
||||||
|
useMouseEvents = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
%option.setKeybindSetting(%label, %bitmapName, %callback, %enabled, %description);
|
||||||
|
|
||||||
|
%this.add(%option);
|
||||||
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
function OptionsMenuCategoryList::onNavigate(%this, %index)
|
function OptionsMenuCategoryList::onNavigate(%this, %index)
|
||||||
{
|
{
|
||||||
|
|
@ -738,6 +825,24 @@ function onDisplayResChange(%val)
|
||||||
OptionsMenuSettingsList.selectOption(5, %newRate);
|
OptionsMenuSettingsList.selectOption(5, %newRate);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function getDisplayDeviceName()
|
||||||
|
{
|
||||||
|
%numDevices = Canvas.getMonitorCount();
|
||||||
|
%devicesList = "";
|
||||||
|
for(%i = 0; %i < %numDevices; %i++)
|
||||||
|
{
|
||||||
|
%device = (%i+1) @ " - " @ Canvas.getMonitorName(%i);
|
||||||
|
if(%i==0)
|
||||||
|
%devicesList = %device;
|
||||||
|
else
|
||||||
|
%devicesList = %devicesList @ "\t" @ %device;
|
||||||
|
}
|
||||||
|
|
||||||
|
return getField(%devicesList, $pref::Video::deviceId);
|
||||||
|
}
|
||||||
|
//
|
||||||
|
//
|
||||||
|
//
|
||||||
function MenuOptionsButton::onMouseEnter(%this)
|
function MenuOptionsButton::onMouseEnter(%this)
|
||||||
{
|
{
|
||||||
OptionName.setText(%this.getLabel());
|
OptionName.setText(%this.getLabel());
|
||||||
|
|
@ -748,4 +853,84 @@ function MenuOptionsButton::onMouseLeave(%this)
|
||||||
{
|
{
|
||||||
OptionName.setText("");
|
OptionName.setText("");
|
||||||
OptionDescription.setText("");
|
OptionDescription.setText("");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function MenuOptionsButton::onChange(%this)
|
||||||
|
{
|
||||||
|
%optionMode = %this.getMode();
|
||||||
|
%optionName = %this.getLabel();
|
||||||
|
%tooltipText = %this.getTooltip();
|
||||||
|
|
||||||
|
%targetVar = %this.targetPrefVar;
|
||||||
|
|
||||||
|
OptionName.setText(%optionName);
|
||||||
|
OptionDescription.setText(%tooltipText);
|
||||||
|
|
||||||
|
%currentValue = %this.getCurrentOption();
|
||||||
|
if(%currentValue !$= "")
|
||||||
|
{
|
||||||
|
if(%currentValue $= "yes" || %currentValue $= "on")
|
||||||
|
%saveReadyValue = 1;
|
||||||
|
else if(%currentValue $= "no" || %currentValue $= "off")
|
||||||
|
%saveReadyValue = 0;
|
||||||
|
else
|
||||||
|
%saveReadyValue = %currentValue;
|
||||||
|
|
||||||
|
%prefIndex = OptionsMenu.unappliedChanges.getIndexFromKey(%targetVar);
|
||||||
|
if(%prefIndex == -1)
|
||||||
|
OptionsMenu.unappliedChanges.add(%targetVar, %saveReadyValue);
|
||||||
|
else
|
||||||
|
OptionsMenu.unappliedChanges.setValue(%saveReadyValue, %prefIndex);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function OptionsMenu::onKeybindChanged(%this, %actionMap, %keybind)
|
||||||
|
{
|
||||||
|
%prefIndex = OptionsMenu.unappliedChanges.getIndexFromKey(%actionMap);
|
||||||
|
if(%prefIndex == -1)
|
||||||
|
OptionsMenu.unappliedChanges.add(%actionMap, %keybind);
|
||||||
|
else
|
||||||
|
OptionsMenu.unappliedChanges.setValue(%keybind, %prefIndex);
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Indicates what category the options item should be added into
|
||||||
|
//
|
||||||
|
function addOptionsMenuCategory(%categoryName, %selectCallback)
|
||||||
|
{
|
||||||
|
OptionsMenu.optionsCategories.add(%categoryName, %selectCallback);
|
||||||
|
}
|
||||||
|
|
||||||
|
function removeOptionsMenuCategory(%categoryName)
|
||||||
|
{
|
||||||
|
%index = OptionsMenu.optionsCategories.getIndexFromKey(%categoryName);
|
||||||
|
if(%index != -1)
|
||||||
|
OptionsMenu.optionsCategories.erase(%index);
|
||||||
|
}
|
||||||
|
|
||||||
|
function addListOption(%label, %description, %targetPrefVar, %optionsList, %wrapOptions, %callback, %enabled)
|
||||||
|
{
|
||||||
|
if(%wrapOptions $= "")
|
||||||
|
%wrapOptions = false;
|
||||||
|
|
||||||
|
if(%enabled $= "")
|
||||||
|
%enabled = true;
|
||||||
|
|
||||||
|
OptionsMenuSettingsList.addOptionRow(%label, %targetPrefVar, %optionsList, %wrapOptions, %callback, %enabled, %description, %targetPrefVar);
|
||||||
|
}
|
||||||
|
|
||||||
|
function addSliderOption(%label, %description, %targetPrefVar, %defaultValue, %increment, %range, %callback, %enabled)
|
||||||
|
{
|
||||||
|
if(%enabled $= "")
|
||||||
|
%enabled = true;
|
||||||
|
|
||||||
|
OptionsMenuSettingsList.addSliderRow(%label, %targetPrefVar, %defaultValue, %increment, %range, %callback, %enabled, %description);
|
||||||
|
}
|
||||||
|
|
||||||
|
function addKeybindOption(%label, %description, %bitmapName, %callback, %enabled)
|
||||||
|
{
|
||||||
|
if(%enabled $= "")
|
||||||
|
%enabled = true;
|
||||||
|
|
||||||
|
OptionsMenuSettingsList.addSliderRow(%label, %bitmapName, %callback, %enabled, %description);
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -49,25 +49,31 @@ $guiContent = new GuiControl(PauseMenu) {
|
||||||
isContainer = "1";
|
isContainer = "1";
|
||||||
canSave = "1";
|
canSave = "1";
|
||||||
canSaveDynamicFields = "0";
|
canSaveDynamicFields = "0";
|
||||||
|
|
||||||
new GuiGameListMenuCtrl(PauseMenuList) {
|
new GuiStackControl(PauseMenuList) {
|
||||||
debugRender = "0";
|
stackingType = "Vertical";
|
||||||
callbackOnInputs = "1";
|
horizStacking = "Left to Right";
|
||||||
consumeKeyInputEvents = "1";
|
vertStacking = "Top to Bottom";
|
||||||
|
padding = "15";
|
||||||
|
dynamicSize = "0";
|
||||||
|
dynamicNonStackExtent = "0";
|
||||||
|
dynamicPos = "0";
|
||||||
|
changeChildSizeToFit = "1";
|
||||||
|
changeChildPosition = "1";
|
||||||
position = "0 0";
|
position = "0 0";
|
||||||
extent = "700 320";
|
extent = "700 320";
|
||||||
minExtent = "8 2";
|
minExtent = "16 16";
|
||||||
horizSizing = "width";
|
horizSizing = "center";
|
||||||
vertSizing = "bottom";
|
vertSizing = "center";
|
||||||
profile = "DefaultListMenuProfile";
|
profile = "GuiDefaultProfile";
|
||||||
visible = "1";
|
visible = "1";
|
||||||
active = "1";
|
active = "1";
|
||||||
tooltipProfile = "GuiToolTipProfile";
|
tooltipProfile = "GuiToolTipProfile";
|
||||||
hovertime = "1000";
|
hovertime = "1000";
|
||||||
isContainer = "0";
|
isContainer = "1";
|
||||||
class = "UIMenuButtonList";
|
|
||||||
canSave = "1";
|
canSave = "1";
|
||||||
canSaveDynamicFields = "0";
|
canSaveDynamicFields = "0";
|
||||||
|
class = "MenuList";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
new GuiControl(PauseButtonHolder) {
|
new GuiControl(PauseButtonHolder) {
|
||||||
|
|
@ -147,5 +153,26 @@ $guiContent = new GuiControl(PauseMenu) {
|
||||||
canSaveDynamicFields = "0";
|
canSaveDynamicFields = "0";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
new GuiInputCtrl(PauseMenuInputHandler) {
|
||||||
|
class = "MenuInputHandler";
|
||||||
|
sendAxisEvents = "1";
|
||||||
|
sendBreakEvents = "1";
|
||||||
|
sendModifierEvents = "0";
|
||||||
|
ignoreMouseEvents = "1";
|
||||||
|
lockMouse = "0";
|
||||||
|
position = "-50 0";
|
||||||
|
extent = "10 10";
|
||||||
|
minExtent = "8 2";
|
||||||
|
horizSizing = "width";
|
||||||
|
vertSizing = "height";
|
||||||
|
profile = "GuiInputCtrlProfile";
|
||||||
|
visible = "1";
|
||||||
|
active = "1";
|
||||||
|
tooltipProfile = "GuiToolTipProfile";
|
||||||
|
hovertime = "1000";
|
||||||
|
isContainer = "0";
|
||||||
|
canSave = "1";
|
||||||
|
canSaveDynamicFields = "0";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
//--- OBJECT WRITE END ---
|
//--- OBJECT WRITE END ---
|
||||||
|
|
|
||||||
|
|
@ -8,19 +8,21 @@ function PauseMenu::onWake(%this)
|
||||||
}
|
}
|
||||||
|
|
||||||
PauseMenuList.hidden = false;
|
PauseMenuList.hidden = false;
|
||||||
PauseMenuList.setFirstResponder();
|
|
||||||
PauseButtonHolder.setActive();
|
|
||||||
|
|
||||||
PauseMenuList.clearRows();
|
PauseMenuList.clear();
|
||||||
|
|
||||||
if($Tools::loaded && EditorIsActive())
|
if($Tools::loaded && EditorIsActive())
|
||||||
{
|
{
|
||||||
PauseMenuList.addRow("Exit Editor", "fastLoadWorldEdit", -1, -30);
|
%this.addPauseMenuButton("Exit Editor", "fastLoadWorldEdit();");
|
||||||
}
|
}
|
||||||
|
|
||||||
PauseMenuList.addRow("Options", "openPauseMenuOptions", -1, -30);
|
%this.addPauseMenuButton("Options", "openPauseMenuOptions();");
|
||||||
PauseMenuList.addRow("Exit to Menu", "pauseMenuExitToMenu", -1, -30);
|
%this.addPauseMenuButton("Exit to Menu", "pauseMenuExitToMenu();");
|
||||||
PauseMenuList.addRow("Exit to Desktop", "pauseMenuExitToDesktop", -1, -30);
|
%this.addPauseMenuButton("Exit to Desktop", "pauseMenuExitToDesktop();");
|
||||||
|
|
||||||
|
PauseMenuList.setAsActiveMenuList();
|
||||||
|
PauseButtonHolder.setActive();
|
||||||
|
PauseMenuInputHandler.setFirstResponder();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -36,8 +38,9 @@ function PauseMenu::onSleep(%this)
|
||||||
function PauseMenu::onReturnTo(%this)
|
function PauseMenu::onReturnTo(%this)
|
||||||
{
|
{
|
||||||
PauseMenuList.hidden = false;
|
PauseMenuList.hidden = false;
|
||||||
PauseMenuList.setFirstResponder();
|
PauseMenuList.setAsActiveMenuList();
|
||||||
PauseButtonHolder.setActive();
|
PauseButtonHolder.setActive();
|
||||||
|
PauseMenuInputHandler.setFirstResponder();
|
||||||
}
|
}
|
||||||
|
|
||||||
function openPauseMenuOptions()
|
function openPauseMenuOptions()
|
||||||
|
|
@ -61,6 +64,32 @@ function pauseMenuExitToDesktop()
|
||||||
|
|
||||||
function PauseButtonHolder::onWake(%this)
|
function PauseButtonHolder::onWake(%this)
|
||||||
{
|
{
|
||||||
%this-->goButton.set("btn_a", "Return", "OK", "PauseMenuList.activateRow();", true);
|
%this-->goButton.set("btn_a", "Return", "OK", "PauseMenuList.activate();", true);
|
||||||
%this-->backButton.set("btn_b", "Escape", "Back", "Canvas.popDialog();");
|
%this-->backButton.set("btn_b", "Escape", "Back", "Canvas.popDialog();");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function PauseMenu::addPauseMenuButton(%this, %buttonText, %buttonCallback)
|
||||||
|
{
|
||||||
|
%newButton = new GuiButtonCtrl() {
|
||||||
|
text = %buttonText;
|
||||||
|
groupNum = "-1";
|
||||||
|
buttonType = "PushButton";
|
||||||
|
useMouseEvents = "0";
|
||||||
|
position = "0 0";
|
||||||
|
extent = "400 55";
|
||||||
|
minExtent = "8 2";
|
||||||
|
horizSizing = "right";
|
||||||
|
vertSizing = "bottom";
|
||||||
|
profile = "GuiMenuButtonProfile";
|
||||||
|
visible = "1";
|
||||||
|
active = "1";
|
||||||
|
command = %buttonCallback;
|
||||||
|
tooltipProfile = "GuiToolTipProfile";
|
||||||
|
hovertime = "1000";
|
||||||
|
isContainer = "0";
|
||||||
|
canSave = "1";
|
||||||
|
canSaveDynamicFields = "0";
|
||||||
|
};
|
||||||
|
|
||||||
|
PauseMenuList.add(%newButton);
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -363,4 +363,4 @@ function metrics( %expr )
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
$GameCanvas.popDialog(FrameOverlayGui);
|
$GameCanvas.popDialog(FrameOverlayGui);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,4 @@
|
||||||
<GUIAsset
|
<GUIAsset
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="true"
|
|
||||||
AssetName="recordingsDlg"
|
AssetName="recordingsDlg"
|
||||||
scriptFile="@assetFile=RecordingsDlg.gui"
|
|
||||||
GUIFile="@assetFile=RecordingsDlg.gui"
|
GUIFile="@assetFile=RecordingsDlg.gui"
|
||||||
VersionId="1" />
|
VersionId="1"/>
|
||||||
|
|
|
||||||
|
|
@ -35,7 +35,7 @@ $guiContent = new GuiFadeinBitmapCtrl(StartupGui) {
|
||||||
Visible = "1";
|
Visible = "1";
|
||||||
tooltipprofile = "GuiToolTipProfile";
|
tooltipprofile = "GuiToolTipProfile";
|
||||||
hovertime = "1000";
|
hovertime = "1000";
|
||||||
bitmap = "";
|
bitmapAsset = "";
|
||||||
wrap = "0";
|
wrap = "0";
|
||||||
command = "StartupGui.click();";
|
command = "StartupGui.click();";
|
||||||
};
|
};
|
||||||
|
|
@ -54,7 +54,7 @@ $guiContent = new GuiFadeinBitmapCtrl(StartupGui) {
|
||||||
Visible = "1";
|
Visible = "1";
|
||||||
tooltipprofile = "GuiToolTipProfile";
|
tooltipprofile = "GuiToolTipProfile";
|
||||||
hovertime = "1000";
|
hovertime = "1000";
|
||||||
bitmap = "";
|
bitmapAsset = "";
|
||||||
wrap = "0";
|
wrap = "0";
|
||||||
command = "StartupGui.click();";
|
command = "StartupGui.click();";
|
||||||
};
|
};
|
||||||
|
|
|
||||||
|
|
@ -32,7 +32,7 @@ function loadStartup()
|
||||||
// A list of the splash screens and logos
|
// A list of the splash screens and logos
|
||||||
// to cycle through. Note that they have to
|
// to cycle through. Note that they have to
|
||||||
// be in consecutive numerical order
|
// be in consecutive numerical order
|
||||||
StartupGui.bitmap[0] = "UI:background_dark_image";
|
StartupGui.bitmap[0] = "UI:backgrounddark_image";
|
||||||
StartupGui.logo[0] = "UI:Torque_3D_logo_alt_image";
|
StartupGui.logo[0] = "UI:Torque_3D_logo_alt_image";
|
||||||
StartupGui.logoPos[0] = "178 251";
|
StartupGui.logoPos[0] = "178 251";
|
||||||
StartupGui.logoExtent[0] = "443 139";
|
StartupGui.logoExtent[0] = "443 139";
|
||||||
|
|
|
||||||
|
Before Width: | Height: | Size: 10 KiB |
|
Before Width: | Height: | Size: 19 KiB |
|
Before Width: | Height: | Size: 8.9 KiB |
|
Before Width: | Height: | Size: 11 KiB |
|
|
@ -2,7 +2,7 @@
|
||||||
canSave="true"
|
canSave="true"
|
||||||
canSaveDynamicFields="true"
|
canSaveDynamicFields="true"
|
||||||
AssetName="Torque_3D_logo_alt_image"
|
AssetName="Torque_3D_logo_alt_image"
|
||||||
imageFile="@assetFile=Torque-3D-logo_alt.png"
|
imageFile="@assetFile=Torque_3D_logo_alt.png"
|
||||||
UseMips="true"
|
UseMips="true"
|
||||||
isHDRImage="false"
|
isHDRImage="false"
|
||||||
imageType="Albedo" />
|
imageType="Albedo" />
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
canSave="true"
|
canSave="true"
|
||||||
canSaveDynamicFields="true"
|
canSaveDynamicFields="true"
|
||||||
AssetName="Torque_3D_logo_image"
|
AssetName="Torque_3D_logo_image"
|
||||||
imageFile="@assetFile=Torque-3D-logo.png"
|
imageFile="@assetFile=Torque_3D_logo.png"
|
||||||
UseMips="true"
|
UseMips="true"
|
||||||
isHDRImage="false"
|
isHDRImage="false"
|
||||||
imageType="Albedo" />
|
imageType="Albedo" />
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
canSave="true"
|
canSave="true"
|
||||||
canSaveDynamicFields="true"
|
canSaveDynamicFields="true"
|
||||||
AssetName="Torque_3D_logo_shortcut_image"
|
AssetName="Torque_3D_logo_shortcut_image"
|
||||||
imageFile="@assetFile=Torque-3D-logo-shortcut.png"
|
imageFile="@assetFile=Torque_3D_logo_shortcut.png"
|
||||||
UseMips="true"
|
UseMips="true"
|
||||||
isHDRImage="false"
|
isHDRImage="false"
|
||||||
imageType="Albedo" />
|
imageType="Albedo" />
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
canSave="true"
|
canSave="true"
|
||||||
canSaveDynamicFields="true"
|
canSaveDynamicFields="true"
|
||||||
AssetName="Torque_3D_logo_w_image"
|
AssetName="Torque_3D_logo_w_image"
|
||||||
imageFile="@assetFile=Torque-3D-logo-w.png"
|
imageFile="@assetFile=Torque_3D_logo_w.png"
|
||||||
UseMips="true"
|
UseMips="true"
|
||||||
isHDRImage="false"
|
isHDRImage="false"
|
||||||
imageType="Albedo" />
|
imageType="Albedo" />
|
||||||
|
|
|
||||||
|
Before Width: | Height: | Size: 5.6 KiB |
|
|
@ -1,8 +0,0 @@
|
||||||
<ImageAsset
|
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="true"
|
|
||||||
AssetName="background_dark_image"
|
|
||||||
imageFile="@assetFile=background-dark.png"
|
|
||||||
UseMips="true"
|
|
||||||
isHDRImage="false"
|
|
||||||
imageType="Albedo" />
|
|
||||||
|
Before Width: | Height: | Size: 593 B |
|
Before Width: | Height: | Size: 595 B |
|
Before Width: | Height: | Size: 377 B |
|
Before Width: | Height: | Size: 280 B |
|
Before Width: | Height: | Size: 468 B |
|
Before Width: | Height: | Size: 439 B |
|
Before Width: | Height: | Size: 132 B |
|
Before Width: | Height: | Size: 390 B |
|
Before Width: | Height: | Size: 278 B |
|
Before Width: | Height: | Size: 468 B |
|
Before Width: | Height: | Size: 437 B |
|
Before Width: | Height: | Size: 1.2 KiB |
|
Before Width: | Height: | Size: 131 B |
|
Before Width: | Height: | Size: 3.5 KiB |
|
Before Width: | Height: | Size: 279 B |
|
Before Width: | Height: | Size: 549 B |
|
Before Width: | Height: | Size: 484 B |
|
Before Width: | Height: | Size: 34 KiB |
|
Before Width: | Height: | Size: 290 B |
|
Before Width: | Height: | Size: 561 B |
|
Before Width: | Height: | Size: 494 B |
|
Before Width: | Height: | Size: 744 B |
|
Before Width: | Height: | Size: 1.9 KiB |
|
Before Width: | Height: | Size: 1.6 KiB |
|
Before Width: | Height: | Size: 3.9 KiB |
|
Before Width: | Height: | Size: 117 B |
|
Before Width: | Height: | Size: 118 B |
|
Before Width: | Height: | Size: 908 B |
|
Before Width: | Height: | Size: 982 B |
|
|
@ -1,8 +0,0 @@
|
||||||
<ImageAsset
|
|
||||||
canSave="true"
|
|
||||||
canSaveDynamicFields="true"
|
|
||||||
AssetName="slider___Copy_image"
|
|
||||||
imageFile="@assetFile=slider - Copy.png"
|
|
||||||
UseMips="true"
|
|
||||||
isHDRImage="false"
|
|
||||||
imageType="Albedo" />
|
|
||||||
|
Before Width: | Height: | Size: 1.2 KiB |
|
|
@ -130,7 +130,7 @@ function fillRemapList()
|
||||||
{
|
{
|
||||||
%device = $remapListDevice;
|
%device = $remapListDevice;
|
||||||
|
|
||||||
OptionsMenuSettingsList.clearRows();
|
OptionsMenuSettingsList.clear();
|
||||||
|
|
||||||
//build out our list of action maps
|
//build out our list of action maps
|
||||||
%actionMapCount = ActionMapGroup.getCount();
|
%actionMapCount = ActionMapGroup.getCount();
|
||||||
|
|
@ -158,7 +158,7 @@ function fillRemapList()
|
||||||
if($activeRemapControlSet $= "")
|
if($activeRemapControlSet $= "")
|
||||||
$activeRemapControlSet = getField(%actionMapList, 0);
|
$activeRemapControlSet = getField(%actionMapList, 0);
|
||||||
|
|
||||||
OptionsMenuSettingsList.addOptionRow("Control Set", %actionMapList, false, "controlSetChanged", -1, -30, true, "Which keybind control set to edit", $activeRemapControlSet);
|
OptionsMenuSettingsList.addOptionRow("Control Set", "$activeRemapControlSet", %actionMapList, false, "controlSetChanged", true, "Which keybind control set to edit", $activeRemapControlSet);
|
||||||
|
|
||||||
for ( %i = 0; %i < $RemapCount; %i++ )
|
for ( %i = 0; %i < $RemapCount; %i++ )
|
||||||
{
|
{
|
||||||
|
|
@ -173,7 +173,9 @@ function fillRemapList()
|
||||||
%keyMap = buildFullMapString( %i, $RemapActionMap[%i], %device );
|
%keyMap = buildFullMapString( %i, $RemapActionMap[%i], %device );
|
||||||
%description = $RemapDescription[%i];
|
%description = $RemapDescription[%i];
|
||||||
|
|
||||||
OptionsMenuSettingsList.addKeybindRow(getField(%keyMap, 0), getButtonBitmap(%device, getField(%keyMap, 1)), "doKeyRemap", -1, -15, true, %description);
|
%buttonImageAsset = getButtonBitmap(%device, getField(%keyMap, 1));
|
||||||
|
|
||||||
|
OptionsMenuSettingsList.addKeybindRow(getField(%keyMap, 0), %buttonImageAsset, "doKeyRemap", true, %description);
|
||||||
}
|
}
|
||||||
|
|
||||||
//OptionsMenuSettingsList.refresh();
|
//OptionsMenuSettingsList.refresh();
|
||||||
|
|
@ -182,7 +184,7 @@ function fillRemapList()
|
||||||
|
|
||||||
function controlSetChanged()
|
function controlSetChanged()
|
||||||
{
|
{
|
||||||
$activeRemapControlSet = OptionsMenuSettingsList.getCurrentOption(0);
|
$activeRemapControlSet = OptionsMenuSettingsList.getCurrentOption();
|
||||||
fillRemapList();
|
fillRemapList();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -194,6 +196,11 @@ function doKeyRemap( %rowIndex )
|
||||||
RemapDlg-->OptRemapText.setValue( "Re-bind \"" @ %name @ "\" to..." );
|
RemapDlg-->OptRemapText.setValue( "Re-bind \"" @ %name @ "\" to..." );
|
||||||
OptRemapInputCtrl.index = %rowIndex;
|
OptRemapInputCtrl.index = %rowIndex;
|
||||||
Canvas.pushDialog( RemapDlg );
|
Canvas.pushDialog( RemapDlg );
|
||||||
|
|
||||||
|
//Let the options menu know
|
||||||
|
%actionMap = $RemapActionMap[%rowIndex];
|
||||||
|
|
||||||
|
OptionsMenu.onKeybindChanged(%actionMap, %name);
|
||||||
}
|
}
|
||||||
|
|
||||||
function ControlsMenuRebindButton::onClick(%this)
|
function ControlsMenuRebindButton::onClick(%this)
|
||||||
|
|
@ -327,4 +334,4 @@ function redoMapping( %device, %actionMap, %action, %cmd, %oldIndex, %newIndex )
|
||||||
%actionMap.bind( %device, %action, %cmd );
|
%actionMap.bind( %device, %action, %cmd );
|
||||||
|
|
||||||
fillRemapList();
|
fillRemapList();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -37,4 +37,4 @@ else
|
||||||
renderOffset = "0 0";
|
renderOffset = "0 0";
|
||||||
bitmapName = "data/ui/images/defaultCursor";
|
bitmapName = "data/ui/images/defaultCursor";
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -10,117 +10,123 @@ function getButtonBitmap(%device, %button)
|
||||||
%device = "Xbox";
|
%device = "Xbox";
|
||||||
}
|
}
|
||||||
|
|
||||||
%path = "";
|
%assetId = "";
|
||||||
if(%device $= "PS4")
|
if(%device $= "PS4")
|
||||||
{
|
{
|
||||||
%path = "data/ui/images/inputs/PS4/PS4_";
|
%assetId = "UI:PS4_";
|
||||||
|
|
||||||
if(%button $= "A" || %button $= "btn_a")
|
if(%button $= "A" || %button $= "btn_a")
|
||||||
%path = %path @ "Cross";
|
%assetId = %assetId @ "Cross";
|
||||||
else if(%button $= "B" || %button $= "btn_b")
|
else if(%button $= "B" || %button $= "btn_b")
|
||||||
%path = %path @ "Circle";
|
%assetId = %assetId @ "Circle";
|
||||||
else if(%button $= "X" || %button $= "btn_x")
|
else if(%button $= "X" || %button $= "btn_x")
|
||||||
%path = %path @ "Square";
|
%assetId = %assetId @ "Square";
|
||||||
else if(%button $= "Y" || %button $= "btn_y")
|
else if(%button $= "Y" || %button $= "btn_y")
|
||||||
%path = %path @ "Triangle";
|
%assetId = %assetId @ "Triangle";
|
||||||
else if(%button $= "LB")
|
else if(%button $= "LB")
|
||||||
%path = %path @ "L1";
|
%assetId = %assetId @ "L1";
|
||||||
else if(%button $= "LT")
|
else if(%button $= "LT")
|
||||||
%path = %path @ "L2";
|
%assetId = %assetId @ "L2";
|
||||||
else if(%button $= "RB")
|
else if(%button $= "RB")
|
||||||
%path = %path @ "R1";
|
%assetId = %assetId @ "R1";
|
||||||
else if(%button $= "RT")
|
else if(%button $= "RT")
|
||||||
%path = %path @ "R2";
|
%assetId = %assetId @ "R2";
|
||||||
else if(%button $= "thumbrx" || %button $= "thumbry")
|
else if(%button $= "thumbrx" || %button $= "thumbry")
|
||||||
%path = %path @ "Right_Stick";
|
%assetId = %assetId @ "Right_Stick";
|
||||||
else if(%button $= "thumblx" || %button $= "thumbly")
|
else if(%button $= "thumblx" || %button $= "thumbly")
|
||||||
%path = %path @ "Left_Stick";
|
%assetId = %assetId @ "Left_Stick";
|
||||||
else if(%button $= "start")
|
else if(%button $= "start")
|
||||||
%path = %path @ "Options";
|
%assetId = %assetId @ "Options";
|
||||||
else if(%button $= "back")
|
else if(%button $= "back")
|
||||||
%path = %path @ "Share";
|
%assetId = %assetId @ "Share";
|
||||||
else if(%button $= "dpadu")
|
else if(%button $= "dpadu")
|
||||||
%path = %path @ "Dpad_Up";
|
%assetId = %assetId @ "Dpad_Up";
|
||||||
else if(%button $= "dpadd")
|
else if(%button $= "dpadd")
|
||||||
%path = %path @ "Dpad_Down";
|
%assetId = %assetId @ "Dpad_Down";
|
||||||
else if(%button $= "dpadl")
|
else if(%button $= "dpadl")
|
||||||
%path = %path @ "Dpad_Left";
|
%assetId = %assetId @ "Dpad_Left";
|
||||||
else if(%button $= "dpadr")
|
else if(%button $= "dpadr")
|
||||||
%path = %path @ "Dpad_Right";
|
%assetId = %assetId @ "Dpad_Right";
|
||||||
|
|
||||||
|
%assetId = %assetId @ "_image";
|
||||||
}
|
}
|
||||||
else if(%device $= "Switch")
|
else if(%device $= "Switch")
|
||||||
{
|
{
|
||||||
%path = "data/ui/images/inputs/Switch/Switch_";
|
%assetId = "UI:Switch_";
|
||||||
|
|
||||||
if(%button $= "A" || %button $= "btn_a")
|
if(%button $= "A" || %button $= "btn_a")
|
||||||
%path = %path @ "B";
|
%assetId = %assetId @ "B";
|
||||||
else if(%button $= "B" || %button $= "btn_b")
|
else if(%button $= "B" || %button $= "btn_b")
|
||||||
%path = %path @ "A";
|
%assetId = %assetId @ "A";
|
||||||
else if(%button $= "X" || %button $= "btn_x")
|
else if(%button $= "X" || %button $= "btn_x")
|
||||||
%path = %path @ "Y";
|
%assetId = %assetId @ "Y";
|
||||||
else if(%button $= "Y" || %button $= "btn_y")
|
else if(%button $= "Y" || %button $= "btn_y")
|
||||||
%path = %path @ "X";
|
%assetId = %assetId @ "X";
|
||||||
else if(%button $= "LB")
|
else if(%button $= "LB")
|
||||||
%path = %path @ "LB";
|
%assetId = %assetId @ "LB";
|
||||||
else if(%button $= "LT")
|
else if(%button $= "LT")
|
||||||
%path = %path @ "LT";
|
%assetId = %assetId @ "LT";
|
||||||
else if(%button $= "RB")
|
else if(%button $= "RB")
|
||||||
%path = %path @ "RB";
|
%assetId = %assetId @ "RB";
|
||||||
else if(%button $= "RT")
|
else if(%button $= "RT")
|
||||||
%path = %path @ "RT";
|
%assetId = %assetId @ "RT";
|
||||||
else if(%button $= "thumbrx" || %button $= "thumbry")
|
else if(%button $= "thumbrx" || %button $= "thumbry")
|
||||||
%path = %path @ "Right_Stick";
|
%assetId = %assetId @ "Right_Stick";
|
||||||
else if(%button $= "thumblx" || %button $= "thumbly")
|
else if(%button $= "thumblx" || %button $= "thumbly")
|
||||||
%path = %path @ "Left_Stick";
|
%assetId = %assetId @ "Left_Stick";
|
||||||
else if(%button $= "start")
|
else if(%button $= "start")
|
||||||
%path = %path @ "Plus";
|
%assetId = %assetId @ "Plus";
|
||||||
else if(%button $= "back")
|
else if(%button $= "back")
|
||||||
%path = %path @ "Minus";
|
%assetId = %assetId @ "Minus";
|
||||||
else if(%button $= "dpadu")
|
else if(%button $= "dpadu")
|
||||||
%path = %path @ "Dpad_Up";
|
%assetId = %assetId @ "Dpad_Up";
|
||||||
else if(%button $= "dpadd")
|
else if(%button $= "dpadd")
|
||||||
%path = %path @ "Dpad_Down";
|
%assetId = %assetId @ "Dpad_Down";
|
||||||
else if(%button $= "dpadl")
|
else if(%button $= "dpadl")
|
||||||
%path = %path @ "Dpad_Left";
|
%assetId = %assetId @ "Dpad_Left";
|
||||||
else if(%button $= "dpadr")
|
else if(%button $= "dpadr")
|
||||||
%path = %path @ "Dpad_Right";
|
%assetId = %assetId @ "Dpad_Right";
|
||||||
|
|
||||||
|
%assetId = %assetId @ "_image";
|
||||||
}
|
}
|
||||||
else if(%device $= "Keyboard" || %device $= "Mouse")
|
else if(%device $= "Keyboard" || %device $= "Mouse")
|
||||||
{
|
{
|
||||||
%pathBase = "data/ui/images/Inputs/Keyboard & Mouse/Keyboard_Black_";
|
%assetId = "UI:Keyboard_Black_" @ %button @ "_image";
|
||||||
%path = %pathBase @ %button @ ".png";
|
|
||||||
if(!isFile(%path))
|
|
||||||
%path = %pathBase @ "Blank";
|
|
||||||
}
|
}
|
||||||
else if(%device !$= "")
|
else if(%device !$= "")
|
||||||
{
|
{
|
||||||
%path = "data/ui/images/inputs/Xbox/Xbox_";
|
%assetId = "UI:Xbox_";
|
||||||
|
|
||||||
if(%button $= "btn_a")
|
if(%button $= "btn_a")
|
||||||
%path = %path @ "B";
|
%assetId = %assetId @ "B";
|
||||||
else if(%button $= "btn_b")
|
else if(%button $= "btn_b")
|
||||||
%path = %path @ "A";
|
%assetId = %assetId @ "A";
|
||||||
else if(%button $= "btn_x")
|
else if(%button $= "btn_x")
|
||||||
%path = %path @ "Y";
|
%assetId = %assetId @ "Y";
|
||||||
else if(%button $= "btn_y")
|
else if(%button $= "btn_y")
|
||||||
%path = %path @ "X";
|
%assetId = %assetId @ "X";
|
||||||
else if(%button $= "thumbrx" || %button $= "thumbry")
|
else if(%button $= "thumbrx" || %button $= "thumbry")
|
||||||
%path = %path @ "Right_Stick";
|
%assetId = %assetId @ "Right_Stick";
|
||||||
else if(%button $= "thumblx" || %button $= "thumbly")
|
else if(%button $= "thumblx" || %button $= "thumbly")
|
||||||
%path = %path @ "Left_Stick";
|
%assetId = %assetId @ "Left_Stick";
|
||||||
else if(%button $= "start")
|
else if(%button $= "start")
|
||||||
%path = %path @ "Menu";
|
%assetId = %assetId @ "Menu";
|
||||||
else if(%button $= "back")
|
else if(%button $= "back")
|
||||||
%path = %path @ "Windows";
|
%assetId = %assetId @ "Windows";
|
||||||
else if(%button $= "dpadu")
|
else if(%button $= "dpadu")
|
||||||
%path = %path @ "Dpad_Up";
|
%assetId = %assetId @ "Dpad_Up";
|
||||||
else if(%button $= "dpadd")
|
else if(%button $= "dpadd")
|
||||||
%path = %path @ "Dpad_Down";
|
%assetId = %assetId @ "Dpad_Down";
|
||||||
else if(%button $= "dpadl")
|
else if(%button $= "dpadl")
|
||||||
%path = %path @ "Dpad_Left";
|
%assetId = %assetId @ "Dpad_Left";
|
||||||
else if(%button $= "dpadr")
|
else if(%button $= "dpadr")
|
||||||
%path = %path @ "Dpad_Right";
|
%assetId = %assetId @ "Dpad_Right";
|
||||||
|
|
||||||
|
%assetId = %assetId @ "_image";
|
||||||
}
|
}
|
||||||
|
|
||||||
return %path;
|
if(!AssetDatabase.isDeclaredAsset(%assetId))
|
||||||
}
|
%assetId = "UI:Keyboard_Black_Blank_image";
|
||||||
|
|
||||||
|
return %assetId;
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -1743,7 +1743,9 @@ function beginGUIImport()
|
||||||
DirectoryHandler::createFolder(0, filePath(%destinationPath));
|
DirectoryHandler::createFolder(0, filePath(%destinationPath));
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!pathCopy(%file, %destinationPath, false))
|
//Check if we need to even copy in the first place. If we do, ensure
|
||||||
|
//the copy actually worked
|
||||||
|
if((makeRelativePath(%file) !$= %destinationPath) && !pathCopy(%file, %destinationPath, false))
|
||||||
{
|
{
|
||||||
projectImporterLog("ProjectImporter::beginGUIImport() - failed to copy GUI: " @ %file @
|
projectImporterLog("ProjectImporter::beginGUIImport() - failed to copy GUI: " @ %file @
|
||||||
" to destination: " @ %destinationPath);
|
" to destination: " @ %destinationPath);
|
||||||
|
|
@ -1779,9 +1781,9 @@ function processGUIntoAsset(%guiName, %file)
|
||||||
%tamlpath = %assetPath @ %assetName @ ".asset.taml";
|
%tamlpath = %assetPath @ %assetName @ ".asset.taml";
|
||||||
|
|
||||||
%scriptFile = "";
|
%scriptFile = "";
|
||||||
if(isImportingFile(%filePath @ "/" @ %fileName @ ".tscript"))
|
if(isImportingFile(makeFullPath(%filePath @ "/" @ %fileName @ "." @ $TorqueScriptFileExtension)))
|
||||||
{
|
{
|
||||||
%scriptFile = %fileName @ ".tscript";
|
%scriptFile = %fileName;
|
||||||
}
|
}
|
||||||
|
|
||||||
%asset = new GUIAsset()
|
%asset = new GUIAsset()
|
||||||
|
|
|
||||||