From 3138daa1f8902a9e57d8ff2aa2951a194808b8ae Mon Sep 17 00:00:00 2001 From: "madmaxoft@gmail.com" Date: Tue, 28 May 2013 18:50:44 +0000 Subject: Block entities now receive the cChunk param in their Tick() function They can safely access that chunk and any of its neighbors during ticking. git-svn-id: http://mc-server.googlecode.com/svn/trunk@1526 0a769ca7-a7f5-676a-18bf-c427514a06d6 --- source/Chunk.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source/Chunk.cpp') diff --git a/source/Chunk.cpp b/source/Chunk.cpp index a119c7c61..56741e3f7 100644 --- a/source/Chunk.cpp +++ b/source/Chunk.cpp @@ -452,7 +452,7 @@ void cChunk::Tick(float a_Dt) // Tick all block entities in this chunk: for (cBlockEntityList::iterator itr = m_BlockEntities.begin(); itr != m_BlockEntities.end(); ++itr) { - m_IsDirty = (*itr)->Tick(a_Dt) | m_IsDirty; + m_IsDirty = (*itr)->Tick(a_Dt, *this) | m_IsDirty; } // Tick all entities in this chunk: -- cgit v1.2.3