summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/UI/SlotArea.cpp17
1 files changed, 10 insertions, 7 deletions
diff --git a/src/UI/SlotArea.cpp b/src/UI/SlotArea.cpp
index f76b11380..d43b91700 100644
--- a/src/UI/SlotArea.cpp
+++ b/src/UI/SlotArea.cpp
@@ -658,17 +658,20 @@ void cSlotAreaEnchanting::ClickedResult(cPlayer & a_Player)
cBlockArea Area;
Area.Read(a_Player.GetWorld(), PosX - 2, PosX + 2, PosY, PosY + 1, PosZ - 2, PosZ + 2);
- for (int x = 0; x < 7; x++)
+ for (int x = 0; x < 6; x++)
{
- for (int y = 0; y < 2; y++)
+ for (int y = 0; y < 3; y++)
{
- for (int z = 0; z < 7; z++)
+ for (int z = 0; z < 6; z++)
{
- LOG(Printf("%i", Area.GetBlockType(x, y, z)).c_str());
-
- if (Area.GetBlockType(x, y, z) == E_BLOCK_BOOKCASE)
+ if ((((x == 0) || (x == 5)) || ((z == 0) || (z == 5))) && ((y == 0) || y == 1))
{
- LOG("BookShelf");
+ LOG("%i", Area.GetRelBlockType(x, y, z));
+
+ if (Area.GetRelBlockType(x, y, z) == E_BLOCK_BOOKCASE)
+ {
+ LOG("BookShelf");
+ }
}
}
}