summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/itemname.cc
diff options
context:
space:
mode:
authorj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2008-12-30 12:31:12 +0000
committerj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2008-12-30 12:31:12 +0000
commit3aa8f2c3c6a065779bdb64db863fbb4fcf8102c8 (patch)
treebe2729a1a305593cf6562b3aa9b76e81c01a899b /crawl-ref/source/itemname.cc
parentbeac344a52eafddd8a3ae1d67635773cf9216325 (diff)
downloadcrawl-ref-3aa8f2c3c6a065779bdb64db863fbb4fcf8102c8.tar.gz
crawl-ref-3aa8f2c3c6a065779bdb64db863fbb4fcf8102c8.zip
* Fix charge/enchantment description leaking information about
unidentified items. * Add two new inscriptions: {fully charged} and {tried on item} * Add freshness to default sort_menus (sorting chunks by age) One question: Is it guaranteed that artefacts (of any type) will have different descriptions than ego items? If so, we should probably display the "This is an ancient artefact. It cannot be modified by any means. It may have hidden properties" text for unidentified ones. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8030 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/itemname.cc')
-rw-r--r--crawl-ref/source/itemname.cc9
1 files changed, 7 insertions, 2 deletions
diff --git a/crawl-ref/source/itemname.cc b/crawl-ref/source/itemname.cc
index d682c92f65..58356b012e 100644
--- a/crawl-ref/source/itemname.cc
+++ b/crawl-ref/source/itemname.cc
@@ -250,6 +250,8 @@ std::string item_def::name(description_level_type descrip,
if (id_type == ID_MON_TRIED_TYPE)
tried_str = "tried by monster";
+ else if (id_type == ID_TRIED_ITEM_TYPE)
+ tried_str = "tried on item";
else
tried_str = "tried";
}
@@ -1247,6 +1249,8 @@ std::string item_def::name_aux( description_level_type desc,
{
if (item_plus2 == ZAPCOUNT_EMPTY)
buff << " {empty}";
+ else if (item_plus2 == ZAPCOUNT_MAX_CHARGED)
+ buff << " {fully recharged}";
else if (item_plus2 == ZAPCOUNT_RECHARGED)
buff << " {recharged}";
else if (item_plus2 > 0)
@@ -1704,8 +1708,9 @@ bool item_type_tried( const item_def& item )
const item_type_id_type idt = objtype_to_idtype(item.base_type);
if (idt != NUM_IDTYPE && item.sub_type < 50)
{
- return ( type_ids[idt][item.sub_type] == ID_TRIED_TYPE
- || type_ids[idt][item.sub_type] == ID_MON_TRIED_TYPE);
+ return (type_ids[idt][item.sub_type] == ID_TRIED_TYPE
+ || type_ids[idt][item.sub_type] == ID_MON_TRIED_TYPE
+ || type_ids[idt][item.sub_type] == ID_TRIED_ITEM_TYPE);
}
else
return (false);