summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/describe.cc
diff options
context:
space:
mode:
authorAdam Borowski <kilobyte@angband.pl>2009-12-15 15:48:37 +0100
committerAdam Borowski <kilobyte@angband.pl>2009-12-15 15:49:46 +0100
commit7fa010c5fe03aee772cdfbc2b6e42fc1b492b57d (patch)
tree8e6a3740176c9b118b2dcd3ff980168eedfbdf94 /crawl-ref/source/describe.cc
parenta80d16e06af7ae4c5088bd8f1985dbe6b0fc76c9 (diff)
downloadcrawl-ref-7fa010c5fe03aee772cdfbc2b6e42fc1b492b57d.tar.gz
crawl-ref-7fa010c5fe03aee772cdfbc2b6e42fc1b492b57d.zip
Autoinscribe armour brands.
Diffstat (limited to 'crawl-ref/source/describe.cc')
-rw-r--r--crawl-ref/source/describe.cc9
1 files changed, 6 insertions, 3 deletions
diff --git a/crawl-ref/source/describe.cc b/crawl-ref/source/describe.cc
index 7d40a8a2cc..8846f838ea 100644
--- a/crawl-ref/source/describe.cc
+++ b/crawl-ref/source/describe.cc
@@ -227,10 +227,13 @@ static std::vector<std::string> _randart_propnames( const item_def& item )
if (!type.empty())
propnames.push_back(type);
}
- else if (item.base_type == OBJ_WEAPONS
- && item_ident(item, ISFLAG_KNOW_TYPE))
+ else if (item_ident(item, ISFLAG_KNOW_TYPE))
{
- std::string ego = weapon_brand_name(item, true);
+ std::string ego;
+ if (item.base_type == OBJ_WEAPONS)
+ ego = weapon_brand_name(item, true);
+ else if (item.base_type == OBJ_ARMOUR)
+ ego = armour_ego_name(item, true);
if (!ego.empty())
{
// XXX: Ugly hack to remove the brackets...