HLMOD.HU Forrás Megtekintés - www.hlmod.hu
  1. /*
  2. [ZP] Addon : Biohazard Icon
  3. As requested by kenwelo at this thread.
  4.  
  5.  
  6. .: Description :.
  7. This plugin will display a biohazard icon at the left of your screen when a new round starts. The colour will differ by round type. The colours are :
  8.  
  9. Normal Round : GREEN
  10. Multiple Infection Round : GREEN
  11. Nemesis Round : RED
  12. Survivor Round : BLUE
  13. Swarm Round : YELLOW
  14. Plague Round : RED (Flashing red and blue in the future if possible)
  15.  
  16. .: CVARS :.
  17. None currently. I dont see the need for any currently.
  18.  
  19. .: Change Log :.
  20. Version 1.0 (02 September 2009)
  21. First Release
  22.  
  23. .: To-Do List :.
  24. Change colour of icon Plague Round to flash red and blue. (Need Ideas)
  25. Change colour of icon Multiple Infection Round. (Optional)
  26.  
  27. .: Screenshots :.
  28. To be added soon...
  29. */
  30.  
  31. #include <amxmodx>
  32. #include <fakemeta>
  33. #include <zombieplague>
  34.  
  35. #define PLUGIN "Biohazard Icon"
  36. #define VERSION "1.0"
  37. #define AUTHOR "Zombie Lurker"
  38.  
  39. new iconstatus
  40.  
  41. public plugin_init() {
  42. register_plugin(PLUGIN, VERSION, AUTHOR)
  43.  
  44. register_forward(FM_PlayerPreThink,"fw_prethink");
  45. iconstatus = get_user_msgid("StatusIcon")
  46. }
  47.  
  48. public fw_prethink(id) {
  49. if (zp_is_nemesis_round() & 1) {
  50. message_begin(MSG_ONE,iconstatus,{0,0,0},id);
  51. write_byte(1); // status (0=hide, 1=show, 2=flash)
  52. write_string("dmg_bio"); // sprite name
  53. write_byte(255); // red
  54. write_byte(0); // green
  55. write_byte(0); // blue
  56. message_end();
  57. } else if (zp_is_survivor_round() & 1) {
  58. message_begin(MSG_ONE,iconstatus,{0,0,0},id);
  59. write_byte(1); // status (0=hide, 1=show, 2=flash)
  60. write_string("dmg_bio"); // sprite name
  61. write_byte(0); // red
  62. write_byte(0); // green
  63. write_byte(255); // blue
  64. message_end();
  65. } else if (zp_is_swarm_round() & 1) {
  66. message_begin(MSG_ONE,iconstatus,{0,0,0},id);
  67. write_byte(1); // status (0=hide, 1=show, 2=flash)
  68. write_string("dmg_bio"); // sprite name
  69. write_byte(255); // red
  70. write_byte(255); // green
  71. write_byte(0); // blue
  72. message_end();
  73. }else if (zp_is_plague_round() & 1) {
  74. message_begin(MSG_ONE,iconstatus,{0,0,0},id);
  75. write_byte(1); // status (0=hide, 1=show, 2=flash)
  76. write_string("dmg_bio"); // sprite name
  77. write_byte(255); // red
  78. write_byte(0); // green
  79. write_byte(0); // blue
  80. message_end();
  81. } else if (zp_has_round_started() & 1) {
  82. message_begin(MSG_ONE,iconstatus,{0,0,0},id);
  83. write_byte(1); // status (0=hide, 1=show, 2=flash)
  84. write_string("dmg_bio"); // sprite name
  85. write_byte(0); // red
  86. write_byte(255); // green
  87. write_byte(0); // blue
  88. message_end();
  89. }
  90. }
  91. /* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
  92. *{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1045\\ f0\\ fs16 \n\\ par }
  93. */
  94.