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

Function weldmsg

src/wield.c:1060–1074  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1058}
1059
1060void
1061weldmsg(struct obj *obj)
1062{
1063 long savewornmask;
1064 const char *hand = body_part(HAND);
1065
1066 if (bimanual(obj))
1067 hand = makeplural(hand);
1068 savewornmask = obj->owornmask;
1069 obj->owornmask = 0L; /* suppress doname()'s "(weapon in hand)";
1070 * Yobjnam2() doesn't actually need this because
1071 * it is based on xname() rather than doname() */
1072 pline("%s welded to your %s!", Yobjnam2(obj, "are"), hand);
1073 obj->owornmask = savewornmask;
1074}
1075
1076/* test whether monster's wielded weapon is stuck to hand/paw/whatever */
1077boolean

Callers 6

dowieldFunction · 0.85
doswapweaponFunction · 0.85
doquiver_coreFunction · 0.85
dropFunction · 0.85
throw_objFunction · 0.85
in_containerFunction · 0.85

Calls 4

body_partFunction · 0.85
makepluralFunction · 0.85
Yobjnam2Function · 0.85
plineFunction · 0.70

Tested by

no test coverage detected