summaryrefslogtreecommitdiffstats
path: root/src/ChunkMap.cpp
diff options
context:
space:
mode:
authorMattes D <github@xoft.cz>2015-05-09 13:22:59 +0200
committerMattes D <github@xoft.cz>2015-05-09 13:22:59 +0200
commitca949447eefe74804e677fff5a46a1f18a826901 (patch)
tree911736baccf3617a13f6b7e04ebbfe3fe035fb50 /src/ChunkMap.cpp
parentRabbit and cooked rabbit now stackable (diff)
parentAdded check against "Type const &" and "Type const *". (diff)
downloadcuberite-ca949447eefe74804e677fff5a46a1f18a826901.tar
cuberite-ca949447eefe74804e677fff5a46a1f18a826901.tar.gz
cuberite-ca949447eefe74804e677fff5a46a1f18a826901.tar.bz2
cuberite-ca949447eefe74804e677fff5a46a1f18a826901.tar.lz
cuberite-ca949447eefe74804e677fff5a46a1f18a826901.tar.xz
cuberite-ca949447eefe74804e677fff5a46a1f18a826901.tar.zst
cuberite-ca949447eefe74804e677fff5a46a1f18a826901.zip
Diffstat (limited to 'src/ChunkMap.cpp')
-rw-r--r--src/ChunkMap.cpp18
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++)
{