From ec91884ca64a65265e0e838faa84697231114950 Mon Sep 17 00:00:00 2001 From: Aleos Date: Wed, 19 May 2021 09:46:49 -0400 Subject: [PATCH] Remove delayed consumption when switching types (#5949) * Fixes #5937. * Removed the delayed consumption flag when switching item types. Thanks to @mazvi! --- src/map/itemdb.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/map/itemdb.cpp b/src/map/itemdb.cpp index 5374b38803..65a7b6b689 100644 --- a/src/map/itemdb.cpp +++ b/src/map/itemdb.cpp @@ -102,6 +102,8 @@ uint64 ItemDatabase::parseBodyNode(const YAML::Node &node) { if (constant == IT_DELAYCONSUME) { // Items that are consumed only after target confirmation constant = IT_USABLE; item->flag.delay_consume |= DELAYCONSUME_TEMP; + } else { + item->flag.delay_consume &= ~DELAYCONSUME_TEMP; // Remove delayed consumption flag if switching types } item->type = static_cast(constant);