MCPcopy Create free account
hub / github.com/NetHack/NetHack / usmellmon

Function usmellmon

src/mon.c:5795–5909  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5793}
5794
5795boolean
5796usmellmon(struct permonst *mdat)
5797{
5798 int mndx;
5799 boolean nonspecific = FALSE;
5800 boolean msg_given = FALSE;
5801
5802 if (mdat) {
5803 if (!olfaction(gy.youmonst.data))
5804 return FALSE;
5805 mndx = monsndx(mdat);
5806 switch (mndx) {
5807 case PM_ROTHE:
5808 case PM_MINOTAUR:
5809 You("notice a bovine smell.");
5810 msg_given = TRUE;
5811 break;
5812 case PM_CAVE_DWELLER:
5813 case PM_BARBARIAN:
5814 case PM_NEANDERTHAL:
5815 You("smell body odor.");
5816 msg_given = TRUE;
5817 break;
5818 /*
5819 case PM_PESTILENCE:
5820 case PM_FAMINE:
5821 case PM_DEATH:
5822 break;
5823 */
5824 case PM_HORNED_DEVIL:
5825 case PM_BALROG:
5826 case PM_ASMODEUS:
5827 case PM_DISPATER:
5828 case PM_YEENOGHU:
5829 case PM_ORCUS:
5830 break;
5831 case PM_HUMAN_WEREJACKAL:
5832 case PM_HUMAN_WERERAT:
5833 case PM_HUMAN_WEREWOLF:
5834 case PM_WEREJACKAL:
5835 case PM_WERERAT:
5836 case PM_WEREWOLF:
5837 case PM_OWLBEAR:
5838 You("detect an odor reminiscent of an animal's den.");
5839 msg_given = TRUE;
5840 break;
5841 /*
5842 case PM_PURPLE_WORM:
5843 break;
5844 */
5845 case PM_STEAM_VORTEX:
5846 You("smell steam.");
5847 msg_given = TRUE;
5848 break;
5849 case PM_GREEN_SLIME:
5850 pline("%s stinks.", Something);
5851 msg_given = TRUE;
5852 break;

Callers 2

wiz_smellFunction · 0.85
newchamFunction · 0.85

Calls 3

olfactionFunction · 0.85
YouFunction · 0.85
plineFunction · 0.70

Tested by

no test coverage detected