From e3af78b8bb3ad47ea17162e6ef591ca881f0370e Mon Sep 17 00:00:00 2001 From: j-p-e-g Date: Mon, 9 Mar 2009 21:29:12 +0000 Subject: * Don't count chunks as "useless" (even if inedible) if the player knows Sublimation of Blood or Simulacrum. * Fix missing message flush when memorising spells. (This should probably be handled globally in prompt_invent_item().) git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@9398 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/itemname.cc | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'crawl-ref/source/itemname.cc') diff --git a/crawl-ref/source/itemname.cc b/crawl-ref/source/itemname.cc index 9f10028228..185e9b86f4 100644 --- a/crawl-ref/source/itemname.cc +++ b/crawl-ref/source/itemname.cc @@ -2608,11 +2608,12 @@ bool is_useless_item(const item_def &item, bool temp) break; case OBJ_FOOD: - if (item.sub_type != FOOD_CHUNK || !is_inedible(item)) + if (!is_inedible(item)) return (false); - if (you.has_spell(SPELL_SUBLIMATION_OF_BLOOD) - || you.has_spell(SPELL_SIMULACRUM)) + if (item.sub_type == FOOD_CHUNK + && (you.has_spell(SPELL_SUBLIMATION_OF_BLOOD) + || you.has_spell(SPELL_SIMULACRUM))) { return (false); } -- cgit v1.2.3-54-g00ecf