summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/stash.cc
diff options
context:
space:
mode:
authorSage <SageBasilMint@gmail.com>2014-01-02 18:36:40 -0800
committerPekka Lampila <pekka.lampila@iki.fi>2014-01-27 06:07:19 +0200
commitf9f55e972c6779a5e47c529fa0a61343cb74af13 (patch)
treecb98d0e56f64ad1cbc7214815cc53fd4fcf4fde4 /crawl-ref/source/stash.cc
parent85eebba965956c22e5a3c6899024ffc015413a86 (diff)
downloadcrawl-ref-f9f55e972c6779a5e47c529fa0a61343cb74af13.tar.gz
crawl-ref-f9f55e972c6779a5e47c529fa0a61343cb74af13.zip
Automatically identify the last unknown item in relevant base types.
'Relevant base types' are wands, staves, scrolls, potions, rings, amulets. (Various tweaks and cleanups by Medar)
Diffstat (limited to 'crawl-ref/source/stash.cc')
-rw-r--r--crawl-ref/source/stash.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/crawl-ref/source/stash.cc b/crawl-ref/source/stash.cc
index a913640f9b..84839afeac 100644
--- a/crawl-ref/source/stash.cc
+++ b/crawl-ref/source/stash.cc
@@ -333,6 +333,7 @@ void Stash::update()
hints_first_item(*pitem);
god_id_item(*pitem);
+ maybe_identify_base_type(*pitem);
const item_def& item = *pitem;
if (!_grid_has_perceived_multiple_items(p))
@@ -661,7 +662,10 @@ void Stash::_update_corpses(int rot_time)
void Stash::_update_identification()
{
for (int i = items.size() - 1; i >= 0; i--)
+ {
god_id_item(items[i]);
+ maybe_identify_base_type(items[i]);
+ }
}
void Stash::add_item(const item_def &item, bool add_to_front)