#include "ui/menudef.h" #include "ui_mp/main.inc" { menuDef { name "cdkey_menu" rect 0 0 640 480 0 0 forecolor 1 1 1 1 focuscolor 1 1 1 1 blurWorld 7 onOpen { focusfirst; } onEsc { close self; if(dvarBool("ended") == 1){ open "final_map"; } } itemDef { rect -426.667 -426.667 893.333 893.333 2 2 decoration visible 1 style 3 forecolor 0 0 0 0.4 background "white" textscale 0.55 } itemDef { rect -426.667 -426.667 893.333 893.333 2 2 decoration visible 1 style 3 forecolor 0 0 0 1 background "black" textscale 0.55 exp forecolor a ( ( cos ( milliseconds( ) / 1500 ) * 3) - 2.75 ) } itemDef { rect -108 -130 860 470 0 0 decoration visible 1 style 3 forecolor 0 0 0 0.15 backcolor 0 0 0 0.15 border 1 borderSize 2 borderColor 0 0 0 0.2 background "black" textscale 0.55 } itemDef { rect 250 45 220 1 1 1 decoration visible 1 style 3 forecolor 1 1 1 0.05 background "white" textscale 0.55 } itemDef { rect 250 75 220 1 1 1 decoration visible 1 style 3 forecolor 1 1 1 0.05 background "white" textscale 0.55 } itemDef { rect (250 - 15) 53 1 165 1 1 decoration visible 1 style 3 forecolor 1 1 1 0.05 background "white" textscale 0.55 } itemDef { rect (250-45) 0 310 305 1 1 style 3 foreColor 1 1 1 1 decoration visible 1 exp material("box") } itemDef { rect (250 + 220 + 13.5) 53 1 165 1 1 decoration visible 1 style 3 forecolor 1 1 1 0.05 background "white" textscale 0.55 } itemDef { rect 250 67.5 220 28 1 1 decoration visible 1 forecolor 1 0.8 0.3 1 textfont 9 textalign 1 textscale 0.35 exp text ("DISTANCE LEADERBOARD") } itemDef { rect 250 0 640 480 4 4 decoration visible 1 style 3 forecolor 1 1 1 0 background "mockup_bg_glow" textscale 0.55 exp forecolor a ( ( ( sin( milliseconds( ) / 1500 ) + 1 ) 0.25 ) + 0.25 ) } #define OPTION(index, dvartop) \ itemDef \ { \ name txt \ rect 250 (77 + (18.5 * index)) 220 18.5 1 1 \ visible 1 \ style 1 \ forecolor 1 1 1 1 \ backcolor 0 0 0 0 \ disablecolor 0.6 0.55 0.55 1 \ type 1 \ textfont 3 \ textAlign 1 \ textAlignX 0 \ textAligny 15 \ textscale 0.25 \ exp text (dvarString(dvartop)) \ disabled when(0 == 1) \ onFocus \ { \ play "mouse_over"; \ setItemColor self backcolor 0 0 0 0.2; \ setLocalVarBool "ui_menuAButton" ( 1 ); \ setLocalVarFloat "ui_popupYPos" ( getfocuseditemy( ) ); \ } \ leaveFocus \ { \ setItemColor self backcolor 0 0 0 "0"; \ setLocalVarString "ui_hint_text" ( "@NULL_EMPTY" ); \ setLocalVarBool "ui_menuAButton" ( 0 ); \ } \ } OPTION(0, "top_0"); OPTION(1, "top_1"); OPTION(2, "top_2"); OPTION(3, "top_3"); OPTION(4, "top_4"); OPTION(5, "top_5"); OPTION(6, "top_6"); OPTION(7, "top_7"); itemDef { rect 250 226 220 1 1 1 decoration visible 1 style 3 forecolor 1 1 1 0.05 background "white" textscale 0.55 } // BOTTOM itemDef { rect 59 390 70 75 0 0 decoration visible 1 forecolor 1 1 1 1 textfont 9 textscale 0.2 exp text ("THIS IS") } itemDef { rect 59 406 120 75 0 0 decoration visible 1 forecolor 1 0.8 0.3 1 textfont 9 textscale 0.43 exp text (dvarString("server_name")) } itemDef { rect 59 418 70 75 0 0 decoration visible 1 forecolor 1 1 1 1 textfont 9 textscale 0.2 exp text ("CREATED BY") } itemDef { rect 59 437 120 75 0 0 decoration visible 1 forecolor 1 0.8 0.3 1 textfont 9 textscale 0.43 exp text ("SHOCKEH & RAEZ") } #define BOTTONE_PICCOLO(fila,colonna,descrizione, materiale, myaction)\ itemDef \ { \ name "social" \ rect (545 + (fila * 25) + 20/6) (374 + colonna * (25) + 20/6) 20 20 0 0 \ style 3 \ foreColor 1 1 1 1 \ textScale 3 \ forecolor 1 1 1 1 \ type 1 \ decoration \ visible 1 \ exp material(materiale) \ } \ itemDef \ { \ rect (545 + (fila * 25)) (374 + colonna * (25) ) 25 25 0 0 \ visible 1 \ style 1 \ forecolor 1 0.8 0.3 1 \ backcolor 0 0 0 0.15 \ border 1 \ borderSize 1 \ borderColor 0 0 0 0.35 \ type 1 \ visible 1 \ action \ { \ play "mouse_click"; \ execnow myaction; \ } \ onFocus \ { \ play "mouse_over"; \ setItemColor self backcolor 0 0 0 0.3 \ setLocalVarBool "ui_menuAButton" ( 1 ); \ setLocalVarFloat "ui_popupYPos" ( getfocuseditemy( ) ); \ } \ leaveFocus \ { \ setItemColor self backcolor 0 0 0 0.1 \ setLocalVarString "ui_hint_text" ( "@NULL_EMPTY" ); \ setLocalVarBool "ui_menuAButton" ( 0 ); \ } \ } \ itemDef \ { \ rect (420 + (fila * 25)) (374 + colonna * (25)) 125 25 0 0 \ visible 1 \ style 1 \ forecolor 1 1 1 1 \ backcolor 0 0 0 0.15 \ border 1 \ borderSize 1 \ borderColor 0 0 0 0.35 \ type 1 \ visible 1 \ decoration \ textfont 9 \ textalign 6 \ textAlignY 7 \ textAlignX -5 \ textscale 0.192 \ exp text(descrizione) \ } // fila colonna testo materiale azione dimX dimY posX posY BOTTONE_PICCOLO(0, 0, "Discord.io/SnRServers", "discord", "openLink www.discord.gg/DX6d38H"); BOTTONE_PICCOLO(0, 1, "Twitter.com/SnRServers", "twitter", "openLink www.twitter.com/SnRServers"); BOTTONE_PICCOLO(0, 2, "SnRServers.com/Donation", "paypal", "openLink www.snrservers.com/donation"); itemDef { rect (545 + 25) 374 93 75 0 0 visible 1 style 1 forecolor 1 0.8 0.3 1 backcolor 0 0 0 0.15 border 1 borderSize 1 borderColor 0 0 0 0.35 type 1 visible 1 action { play "mouse_click"; open "popup_leavegame"; } onFocus { play "mouse_over"; setItemColor self backcolor 0 0 0 0.3 setLocalVarBool "ui_menuAButton" ( 1 ); setLocalVarFloat "ui_popupYPos" ( getfocuseditemy( ) ); } leaveFocus { setItemColor self backcolor 0 0 0 0.1 setLocalVarString "ui_hint_text" ( "@NULL_EMPTY" ); setLocalVarBool "ui_menuAButton" ( 0 ); } } itemDef { rect (545 + 25 + 10) (374 + 10) 70 56 0 0 style 3 foreColor 1 1 1 1 textScale 3 forecolor 1 1 1 1 type 1 decoration visible 1 exp material("leave") } itemDef { rect -100 55 220 170 0 1 style 3 foreColor 1 1 1 1 decoration visible 1 exp material("box") } itemDef { rect -80 80 180 28 0 1 decoration visible 1 forecolor 1 0.8 0.3 1 textfont 9 textalign 4 textalignx 4 textscale 0.25 exp text ( "Online vips and admins" ) } itemDef { rect -80 95 175 120 0 1 decoration autowrapped visible 1 forecolor 1 1 1 0.75 textalign 4 textalignx 4 textscale 0.25 exp text dvarstring("g_description") } itemDef { rect 9 -75 76.8 81.6 1 3 decoration visible 1 style 3 forecolor 1 1 1 1 textfont 9 background "cardicon_prestige10_02" } itemDef { rect 15 -69 64.5 68 1 3 decoration visible 1 style 3 forecolor 1 1 1 1 textfont 9 border 1 borderSize 0.5 forecolor 0 0 0 0 backcolor 0 0 0 0 borderColor 1 0.8 0.3 1 background "white" textscale 0.52 } itemDef { rect 510 55 220 170 0 1 style 3 foreColor 1 1 1 1 decoration visible 1 exp material("box") } itemDef { rect 530 80 175 120 0 1 decoration visible 1 forecolor 1 0.8 0.3 1 textfont 9 textalign 4 textalignx 4 textscale 0.25 exp text ( "Rules & More info" ) } itemDef { rect 530 95 175 120 0 1 decoration autowrapped visible 1 forecolor 1 1 1 0.75 textalign 4 textalignx 4 textscale 0.25 exp text(dvarString("server_rules")) } } }