Anvil: Fixed loading block entities with invalid Y coord.
This commit is contained in:
parent
e9dda864ea
commit
254c8c9154
@ -589,7 +589,7 @@ void cWSSAnvil::LoadBlockEntitiesFromNBT(cBlockEntityList & a_BlockEntities, con
|
||||
|
||||
// Get the BlockEntity's position
|
||||
int x, y, z;
|
||||
if (!GetBlockEntityNBTPos(a_NBT, Child, x, y, z))
|
||||
if (!GetBlockEntityNBTPos(a_NBT, Child, x, y, z) || (y < 0) || (y >= cChunkDef::Height))
|
||||
{
|
||||
LOGWARNING("Bad block entity, missing the coords. Will be ignored.");
|
||||
continue;
|
||||
|
Loading…
Reference in New Issue
Block a user