allow big humanoids to wear mummy wrappings

A giant mummy starts out with a mummy wrapping but couldn't wear it.
Allow humanoids who are bigger than human size (including poly'd hero
when applicable) to wear such cloaks.  They won't do so if they are
invisible and the cloak would let hero start seeing them.
This commit is contained in:
PatR
2022-10-22 17:14:22 -07:00
parent f1e2c393f2
commit 84fabf764a
5 changed files with 72 additions and 38 deletions

View File

@@ -411,6 +411,12 @@ struct obj {
#define is_art(o,art) ((o) && (o)->oartifact == (art))
#define u_wield_art(art) is_art(uwep, art)
/* mummy wrappings are more versatile sizewise than other cloaks */
#define WrappingAllowed(mptr) \
(humanoid(mptr) && (mptr)->msize >= MZ_SMALL && (mptr)->msize <= MZ_HUGE \
&& !noncorporeal(mptr) && (mptr)->mlet != S_CENTAUR \
&& (mptr) != &mons[PM_WINGED_GARGOYLE] && (mptr) != &mons[PM_MARILITH])
/* Flags for get_obj_location(). */
#define CONTAINED_TOO 0x1
#define BURIED_TOO 0x2