oh u got that from a tutorial , actually the menu guy gave it to me

, ok as you can see there are 4 lines in the menu , and they are :
1.Choose your primary weapon
2.ak47
3.M4a1
4.AWP
But on this line :
new keys = MENU_KEY_0|MENU_KEY_1|MENU_KEY_2|
there are 3 keys , so add one in the end and it should be like this :
PHP Code:
public event_spawn (id)
{
new menu[192]
new keys = MENU_KEY_0|MENU_KEY_1|MENU_KEY_2|MENU_KEY_3|
format(menu, 191, "Choose your primary weapon^n^n1. AK47^n2. M4A1^n3. AWP")
show_menu (id, keys, menu)
PLUGIN_HANDLED
}
public giveWeapon (id, key)
{
if (key == 0)
{
give_item (id, "weapon_ak47")
}
if (key == 1) {
give_item (id, "weapon_m4a1")
}
if (key == 2) {
give_item (id, "weapon_awp")
}
}