diff options
Diffstat (limited to 'crawl-ref/source/itemprop.cc')
-rw-r--r-- | crawl-ref/source/itemprop.cc | 24 |
1 files changed, 21 insertions, 3 deletions
diff --git a/crawl-ref/source/itemprop.cc b/crawl-ref/source/itemprop.cc index cbfb90505d..19ca2226ea 100644 --- a/crawl-ref/source/itemprop.cc +++ b/crawl-ref/source/itemprop.cc @@ -528,9 +528,7 @@ void do_uncurse_item( item_def &item ) item.flags &= (~ISFLAG_CURSED); } -// -// Is item stationary (cannot be picked up?) -// +// Is item stationary (cannot be picked up)? void set_item_stationary( item_def &item ) { if (item.base_type == OBJ_MISSILES && item.sub_type == MI_THROWING_NET) @@ -573,6 +571,26 @@ bool item_is_critical(const item_def &item) && item.plus != RUNE_ABYSSAL); } +// Is item something that no one would bother enchanting? +bool item_is_mundane(const item_def &item) +{ + bool retval = false; + + switch (item.base_type) + { + case OBJ_WEAPONS: + retval = (item.sub_type == WPN_CLUB + || item.sub_type == WPN_GIANT_CLUB + || item.sub_type == WPN_GIANT_SPIKED_CLUB + || item.sub_type == WPN_KNIFE); + break; + default: + break; + } + + return (retval); +} + void set_ident_flags( item_def &item, unsigned long flags ) { preserve_quiver_slots p; |