summaryrefslogtreecommitdiff
path: root/src/resources/iteminfo.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/resources/iteminfo.cpp')
-rw-r--r--src/resources/iteminfo.cpp11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/resources/iteminfo.cpp b/src/resources/iteminfo.cpp
index 6dbb90d2a..ca5d122b7 100644
--- a/src/resources/iteminfo.cpp
+++ b/src/resources/iteminfo.cpp
@@ -23,6 +23,7 @@
#include "resources/iteminfo.h"
#include "resources/spriteaction.h"
+#include "resources/spritedef.h"
#include "resources/map/mapconsts.h"
@@ -249,11 +250,17 @@ const SpriteToItemMap *ItemInfo::getSpriteToItemReplaceMap(const int direction)
SpriteToItemMap *const spMap = mSpriteToItemReplaceMap[direction];
if (spMap)
return spMap;
- if (direction == SpriteDirection::UPLEFT || direction == SpriteDirection::UPRIGHT)
+ if (direction == SpriteDirection::UPLEFT
+ || direction == SpriteDirection::UPRIGHT)
+ {
return mSpriteToItemReplaceMap[SpriteDirection::UP];
+ }
- if (direction == SpriteDirection::DOWNLEFT || direction == SpriteDirection::DOWNRIGHT)
+ if (direction == SpriteDirection::DOWNLEFT
+ || direction == SpriteDirection::DOWNRIGHT)
+ {
return mSpriteToItemReplaceMap[SpriteDirection::DOWN];
+ }
return nullptr;
}