diff options
author | Adam Borowski <kilobyte@angband.pl> | 2013-04-12 13:59:57 +0200 |
---|---|---|
committer | Adam Borowski <kilobyte@angband.pl> | 2013-04-26 17:03:15 +0200 |
commit | 3d87c34f773afb613986b3343e7cc83a7a09781e (patch) | |
tree | 4926bf8186847d6c74e97367ca5e829890309938 /crawl-ref/source/invent.h | |
parent | bcafd50d28ce15105ae43bb6a32cb08d55c30a15 (diff) | |
download | crawl-ref-3d87c34f773afb613986b3343e7cc83a7a09781e.tar.gz crawl-ref-3d87c34f773afb613986b3343e7cc83a7a09781e.zip |
Revert "Prevent selecting inventory items that cannot be used, including melded items for scrolls"
Doing this in the filter causes severe regressions:
* no failure messages are given anymore. This includes cases that are
unobvious to new players, like, say, why that bright green or red chunk
is inedible.
* if a chunk rots without you noticing, the menu interface will consume
any keys you pressed subsequently, making you waste permafood. This can
happen for other item types too, it's just chunks being ingrained so
hard into muscle memory that people don't read prompts carefully.
Having the menu filter duplicate the work is not good either, but until
this mess is refactored, the filter has not enough data.
Proposed interface: const char* why_not_use(CMD_EAT, item) which returns
null if you can actually use the item.
This reverts commit bab355256aed893ee730059d95111987b32c3815.
Diffstat (limited to 'crawl-ref/source/invent.h')
-rw-r--r-- | crawl-ref/source/invent.h | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/crawl-ref/source/invent.h b/crawl-ref/source/invent.h index 193c1dc9c7..b6d9ab34ed 100644 --- a/crawl-ref/source/invent.h +++ b/crawl-ref/source/invent.h @@ -30,8 +30,7 @@ enum object_selector OSEL_CURSED_WORN = -14, OSEL_UNCURSED_WORN_ARMOUR = -15, OSEL_UNCURSED_WORN_JEWELLERY = -16, - OSEL_ANY_UNMELDED = -17, - OSEL_SCROLL_TARGET = -18, + OSEL_SCROLL_TARGET = -17, }; #define SLOT_BARE_HANDS -2 @@ -192,8 +191,7 @@ int prompt_invent_item(const char *prompt, int excluded_slot = -1, int *const count = NULL, operation_types oper = OPER_ANY, - bool allow_list_known = false, - bool accept_any = false); + bool allow_list_known = false); vector<SelItem> select_items( const vector<const item_def*> &items, |