summaryrefslogtreecommitdiff
path: root/src/being
diff options
context:
space:
mode:
Diffstat (limited to 'src/being')
-rw-r--r--src/being/playerinfo.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/being/playerinfo.cpp b/src/being/playerinfo.cpp
index c86200219..8c7b55639 100644
--- a/src/being/playerinfo.cpp
+++ b/src/being/playerinfo.cpp
@@ -41,6 +41,10 @@
#include "net/mercenaryhandler.h"
#include "net/playerhandler.h"
+#ifdef EATHENA_SUPPORT
+#include "resources/itemtype.h"
+#endif
+
#include "utils/delete2.h"
#include "debug.h"
@@ -267,6 +271,18 @@ void useEquipItem(const Item *const item, const Sfx sfx)
{
if (item)
{
+#ifdef EATHENA_SUPPORT
+ if (item->getType() == ItemType::CARD)
+ {
+ if (mProtectedItems.find(item->getId()) == mProtectedItems.end())
+ {
+ inventoryHandler->useCard(item);
+ if (sfx == Sfx_true)
+ ItemSoundManager::playSfx(item, ItemSoundEvent::USECARD);
+ }
+ }
+ else
+#endif
if (item->isEquipment() == Equipm_true)
{
if (item->isEquipped() == Equipped_true)