Falling blocks can now be spawned at any position. (#4620)
* Falling blocks can now be spawned at any position. * Added a /cake command to Debuggers that throws a cake in a nice slow arc. * Fixed regular falling blocks.
This commit is contained in:
@@ -62,12 +62,7 @@ void cSandSimulator::SimulateChunk(std::chrono::milliseconds a_Dt, int a_ChunkX,
|
||||
);
|
||||
*/
|
||||
|
||||
auto FallingBlock = cpp14::make_unique<cFallingBlock>(Pos, BlockType, a_Chunk->GetMeta(itr->x, itr->y, itr->z));
|
||||
auto FallingBlockPtr = FallingBlock.get();
|
||||
if (!FallingBlockPtr->Initialize(std::move(FallingBlock), m_World))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
m_World.SpawnFallingBlock(Pos, BlockType, a_Chunk->GetMeta(itr->x, itr->y, itr->z));
|
||||
a_Chunk->SetBlock({itr->x, itr->y, itr->z}, E_BLOCK_AIR, 0);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user