public OnPlayerKeyStateChange(playerid, newkeys, oldkeys){ new weaponid = GetPlayerWeapon(playerid); if(newkeys & KEY_FIRE && weaponid == 16)//16 for grenade { // your codes } return 1;}