The items that can be eaten are hard coded on the clients side. You can simulate a diamond being eaten but thats about the best you can do.
I'm not saying this with complete confidence, only thinking logically. The "eat" animations are likely made per-food item and sent only for those items. Maybe you could spoof the animation, but you'd end up with cookie crumbs coming out of your diamond lol.
it is necessary to make diamonds be eaten? because you can always do if he right click to eat to do the stuff you want and the diamond get removed.
there's only one way after right clicking the diamonds it will lost 1 piece then add an appetite to the player.
yeah he can do like what i said if he right click to the diamond to remove the diamond from his hand and then set the hunger or right click it and do a runnable to make the item disappear after 3 sec for example set the hunger but im not sure if he can to add effect like an eating one when he right click it and do the sound of eating.
Unless mojang do, I simply agree that's nearly impossible to have an effect with eathing something that isn't edible.
Yah, thats what I did, I took the item, played an eat sound, and displayed a block break effect in their head.
haha cool well i would do the same thing if i was you because we can't set other items to work as food.