summaryrefslogtreecommitdiffstats
path: root/src/UI/SlotArea.cpp
diff options
context:
space:
mode:
authorAlexander Harkness <me@bearbin.net>2015-05-27 13:21:17 +0200
committerAlexander Harkness <me@bearbin.net>2015-05-27 13:21:17 +0200
commitda4a76bb5043d072513b74823dc79279c75dd70c (patch)
tree5c46cca70beb5e0b0d0161b5ccb306425e6426dd /src/UI/SlotArea.cpp
parentMerge pull request #2143 from jammet/patch-6 (diff)
parentFixes #2041 (diff)
downloadcuberite-da4a76bb5043d072513b74823dc79279c75dd70c.tar
cuberite-da4a76bb5043d072513b74823dc79279c75dd70c.tar.gz
cuberite-da4a76bb5043d072513b74823dc79279c75dd70c.tar.bz2
cuberite-da4a76bb5043d072513b74823dc79279c75dd70c.tar.lz
cuberite-da4a76bb5043d072513b74823dc79279c75dd70c.tar.xz
cuberite-da4a76bb5043d072513b74823dc79279c75dd70c.tar.zst
cuberite-da4a76bb5043d072513b74823dc79279c75dd70c.zip
Diffstat (limited to 'src/UI/SlotArea.cpp')
-rw-r--r--src/UI/SlotArea.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/UI/SlotArea.cpp b/src/UI/SlotArea.cpp
index 37683a8e5..5b58b18b6 100644
--- a/src/UI/SlotArea.cpp
+++ b/src/UI/SlotArea.cpp
@@ -1394,7 +1394,7 @@ void cSlotAreaBeacon::OnSlotChanged(cItemGrid * a_ItemGrid, int a_SlotNum)
// cSlotAreaEnchanting:
cSlotAreaEnchanting::cSlotAreaEnchanting(cWindow & a_ParentWindow, int a_BlockX, int a_BlockY, int a_BlockZ) :
- cSlotAreaTemporary(1, a_ParentWindow),
+ cSlotAreaTemporary(2, a_ParentWindow),
m_BlockX(a_BlockX),
m_BlockY(a_BlockY),
m_BlockZ(a_BlockZ)
@@ -2154,10 +2154,10 @@ bool cSlotAreaArmor::CanPlaceArmorInSlot(int a_SlotNum, const cItem & a_Item)
{
switch (a_SlotNum)
{
- case 0: return ItemCategory::IsHelmet (a_Item.m_ItemType);
+ case 0: return (ItemCategory::IsHelmet(a_Item.m_ItemType) || (a_Item.m_ItemType == E_BLOCK_PUMPKIN));
case 1: return ItemCategory::IsChestPlate(a_Item.m_ItemType);
- case 2: return ItemCategory::IsLeggings (a_Item.m_ItemType);
- case 3: return ItemCategory::IsBoots (a_Item.m_ItemType);
+ case 2: return ItemCategory::IsLeggings(a_Item.m_ItemType);
+ case 3: return ItemCategory::IsBoots(a_Item.m_ItemType);
}
return false;
}