Well technically, you can code Get Item Num but it will take you a few blocks, what you do is you repeat thru the player's inventory, check if the item material is equals to the one you want, if it is, get item amount and add it to a counter; but you might need to do this for these game values...