summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--source/Chunk.cpp2
-rw-r--r--source/MobCensus.cpp4
-rw-r--r--source/MobCensus.h8
-rw-r--r--source/MobProximityCounter.cpp4
-rw-r--r--source/MobProximityCounter.h6
5 files changed, 12 insertions, 12 deletions
diff --git a/source/Chunk.cpp b/source/Chunk.cpp
index 01cb13c4d..0d6ce335d 100644
--- a/source/Chunk.cpp
+++ b/source/Chunk.cpp
@@ -434,7 +434,7 @@ void cChunk::Stay(bool a_Stay)
void cChunk::CollectMobCensus(cMobCensus& toFill)
{
- toFill.CollectSpawnableChunck(*this);
+ toFill.CollectSpawnableChunk(*this);
std::list<const Vector3d*> playerPositions;
cPlayer* currentPlayer;
for (cClientHandleList::iterator itr = m_LoadedByClient.begin(), end = m_LoadedByClient.end(); itr != end; ++itr)
diff --git a/source/MobCensus.cpp b/source/MobCensus.cpp
index 4984c53c4..612f25916 100644
--- a/source/MobCensus.cpp
+++ b/source/MobCensus.cpp
@@ -50,7 +50,7 @@ void cMobCensus::CollectMob(cMonster& a_Monster, cChunk& a_Chunk, double a_Dista
bool cMobCensus::isCaped(cMonster::eFamily a_MobFamily)
{
bool toReturn = true;
- const int ratio = 319; // this should be 256 as we are only supposed to take account from chuncks that are in 17x17 from a player
+ const int ratio = 319; // this should be 256 as we are only supposed to take account from chunks that are in 17x17 from a player
// but for now, we use all chunks loaded by players. that means 19 x 19 chucks. That's why we use 256 * (19*19) / (17*17) = 319
// MG TODO : code the correct count
tCapMultipliersMap::const_iterator capMultiplier = m_CapMultipliers().find(a_MobFamily);
@@ -64,7 +64,7 @@ bool cMobCensus::isCaped(cMonster::eFamily a_MobFamily)
return toReturn;
}
-void cMobCensus::CollectSpawnableChunck(cChunk& a_Chunk)
+void cMobCensus::CollectSpawnableChunk(cChunk& a_Chunk)
{
m_EligibleForSpawnChunks.insert(&a_Chunk);
}
diff --git a/source/MobCensus.h b/source/MobCensus.h
index 32e608324..8aa8f3a6c 100644
--- a/source/MobCensus.h
+++ b/source/MobCensus.h
@@ -11,7 +11,7 @@ class cMonster;
// it was first being designed in order to make mobs spawn / despawn / act
// as the behaviour and even life of mobs depends on the distance to closest player
//
-// as side effect : it also collect the chuncks that are elligible for spawning
+// as side effect : it also collect the chunks that are elligible for spawning
// as side effect 2 : it also know the caps for mobs number and can compare census to this numbers
class cMobCensus
{
@@ -27,7 +27,7 @@ protected :
std::set<cChunk*> m_EligibleForSpawnChunks;
- // count the chunks that are elligible to spawn (for now, the loaded valide not null chuncks)
+ // count the chunks that are elligible to spawn (for now, the loaded valide not null chunks)
int getChunkNb();
public:
@@ -39,8 +39,8 @@ public:
public :
// collect an elligible Chunk for Mob Spawning
- // MG TODO : code the correct rule (not loaded chunck but short distant from players)
- void CollectSpawnableChunck(cChunk& a_Chunk);
+ // MG TODO : code the correct rule (not loaded chunk but short distant from players)
+ void CollectSpawnableChunk(cChunk& a_Chunk);
// collect a mob - it's distance to player, it's family ...
void CollectMob(cMonster& a_Monster, cChunk& a_Chunk, double a_Distance);
diff --git a/source/MobProximityCounter.cpp b/source/MobProximityCounter.cpp
index 3c5ec9153..583a71579 100644
--- a/source/MobProximityCounter.cpp
+++ b/source/MobProximityCounter.cpp
@@ -12,8 +12,8 @@ void cMobProximityCounter::CollectMob(cEntity& a_Monster, cChunk& a_Chunk, doubl
tMonsterToDistance::iterator it = m_MonsterToDistance.find(&a_Monster);
if (it == m_MonsterToDistance.end())
{
- sDistanceAndChunk newDistanceAndChunck(a_Distance,a_Chunk);
- std::pair<tMonsterToDistance::iterator,bool> result = m_MonsterToDistance.insert(tMonsterToDistance::value_type(&a_Monster,newDistanceAndChunck));
+ sDistanceAndChunk newDistanceAndChunk(a_Distance,a_Chunk);
+ std::pair<tMonsterToDistance::iterator,bool> result = m_MonsterToDistance.insert(tMonsterToDistance::value_type(&a_Monster,newDistanceAndChunk));
if (!result.second)
{
ASSERT(!"A collected Monster was not found inside distance map using find(), but insert() said there already is a key for it");
diff --git a/source/MobProximityCounter.h b/source/MobProximityCounter.h
index d033f1b7f..8a67139aa 100644
--- a/source/MobProximityCounter.h
+++ b/source/MobProximityCounter.h
@@ -38,7 +38,7 @@ protected :
// this map is generated after collection phase, in order to access monster by distance to player
tDistanceToMonster m_DistanceToMonster;
- // this are the collected chuncks. Used to determinate the number of elligible chunck for spawning.
+ // this are the collected chunks. Used to determinate the number of elligible chunk for spawning.
std::set<cChunk*> m_EligibleForSpawnChunks;
protected :
@@ -47,9 +47,9 @@ protected :
void convertMaps();
public :
- // count a mob on a specified chunck with specified distance to an unkown player
+ // count a mob on a specified chunk with specified distance to an unkown player
// if the distance is shortest than the one collected, this become the new closest
- // distance and the chunck become the "hosting" chunk (that is the one that will perform the action)
+ // distance and the chunk become the "hosting" chunk (that is the one that will perform the action)
void CollectMob(cEntity& a_Monster, cChunk& a_Chunk, double a_Distance);
// return the mobs that are within the range of distance of the closest player they are