From: Pasi Kallinen Date: Thu, 24 Dec 2020 20:37:58 +0000 (+0200) Subject: Prevent monsters from picking up locked containers X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=a4184c86843d90f57a63e1e7e713e769b454824d;p=nethack Prevent monsters from picking up locked containers --- diff --git a/src/muse.c b/src/muse.c index e30bee61e..a9fadee8b 100644 --- a/src/muse.c +++ b/src/muse.c @@ -2407,7 +2407,8 @@ struct obj *obj; && mon->data != &mons[PM_KI_RIN]); if (typ == FROST_HORN || typ == FIRE_HORN) return (obj->spe > 0 && can_blow(mon)); - if (Is_container(obj) && !(Is_mbag(obj) && obj->cursed)) + if (Is_container(obj) && !(Is_mbag(obj) && obj->cursed) + && !obj->olocked) return TRUE; break; case FOOD_CLASS: