The diet of a monster describes which types of things it will eat.
Every monster, including yourself, is restricted to eating only certain materials. Solid foods that are edible to your starting character are generally classified as comestibles, but if you polymorph into a different type of monster, you may find yourself snacking on such things as shirts or wands. Further, many types of monsters have strong innate preferences with regard to meats and vegetable matter.
You, as a monster endowed with free will, are restricted only by your physical capacity to consume. Still, your diet is determined by what you are. Most character types are omnivores, although monks are effectively herbivores, suffering an alignment penalty for eating non-vegetarian food. Being a carnivore or herbivore (or even inediate) does not restrict your ability to eat, but does make the respective food types more delicious.
You are the only monster that can open a tin of food. You can also quaff any form of liquid nourishment, provided you are capable of drinking. When polymorphed into a new type of monster, you can eat whatever that monster type can eat, in addition to the usual comestibles. Note, however, that being capable of eating something does not mean that you should eat it; eating a dead cockatrice by mistake has ended many a game, and eating your own race carries the penalties of cannibalism.
Most types of monsters eat only when tame, i.e., your pets; the exceptions are metallivores and other unique diets, which largely avoid safe comestibles. A pet encountering something it is capable of eating will decide whether to eat it according to its dietary preference and its degree of hunger, with due care to avoid harmful meals. A pet cat, for example, will eat a banana only when starving. Diet also determines which foods will tame a domestic animal and which foods a pet considers a treat. Thus it is helpful to be aware of the diets of your pets or potential pets you want to tame (that pony wants an apple, not a yucky tripe ration!), besides watching out for monsters that might go after your treasures (a rock mole ate my gold stash!).
Most pets must continually eat to stave off starvation. Besides a normal state of contentment, a pet has two degrees of hunger. Hungry is what a stethoscope and #chatting indicate. Starving means the pet "is confused from hunger" or "you feel worried about" it, and implies the pet's maximum hit points are reduced to 25%. Beyond that, it will cease to be your pet, either dying or, if on another level, becoming hostile.
|Food grade||Internal name||Effect|
|treat||DOGFOOD||A delicious treat suitable for training. Will make pets follow more closely.. Pets will "catch" it, which is purely cosmetic.|
|good||CADAVER||Will be eaten happily.|
|hungry||ACCFOOD||Will be eaten if hungry, but the pet will seek it out only if starving. (Try throwing the food at the pet.) The minimum food grade needed for taming. The worst quality food that will to suppress the message "Foo moves only reluctantly."|
|starving||MANFOOD (ACCFOOD when starving)||Will be eaten only if starving. Otherwise, the pet wants to apport the food.|
|inedible||MANFOOD, APPORT, POISON, UNDEF, TABU||Will be left untouched even while the poor creature starves to death.|
Untame domestic animals (dogs, cats, and horses, plus many others in SLASH'EM) will not eat spontaneously but will react favorably to food you throw at them (apart from eggs, melons, and cream pies that hit their target and splat 99% of the time). If the food is considered grade "hungry" or better, the animal will eat it and become tame; this is an easy way to acquire pets. Any other comestible will not be eaten but will pacify the animal and remove any fear effects.
Carnivores and herbivores evaluate food in very different ways, tabulated below. The obvious trend to bear in mind is that carnivores prefer meats and herbivores prefer vegetable matter. Omnivores generally apply the more favorable grade out of both.
|tripe ration, or meat ring/stick/ball/chunk||treat||inedible|
|safe egg (do not throw!)||good||inedible|
|safe corpse, non-vegan||good||inedible|
|safe corpse, vegan||inedible||good|
|non-vegan people food:||hungry||starving|
|other vegan comestibles:||starving||hungry|
|harmful corpse unless resistant:||inedible||inedible|
Types of diet
Carnivores are monsters that (when tamed) prefer to eat meat. Tripe and meat created with stone to flesh are considered treats. They will eat any safe corpses and eggs that they find on the ground. They will eat "people food" such as food rations, pancakes, or fortune cookies if they are hungry and vegetarian food such as fruit and melons if starving. They will not eat vegan corpses such as mold or lichens, nor will they eat tins.
Herbivores are monsters that (when tamed) prefer to eat vegetable matter such as fruit, vegetables, fungi, and other plants. Apples and carrots are considered treats. They will eat safe vegan corpses such as lichens, mold, shriekers, blobs, and jellies if they find them lying on the ground. They will also eat melons, oranges, pears, wolfsbane, garlic, kelp fronds, and so on, but only when hungry. If they are very hungry, they will eat some people food like food rations, pancakes, and lembas. They will never eat meat products, meaty corpses, eggs, or tins.
Metallivores subsist on metals, including not only metallic weapons and armor but also rings, amulets, and wands made of metal. In fact, a useful strategy is to polymorph into a metallivore to gain intrinsics by eating jewelry. They also eat tins of food, biting right through the tasty metal. Non-rustproof iron objects are considered treats. Unlike xorns and rock moles, rust monsters are restricted to the one metal that can rust, iron.
Metallivore monsters and players do not get hungry (unless they also eat meat/vegetables), but ring and amulet hunger still apply.
Lithivores (which currently only exist in Slash'EM Extended) subsist on stones, including not only rocks and gems but also pieces of glass, and any other items made of mineral, bone, gemstone or glass. In fact, a useful strategy is to polymorph into a lithivore to gain intrinsics by eating jewelry. Lithic objects are considered treats.
Lithivore monsters and players do not get hungry (unless they also eat meat/vegetables), but ring and amulet hunger still apply. However, in Slash'EM Extended version v36 and higher, both lithivores and metallivores will get hungry even if they can't eat anything else.
Several monsters have unique diets.
- b Gelatinous cubes eat wood, leather, and cloth, and engulf most everything else.
- h Mind flayers eat the brains out of living monsters.
- U Umber hulks can chew through solid rock, which gives them nutrition. They cannot, however, eat items made of rock (mineral, as it is called in-game).
- Z Ghouls eat only old corpses.
None of these monsters need to eat to stay alive.
Internally, the diet of a monster type is indicated by the flags M1_CARNIVORE and M1_HERBIVORE; both flags are set for an omnivore, and neither is set for inediates. The M1_METALLIVORE flag denotes a metallivore. Interestingly, a monster with M1_METALLIVORE but not M1_CARNIVORE or M1_HERBIVORE is considered inediate for ingame purposes.
- Source:Edog.h#line10 for definition of food grades
- Source:Dog.c#dogfood for food classification
- Dogmove.c in NetHack 3.4.3, line 170
- Dogmove.c in NetHack 3.4.3, line 427
- Dog.c in NetHack 3.4.3, line 780
- Dogmove.c, line 297 and Dogmove.c, line 675
- Dogmove.c, line 675 Dog.c, line 780, Dothrow.c, line 1382
- Dogmove.c in NetHack 3.4.3, line 297
- Dog.c in NetHack 3.4.3, line 808
- Dogmove.c in NetHack 3.4.3, line 377
- Source:Dog.c#dogfood technically reclassifies some of it as ACCFOOD when starving.
- Dogmove.c in NetHack 3.4.3, line 377
- dothrow.c, line 1383 (see also definition of befriend_with_obj at mondata.h, line 190)
- dog.c, line 756: "worst case, at least it'll be peaceful" (see also dogfood above)