Fix polymorphing into a large monster while wearing unusual cloaks

Most cloaks have a clasp, but some don't, so they need different
messages (and occasionally different behaviour).
This commit is contained in:
Alex Smith
2026-04-14 17:42:03 +01:00
parent 89473216ae
commit a5be241bd4

View File

@@ -1176,9 +1176,20 @@ break_armor(void)
if ((otmp = uarmc) != 0
/* mummy wrapping adapts to small and very big sizes */
&& (otmp->otyp != MUMMY_WRAPPING || !WrappingAllowed(uptr))) {
pline_The("clasp on your %s breaks open!", cloak_simple_name(otmp));
(void) Cloak_off();
dropp(otmp);
if (otmp->otyp == MUMMY_WRAPPING) {
/* doesn't have a clasp to break open */
Your("%s tears apart!", cloak_simple_name(otmp));
(void) Cloak_off();
useup(otmp);
} else if (otmp->otyp == ALCHEMY_SMOCK) {
pline_The("knot on your %s is pulled apart!", cloak_simple_name(otmp));
(void) Cloak_off();
dropp(otmp);
} else {
pline_The("clasp on your %s breaks open!", cloak_simple_name(otmp));
(void) Cloak_off();
dropp(otmp);
}
}
if (uarmu) {
Your("shirt rips to shreds!");