diff options
author | Mattes D <github@xoft.cz> | 2015-05-09 11:16:56 +0200 |
---|---|---|
committer | Mattes D <github@xoft.cz> | 2015-05-09 12:58:55 +0200 |
commit | 846d16315a8b5a81fbc37d66da4d1254038ec494 (patch) | |
tree | 2a7c873756a3063480a64a975491bd58d9538554 /src/ChunkMap.cpp | |
parent | More style checking. (diff) | |
download | cuberite-846d16315a8b5a81fbc37d66da4d1254038ec494.tar cuberite-846d16315a8b5a81fbc37d66da4d1254038ec494.tar.gz cuberite-846d16315a8b5a81fbc37d66da4d1254038ec494.tar.bz2 cuberite-846d16315a8b5a81fbc37d66da4d1254038ec494.tar.lz cuberite-846d16315a8b5a81fbc37d66da4d1254038ec494.tar.xz cuberite-846d16315a8b5a81fbc37d66da4d1254038ec494.tar.zst cuberite-846d16315a8b5a81fbc37d66da4d1254038ec494.zip |
Diffstat (limited to '')
-rw-r--r-- | src/ChunkMap.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/ChunkMap.cpp b/src/ChunkMap.cpp index edff6baf1..44acc2013 100644 --- a/src/ChunkMap.cpp +++ b/src/ChunkMap.cpp @@ -65,7 +65,7 @@ cChunkMap::~cChunkMap() -void cChunkMap::RemoveLayer( cChunkLayer* a_Layer) +void cChunkMap::RemoveLayer(cChunkLayer * a_Layer) { cCSLock Lock(m_CSLayers); m_Layers.remove(a_Layer); @@ -2716,12 +2716,12 @@ void cChunkMap::SetNextBlockTick(int a_BlockX, int a_BlockY, int a_BlockZ) -void cChunkMap::CollectMobCensus(cMobCensus& a_ToFill) +void cChunkMap::CollectMobCensus(cMobCensus & a_ToFill) { cCSLock Lock(m_CSLayers); - for (cChunkLayerList::iterator itr = m_Layers.begin(); itr != m_Layers.end(); ++itr) + for (auto && layer: m_Layers) { - (*itr)->CollectMobCensus(a_ToFill); + layer->CollectMobCensus(a_ToFill); } // for itr - m_Layers } @@ -2730,12 +2730,12 @@ void cChunkMap::CollectMobCensus(cMobCensus& a_ToFill) -void cChunkMap::SpawnMobs(cMobSpawner& a_MobSpawner) +void cChunkMap::SpawnMobs(cMobSpawner & a_MobSpawner) { cCSLock Lock(m_CSLayers); - for (cChunkLayerList::iterator itr = m_Layers.begin(); itr != m_Layers.end(); ++itr) + for (auto && layer: m_Layers) { - (*itr)->SpawnMobs(a_MobSpawner); + layer->SpawnMobs(a_MobSpawner); } // for itr - m_Layers } @@ -2936,7 +2936,7 @@ cChunk * cChunkMap::cChunkLayer::FindChunk(int a_ChunkX, int a_ChunkZ) -void cChunkMap::cChunkLayer::CollectMobCensus(cMobCensus& a_ToFill) +void cChunkMap::cChunkLayer::CollectMobCensus(cMobCensus & a_ToFill) { for (size_t i = 0; i < ARRAYCOUNT(m_Chunks); i++) { @@ -2955,7 +2955,7 @@ void cChunkMap::cChunkLayer::CollectMobCensus(cMobCensus& a_ToFill) -void cChunkMap::cChunkLayer::SpawnMobs(cMobSpawner& a_MobSpawner) +void cChunkMap::cChunkLayer::SpawnMobs(cMobSpawner & a_MobSpawner) { for (size_t i = 0; i < ARRAYCOUNT(m_Chunks); i++) { |