1
0

Fixed a potential crash

This commit is contained in:
Tiger Wang 2014-03-28 22:51:39 +00:00
parent 283a66bcae
commit 8ece214920

View File

@ -884,7 +884,7 @@ void cChunk::ApplyWeatherToTop()
FastSetBlock(X, Height, Z, E_BLOCK_SNOW, TopMeta - 1); FastSetBlock(X, Height, Z, E_BLOCK_SNOW, TopMeta - 1);
} }
} }
else if (cBlockInfo::IsSnowable(TopBlock)) else if (cBlockInfo::IsSnowable(TopBlock) && (Height + 1 < cChunkDef::Height))
{ {
SetBlock(X, Height + 1, Z, E_BLOCK_SNOW, 0); SetBlock(X, Height + 1, Z, E_BLOCK_SNOW, 0);
} }