No, you can't put a function header inside another. You would do it like this:
Code:
#include <amxmodx>
#include <hamsandwich>
new bool: g_bCanPickup[ 33 ];
new g_iMaxPlayers;
public plugin_init()
{
RegisterHam( Ham_Touch, "weaponbox", "ham_TouchWeapon" );
RegisterHam( Ham_Touch, "armoury_entity", "ham_TouchWeapon" );
RegisterHam( Ham_Touch, "weapon_shield", "ham_TouchWeapon" );
register_event( "HLTV", "Event_RoundStart", "a", "1=0", "2=0" );
register_clcmd( "say /giveme", "cmd_GiveWeapon" );
g_iMaxPlayers = get_maxplayers();
}
public Event_RoundStart()
{
for( new i = 1 ; i <= g_iMaxPlayers ; i ++ )
g_bCanPickup[ i ] = true;
}
public ham_TouchWeapon( iEnt, id )
{
if( !g_bCanPickup[ id ] )
return HAM_SUPERCEDE;
return HAM_IGNORED;
}
public cmd_GiveWeapon( id )
{
g_bCanPickup[ id ] = false;
/* do stuff here */
}
__________________