mirror of
https://github.com/minetest/minetest.git
synced 2024-11-27 01:53:45 +01:00
Fix crash in commit a69b7abe00fb818fd88f3cd04e7f9997ffd21072
This commit is contained in:
parent
4baf56520d
commit
14c283a623
@ -258,6 +258,7 @@ void LBMManager::applyLBMs(ServerEnvironment *env, MapBlock *block, u32 stamp)
|
||||
v3s16 pos;
|
||||
MapNode n;
|
||||
content_t c;
|
||||
bool pos_valid; // dummy, we know it's valid
|
||||
auto it = getLBMsIntroducedAfter(stamp);
|
||||
for (; it != m_lbm_lookup.end(); ++it) {
|
||||
// Cache previous version to speedup lookup which has a very high performance
|
||||
@ -268,7 +269,7 @@ void LBMManager::applyLBMs(ServerEnvironment *env, MapBlock *block, u32 stamp)
|
||||
for (pos.X = 0; pos.X < MAP_BLOCKSIZE; pos.X++)
|
||||
for (pos.Y = 0; pos.Y < MAP_BLOCKSIZE; pos.Y++)
|
||||
for (pos.Z = 0; pos.Z < MAP_BLOCKSIZE; pos.Z++) {
|
||||
n = block->getNodeNoCheck(pos, nullptr);
|
||||
n = block->getNodeNoCheck(pos, &pos_valid);
|
||||
c = n.getContent();
|
||||
|
||||
// If content_t are not matching perform an LBM lookup
|
||||
|
Loading…
Reference in New Issue
Block a user