summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/item_use.cc
diff options
context:
space:
mode:
Diffstat (limited to 'crawl-ref/source/item_use.cc')
-rw-r--r--crawl-ref/source/item_use.cc11
1 files changed, 8 insertions, 3 deletions
diff --git a/crawl-ref/source/item_use.cc b/crawl-ref/source/item_use.cc
index 5a643a6276..b184f89d82 100644
--- a/crawl-ref/source/item_use.cc
+++ b/crawl-ref/source/item_use.cc
@@ -23,6 +23,9 @@ REVISION("$Rev$");
#include "cloud.h"
#include "command.h"
#include "debug.h"
+#ifdef USE_TILE
+#include "decks.h"
+#endif
#include "delay.h"
#include "describe.h"
#include "directn.h"
@@ -5435,17 +5438,19 @@ void tile_item_use(int idx)
case OBJ_STAVES:
case OBJ_MISCELLANY:
// Wield any unwielded item of these types.
- if (!equipped)
+ if (!equipped
+ && (item.base_type != OBJ_MISCELLANY || is_deck(item)
+ || item.sub_type == MISC_LANTERN_OF_SHADOWS))
{
if (check_warning_inscriptions(item, OPER_WIELD))
wield_weapon(true, idx);
return;
}
// Evoke misc. items and rods.
- if (item.base_type == OBJ_MISCELLANY || item_is_rod(item))
+ if (item_is_evokable(item))
{
if (check_warning_inscriptions(item, OPER_EVOKE))
- evoke_wielded();
+ evoke_item(idx);
return;
}
// Unwield staves or weapons.