AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Approved Plugins (https://forums.alliedmods.net/forumdisplay.php?f=8)
-   -   Show The Kill (https://forums.alliedmods.net/showthread.php?t=91607)

{PHILMAGROIN} 05-03-2009 04:11

Show The Kill
 
3 Attachment(s)
Show The Kill

Description:
This plugin shows in the bottom right hand corner just above your money when you kill someone. It simply says "KILL." Or above the crosshair. There is also a cvar for it to say HEADSHOT when you get a headshot.

Reason:
The reason for this plugin is becuase whenever i play cs and im playing lets say deathmatch, while I am shooting at someone(usually when they are far away) i shoot until i see out of the corner of my eye the +300. When you have $16000 dollars and you get a kill the +300 doesnt show up so I usually keep shooting. This is just a simple plugin that lets you know you killed someone.

Cvars:
stk_on (1/0) default: 1 turns plugin on/off
stk_cross (1/0) defualt: 1 puts the KILL over the crosshair
stk_headshot (1/0) defualt: 1 says HEADSHOT when you get a headshot!
stk_screenfade (1/0) defualt: 1 the screen fades red when you kill someone.
stk_red (0-255) default: 255 changes the color of the screenfade and the HEADSHOT or KILL.
stk_green (0-255) default: 0
changes the color of the screenfade and the HEADSHOT or KILL.
stk_blue (0-255) default: 0 changes the color of the screenfade and the HEADSHOT or KILL.


Screen Shot:
http://i199.photobucket.com/albums/a...440/Kill-1.jpg

sidenote:
If you dont already have the screenfade_util you will need to download it as well and put it in your addons/amxmodx/scripting/include folder.

Thanks to:
xPaw
Exolent
Bugsy- especially for my badly named cvars etc. haha
ConnorMcLeod- for the screenfade_util

updates:
1.1
New cvar: stk_cross 1/0 defualt 0 = puts the KILL over the crosshair
1.2
Optimized code a bunch. new cvar: stk_headshot 1/0 defualt 1
1.3
more optimization and when you kill yourself it no longer displays KILL. thanks bugsy.
1.4
added screenfade when you kill someone
1.5
added a color changing cvar for the rgb colors of the screenfade and the KILL/HEADSHOT

crazyeffect 05-03-2009 04:25

Re: Show The Kill
 
Ohh, i know that from other games

xPaw 05-03-2009 04:38

Re: Show The Kill
 
Use pcvar
You need branches after if( Killer )

PHP Code:

#include <amxmodx>

#define PLUGIN "Show the Kill"
#define VERSION "1.0"
#define AUTHOR "{PHILMAGROIN}"

new gCvar_Enabled;

public 
plugin_init() {
    
register_pluginPLUGINVERSIONAUTHOR );
    
gCvar_Enabled register_cvar"stk_on""1" );
    
register_event"DeathMsg""find_it""a" );
}

public 
find_itid ) {
    if( 
get_pcvar_numgCvar_Enabled ) ) {
        if( 
read_data) ) {
            
set_hudmessage255000.940.8301.03.00.010.01, -);
            
show_hudmessageid"KILL" );
        }
    }



{PHILMAGROIN} 05-03-2009 04:42

Re: Show The Kill
 
Quote:

Originally Posted by xPaw (Post 819981)
Use pcvar
You need branches after if( Killer )

PHP Code:

#include <amxmodx>

#define PLUGIN "Show the Kill"
#define VERSION "1.0"
#define AUTHOR "{PHILMAGROIN}"

new gCvar_Enabled;

public 
plugin_init() {
    
register_pluginPLUGINVERSIONAUTHOR );
    
gCvar_Enabled register_cvar"stk_on""1" );
    
register_event"DeathMsg""find_it""a" );
}

public 
find_itid ) {
    if( 
get_pcvar_numgCvar_Enabled ) ) {
        if( 
read_data) ) {
            
set_hudmessage255000.940.8301.03.00.010.01, -);
            
show_hudmessageid"KILL" );
        }
    }



changed!

KadiR 05-03-2009 06:47

Re: Show The Kill
 
isnt it better, if you use DEAD instead of KILL ?

btw n1 plugin.. :)

what about Multilingual?

{PHILMAGROIN} 05-03-2009 10:53

Re: Show The Kill
 
Quote:

Originally Posted by KadiR (Post 820035)
isnt it better, if you use DEAD instead of KILL ?

btw n1 plugin.. :)

what about Multilingual?

I thought about it. but then i figured its just one word, i dont think it is necessary. but if people want it ill do it.

KadiR 05-03-2009 12:59

Re: Show The Kill
 
Quote:

Originally Posted by KadiR (Post 820035)
isnt it better, if you use DEAD instead of KILL?


{PHILMAGROIN} 05-03-2009 13:03

Re: Show The Kill
 
eh. I dont think it really matters. at first I had it just +1 but you can see KILL better. and the name sounds better =]

TitANious 05-03-2009 13:30

Re: Show The Kill
 
Use pcvar?
PHP Code:

#include <amxmodx>

#define PLUGIN "Show the Kill"
#define VERSION "1.0"
#define AUTHOR "{PHILMAGROIN}"

new gCvar_Enabled;
new 
gCvar_deathmessage;

public 
plugin_init() {
    
register_pluginPLUGINVERSIONAUTHOR );
    
gCvar_Enabled register_cvar"stk_on""1" );
    new 
gCvar_deathmessage register_cvar ("Deathmsg_msg""KILL")
    
register_event"DeathMsg""find_it""a" );
}

public 
find_itid ) {
    if( 
get_pcvar_numgCvar_Enabled ) ) {
        if( 
read_data) ) {
            
set_hudmessage255000.940.8301.03.00.010.01, -);
            
show_hudmessageid"get_pcvar_num(gCvar_deathmessage)" );
        }
    }


I hope it work :)

{PHILMAGROIN} 05-03-2009 13:32

Re: Show The Kill
 
Quote:

Originally Posted by TitANious (Post 820250)
Use pcvar?
PHP Code:

#include <amxmodx>

#define PLUGIN "Show the Kill"
#define VERSION "1.0"
#define AUTHOR "{PHILMAGROIN}"

new gCvar_Enabled;
new 
gCvar_deathmessage;

public 
plugin_init() {
    
register_pluginPLUGINVERSIONAUTHOR );
    
gCvar_Enabled register_cvar"stk_on""1" );
    new 
gCvar_deathmessage register_cvar ("Deathmsg_msg""KILL")
    
register_event"DeathMsg""find_it""a" );
}

public 
find_itid ) {
    if( 
get_pcvar_numgCvar_Enabled ) ) {
        if( 
read_data) ) {
            
set_hudmessage255000.940.8301.03.00.010.01, -);
            
show_hudmessageid"get_pcvar_num(gCvar_deathmessage)" );
        }
    }


I hope it work :)

already did thanks to xPaw. Why would you have two with such a simple plugin? all i need is a simple on/off cvar.


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

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