Raised This Month: $ Target: $400
 0% 

Slaughter Reward


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Debesėlis
Senior Member
Join Date: Aug 2008
Location: Lithuania
Old 08-06-2009 , 06:10   Slaughter Reward
Reply With Quote #1

Why don't give reward?????

PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <cstrike>

#define PLUGIN "Slaughter Reward"
#define VERSION "1.0"
#define AUTHOR "BOYSplayCS"

#define Killed ADMIN_LEVEL_H

new Reward


public plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)
    
    
register_event("DeathMsg""Event_Death""a""1 > 0")
    
    
Reward register_cvar("amx_kill_reward""300")
}

public 
Event_Death()
{
    new 
Killer read_data(1)
    new 
Victim read_data(2)

    if((
Killer == Victim) || !(get_user_flags(Victim) & Killed) || (get_user_team(Victim) == get_user_team(Killer)))
        return 
PLUGIN_CONTINUE

    
new CheckWeapon[6];
    
read_data(4CheckWeapon5);

    if(
equal(CheckWeapon"knife"))
    {
        new 
KillReward get_pcvar_num(Reward)

        
cs_set_user_money(Killerclamp(cs_get_user_money(Killer) + KillReward016000))
        
client_print(Killerprint_chat"[AMXX] You have slaughtered an player! You have been awarded an extra %s dollars!"KillReward)
    }
    return 
PLUGIN_HANDLED


Last edited by Debesėlis; 08-06-2009 at 08:05.
Debesėlis is offline
 


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 18:16.


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