PHP Code:
#include <amxmodx>
#include <cstrike>
#define VERSION "0.0.1"
public plugin_init()
{
register_plugin("Hook Buy SmokeGrenade", VERSION, "Author")
register_menucmd(register_menuid("T_BuyItem", 1), (1<<4), "BuySmokeGrenade")
}
public BuySmokeGrenade( id )
{
// attempt to buy a smoke grenade
}
public client_command(id)
{
static szCommand[7] // sgren
if( read_argv(0, szCommand, charsmax(szCommand)) == 5 && equal(szCommand, "sgren") )
{
// attempt to buy a smoke grenade
}
}
public CS_InternalCommand(id, const szCommand[])
{
if( equal(szCommand, "sgren") )
{
// attempt to buy a smoke grenade
}
}
__________________