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

Function setmnotwielded

src/weapon.c:1813–1828  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1811}
1812
1813void
1814setmnotwielded(struct monst *mon, struct obj *obj)
1815{
1816 if (!obj)
1817 return;
1818 if (artifact_light(obj) && obj->lamplit) {
1819 end_burn(obj, FALSE);
1820 if (canseemon(mon))
1821 pline("%s in %s %s %s shining.", The(xname(obj)),
1822 s_suffix(mon_nam(mon)), mbodypart(mon, HAND),
1823 otense(obj, "stop"));
1824 }
1825 if (MON_WEP(mon) == obj)
1826 MON_NOWEP(mon);
1827 obj->owornmask &= ~W_WEP;
1828}
1829
1830#undef PN_BARE_HANDED
1831#undef PN_RIDING

Callers 8

hmon_hitmon_weapon_meleeFunction · 0.85
possibly_unwieldFunction · 0.85
mon_wield_itemFunction · 0.85
mwepgoneFunction · 0.85
rot_corpseFunction · 0.85
shrinking_glob_goneFunction · 0.85
mthrowu.cFile · 0.85
use_whipFunction · 0.85

Calls 10

artifact_lightFunction · 0.85
end_burnFunction · 0.85
canseemonFunction · 0.85
TheFunction · 0.85
xnameFunction · 0.85
s_suffixFunction · 0.85
mon_namFunction · 0.85
mbodypartFunction · 0.85
otenseFunction · 0.85
plineFunction · 0.70

Tested by

no test coverage detected