Raised This Month: $ Target: $400
 0% 

admin give weapon help


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
lashsh
BANNED
Join Date: Jun 2010
Location: Georgia, Tbilisi
Old 08-10-2010 , 14:59   admin give weapon help
Reply With Quote #1

admin give weapon players cvar register sorry my bad english

PHP Code:
#include <amxmodx>
#include <cstrike>
#include <fakemeta>
#include <fun>
#include <engine>
#include <hamsandwich>

#define PLUGIN "Knife Mod + respawn"
#define VERSION "0.5"
#define AUTHOR "LaSsHhH & vL. & 5c0r-|3i0"

new plugin_on
new cvar_respawn,cvar_respawntime

// Macros
#if cellbits == 32
#define OFFSET_BZ 235
#else
#define OFFSET_BZ 268
#endif

public plugin_init()
{
register_plugin(PLUGINVERSIONAUTHOR);
plugin_on register_cvar("knife_mod""1");
RegisterHam(Ham_Spawn"player""Fwd_Ham_Spawn_Post"1); // Spawns
RegisterHam(Ham_Killed,"player","fwd_killed"
cvar_respawn register_cvar("knife_mod_respawn_on","1"
cvar_respawntime register_cvar("knife_mod_respawn_time","3.0"// Must be a float
register_clcmd("say /respawn""cmd_respawn")     

register_message(get_user_msgid("StatusIcon" ), "MsgStatusIcon" ); // BuyZone Icon

// Remove buyzone on map
remove_entity_name("info_map_parameters");
remove_entity_name("func_buyzone");

// Create own entity to block buying
new iEntity create_entity("info_map_parameters");

DispatchKeyValue(iEntity"buying""3");
DispatchSpawn(iEntity);
}

public 
cmd_respawn(id)     
{   
ExecuteHamB(Ham_CS_RoundRespawn,id)
}

public 
fwd_killed(victim,attacker

if (
get_pcvar_num(cvar_respawn)) set_task(get_pcvar_float(cvar_respawntime),"task_respawn",victim

public 
task_respawn(id

ExecuteHamB(Ham_CS_RoundRespawn,id
client_print(id,print_center,"You are respawned"


public 
Fwd_Ham_Spawn_Post(id

{
    if(
get_pcvar_num(plugin_on)) // If your cvar is on
    
{

strip_user_weapons(id);

give_item(id"weapon_knife");
}
    }


public 
MsgStatusIcon(msg_idmsg_destid)
{
new 
szIcon[8];
get_msg_arg_string(2szIcon7);

static const 
BuyZone[ ] = "buyzone";

if(
equal(szIconBuyZone))
{
set_pdata_int(idOFFSET_BZget_pdata_int(idOFFSET_BZ5) & ~(<< 0), 5)

return 
PLUGIN_HANDLED;
}

return 
PLUGIN_CONTINUE;

lashsh is offline
Send a message via Skype™ to lashsh
naven
Veteran Member
Join Date: Jun 2008
Location: Poland, Cieszyn
Old 08-10-2010 , 16:26   Re: admin give weapon help
Reply With Quote #2

You didn't actually told us, what you want to do, or I don't understand you
__________________
naven.com.pl
"At the end of the day, there are always going to be mental disorders and people who cause violence for no other reason than the fact that they're fucked up and lost. And all we can do is try to learn from it." Corey Taylor.
naven 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 21:59.


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