1
0

Fixed Clang warnings in itemhandlers.

This commit is contained in:
madmaxoft
2014-04-04 09:56:57 +02:00
parent 446a651502
commit 402d85d896
6 changed files with 21 additions and 20 deletions

View File

@@ -506,13 +506,13 @@ bool cItemHandler::GetPlacementBlockTypeMeta(
{
ASSERT(m_ItemType < 256); // Items with IDs above 255 should all be handled by specific handlers
if (m_ItemType > 256)
if (m_ItemType >= 256)
{
LOGERROR("%s: Item %d has no valid block!", __FUNCTION__, m_ItemType);
LOGERROR("%s: Item %d is not eligible for direct block placement!", __FUNCTION__, m_ItemType);
return false;
}
cBlockHandler * BlockH = BlockHandler(m_ItemType);
cBlockHandler * BlockH = BlockHandler((BLOCKTYPE)m_ItemType);
cChunkInterface ChunkInterface(a_World->GetChunkMap());
return BlockH->GetPlacementBlockTypeMeta(
ChunkInterface, a_Player,