aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Maps
diff options
context:
space:
mode:
authorkaelima <kaelima@live.se>2012-04-08 23:59:52 +0200
committerkaelima <kaelima@live.se>2012-04-08 23:59:52 +0200
commit49e24e2dfbcdc312cb5a4d742262300363263751 (patch)
tree9a5b2a932777b98bad655583758fb997603a190f /src/server/game/Maps
parent38d5fbac0ecbc380e9ebf49b3b09080c8e9e96f6 (diff)
Core/Cleanup:
Mostly if(.. -> if (.. and for(.. -> for (.. but also some miscellaneous cleanup
Diffstat (limited to 'src/server/game/Maps')
-rwxr-xr-xsrc/server/game/Maps/Map.cpp8
-rwxr-xr-xsrc/server/game/Maps/MapManager.cpp16
2 files changed, 12 insertions, 12 deletions
diff --git a/src/server/game/Maps/Map.cpp b/src/server/game/Maps/Map.cpp
index f60a8f20c1c..a1b3d913c99 100755
--- a/src/server/game/Maps/Map.cpp
+++ b/src/server/game/Maps/Map.cpp
@@ -787,20 +787,20 @@ void Map::RemoveCreatureFromMoveList(Creature* c)
void Map::MoveAllCreaturesInMoveList()
{
_creatureToMoveLock = true;
- for(std::vector<Creature*>::iterator itr = _creaturesToMove.begin(); itr != _creaturesToMove.end(); ++itr)
+ for (std::vector<Creature*>::iterator itr = _creaturesToMove.begin(); itr != _creaturesToMove.end(); ++itr)
{
Creature* c = *itr;
- if(c->FindMap() != this) //pet is teleported to another map
+ if (c->FindMap() != this) //pet is teleported to another map
continue;
- if(c->_moveState != CREATURE_CELL_MOVE_ACTIVE)
+ if (c->_moveState != CREATURE_CELL_MOVE_ACTIVE)
{
c->_moveState = CREATURE_CELL_MOVE_NONE;
continue;
}
c->_moveState = CREATURE_CELL_MOVE_NONE;
- if(!c->IsInWorld())
+ if (!c->IsInWorld())
continue;
// do move or do move to respawn or remove creature if previous all fail
diff --git a/src/server/game/Maps/MapManager.cpp b/src/server/game/Maps/MapManager.cpp
index 0fb28008c1e..eb09538721d 100755
--- a/src/server/game/Maps/MapManager.cpp
+++ b/src/server/game/Maps/MapManager.cpp
@@ -96,32 +96,32 @@ void MapManager::checkAndCorrectGridStatesArray()
Map* MapManager::CreateBaseMap(uint32 id)
{
- Map* m = FindBaseMap(id);
+ Map* map = FindBaseMap(id);
- if (m == NULL)
+ if (map == NULL)
{
TRINITY_GUARD(ACE_Thread_Mutex, Lock);
const MapEntry* entry = sMapStore.LookupEntry(id);
if (entry && entry->Instanceable())
{
- m = new MapInstanced(id, i_gridCleanUpDelay);
+ map = new MapInstanced(id, i_gridCleanUpDelay);
}
else
{
- m = new Map(id, i_gridCleanUpDelay, 0, REGULAR_DIFFICULTY);
+ map = new Map(id, i_gridCleanUpDelay, 0, REGULAR_DIFFICULTY);
}
- i_maps[id] = m;
+ i_maps[id] = map;
}
- ASSERT(m != NULL);
- return m;
+ ASSERT(map);
+ return map;
}
Map* MapManager::FindBaseNonInstanceMap(uint32 mapId) const
{
Map* map = FindBaseMap(mapId);
- if(map && map->Instanceable())
+ if (map && map->Instanceable())
return NULL;
return map;
}