cod5-sdk/raw/ui_mp/mods.menu
2008-11-20 00:00:00 +00:00

150 lines
No EOL
3.8 KiB
Text

#include "ui/menudef.h"
#include "ui_mp/common_macro.inc"
#define CHOICE_GROUP "mods"
#include "ui_mp/menustyle.inc"
#define CHOICE_Y_OFFSET 0
#include "ui/choices_setup_common.menu"
#undef CHOICE_HORIZONTAL_ALIGN
#define CHOICE_HORIZONTAL_ALIGN HORIZONTAL_ALIGN_CENTER
#undef CHOICE_SIZE_X
#define CHOICE_SIZE_X 340
#undef CHOICE_X_START
#undef CHOICE_Y_START
#define CHOICE_X_START -170
#define CHOICE_Y_START 365
#define SIGNED_IN_RECT -350 60 250 15
{
menuDef {
name mods_menu
rect 0 0 640 480 HORIZONTAL_ALIGN_FULLSCREEN
focuscolor COLOR_FOCUSED
style 1
onOpen
{
setLocalVarBool ui_hideBack 1;
setLocalVarBool ui_inOverlay 1;
setdvar ui_showOnlineOfflineButton "0";
uiScript loadMods;
}
onClose
{
setLocalVarBool ui_hideBack 0;
setLocalVarBool ui_inOverlay 0;
setdvar ui_showOnlineOfflineButton "1";
}
onESC
{
close self; open main_text;
}
#include "ui/overlaybg.inc"
BACKGROUND_BLACK_LETTERBOX_BLURWORLD_VIS( 0 , 0 )
OVERLAY_BACKGROUND_VIS( !menuisopen( "menu_xboxlive_barracks" ) )
CHOICE_OVERLAY_TITLE( "@MENU_MODS" )
#include "ui_mp/navcontrols.inc"
// CHOICE_MENU_TITLE( "@MENU_MODS" )
itemDef
{
name modlist
rect -170 80 340 280 HORIZONTAL_ALIGN_CENTER CHOICE_VERTICAL_ALIGN
type ITEM_TYPE_LISTBOX
style WINDOW_STYLE_FILLED
textstyle ITEM_TEXTSTYLE_SHADOWED
elementwidth 120
elementheight 22
textscale CHOICE_TEXTSIZE
elementtype LISTBOX_TEXT
feeder FEEDER_MODS
textalignx 6
textaligny 0
forecolor 1 1 1 0.9
focusColor 1 1 1 0.9
disableColor 1 1 1 0.9
backcolor 0 0 0 0
border 1
bordersize 1
bordercolor 1 1 1 0.15
outlinecolor 1 1 1 0.2
visible MENU_TRUE
action { show accept; }
doubleClick { play "mouse_click"; uiScript RunMod; }
//mouseEnter { show floater_message }
//mouseExit { hide floater_message }
}
CHOICE_BUTTON( 1, "@MENU_LAUNCH", uiScript RunMod; )
CHOICE_BUTTON_VIS( 2, "Launch Without Mods", uiScript ClearMods;, when( dvarString( fs_game ) != "" ); )
/*
itemDef
{
name accept
text "@MENU_LAUNCH"
type 1
style WINDOW_STYLE_FILLED
textstyle ITEM_TEXTSTYLE_SHADOWED
rect 40 360 100 20 CHOICE_HORIZONTAL_ALIGN CHOICE_VERTICAL_ALIGN
textalign ITEM_ALIGN_CENTER
textalignx 48
textaligny 14
textscale CHOICE_TEXTSIZE
forecolor CHOICE_TEXTCOLOR
backcolor 0 0 0 0
visible MENU_TRUE
//mouseEnter { setitemcolor accept backcolor UI_BUTTON_BACK_COLOR_HOVER;play "mouse_over"; }
//mouseExit { setitemcolor accept backcolor UI_BUTTON_BACK_COLOR }
action { play "mouse_click"; uiScript RunMod }
}
itemDef
{
name launchWithoutMods
text "Launch Without Mods"
type 1
style WINDOW_STYLE_FILLED
textstyle ITEM_TEXTSTYLE_SHADOWED
rect 160 360 100 20 CHOICE_HORIZONTAL_ALIGN CHOICE_VERTICAL_ALIGN
textalign ITEM_ALIGN_CENTER
textalignx 48
textaligny 14
textscale CHOICE_TEXTSIZE
forecolor CHOICE_TEXTCOLOR
backcolor 0 0 0 0
visible MENU_TRUE
//mouseEnter { setitemcolor launchWithoutMods backcolor UI_BUTTON_BACK_COLOR_HOVER;play "mouse_over"; }
//mouseExit { setitemcolor launchWithoutMods backcolor UI_BUTTON_BACK_COLOR }
action { play "mouse_click"; uiScript ClearMods }
}
*/
/*
itemDef
{
name floater_message
rect 0 322 640 30
text "@MENU_SELECT_MOD_NAME_TO_LAUNCH"
forecolor 1 .75 0 1
textfont UI_FONT_NORMAL
textscale .25
textalignx 221
textalign 1
textaligny 20
visible 0
}
*/
}
}