cod4-sdk/raw/ui_mp/scriptmenus/class_splitscreen.menu
2008-01-19 00:00:00 +00:00

126 lines
3.6 KiB
Text

#include "ui/menudef.h"
#include "ui_mp/common_macro.inc"
#define CHOICE_SEP_OFFSET_Y -2
#define CHOICE_SEP_1 3
#define STYLE2_NOPOSITION 1
#define SPLITSCREEN_ENABLED 1
#ifndef CHOICE_X_START
#define CHOICE_X_START 0
#endif
#ifndef CHOICE_Y_START
#define CHOICE_Y_START 70
#include "ui_mp/menustyle.inc"
#include "ui_mp/choices_setup_teams.menu"
#undef A_BUTTON_SIZE
#define A_BUTTON_SIZE 0.3
#undef A_BUTTON_OFFSET_Y
#define A_BUTTON_OFFSET_Y 1
#undef A_BUTTON_OFFSET_X
#define A_BUTTON_OFFSET_X (0-2)
#undef A_BUTTON_FONT
#define A_BUTTON_FONT UI_FONT_SMALL
#undef CHOICE_TEXTFONT
#define CHOICE_TEXTFONT UI_FONT_SMALL
#define ORIGIN_DESCRIPTION (CHOICE_X_START + 15) 190
{
menuDef
{
name "class_splitscreen"
rect 0 0 640 480
focuscolor COLOR_FOCUSED
style WINDOW_STYLE_EMPTY
blurWorld 7.0
legacySplitScreenScale
onOpen {
focusFirst;
}
onEsc {
scriptMenuResponse "back";
}
execkeyint BUTTON_START {
scriptMenuResponse "back";
}
// background overlay
itemDef
{
style WINDOW_STYLE_FILLED
rect 0 0 640 480 HORIZONTAL_ALIGN_FULLSCREEN VERTICAL_ALIGN_FULLSCREEN
backcolor 0 0 0 0.85 //0 0.05 0.15 0.5
visible 1
decoration
}
// gradient_top
itemDef
{
style WINDOW_STYLE_SHADER
rect 0 0 854 75 HORIZONTAL_ALIGN_FULLSCREEN 0
background "gradient_top"
visible 1
decoration
}
// gradient_bottom
itemDef
{
style WINDOW_STYLE_SHADER
rect 0 400 854 75 HORIZONTAL_ALIGN_FULLSCREEN 0
background "gradient_bottom"
visible 1
decoration
}
// map display ================================================
#include "ui_mp/tactical_map.inc";
// ------------------ TREE TITLE ------------------
CHOICE_MENU_TITLE_SS( "@MENU_OPTIONS_UPPER_CASE" )
// ------------------ buttons ---------------------
#include "ui_mp/navcontrols.inc"
//=========================================================
//===================== MENU SELECTION ====================
//=========================================================
#include "ui_mp/teamicon.inc"
CHOICE_BUTTON_BG( 1, 1 )
CHOICE_HIGHLIGHT( 1, 1 )
CHOICE_BUTTON_VIS_NOHI( 1, "@MPUI_CHOOSE_CLASS", close self; open "changeclass_splitscreen"; setLocalVarString ui_team "marines";, when( TEAM_IS_MARINES && MAY_CHOOSE_CLASS ); )
CHOICE_BUTTON_VIS_NOHI( 1, "@MPUI_CHOOSE_CLASS", close self; open "changeclass_splitscreen"; setLocalVarString ui_team "opfor";, when( TEAM_IS_OPFOR && MAY_CHOOSE_CLASS ); )
CHOICE_DBUTTON_VIS( 1, "@MPUI_CHOOSE_CLASS", when( dvarInt( scr_oldschool ) == 1 ); )
// CHOICE_HIGHLIGHT_FOR_TEAM( 2 )
CHOICE_BUTTON_VIS( 2, "@MPUI_CHANGE_TEAM", scriptMenuResponse "changeteam", when( MAY_CHOOSE_TEAM ) )
// CHOICE_CAPTION_VIS( 2, "Change Team", when( !MAY_CHOOSE_TEAM ) )
// CHOICE_HIGHLIGHT_FOR_TEAM( 3 )
CHOICE_BUTTON_VIS_ADV( 3, "@MENU_OPTIONS", close self; open ingame_controls_splitscreen, when ( dvarBool(ui_allow_controlschange) );, dvarBool(ui_allow_controlschange) )
CHOICE_BUTTON_VIS_NOHI( 3, "", ;, when( dvarBool(ui_allow_controlschange)==0 ); )
CHOICE_DBUTTON_VIS( 3, "@MENU_OPTIONS", when( dvarBool(ui_allow_controlschange)==0 ); )
CHOICE_SEPARATOR( CHOICE_SEP_1 )
//CHOICE_BUTTON_BG( 4, 1 )
//CHOICE_HIGHLIGHT( 4, 1 )
CHOICE_BUTTON( 4, "@MENU_END_GAME", open popup_endgame_splitscreen )
//CHOICE_BUTTON_VIS_NOHI( 4, "Leave Game", open popup_leavegame_splitscreen, when( dvarInt( splitscreen_playerNum ) > 2 ); )
#include "ui/safearea.menu"
}
}