summaryrefslogtreecommitdiffstats
path: root/src/Map.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/Map.cpp')
-rw-r--r--src/Map.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/Map.cpp b/src/Map.cpp
index 30d761154..c02cd80f8 100644
--- a/src/Map.cpp
+++ b/src/Map.cpp
@@ -3,14 +3,14 @@
#include "Globals.h"
-#include "Map.h"
#include "BlockInfo.h"
-#include "World.h"
+#include "Blocks/BlockHandler.h"
#include "Chunk.h"
+#include "ClientHandle.h"
#include "Entities/Player.h"
#include "FastRandom.h"
-#include "Blocks/BlockHandler.h"
-#include "ClientHandle.h"
+#include "Map.h"
+#include "World.h"
@@ -139,7 +139,7 @@ bool cMap::UpdatePixel(unsigned int a_X, unsigned int a_Z)
auto Height = a_Chunk.GetHeight(RelX, RelZ);
auto ChunkHeight = cChunkDef::Height;
a_Chunk.GetBlockTypeMeta(RelX, Height, RelZ, TargetBlock, TargetMeta);
- auto ColourID = BlockHandler(TargetBlock)->GetMapBaseColourID(TargetMeta);
+ auto ColourID = cBlockHandler::For(TargetBlock).GetMapBaseColourID(TargetMeta);
if (IsBlockWater(TargetBlock))
{
@@ -151,7 +151,7 @@ bool cMap::UpdatePixel(unsigned int a_X, unsigned int a_Z)
}
else if (ColourID == 0)
{
- while (((--Height) != -1) && ((ColourID = BlockHandler(a_Chunk.GetBlock(RelX, Height, RelZ))->GetMapBaseColourID(a_Chunk.GetMeta(RelX, Height, RelZ))) == 0))
+ while (((--Height) != -1) && ((ColourID = cBlockHandler::For(a_Chunk.GetBlock(RelX, Height, RelZ)).GetMapBaseColourID(a_Chunk.GetMeta(RelX, Height, RelZ))) == 0))
{
continue;
}