Cosmetic: Multiple cosmetic changes

- Added missing space to 'if', 'for', 'while' and 'switch' when it's followed by '('
- Added missing space after a comma and remove space before comma (with some exceptions)
- Remove trailing spaces
- Convert tab to spaces

Note: Only affects files with extension "cpp" and "h" under /src/server
This commit is contained in:
Spp
2011-09-29 12:43:05 +02:00
parent 8b820baa73
commit b16d2245bb
390 changed files with 1545 additions and 1545 deletions

View File

@@ -119,7 +119,7 @@ void Map::LoadVMap(int gx, int gy)
{
// x and y are swapped !!
int vmapLoadResult = VMAP::VMapFactory::createOrGetVMapManager()->loadMap((sWorld->GetDataPath()+ "vmaps").c_str(), GetId(), gx, gy);
switch(vmapLoadResult)
switch (vmapLoadResult)
{
case VMAP::VMAP_LOAD_RESULT_OK:
sLog->outDetail("VMAP loaded name:%s, id:%d, x:%d, y:%d (vmap rep.: x:%d, y:%d)", GetMapName(), GetId(), gx, gy, gx, gy);
@@ -305,8 +305,8 @@ void Map::SwitchGridContainers(T* obj, bool on)
obj->m_isWorldObject = on;
}
template void Map::SwitchGridContainers(Creature* , bool);
//template void Map::SwitchGridContainers(DynamicObject* , bool);
template void Map::SwitchGridContainers(Creature*, bool);
//template void Map::SwitchGridContainers(DynamicObject*, bool);
template<class T>
void Map::DeleteFromWorld(T* obj)
@@ -2028,7 +2028,7 @@ void Map::RemoveAllObjectsInRemoveList()
bool on = itr->second;
i_objectsToSwitch.erase(itr);
switch(obj->GetTypeId())
switch (obj->GetTypeId())
{
case TYPEID_UNIT:
if (!obj->ToCreature()->isPet())
@@ -2045,7 +2045,7 @@ void Map::RemoveAllObjectsInRemoveList()
std::set<WorldObject*>::iterator itr = i_objectsToRemove.begin();
WorldObject* obj = *itr;
switch(obj->GetTypeId())
switch (obj->GetTypeId())
{
case TYPEID_CORPSE:
{
@@ -2181,10 +2181,10 @@ template void Map::Add(Creature*);
template void Map::Add(GameObject*);
template void Map::Add(DynamicObject*);
template void Map::Remove(Corpse* , bool);
template void Map::Remove(Creature* , bool);
template void Map::Remove(GameObject* , bool);
template void Map::Remove(DynamicObject* , bool);
template void Map::Remove(Corpse*, bool);
template void Map::Remove(Creature*, bool);
template void Map::Remove(GameObject*, bool);
template void Map::Remove(DynamicObject*, bool);
/* ******* Dungeon Instance Maps ******* */
@@ -2593,7 +2593,7 @@ BattlegroundMap::BattlegroundMap(uint32 id, time_t expiry, uint32 InstanceId, Ma
BattlegroundMap::~BattlegroundMap()
{
if(m_bg)
if (m_bg)
{
//unlink to prevent crash, always unlink all pointer reference before destruction
m_bg->SetBgMap(NULL);