fix issue #949 - dropping welded iron ball
If punished and the attached iron ball was both cursed and wielded, falling while going down stairs would drop it instead of leaving it welded to hero's hand. ( Didn't happen for iron ball that wasn't chained to hero's leg.) I thought that this was going to be a one or two line fix but ball and chain stuff is never that simple. Fixes #949
This commit is contained in:
10
src/wield.c
10
src/wield.c
@@ -1030,11 +1030,15 @@ void
|
||||
weldmsg(struct obj *obj)
|
||||
{
|
||||
long savewornmask;
|
||||
const char *hand = body_part(HAND);
|
||||
|
||||
if (bimanual(obj))
|
||||
hand = makeplural(hand);
|
||||
savewornmask = obj->owornmask;
|
||||
pline("%s welded to your %s!", Yobjnam2(obj, "are"),
|
||||
bimanual(obj) ? (const char *) makeplural(body_part(HAND))
|
||||
: body_part(HAND));
|
||||
obj->owornmask = 0L; /* suppress doname()'s "(weapon in hand)";
|
||||
* Yobjnam2() doesn't actually need this because
|
||||
* it is based on xname() rather than doname() */
|
||||
pline("%s welded to your %s!", Yobjnam2(obj, "are"), hand);
|
||||
obj->owornmask = savewornmask;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user