cod5-sdk/raw/ui/leaderboards.menu
2008-11-20 00:00:00 +00:00

157 lines
8.1 KiB
Text

#include "ui/menudef.h"
#include "ui_mp/common_macro.inc"
#define CHOICE_SIZE_X 220
#define CHOICE_X_SPACING 280
#define CHOICE_Y_COUNT 14
#define CHOICE_X_START 0
#define CHOICE_Y_START 34
#include "ui_mp/menustyle.inc"
#include "ui/choices_setup_common.menu"
#define PLAYERLIST_WIDTH 270
#define ORIGIN_PLAYERLIST (- (PLAYERLIST_WIDTH - RIGHTITEM_OFFSET)) 40
#define ORIGIN_STATUS (- (PLAYERLIST_WIDTH - RIGHTITEM_OFFSET)) 0
#define ORIGIN_DESCRIPTION (CHOICE_X_START + 15) 180
#define COLOR_DESC_TEXT 1 1 1 0.7
#define MENU_FONT_SIZE TEXTSIZE_DEFAULT
#define HIGHLIGHT_SIZE 142 22
#define MENU_FONT_COLOR 1 1 1 0.5
#define MENU_FONT_COLOR2 1 1 1 0.5
#define MENU_LOCKED_COLOR 0.25 0.25 0.25 1
#define ORIGIN_BUTTON_BACK 52 438
#define ORIGIN_BUTTON_INVITE 390 86
#define CLEARUIHINT exec "set ui_hint_text @NULL_EMPTY"
#define PREPROC_HIGHLIGHT( pname, porigin ) \
itemDef { \
name pname \
style WINDOW_STYLE_SHADER \
rect porigin HIGHLIGHT_SIZE 0 0 \
background HIGHLIGHT_SHADER \
forecolor HIGHLIGHT_COLOR \
border HIGHLIGHT_BORDER \
bordersize 1 \
bordercolor HIGHLIGHT_BORDER_COLOR \
visible 1 \
decoration \
}
#define PREPROC_A_BUTTON( pname, porigin ) \
itemDef { \
name pname \
text "@XBOXLIVE_SELECTBUTTON" \
textfont UI_FONT_NORMAL \
textscale A_BUTTON_SIZE \
origin porigin \
forecolor A_BUTTON_COLOR \
visible 1 \
decoration \
}
#define HIDEALL \
hide description_choice1; \
hide description2_choice1; \
hide highlight_choice1; \
hide a_button_choice1; \
hide description_choice2; \
hide description2_choice2; \
hide highlight_choice2; \
hide a_button_choice2; \
hide description_choice3; \
hide highlight_choice3; \
hide a_button_choice3; \
hide description_choice4; \
hide description2_choice4; \
hide highlight_choice4; \
hide a_button_choice4;
{
menuDef{
name menu_leaderboards
fullscreen 1
rect 0 0 640 480
focuscolor COLOR_FOCUSED
style WINDOW_STYLE_FILLED
border 0
soundloop "music_mainmenu"
onOpen{
focusFirst;
}
onEsc{
CLEARUIHINT;
close menu_leaderboards;
}
// ------------------ statics ------------------------
#include "ui/blurredbg.inc"
#include "ui/overlaybg.inc"
OVERLAY_BACKGROUND
CHOICE_MENU_TITLE( "@MENU_LEADERBOARDS_CAP" )
#include "ui/navcontrols.inc"
//=========================================================
//===================== MENU SELECTION ====================
//=========================================================
#define SETUP_ACTION_LEADERBOARD(pname) \
setdvar ui_lb_level pname;\
open menu_leaderboard_level;
#define SETUP_ACTION_LEADERBOARD_NZ(pname, leaderboard_type) \
setdvar ui_lb_level pname;\
setdvar nz_leaderboard_type leaderboard_type;\
open menu_leaderboard_level;
#define LEFT_NAV( pname, to )\
name pname \
execkeyint DPAD_LEFT { setfocus to; } \
execkeyint APAD_LEFT { setfocus to; }
#define RIGHT_NAV( pname, to )\
name pname \
execkeyint DPAD_RIGHT { setfocus to; } \
execkeyint APAD_RIGHT { setfocus to; }
CHOICE_SECTION_TITLE( 1, "@MENU_COMPETITIVE_COOP" )
CHOICE_BUTTON_FOCUS_VIS_EX( 2, "@MENU_LEVEL_MAK", SETUP_ACTION_LEADERBOARD("@MENU_LEVEL_MAK"), exec "set ui_hint_text @MENU_CHECK_HOW_YOUR_SCORE; set lb_type mak; set lb_gametype cmp;", CLEARUIHINT, 1, RIGHT_NAV("L1","R1") )
CHOICE_BUTTON_FOCUS_VIS_EX( 3, "@MENU_LEVEL_PEL1", SETUP_ACTION_LEADERBOARD("@MENU_LEVEL_PEL1"), exec "set ui_hint_text @MENU_CHECK_HOW_YOUR_SCORE; set lb_type pel1; set lb_gametype cmp;", CLEARUIHINT, 1, RIGHT_NAV("L2","R2") )
CHOICE_BUTTON_FOCUS_VIS_EX( 4, "@MENU_LEVEL_PEL2", SETUP_ACTION_LEADERBOARD("@MENU_LEVEL_PEL2"), exec "set ui_hint_text @MENU_CHECK_HOW_YOUR_SCORE; set lb_type pel2; set lb_gametype cmp;", CLEARUIHINT, 1, RIGHT_NAV("L3","R2") )
CHOICE_BUTTON_FOCUS_VIS_EX( 5, "@MENU_LEVEL_SEE1", SETUP_ACTION_LEADERBOARD("@MENU_LEVEL_SEE1"), exec "set ui_hint_text @MENU_CHECK_HOW_YOUR_SCORE; set lb_type see1; set lb_gametype cmp;", CLEARUIHINT, 1, RIGHT_NAV("L4","R2") )
CHOICE_BUTTON_FOCUS_VIS_EX( 6, "@MENU_LEVEL_PEL1A", SETUP_ACTION_LEADERBOARD("@MENU_LEVEL_PEL1A"), exec "set ui_hint_text @MENU_CHECK_HOW_YOUR_SCORE; set lb_type pel1a; set lb_gametype cmp;", CLEARUIHINT, 1, RIGHT_NAV("L5","R2") )
CHOICE_BUTTON_FOCUS_VIS_EX( 7, "@MENU_LEVEL_PEL1B", SETUP_ACTION_LEADERBOARD("@MENU_LEVEL_PEL1B"), exec "set ui_hint_text @MENU_CHECK_HOW_YOUR_SCORE; set lb_type pel1b; set lb_gametype cmp;", CLEARUIHINT, 1, RIGHT_NAV("L6","R2") )
CHOICE_BUTTON_FOCUS_VIS_EX( 8, "@MENU_LEVEL_SEE2", SETUP_ACTION_LEADERBOARD("@MENU_LEVEL_SEE2"), exec "set ui_hint_text @MENU_CHECK_HOW_YOUR_SCORE; set lb_type see2; set lb_gametype cmp;", CLEARUIHINT, 1, RIGHT_NAV("L7","R2") )
CHOICE_BUTTON_FOCUS_VIS_EX( 9, "@MENU_LEVEL_BER1", SETUP_ACTION_LEADERBOARD("@MENU_LEVEL_BER1"), exec "set ui_hint_text @MENU_CHECK_HOW_YOUR_SCORE; set lb_type ber1; set lb_gametype cmp;", CLEARUIHINT, 1, RIGHT_NAV("L8","R2") )
CHOICE_BUTTON_FOCUS_VIS_EX( 10, "@MENU_LEVEL_BER2", SETUP_ACTION_LEADERBOARD("@MENU_LEVEL_BER2"), exec "set ui_hint_text @MENU_CHECK_HOW_YOUR_SCORE; set lb_type ber2; set lb_gametype cmp;", CLEARUIHINT, 1, RIGHT_NAV("L9","R2") )
CHOICE_BUTTON_FOCUS_VIS_EX( 11, "@MENU_LEVEL_OKI2", SETUP_ACTION_LEADERBOARD("@MENU_LEVEL_OKI2"), exec "set ui_hint_text @MENU_CHECK_HOW_YOUR_SCORE; set lb_type oki2; set lb_gametype cmp;", CLEARUIHINT, 1, RIGHT_NAV("L10","R2") )
CHOICE_BUTTON_FOCUS_VIS_EX( 12, "@MENU_LEVEL_OKI3", SETUP_ACTION_LEADERBOARD("@MENU_LEVEL_OKI3"), exec "set ui_hint_text @MENU_CHECK_HOW_YOUR_SCORE; set lb_type oki3; set lb_gametype cmp;", CLEARUIHINT, 1, RIGHT_NAV("L11","R2") )
CHOICE_BUTTON_FOCUS_VIS_EX( 13, "@MENU_LEVEL_BER3", SETUP_ACTION_LEADERBOARD("@MENU_LEVEL_BER3"), exec "set ui_hint_text @MENU_CHECK_HOW_YOUR_SCORE; set lb_type ber3; set lb_gametype cmp;", CLEARUIHINT, 1, RIGHT_NAV("L12","R2") )
CHOICE_BUTTON_FOCUS_VIS_EX( 14, "@MENU_LEVEL_BER3B", SETUP_ACTION_LEADERBOARD("@MENU_LEVEL_BER3B"), exec "set ui_hint_text @MENU_CHECK_HOW_YOUR_SCORE; set lb_type ber3b; set lb_gametype cmp;", CLEARUIHINT, 1, RIGHT_NAV("L13","R2") )
CHOICE_SECTION_TITLE_VIS( 15, "@MENU_NAZI_ZOMBIES", when( dvarInt("mis_01") >= dvarInt("mis_01_unlock") && dvarString( language ) != "german" ) )
CHOICE_SECTION_TITLE_VIS( 15, "@MPUI_LOCKED_MODE", when( dvarInt("mis_01") < dvarInt("mis_01_unlock") && dvarString( language ) != "german" ) )
CHOICE_LOCKEDICON_VIS( 16, "specialty_locked", when( dvarInt("mis_01") < dvarInt("mis_01_unlock") && dvarString( language ) != "german" ) )
CHOICE_BUTTON_FOCUS_VIS_NOHI_EX( 16, "", ;, ;, ;, when( dvarInt("mis_01") < dvarInt("mis_01_unlock") && dvarString( language ) != "german" ), ; )
CHOICE_DBUTTON_VIS( 16, "@MPUI_LOCKED_MODE", when( dvarInt("mis_01") < dvarInt("mis_01_unlock") && dvarString( language ) != "german" ) )
CHOICE_BUTTON_FOCUS_VIS_EX( 16, "@MENU_ZOMBIES_WAVES", SETUP_ACTION_LEADERBOARD_NZ("@MENU_ZOMBIES_WAVES", waves), exec "set ui_hint_text @MENU_CHECK_HOW_YOUR_SCORE; set lb_type nazi_zombie_prototype_waves; set lb_gametype zom;", CLEARUIHINT, when( dvarInt("mis_01") >= dvarInt("mis_01_unlock") && dvarString( language ) != "german" ), LEFT_NAV("R1","L1") )
CHOICE_LOCKEDICON_VIS( 17, "specialty_locked", when( dvarInt("mis_01") < dvarInt("mis_01_unlock") && dvarString( language ) != "german" ) )
CHOICE_BUTTON_FOCUS_VIS_NOHI_EX( 17, "", ;, ;, ;, when( dvarInt("mis_01") < dvarInt("mis_01_unlock") && dvarString( language ) != "german" ), ; )
CHOICE_DBUTTON_VIS( 17, "@MPUI_LOCKED_MODE", when( dvarInt("mis_01") < dvarInt("mis_01_unlock") && dvarString( language ) != "german" ) )
CHOICE_BUTTON_FOCUS_VIS_EX( 17, "@MENU_ZOMBIES_POINTS", SETUP_ACTION_LEADERBOARD_NZ("@MENU_ZOMBIES_POINTS", points), exec "set ui_hint_text @MENU_CHECK_HOW_YOUR_SCORE; set lb_type nazi_zombie_prototype_points; set lb_gametype zom;", CLEARUIHINT, when( dvarInt("mis_01") >= dvarInt("mis_01_unlock") && dvarString( language ) != "german" ), LEFT_NAV("R2","L2") )
#include "ui/safearea.menu"
}
}