Raised This Month: $ Target: $400
 0% 

[HELP] Kick the attacker when he kills the CT


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Excalibur.007
Veteran Member
Join Date: Sep 2009
Location: Singapore
Old 12-27-2009 , 22:14   [HELP] Kick the attacker when he kills the CT
Reply With Quote #1

How can I AUTOMATICALLY kick the T(Attacker) when the CT dies(Victim)?
Excalibur.007 is offline
Doc-Holiday
AlliedModders Donor
Join Date: Jul 2007
Old 12-27-2009 , 23:26   Re: [HELP] Kick the attacker when he kills the CT
Reply With Quote #2

Quote:
Originally Posted by Excalibur.007 View Post
How can I AUTOMATICALLY kick the T(Attacker) when the CT dies(Victim)?
register ham_killed
PHP Code:
if(get_user_team(attacker) == && get_user_team(victim) == 2)
{
         
KICK!!!!

Doc-Holiday is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 12-28-2009 , 00:22   Re: [HELP] Kick the attacker when he kills the CT
Reply With Quote #3

Quote:
Originally Posted by Excalibur.007 View Post
How can I AUTOMATICALLY kick the T(Attacker) when the CT dies(Victim)?
This begs for an empty server.
__________________
fysiks is offline
Merc3y
Member
Join Date: Dec 2009
Old 12-28-2009 , 01:54   Re: [HELP] Kick the attacker when he kills the CT
Reply With Quote #4

Quote:
Originally Posted by fysiks View Post
This begs for an empty server.
Maybe he trying to make it for his catcher server. If i'm not wrong.
__________________
How I Wish That I Can Host Without Any Problem.
Merc3y is offline
Excalibur.007
Veteran Member
Join Date: Sep 2009
Location: Singapore
Old 12-28-2009 , 02:06   Re: [HELP] Kick the attacker when he kills the CT
Reply With Quote #5

Yeah Merc3y is right. I tried to use DeathMsg event but it doesn't kick the user.
Excalibur.007 is offline
Merc3y
Member
Join Date: Dec 2009
Old 12-28-2009 , 08:56   Re: [HELP] Kick the attacker when he kills the CT
Reply With Quote #6

Quote:
Originally Posted by Excalibur.007 View Post
Yeah Merc3y is right. I tried to use DeathMsg event but it doesn't kick the user.
Show your currently code.
__________________
How I Wish That I Can Host Without Any Problem.
Merc3y is offline
superang
Senior Member
Join Date: Apr 2009
Location: Portugal
Old 12-28-2009 , 18:07   Re: [HELP] Kick the attacker when he kills the CT
Reply With Quote #7

don't use kick, but slay its more "cool"
__________________
superang is offline
Send a message via MSN to superang
Doc-Holiday
AlliedModders Donor
Join Date: Jul 2007
Old 12-28-2009 , 18:27   Re: [HELP] Kick the attacker when he kills the CT
Reply With Quote #8

Quote:
Originally Posted by superang View Post
don't use kick, but slay its more "cool"
PHP Code:
#include <amxmodx>
#include <amxmisc>

#define IsPlayer(%1) (1 <= %1 <= g_iMaxPlayers)

new g_iMaxPlayers;

public 
plugin_init()
{
    
register_plugin("Attacker""1.0""=(GrG)=");
    
RegisterHam(Ham_Killed"player""PlayerDeath");
    
g_iMaxPlayers get_maxplayers();
}

public 
PlayerDeath(victimattacker)
{
    if(
IsPlayer(attacker))
    {
        if(
get_user_team(victim) != get_user_team(attacker))
        {
            
server_cmd("kick #%d ^"Reason Goes Here^"",get_user_userid(id))
        }
    }

Doc-Holiday is offline
Excalibur.007
Veteran Member
Join Date: Sep 2009
Location: Singapore
Old 12-28-2009 , 18:47   Re: [HELP] Kick the attacker when he kills the CT
Reply With Quote #9

Quote:
Originally Posted by superang View Post
don't use kick, but slay its more "cool"
Slaying isn't very good, since when you kill the CT he dies and you get slayed but you still get to play for next round.
Excalibur.007 is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 12-28-2009 , 19:07   Re: [HELP] Kick the attacker when he kills the CT
Reply With Quote #10

Quote:
Originally Posted by fysiks View Post
This begs for an empty server.
__________________
fysiks is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 04:04.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode