Well... I have a menu that will get the players alive, team, and skip bots. the team = terrorists. It will give health to terrorists to who ever you select.
Code:
public HMenu(id) {
new menu = menu_create ( "\rWee", "menu_handler_2" );
new players[32], pnum, tempid;
new szName[32], szTempid[10];
get_players( players, pnum, "ceh", "TERRORIST" );
for( new i; i<pnum; i++ )
{
tempid = players[i];
get_user_name( tempid, szName, charsmax( szName ) );
num_to_str( tempid, szTempid, charsmax( szTempid ) );
menu_additem( menu, szName, szTempid, 0 );
}
menu_display( id, menu, 0 );
}
public menu_handler_2(id, menu, item) {
if( item == MENU_EXIT )
{
menu_destroy( menu );
return PLUGIN_HANDLED;
}
new data[6], szName[64];
new access, callback;
menu_item_getinfo( menu, item, access, data,charsmax( data ), szName,charsmax( szName ), callback );
new tempid = str_to_num( data );
if ( is_user_alive ( tempid ) ) {
set_user_health( tempid, 1000 )
}
menu_destroy( menu );
return PLUGIN_HANDLED;
}
__________________