MCPcopy Create free account
hub / github.com/cuberite/cuberite / VerifyHeightmap

Method VerifyHeightmap

src/Generating/ChunkDesc.cpp:607–625  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

605#ifdef _DEBUG
606
607void cChunkDesc::VerifyHeightmap(void)
608{
609 for (int x = 0; x < cChunkDef::Width; x++)
610 {
611 for (int z = 0; z < cChunkDef::Width; z++)
612 {
613 for (int y = cChunkDef::Height - 1; y > 0; y--)
614 {
615 BLOCKTYPE BlockType = GetBlockType(x, y, z);
616 if (BlockType != E_BLOCK_AIR)
617 {
618 int Height = GetHeight(x, z);
619 ASSERT(Height == y);
620 break;
621 }
622 } // for y
623 } // for z
624 } // for x
625}
626
627#endif // _DEBUG
628

Callers 1

DoGenerateMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected