summaryrefslogtreecommitdiffstats
path: root/src/BlockEntities
diff options
context:
space:
mode:
Diffstat (limited to 'src/BlockEntities')
-rw-r--r--src/BlockEntities/ChestEntity.h2
-rw-r--r--src/BlockEntities/HopperEntity.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/BlockEntities/ChestEntity.h b/src/BlockEntities/ChestEntity.h
index 8ead8bda0..6eb72fc77 100644
--- a/src/BlockEntities/ChestEntity.h
+++ b/src/BlockEntities/ChestEntity.h
@@ -55,7 +55,7 @@ private:
int m_NumActivePlayers;
/** cItemGrid::cListener overrides: */
- virtual void OnSlotChanged(cItemGrid * a_Grid, int a_SlotNum)
+ virtual void OnSlotChanged(cItemGrid * a_Grid, int a_SlotNum) override
{
UNUSED(a_SlotNum);
ASSERT(a_Grid == &m_Contents);
diff --git a/src/BlockEntities/HopperEntity.cpp b/src/BlockEntities/HopperEntity.cpp
index 203f47534..662212c4d 100644
--- a/src/BlockEntities/HopperEntity.cpp
+++ b/src/BlockEntities/HopperEntity.cpp
@@ -507,7 +507,7 @@ bool cHopperEntity::MoveItemsFromSlot(cBlockEntityWithItems & a_Entity, int a_Sl
auto PreviousCount = m_Contents.GetSlot(i).m_ItemCount;
m_Contents.ChangeSlotCount(i, 1);
- if (PreviousCount == m_Contents.GetSlot(i).m_ItemCount + 1)
+ if (PreviousCount + 1 == m_Contents.GetSlot(i).m_ItemCount)
{
// Successfully added a new item. (Failure condition consistutes: stack full)
return true;