summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/Chunk.cpp10
-rw-r--r--src/Chunk.h2
2 files changed, 6 insertions, 6 deletions
diff --git a/src/Chunk.cpp b/src/Chunk.cpp
index c9e4f5411..7ca0a4afd 100644
--- a/src/Chunk.cpp
+++ b/src/Chunk.cpp
@@ -86,7 +86,7 @@ cChunk::cChunk(
m_NeighborZP(a_NeighborZP),
m_WaterSimulatorData(a_World->GetWaterSimulator()->CreateChunkData()),
m_LavaSimulatorData (a_World->GetLavaSimulator ()->CreateChunkData()),
- m_EntityTickIteratorData(std::make_pair(false, &m_Entities.end()))
+ m_EntityTickIteratorData(std::make_pair(false, m_Entities.end()))
{
if (a_NeighborXM != NULL)
{
@@ -584,12 +584,12 @@ void cChunk::Tick(float a_Dt)
// Don't tick things queued to be removed
if (!((*itr)->IsMob()))
{
- m_EntityTickIteratorData.second = &itr;
+ m_EntityTickIteratorData.second = itr;
(*itr)->Tick(a_Dt, *this);
- if (itr != *m_EntityTickIteratorData.second)
+ if (itr != m_EntityTickIteratorData.second)
{
- itr = *m_EntityTickIteratorData.second;
+ itr = m_EntityTickIteratorData.second;
}
else
{
@@ -1876,7 +1876,7 @@ void cChunk::RemoveEntity(cEntity * a_Entity)
{
if (m_EntityTickIteratorData.first)
{
- *m_EntityTickIteratorData.second = m_Entities.erase(*m_EntityTickIteratorData.second);
+ m_EntityTickIteratorData.second = m_Entities.erase(m_EntityTickIteratorData.second);
}
else
{
diff --git a/src/Chunk.h b/src/Chunk.h
index 3046b2efe..1619df333 100644
--- a/src/Chunk.h
+++ b/src/Chunk.h
@@ -425,7 +425,7 @@ private:
// A critical section is not needed, because all chunk access is protected by its parent ChunkMap's csLayers
cClientHandleList m_LoadedByClient;
cEntityList m_Entities;
- std::pair<bool, cEntityList::iterator *> m_EntityTickIteratorData;
+ std::pair<bool, cEntityList::iterator> m_EntityTickIteratorData;
cBlockEntityList m_BlockEntities;
/** Number of times the chunk has been requested to stay (by various cChunkStay objects); if zero, the chunk can be unloaded */