Advertisement
Guest User

hud

a guest
Apr 10th, 2014
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 9.11 KB | None | 0 0
  1.  
  2.  
  3.  
  4.  
  5. // Gametypes: g_gametype: 0 = FFA, 1 = Duel, 2 = Single Player (not usable), 3 = TDM, 4 = CA, 5 = CTF, 6 = One-Flag CTF = 7
  6. // Overload (not complete), 8 = Harvester, 9 = Freeze Tag, 10 = Domination, 11 = Attack & Defend, 12 = Red Rover
  7. // elementcolor: text=backcolor paint=forecolor
  8. // background "gfx/2d/crosshair14.tga" style 1 backcolor 0 0 0 1 visible 1
  9.  
  10.  
  11. #include "ui/menudef.h"
  12.  
  13.  
  14.  
  15.  
  16.  
  17.  
  18.  
  19.  
  20.  
  21. /// HEALTH VALUE
  22.  
  23. menuDef { fullScreen MENU_FALSE visible MENU_TRUE rect 0 3 0 0
  24.  
  25. itemDef { ownerdraw CG_PLAYER_HEALTH visible 1 textstyle 6 textscale 0.9
  26. addColorRange -999 0 0 0 0 0
  27. addColorRange 1 40 1 0.02 0 1
  28. addColorRange 41 80 0.9 0.02 0 1
  29. addColorRange 81 100 1 0.8 0 1
  30.  
  31. addColorRange 101 299 0.25 0.25 0.25 1 // 0.5 0.5 0.5 1
  32. addColorRange 300 999 0.25 0.25 0.25 1 // 0 0 0 0.7 //
  33. rect 320 471 0 0
  34. }
  35.  
  36.  
  37.  
  38.  
  39.  
  40.  
  41.  
  42.  
  43. /// ARMOR VALUE
  44.  
  45. itemDef { ownerdraw CG_PLAYER_ARMOR_VALUE visible 1 textstyle 6 textalign 0 textscale 0.5
  46. addColorRange -999 0 0 0 0 0
  47. addColorRange 1 50 1 0.02 0 1
  48. addColorRange 51 999 1 0.8 0 1
  49. rect 415 471 0 0
  50.  
  51. cvartest "g_gametype" showcvar { 0 1 3 9 }
  52. }
  53. }
  54.  
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.  
  64.  
  65. /// OBITS
  66.  
  67. menuDef { fullScreen MENU_FALSE visible MENU_TRUE
  68.  
  69. itemdef {
  70. rect 470 473 20 400
  71. textscale .3
  72. textalign ITEM_ALIGN_CENTER ownerdraw CG_PLAYER_OBIT visible 1 style 1
  73. }
  74.  
  75. }
  76.  
  77.  
  78.  
  79.  
  80.  
  81.  
  82.  
  83.  
  84.  
  85. /// CHAT AREA
  86.  
  87. menuDef { fullScreen MENU_FALSE visible MENU_TRUE rect 10 400 50 100 // rect here!
  88.  
  89. itemDef {
  90. rect -10 -400 640 480 visible 1 style 1
  91. ownerdrawflag CG_SHOW_IF_CHAT_VISIBLE
  92. backcolor 0 0 0 0.75 }
  93.  
  94. itemdef { ownerdraw CG_AREA_NEW_CHAT textscale 1 visible 1 }
  95. }
  96.  
  97.  
  98.  
  99.  
  100.  
  101.  
  102.  
  103.  
  104.  
  105. /// TIMER CLOCK
  106.  
  107. menuDef { fullScreen MENU_FALSE visible MENU_TRUE
  108.  
  109.  
  110. itemDef { visible 1 style WINDOW_STYLE_TEAMCOLOR // BACKGROUND
  111. rect 190 0 130 32
  112. }
  113.  
  114.  
  115. itemDef {
  116. rect 220 27 0 0 // CLOCK
  117. visible 1 textstyle 2 forecolor 1 1 1 1
  118. textscale 0.666 ownerdraw CG_LEVELTIMER textalign 0
  119. }
  120. }
  121.  
  122.  
  123.  
  124. /// ROUND COUNTDOWN 30s
  125.  
  126. menuDef { fullScreen MENU_FALSE visible MENU_TRUE
  127.  
  128. /// ROUND TIMER -30sec-
  129. itemDef {
  130. rect 240 60 0 0
  131. visible 1 textscale .3 textalign 0
  132. ownerdraw CG_ROUNDTIMER textstyle 3 style 1 }
  133. }
  134.  
  135.  
  136.  
  137.  
  138.  
  139.  
  140.  
  141.  
  142.  
  143. /// POWERUP QUAD + BATTLESUIT
  144.  
  145. menuDef { fullScreen MENU_FALSE visible MENU_TRUE rect 550 250 0 0 // 15 425 0 0 //
  146. itemDef { visible 1 ownerdraw CG_AREA_POWERUP
  147. rect -10 0 50 40
  148. textscale .8 }
  149. }
  150.  
  151.  
  152.  
  153.  
  154.  
  155.  
  156.  
  157.  
  158.  
  159. /// PICKUPS TELEPORT + KAMI
  160.  
  161. menuDef { fullScreen MENU_FALSE visible MENU_TRUE
  162. rect 600 400 1 1
  163. itemDef { name "playeritem" visible 1 ownerdraw CG_PLAYER_ITEM rect 0 0 27 27 }
  164. itemDef { name "CTFPOWERUP" visible 1 ownerdraw CG_CTF_POWERUP rect 0 40 27 27 }
  165. }
  166.  
  167.  
  168.  
  169.  
  170.  
  171.  
  172.  
  173.  
  174. // SKILLRATING
  175.  
  176. menuDef { fullScreen MENU_FALSE visible MENU_TRUE
  177.  
  178. // rect 600 150 0 0
  179. rect 576 388 0 0
  180.  
  181. itemDef { visible 1 textstyle 0
  182. textscale 0.3 forecolor 1 1 1 1
  183. cvar "sv_skillrating"
  184. cvartest "ybl_skill" showcvar { 1 }
  185. }
  186.  
  187. }
  188.  
  189.  
  190.  
  191.  
  192.  
  193.  
  194.  
  195.  
  196.  
  197.  
  198.  
  199.  
  200. // BACKGROUND ( FFA )
  201.  
  202. menuDef { fullScreen MENU_FALSE visible MENU_TRUE
  203. rect 0 2 0 0
  204.  
  205. itemDef { visible 1 style 1 backcolor .23 .23 .23 1
  206. rect 0 2 153 16 cvartest "g_gametype" showcvar { 0 1 12 }
  207. }
  208.  
  209. itemDef { visible 1 style 1 backcolor .23 .23 .23 1
  210. rect 0 22 153 16 cvartest "g_gametype" showcvar { 0 1 12 }
  211. }
  212. }
  213.  
  214.  
  215.  
  216. /// SCOREBOARD SELF HIGHLIGHT ( FFA )
  217.  
  218.  
  219.  
  220. menuDef {
  221. name "SelfFrameHighlights"
  222. fullScreen MENU_FALSE
  223. visible MENU_TRUE
  224.  
  225. rect 0 2 0 0
  226.  
  227. itemDef {
  228. cvartest "g_gametype" showcvar { 0 1 12 }
  229. name "SelfTLeft"
  230. rect 0 2 153 16
  231. visible 1
  232. backcolor .6 .6 .6 1
  233. style WINDOW_STYLE_FILLED
  234. ownerdrawflag CG_SHOW_IF_PLYR_IS_FIRST_PLACE
  235.  
  236. }
  237.  
  238. itemDef {
  239. cvartest "g_gametype" showcvar { 0 1 12 }
  240. name "SelfTLeft"
  241. rect 0 22 153 16
  242. visible 1
  243. ownerdrawflag CG_SHOW_IF_PLYR_IS_NOT_FIRST_PLACE
  244. backcolor .6 .6 .6 1
  245. style WINDOW_STYLE_FILLED
  246. }
  247. }
  248.  
  249.  
  250.  
  251.  
  252. // BACKGROUND SHADOW 4 SCORES ( FFA )
  253.  
  254. menuDef { fullScreen MENU_FALSE visible MENU_TRUE
  255. rect 0 2 0 0
  256.  
  257. itemDef { visible 1 style 1 backcolor 0 0 0 .3
  258. rect 123 2 30 16 cvartest "g_gametype" showcvar { 0 1 12 }
  259. }
  260.  
  261. itemDef { visible 1 style 1 backcolor 0 0 0 .3
  262. rect 123 22 30 16 cvartest "g_gametype" showcvar { 0 1 12 }
  263. }
  264. }
  265.  
  266.  
  267.  
  268.  
  269.  
  270.  
  271.  
  272.  
  273. // SCOREBOARD VALUE ( FFA )
  274.  
  275.  
  276. menuDef {
  277. name "scores"
  278. fullScreen MENU_FALSE
  279. visible MENU_TRUE
  280. rect -3 2 0 0
  281.  
  282. itemDef {
  283. name "1stplace"
  284. ownerdraw CG_1ST_PLACE_SCORE
  285. rect 10 14 140 40
  286. visible 1 cvartest "g_gametype" showcvar { 0 1 12 }
  287. textscale .24 textstyle 3
  288. }
  289.  
  290.  
  291. itemdef {
  292.  
  293. name "2ndplace"
  294. ownerdraw CG_2ND_PLACE_SCORE
  295. rect 10 34 140 40
  296. visible 1 cvartest "g_gametype" showcvar { 0 1 12 }
  297. textscale .24 textstyle 3
  298. }
  299. }
  300.  
  301.  
  302.  
  303.  
  304.  
  305.  
  306.  
  307.  
  308.  
  309.  
  310.  
  311.  
  312. /// PLAYER COUNTER /// ( TEAM )
  313.  
  314.  
  315. menuDef { fullScreen MENU_FALSE visible MENU_TRUE
  316. rect 15 474 0 0
  317.  
  318.  
  319. // HOME
  320.  
  321. itemdef { textstyle 2 visible 1 ownerdraw CG_RED_CLAN_PLYRS ownerdrawflag CG_SHOW_IF_PLYR_IS_ON_RED
  322. forecolor 1 1 1 1 textscale .45 cvartest "g_gametype" showcvar { 4 9 } }
  323.  
  324. itemdef { textstyle 2 visible 1 ownerdraw CG_BLUE_CLAN_PLYRS ownerdrawflag CG_SHOW_IF_PLYR_IS_ON_BLUE
  325. forecolor 1 1 1 1 textscale .45 cvartest "g_gametype" showcvar { 4 9 } }
  326. }
  327.  
  328. // GUEST
  329.  
  330. menuDef { fullScreen MENU_FALSE visible MENU_TRUE
  331. rect 45 474 0 0
  332.  
  333. itemdef { visible 1 textstyle 2 ownerdraw CG_BLUE_CLAN_PLYRS ownerdrawflag CG_SHOW_IF_PLYR_IS_ON_RED
  334. forecolor 1 1 1 1 textscale .45 cvartest "g_gametype" showcvar { 4 9 } }
  335.  
  336. itemdef {
  337. visible 1 textstyle 2 ownerdraw CG_RED_CLAN_PLYRS ownerdrawflag CG_SHOW_IF_PLYR_IS_ON_BLUE
  338. forecolor 1 1 1 1 textscale .45 cvartest "g_gametype" showcvar { 4 9 } }
  339. }
  340.  
  341.  
  342.  
  343.  
  344.  
  345.  
  346.  
  347.  
  348.  
  349.  
  350.  
  351.  
  352.  
  353.  
  354. /// SCOREBOARD BACKGROUND ( TEAM )
  355.  
  356.  
  357.  
  358. menuDef {
  359. name "SelfFrameHighlights"
  360. fullScreen MENU_FALSE
  361. visible MENU_TRUE
  362.  
  363. rect 2 2 0 0
  364.  
  365.  
  366.  
  367.  
  368.  
  369.  
  370.  
  371.  
  372. itemDef { //// MY TEAM SHADOW (TEAMCOLOR)
  373. name "SelfTLeft"
  374. rect 4 22 25 2
  375. visible 1
  376. cvartest "g_gametype" showcvar { 3 4 9 10 }
  377. ownerdrawflag CG_SHOW_IF_PLYR_IS_FIRST_PLACE
  378. style WINDOW_STYLE_TEAMCOLOR
  379.  
  380. }
  381.  
  382. itemDef { //// MY TEAM SHADOW (TEAMCOLOR)
  383. name "SelfBLeft"
  384. rect 29 4 25 20
  385. visible 1
  386. cvartest "g_gametype" showcvar { 3 4 9 10 }
  387. ownerdrawflag CG_SHOW_IF_PLYR_IS_NOT_FIRST_PLACE
  388. style WINDOW_STYLE_TEAMCOLOR
  389. }
  390.  
  391. itemDef { //// ENEMY TEAM SHADOW
  392. name "SelfBLeft"
  393. rect 4 4 25 20
  394. visible 1
  395. cvartest "g_gametype" showcvar { 3 4 9 10 }
  396. ownerdrawflag CG_SHOW_IF_PLYR_IS_NOT_FIRST_PLACE
  397. style WINDOW_STYLE_FILLED backcolor 0 0 0 .3
  398. }
  399.  
  400. itemDef { //// ENEMY TEAM SHADOW
  401. name "SelfBLeft"
  402. rect 29 4 25 20
  403. visible 1
  404. cvartest "g_gametype" showcvar { 3 4 9 10 }
  405. ownerdrawflag CG_SHOW_IF_PLYR_IS_FIRST_PLACE
  406. style WINDOW_STYLE_FILLED backcolor 0 0 0 .3
  407. }
  408.  
  409.  
  410.  
  411.  
  412.  
  413. itemDef { /// BOX (ENEMY TEAM)
  414. name "SelfBLeft"
  415. rect 2 2 25 20
  416. visible 1
  417. cvartest "g_gametype" showcvar { 3 4 9 10 }
  418. backcolor 0 0 0 1
  419. style WINDOW_STYLE_FILLED
  420. }
  421. itemDef { /// BOX (ENEMY TEAM)
  422. name "SelfBLeft"
  423. rect 27 2 25 20
  424. visible 1
  425. cvartest "g_gametype" showcvar { 3 4 9 10 }
  426. backcolor 0 0 0 1
  427. style WINDOW_STYLE_FILLED
  428. }
  429.  
  430.  
  431.  
  432.  
  433.  
  434.  
  435. //// MY TEAM BOX (TEAMCOLOR)
  436.  
  437. itemDef {
  438. name "SelfTLeft"
  439. rect 2 2 25 20
  440. visible 1
  441. cvartest "g_gametype" showcvar { 3 4 9 10 }
  442. ownerdrawflag CG_SHOW_IF_PLYR_IS_FIRST_PLACE
  443. style WINDOW_STYLE_FILLED
  444. ownerdraw CG_TEAM_COLOR
  445.  
  446. }
  447.  
  448. itemDef {
  449. name "SelfBLeft"
  450. rect 27 2 25 20
  451. visible 1
  452. cvartest "g_gametype" showcvar { 3 4 9 10 }
  453. ownerdrawflag CG_SHOW_IF_PLYR_IS_NOT_FIRST_PLACE
  454. style 1
  455. ownerdraw CG_TEAM_COLOR
  456. }
  457.  
  458.  
  459. }
  460.  
  461.  
  462.  
  463.  
  464.  
  465.  
  466.  
  467.  
  468.  
  469.  
  470.  
  471.  
  472.  
  473. /// SCOREBOARD VALUE ( TEAM )
  474.  
  475.  
  476. menuDef {
  477. name "scores"
  478. fullScreen MENU_FALSE
  479. visible MENU_TRUE
  480.  
  481. rect -12 3 0 0
  482.  
  483. itemdef { // 1STPLACE VALUE
  484.  
  485. ownerdraw CG_1ST_PLACE_SCORE
  486. rect -130 15 165 0
  487. cvartest "g_gametype" showcvar { 3 4 9 10 }
  488. visible 1 textstyle 3
  489. textscale .2
  490.  
  491. }
  492. itemdef { // 2ND PLACE VALUE
  493. name "2ndplace"
  494. ownerdraw CG_2ND_PLACE_SCORE
  495. rect -130 15 190 0
  496. cvartest "g_gametype" showcvar { 3 4 9 10 }
  497. visible 1 textstyle 3
  498. textscale .2
  499.  
  500. }
  501.  
  502. }
  503.  
  504.  
  505.  
  506.  
  507.  
  508. //////// end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement