
   /* AMX Mod script.
   *
   * (c) Copyright 2002-2003, KkkkkkTzs
   * This file is provided as is (no warranties).
   *
   */
   #include <amxmod>
   new soundsendCT = 1 // mark that we have send the sound
   new soundsendT = 1  // mark that we have send the sound
   public death_msg(id){
       new players_ct[32], players_t[32], ict, ite, name[32]
       get_players(players_ct,ict,"ae","CT")
       get_players(players_t,ite,"ae","TERRORIST")
       new victim = read_data(2)
       new victim_team = get_user_team(victim,"",0)
       if (victim_team == 1 && ite > 0)
           soundsendT = 0  // mark that we have not send the sound
       else if ((victim_team == 2 || victim_team == 4) && ict > 0)
           soundsendCT = 0 // mark that we have not send the sound

       if (ict==1&&ite==1){
           get_user_name(players_ct[0],name,32)
           set_hudmessage(50,255,0,-1.0,0.30,0, 6.0, 8.0, 1.0, 2.0, 1)
           show_hudmessage(players_t[0],"You and %s left!",name)
           get_user_name(players_t[0],name,32)
           set_hudmessage(50,255,0,-1.0,0.30,0, 6.0, 8.0, 1.0, 2.0, 1)
           show_hudmessage(players_ct[0],"You and %s left!",name)
           if (!soundsendT) {
               client_cmd(players_t[0],"spk  ^"vox/_period  _period  your
   the last man^"")
               soundsendT  =  1  // mark that we have send the sound (for
   1on1)
           }
           if (!soundsendCT) {
               client_cmd(players_ct[0],"spk  ^"vox/_period  _period your
   the last man^"")
               soundsendCT  =  1 // mark that we have send the sound (for
   1on1)
           }
       }
       else if (ict==1) {
           if    (!soundsendCT && ite>=1){
               set_hudmessage(50,255,0,-1.0,0.30,0,  6.0,  8.0, 1.0, 2.0,
   1)
               show_hudmessage(players_ct[0],"Only    you    against   %i
   Terrorists!",ite)
               client_cmd(players_ct[0],"spk  ^"vox/_period  _period your
   the last man^"")
               soundsendCT = ite // mark that we have send the sound (for
   1on>1)
           }
           if (ite==0&&soundsendCT>=2) {
               set_hudmessage(50,255,0,-1.0,0.30,0,  6.0,  8.0, 1.0, 2.0,
   1)
               show_hudmessage(players_ct[0],"You    killed    last    %i
   alone!",soundsendCT)
               client_cmd(players_ct[0],"spk    ^"barney/_comma    _comma
   _comma _comma _comma _comma donthurtem^"")
           }
       }
       else if (ite==1) {
           if (!soundsendT && ict>=1) {
               set_hudmessage(50,255,0,-1.0,0.30,0,  6.0,  8.0, 1.0, 2.0,
   1)
               show_hudmessage(players_t[0],"Only    you    against    %i
   CT!",ict)
               client_cmd(players_t[0],"spk  ^"vox/_period  _period  your
   the last man^"")
               soundsendT  = ict // mark that we have send the sound (for
   1on>1)
           }
           if (ict==0&&soundsendT>=2) {
               set_hudmessage(50,255,0,-1.0,0.30,0,  6.0,  8.0, 1.0, 2.0,
   1)
               show_hudmessage(players_t[0],"You     killed    last    %i
   alone!",soundsendT)
               client_cmd(players_t[0],"spk ^"barney/_comma _comma _comma
   _comma _comma _comma donthurtem^"")
           }
       }
       return PLUGIN_CONTINUE
   }
   public plugin_init(){
       register_plugin("Last Man 2","0.9","KkkkkkTzs")
       register_event("DeathMsg","death_msg","a")
       register_cvar("amx_tzs_lastman","v2.02",FCVAR_SERVER )
       return PLUGIN_CONTINUE
   }
