Raised This Month: $51 Target: $400
 12% 

Antidote Gun for Flag F (ADMIN_MAP) ONLY please


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Godofwar
AlliedModders Donor
Join Date: Dec 2015
Location: Germany
Old 02-24-2018 , 11:13   Antidote Gun for Flag F (ADMIN_MAP) ONLY please
Reply With Quote #1

Hello, can anyone make that for this here only:

#define ADMIN_MAP (1<<5) /* flag "f" */

That would be great


Code:
#include <amxmodx>
#include <fakemeta>
#include <zombieplague>
#include <fakemeta_util>

#define PA_LOW 25.0
#define PA_HIGH 50.0

new g_antidotegun;
new g_hasantidotegun[33];

new PCVAR_STATUS;

new const CVAR_STATUS[] = "zp_antidotegun_on";

public plugin_init()
{
register_plugin("[ZP] AntiDote Gun", "1.0", "=)");
register_event("Damage", "event_Damage", "b", "2>0");
register_event("HLTV","event_new_round", "a","1=0", "2=0");
PCVAR_STATUS = register_cvar(CVAR_STATUS, "1");
g_antidotegun = zp_register_extra_item("AntiDote Gun" ,15 , ZP_TEAM_HUMAN);
}
public zp_extra_item_selected(player, itemid)
{
if ( itemid == g_antidotegun )
{
g_hasantidotegun[player] = 1
fm_give_item(player, "weapon_scout")
}
}
public event_Damage(id)
{
if(get_pcvar_num(PCVAR_STATUS) <= 0 || !is_user_alive(id) || is_user_bot(id))
return PLUGIN_CONTINUE;

new iWeapID, attacker = get_user_attacker(id, iWeapID);

if(!is_user_connected(attacker))
return PLUGIN_CONTINUE;

if(!is_user_connected(id))
return PLUGIN_CONTINUE;


if(!g_hasantidotegun[attacker])
return PLUGIN_CONTINUE;


if(iWeapID == CSW_SCOUT)
{
zp_disinfect_user(id)
}

return PLUGIN_CONTINUE;
}

public event_new_round() {
for(new i = 0; i < 32; i++)
{
g_hasantidotegun[i] = 0
}


}
Godofwar is offline
Reply



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 05:47.


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