]> git.lizzy.rs Git - dragonfireclient.git/commitdiff
Avoid marking map blocks dirty upon deserialization.
authorLars <larsh@apache.org>
Thu, 26 Nov 2020 01:16:41 +0000 (17:16 -0800)
committerlhofhansl <larsh@apache.org>
Thu, 26 Nov 2020 19:41:55 +0000 (11:41 -0800)
src/mapblock.cpp

index 5fb6b221b36a86ac92c0596133a3eae4e35a334f..8bfecd7558820a07c4fa04f760f93f8ebe6da90e 100644 (file)
@@ -533,7 +533,7 @@ void MapBlock::deSerialize(std::istream &is, u8 version, bool disk)
                // Timestamp
                TRACESTREAM(<<"MapBlock::deSerialize "<<PP(getPos())
                                <<": Timestamp"<<std::endl);
-               setTimestamp(readU32(is));
+               setTimestampNoChangedFlag(readU32(is));
                m_disk_timestamp = m_timestamp;
 
                // Dynamically re-set ids based on node names
@@ -716,10 +716,10 @@ void MapBlock::deSerialize_pre22(std::istream &is, u8 version, bool disk)
 
                // Timestamp
                if (version >= 17) {
-                       setTimestamp(readU32(is));
+                       setTimestampNoChangedFlag(readU32(is));
                        m_disk_timestamp = m_timestamp;
                } else {
-                       setTimestamp(BLOCK_TIMESTAMP_UNDEFINED);
+                       setTimestampNoChangedFlag(BLOCK_TIMESTAMP_UNDEFINED);
                }
 
                // Dynamically re-set ids based on node names