1
0
Fork 0

Simply Y-check in door handler

This commit is contained in:
Tiger Wang 2020-08-04 18:26:25 +01:00
parent 766a950d20
commit 5bb6512435
1 changed files with 1 additions and 1 deletions

View File

@ -33,7 +33,7 @@ void cBlockDoorHandler::OnBroken(cChunkInterface & a_ChunkInterface, cWorldInter
else
{
const auto Upper = a_BlockPos.addedY(1);
if ((Upper.y <= cChunkDef::Height - 1) && IsDoorBlockType(a_ChunkInterface.GetBlock(Upper)))
if ((Upper.y < cChunkDef::Height) && IsDoorBlockType(a_ChunkInterface.GetBlock(Upper)))
{
// Was lower part, remove upper:
a_ChunkInterface.SetBlock(Upper, E_BLOCK_AIR, 0);