aboutsummaryrefslogtreecommitdiff
path: root/src/server/collision
diff options
context:
space:
mode:
authorMachiavelli <machiavelli.trinity@gmail.com>2011-02-20 20:16:34 +0100
committerMachiavelli <machiavelli.trinity@gmail.com>2011-02-20 20:16:34 +0100
commite07e20ffcaf6911d4dd47e0895fbdc52c5a52f05 (patch)
treefcc0c8865a387c67b925df174e22f49820a985a0 /src/server/collision
parent45db1591a4959ca9d58fc40ea2294936bcf4bd10 (diff)
Core/Log: Implement log masks for debug log level, to allow selective debug output. Update your worldserver.conf.
Diffstat (limited to 'src/server/collision')
-rw-r--r--src/server/collision/Management/VMapManager2.cpp4
-rw-r--r--src/server/collision/Maps/MapTree.cpp16
2 files changed, 10 insertions, 10 deletions
diff --git a/src/server/collision/Management/VMapManager2.cpp b/src/server/collision/Management/VMapManager2.cpp
index ffcb6e838b5..b318b91b29e 100644
--- a/src/server/collision/Management/VMapManager2.cpp
+++ b/src/server/collision/Management/VMapManager2.cpp
@@ -274,7 +274,7 @@ namespace VMAP
delete worldmodel;
return NULL;
}
- sLog->outDebug("VMapManager2: loading file '%s%s'", basepath.c_str(), filename.c_str());
+ sLog->outDebug(LOG_FILTER_MAPS, "VMapManager2: loading file '%s%s'", basepath.c_str(), filename.c_str());
model = iLoadedModelFiles.insert(std::pair<std::string, ManagedModel>(filename, ManagedModel())).first;
model->second.setModel(worldmodel);
}
@@ -292,7 +292,7 @@ namespace VMAP
}
if( model->second.decRefCount() == 0)
{
- sLog->outDebug("VMapManager2: unloading file '%s'", filename.c_str());
+ sLog->outDebug(LOG_FILTER_MAPS, "VMapManager2: unloading file '%s'", filename.c_str());
delete model->second.getModel();
iLoadedModelFiles.erase(model);
}
diff --git a/src/server/collision/Maps/MapTree.cpp b/src/server/collision/Maps/MapTree.cpp
index de4c044b616..4c9598ce242 100644
--- a/src/server/collision/Maps/MapTree.cpp
+++ b/src/server/collision/Maps/MapTree.cpp
@@ -62,7 +62,7 @@ namespace VMAP
void operator()(const Vector3& point, uint32 entry)
{
#ifdef VMAP_DEBUG
- sLog->outDebug("AreaInfoCallback: trying to intersect '%s'", prims[entry].name.c_str());
+ sLog->outDebug(LOG_FILTER_MAPS, "AreaInfoCallback: trying to intersect '%s'", prims[entry].name.c_str());
#endif
prims[entry].intersectPoint(point, aInfo);
}
@@ -78,7 +78,7 @@ namespace VMAP
void operator()(const Vector3& point, uint32 entry)
{
#ifdef VMAP_DEBUG
- sLog->outDebug("LocationInfoCallback: trying to intersect '%s'", prims[entry].name.c_str());
+ sLog->outDebug(LOG_FILTER_MAPS, "LocationInfoCallback: trying to intersect '%s'", prims[entry].name.c_str());
#endif
if (prims[entry].GetLocationInfo(point, locInfo))
result = true;
@@ -278,7 +278,7 @@ namespace VMAP
bool StaticMapTree::InitMap(const std::string &fname, VMapManager2 *vm)
{
- sLog->outDebug("StaticMapTree::InitMap() : initializing StaticMapTree '%s'", fname.c_str());
+ sLog->outDebug(LOG_FILTER_MAPS, "StaticMapTree::InitMap() : initializing StaticMapTree '%s'", fname.c_str());
bool success = true;
std::string fullname = iBasePath + fname;
FILE *rf = fopen(fullname.c_str(), "rb");
@@ -306,12 +306,12 @@ namespace VMAP
// only non-tiled maps have them, and if so exactly one (so far at least...)
ModelSpawn spawn;
#ifdef VMAP_DEBUG
- sLog->outDebug("StaticMapTree::InitMap() : map isTiled: %u", static_cast<uint32>(iIsTiled));
+ sLog->outDebug(LOG_FILTER_MAPS, "StaticMapTree::InitMap() : map isTiled: %u", static_cast<uint32>(iIsTiled));
#endif
if (!iIsTiled && ModelSpawn::readFromFile(rf, spawn))
{
WorldModel *model = vm->acquireModelInstance(iBasePath, spawn.name);
- sLog->outDebug("StaticMapTree::InitMap() : loading %s", spawn.name.c_str());
+ sLog->outDebug(LOG_FILTER_MAPS, "StaticMapTree::InitMap() : loading %s", spawn.name.c_str());
if (model)
{
// assume that global model always is the first and only tree value (could be improved...)
@@ -395,7 +395,7 @@ namespace VMAP
#ifdef VMAP_DEBUG
if (referencedVal > iNTreeValues)
{
- sLog->outDebug("StaticMapTree::LoadMapTile() : invalid tree element (%u/%u)", referencedVal, iNTreeValues);
+ sLog->outDebug(LOG_FILTER_MAPS, "StaticMapTree::LoadMapTile() : invalid tree element (%u/%u)", referencedVal, iNTreeValues);
continue;
}
#endif
@@ -407,9 +407,9 @@ namespace VMAP
++iLoadedSpawns[referencedVal];
#ifdef VMAP_DEBUG
if (iTreeValues[referencedVal].ID != spawn.ID)
- sLog->outDebug("StaticMapTree::LoadMapTile() : trying to load wrong spawn in node");
+ sLog->outDebug(LOG_FILTER_MAPS, "StaticMapTree::LoadMapTile() : trying to load wrong spawn in node");
else if (iTreeValues[referencedVal].name != spawn.name)
- sLog->outDebug("StaticMapTree::LoadMapTile() : name collision on GUID=%u", spawn.ID);
+ sLog->outDebug(LOG_FILTER_MAPS, "StaticMapTree::LoadMapTile() : name collision on GUID=%u", spawn.ID);
#endif
}
}