P1xeL

Round Sound v1.0 By P1xeL`

Oct 26th, 2012
224
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 0.98 KB | None | 0 0
  1. #include <amxmodx>
  2.  
  3. new const CounterTerroristSounds[][] = {
  4.     "sound/CounterTerrorist_1.mp3",
  5.     "sound/CounterTerrorist_2.mp3",
  6.     "sound/CounterTerrorist_3.mp3"
  7. };
  8.  
  9. new const TerroristSounds[][] = {
  10.     "sound/Terrorist_1.mp3",
  11.     "sound/Terrorist_2.mp3",
  12.     "sound/Terrorist_3.mp3"
  13. };
  14.  
  15. public plugin_init() {
  16.     register_plugin("Round Sound","v1.0","P1xeL`");
  17.    
  18.     register_event("SendAudio", "CounterTerroristWin", "a", "2&%!MRAD_ctwin");
  19.     register_event("SendAudio", "TerroristWin", "a", "2&%!MRAD_terwin");
  20. }
  21.  
  22. public plugin_precache() {
  23.     for(new i = 0; i < sizeof CounterTerroristSounds; i++)
  24.         precache_generic(CounterTerroristSounds[i]);
  25.    
  26.     for(new j = 0; j < sizeof TerroristSounds; j++)
  27.         precache_generic(TerroristSounds[j]);
  28. }
  29.  
  30. public TerroristWin()
  31.     client_cmd(0, "mp3 play %s", TerroristSounds[random_num(0, charsmax(TerroristSounds))]);
  32.  
  33. public CounterTerroristWin()
  34.     client_cmd(0, "mp3 play %s", CounterTerroristSounds[random_num(0, charsmax(CounterTerroristSounds))]);
Advertisement
Add Comment
Please, Sign In to add comment