mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-01-19 20:24:49 +00:00
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
284 lines
8.2 KiB
Plaintext
284 lines
8.2 KiB
Plaintext
//--- OBJECT WRITE BEGIN ---
|
|
$guiContent = new GuiChunkedBitmapCtrl(MainMenuGui) {
|
|
BitmapAsset = "UI:backgrounddark_image";
|
|
useVariable = "0";
|
|
tile = "0";
|
|
position = "0 0";
|
|
extent = "1024 768";
|
|
minExtent = "8 8";
|
|
horizSizing = "width";
|
|
vertSizing = "height";
|
|
profile = "GuiDefaultProfile";
|
|
visible = "1";
|
|
active = "1";
|
|
tooltipProfile = "GuiToolTipProfile";
|
|
hovertime = "1000";
|
|
isContainer = "1";
|
|
canSave = "1";
|
|
canSaveDynamicFields = "1";
|
|
Enabled = "1";
|
|
isDecoy = "0";
|
|
navigationIndex = "-1";
|
|
|
|
new GuiBitmapCtrl(MainMenuAppLogo) {
|
|
BitmapAsset = "UI:Torque_3D_logo_alt_image";
|
|
color = "255 255 255 255";
|
|
wrap = "0";
|
|
position = "550 30";
|
|
extent = "443 139";
|
|
minExtent = "8 2";
|
|
horizSizing = "left";
|
|
vertSizing = "bottom";
|
|
profile = "GuiDefaultProfile";
|
|
visible = "1";
|
|
active = "1";
|
|
tooltipProfile = "GuiToolTipProfile";
|
|
hovertime = "1000";
|
|
isContainer = "0";
|
|
canSave = "1";
|
|
canSaveDynamicFields = "1";
|
|
autoFitExtents = "0";
|
|
bitmapMode = "Stretched";
|
|
groupNum = "-1";
|
|
masked = "0";
|
|
navigationIndex = "-1";
|
|
useModifiers = "0";
|
|
useStates = "1";
|
|
};
|
|
new GuiStackControl(MainMenuButtonList) {
|
|
stackingType = "Vertical";
|
|
horizStacking = "Left to Right";
|
|
vertStacking = "Top to Bottom";
|
|
padding = "15";
|
|
dynamicSize = "0";
|
|
dynamicNonStackExtent = "0";
|
|
dynamicPos = "0";
|
|
changeChildSizeToFit = "1";
|
|
changeChildPosition = "1";
|
|
position = "312 111";
|
|
extent = "400 477";
|
|
minExtent = "16 16";
|
|
horizSizing = "center";
|
|
vertSizing = "center";
|
|
profile = "GuiDefaultProfile";
|
|
visible = "1";
|
|
active = "1";
|
|
tooltipProfile = "GuiToolTipProfile";
|
|
hovertime = "1000";
|
|
isContainer = "1";
|
|
canSave = "1";
|
|
canSaveDynamicFields = "0";
|
|
class = "MenuList";
|
|
|
|
new GuiButtonCtrl(MainMenuSinglePlayerBtn) {
|
|
text = "Single Player";
|
|
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 = "openSinglePlayerMenu();";
|
|
tooltipProfile = "GuiToolTipProfile";
|
|
hovertime = "1000";
|
|
isContainer = "0";
|
|
canSave = "1";
|
|
canSaveDynamicFields = "0";
|
|
};
|
|
new GuiButtonCtrl(MainMenuCreateSrvrBtn) {
|
|
text = "Create Server";
|
|
groupNum = "-1";
|
|
buttonType = "PushButton";
|
|
useMouseEvents = "0";
|
|
position = "0 70";
|
|
extent = "400 55";
|
|
minExtent = "8 2";
|
|
horizSizing = "right";
|
|
vertSizing = "bottom";
|
|
profile = "GuiMenuButtonProfile";
|
|
visible = "1";
|
|
active = "1";
|
|
command = "openMultiPlayerMenu();";
|
|
tooltipProfile = "GuiToolTipProfile";
|
|
hovertime = "1000";
|
|
isContainer = "0";
|
|
canSave = "1";
|
|
canSaveDynamicFields = "0";
|
|
};
|
|
new GuiButtonCtrl(MainMenuJoinSrvrBtn) {
|
|
text = "Join Server";
|
|
groupNum = "-1";
|
|
buttonType = "PushButton";
|
|
useMouseEvents = "0";
|
|
position = "0 140";
|
|
extent = "400 55";
|
|
minExtent = "8 2";
|
|
horizSizing = "right";
|
|
vertSizing = "bottom";
|
|
profile = "GuiMenuButtonProfile";
|
|
visible = "1";
|
|
active = "1";
|
|
command = "openJoinServerMenu();";
|
|
tooltipProfile = "GuiToolTipProfile";
|
|
hovertime = "1000";
|
|
isContainer = "0";
|
|
canSave = "1";
|
|
canSaveDynamicFields = "0";
|
|
};
|
|
new GuiButtonCtrl(MainMenuOptionBtn) {
|
|
text = "Options";
|
|
groupNum = "-1";
|
|
buttonType = "PushButton";
|
|
useMouseEvents = "0";
|
|
position = "0 210";
|
|
extent = "400 55";
|
|
minExtent = "8 2";
|
|
horizSizing = "right";
|
|
vertSizing = "bottom";
|
|
profile = "GuiMenuButtonProfile";
|
|
visible = "1";
|
|
active = "1";
|
|
command = "openOptionsMenu();";
|
|
tooltipProfile = "GuiToolTipProfile";
|
|
hovertime = "1000";
|
|
isContainer = "0";
|
|
canSave = "1";
|
|
canSaveDynamicFields = "0";
|
|
};
|
|
new GuiButtonCtrl(MainMenuWorldEditBtn) {
|
|
text = "Open World Editor";
|
|
groupNum = "-1";
|
|
buttonType = "PushButton";
|
|
useMouseEvents = "0";
|
|
position = "0 280";
|
|
extent = "400 55";
|
|
minExtent = "8 2";
|
|
horizSizing = "right";
|
|
vertSizing = "bottom";
|
|
profile = "GuiMenuButtonProfile";
|
|
visible = "1";
|
|
active = "1";
|
|
command = "openWorldEditorBtn();";
|
|
tooltipProfile = "GuiToolTipProfile";
|
|
hovertime = "1000";
|
|
isContainer = "0";
|
|
canSave = "1";
|
|
canSaveDynamicFields = "0";
|
|
};
|
|
new GuiButtonCtrl(MainMenuGuiEditBtn) {
|
|
text = "Open GUI Editor";
|
|
groupNum = "-1";
|
|
buttonType = "PushButton";
|
|
useMouseEvents = "0";
|
|
position = "0 350";
|
|
extent = "400 55";
|
|
minExtent = "8 2";
|
|
horizSizing = "right";
|
|
vertSizing = "bottom";
|
|
profile = "GuiMenuButtonProfile";
|
|
visible = "1";
|
|
active = "1";
|
|
command = "openGUIEditorBtn();";
|
|
tooltipProfile = "GuiToolTipProfile";
|
|
hovertime = "1000";
|
|
isContainer = "0";
|
|
canSave = "1";
|
|
canSaveDynamicFields = "0";
|
|
};
|
|
new GuiButtonCtrl(MainMenuExitBtn) {
|
|
text = "Exit";
|
|
groupNum = "-1";
|
|
buttonType = "PushButton";
|
|
useMouseEvents = "0";
|
|
position = "0 420";
|
|
extent = "400 55";
|
|
minExtent = "8 2";
|
|
horizSizing = "right";
|
|
vertSizing = "bottom";
|
|
profile = "GuiMenuButtonProfile";
|
|
visible = "1";
|
|
active = "1";
|
|
command = "quit();";
|
|
tooltipProfile = "GuiToolTipProfile";
|
|
hovertime = "1000";
|
|
isContainer = "0";
|
|
canSave = "1";
|
|
canSaveDynamicFields = "0";
|
|
};
|
|
};
|
|
new GuiControl(MainMenuButtonHolder) {
|
|
position = "189 711";
|
|
extent = "646 40";
|
|
minExtent = "8 2";
|
|
horizSizing = "center";
|
|
vertSizing = "top";
|
|
profile = "GuiDefaultProfile";
|
|
visible = "1";
|
|
active = "1";
|
|
tooltipProfile = "GuiToolTipProfile";
|
|
hovertime = "1000";
|
|
isContainer = "1";
|
|
class = "MenuInputButtonContainer";
|
|
canSave = "1";
|
|
canSaveDynamicFields = "0";
|
|
|
|
new GuiIconButtonCtrl() {
|
|
buttonMargin = "4 4";
|
|
BitmapAsset = "UI:Keyboard_Black_Return_image";
|
|
iconLocation = "Left";
|
|
sizeIconToButton = "1";
|
|
makeIconSquare = "1";
|
|
textLocation = "Right";
|
|
textMargin = "4";
|
|
autoSize = "0";
|
|
text = "Go";
|
|
groupNum = "-1";
|
|
buttonType = "PushButton";
|
|
useMouseEvents = "0";
|
|
position = "507 0";
|
|
extent = "140 40";
|
|
minExtent = "8 2";
|
|
horizSizing = "right";
|
|
vertSizing = "bottom";
|
|
profile = "GuiMenuButtonProfile";
|
|
visible = "1";
|
|
active = "1";
|
|
command = "MainMenuButtonList.activateRow();";
|
|
tooltipProfile = "GuiToolTipProfile";
|
|
hovertime = "1000";
|
|
isContainer = "0";
|
|
internalName = "goButton";
|
|
class = "MenuInputButton";
|
|
canSave = "1";
|
|
canSaveDynamicFields = "0";
|
|
};
|
|
};
|
|
new GuiInputCtrl(MainMenuInputHandler) {
|
|
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 ---
|