diff options
Diffstat (limited to 'src/World.cpp')
-rw-r--r-- | src/World.cpp | 21 |
1 files changed, 18 insertions, 3 deletions
diff --git a/src/World.cpp b/src/World.cpp index 83a8b6c10..dec335253 100644 --- a/src/World.cpp +++ b/src/World.cpp @@ -838,6 +838,7 @@ void cWorld::Tick(std::chrono::milliseconds a_Dt, std::chrono::milliseconds a_La AddQueuedPlayers(); m_ChunkMap->Tick(a_Dt); + m_MapManager.TickMaps(); TickClients(static_cast<float>(a_Dt.count())); TickQueuedBlocks(); @@ -855,7 +856,7 @@ void cWorld::Tick(std::chrono::milliseconds a_Dt, std::chrono::milliseconds a_La SaveAllChunks(); } - if (m_WorldAge - m_LastUnload > std::chrono::minutes(5)) // Unload every 10 seconds + if (m_WorldAge - m_LastUnload > std::chrono::seconds(10)) // Unload every 10 seconds { UnloadUnusedChunks(); } @@ -1393,9 +1394,23 @@ void cWorld::GrowTreeFromSapling(int a_X, int a_Y, int a_Z, NIBBLETYPE a_Sapling case E_META_SAPLING_APPLE: GetAppleTreeImage (a_X, a_Y, a_Z, Noise, WorldAge, Logs, Other); break; case E_META_SAPLING_BIRCH: GetBirchTreeImage (a_X, a_Y, a_Z, Noise, WorldAge, Logs, Other); break; case E_META_SAPLING_CONIFER: GetConiferTreeImage(a_X, a_Y, a_Z, Noise, WorldAge, Logs, Other); break; - case E_META_SAPLING_JUNGLE: GetJungleTreeImage (a_X, a_Y, a_Z, Noise, WorldAge, Logs, Other); break; case E_META_SAPLING_ACACIA: GetAcaciaTreeImage (a_X, a_Y, a_Z, Noise, WorldAge, Logs, Other); break; - case E_META_SAPLING_DARK_OAK: GetDarkoakTreeImage(a_X, a_Y, a_Z, Noise, WorldAge, Logs, Other); break; + case E_META_SAPLING_JUNGLE: + { + bool IsLarge = GetLargeTreeAdjustment(*this, a_X, a_Y, a_Z, a_SaplingMeta); + GetJungleTreeImage (a_X, a_Y, a_Z, Noise, WorldAge, Logs, Other, IsLarge); + break; + } + case E_META_SAPLING_DARK_OAK: + { + if (!GetLargeTreeAdjustment(*this, a_X, a_Y, a_Z, a_SaplingMeta)) + { + return; + } + + GetDarkoakTreeImage(a_X, a_Y, a_Z, Noise, WorldAge, Logs, Other); + break; + } } Other.insert(Other.begin(), Logs.begin(), Logs.end()); Logs.clear(); |