1
0
Fork 0

Fixed possible crash in the NetherClumpFoliage finisher.

This commit is contained in:
STRWarrior 2014-07-23 11:02:42 +02:00
parent dfadcf7453
commit 9080f14dc2
1 changed files with 5 additions and 0 deletions

View File

@ -125,6 +125,11 @@ void cFinishGenNetherClumpFoliage::TryPlaceClump(cChunkDesc & a_ChunkDesc, int a
float zz = (float) a_ChunkDesc.GetChunkZ() * cChunkDef::Width + z;
for (int y = a_RelY - 2; y < a_RelY + 2; y++)
{
if ((y < 1) || (y > cChunkDef::Height))
{
continue;
}
if (a_ChunkDesc.GetBlockType(x, y, z) != E_BLOCK_AIR) // Don't replace non air blocks.
{
continue;