From be121f9e80290fb3ad126a6f063784161e516fd0 Mon Sep 17 00:00:00 2001 From: Tiger Wang Date: Fri, 28 Aug 2020 21:40:40 +0100 Subject: Save enderchest block entities to storage + Add EnderChest saving, as Vanilla does - Remove CreateBlockEntities. Storage should save & load everything so looping over chunk data is not needed --- src/Chunk.h | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) (limited to 'src/Chunk.h') diff --git a/src/Chunk.h b/src/Chunk.h index fa4e9ad19..8aa73cde5 100644 --- a/src/Chunk.h +++ b/src/Chunk.h @@ -581,7 +581,7 @@ private: // A critical section is not needed, because all chunk access is protected by its parent ChunkMap's csLayers std::vector m_LoadedByClient; std::vector m_Entities; - cBlockEntities m_BlockEntities; + cBlockEntities m_BlockEntities; /** Number of times the chunk has been requested to stay (by various cChunkStay objects); if zero, the chunk can be unloaded */ unsigned m_StayCount; @@ -623,12 +623,6 @@ private: void RemoveBlockEntity(cBlockEntity * a_BlockEntity); void AddBlockEntity (OwnedBlockEntity a_BlockEntity); - /** Add a block entity to the chunk without marking the chunk dirty */ - void AddBlockEntityClean(OwnedBlockEntity a_BlockEntity); - - /** Creates a block entity for each block that needs a block entity and doesn't have one already */ - void CreateBlockEntities(void); - /** Wakes up each simulator for its specific blocks; through all the blocks in the chunk */ void WakeUpSimulators(void); @@ -659,11 +653,3 @@ private: /** Check m_Entities for cPlayer objects. */ bool HasPlayerEntities() const; }; - -typedef cChunk * cChunkPtr; - -typedef std::list cChunkPtrList; - - - - -- cgit v1.2.3