Raised This Month: $ Target: $400
 0% 

Gives to everyone


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
edga85
BANNED
Join Date: Jan 2009
Old 10-14-2009 , 13:56   Gives to everyone
Reply With Quote #1

Why it gives ammo packs to everyone if have to give only admins with ADMIN_LEVEL_H when human kills zombie?
Code:
#include <amxmodx>
#include <amxmisc>
#include <cstrike>
#include <fun>
#include <zombieplague>
 
new g_kill_ammo
new attacker
 
public plugin_init(){
register_plugin("Give Ammo Packs", "1.0", "aaarnas")
g_kill_ammo = register_cvar("zpvip_kill_ammo", "2")
 
register_event("DeathMsg","death_msg","a")
}
 
public death_msg(){ 
if(get_user_flags ( attacker ) & ADMIN_LEVEL_H ) 
{ 
new attacker = read_data(1)
zp_set_user_ammo_packs(attacker, zp_get_user_ammo_packs(attacker) + get_pcvar_num(g_kill_ammo)); 
} 
}
edga85 is offline
Send a message via Skype™ to edga85
 


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 22:39.


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