mirror of
https://github.com/glest/glest-source.git
synced 2025-08-18 14:11:15 +02:00
* added DebugType debugPathFinder
This commit is contained in:
@@ -151,6 +151,12 @@ public:
|
||||
}
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
std::ostream& operator<<(std::ostream &stream, const Vec2<T> &vec) {
|
||||
return stream << "(" << vec.x << ", " << vec.y << ")";
|
||||
}
|
||||
|
||||
|
||||
typedef Vec2<int> Vec2i;
|
||||
typedef Vec2<bool> Vec2b;
|
||||
typedef Vec2<char> Vec2c;
|
||||
|
@@ -40,7 +40,8 @@ public:
|
||||
debugNetwork,
|
||||
debugPerformance,
|
||||
debugWorldSynch,
|
||||
debugUnitCommands
|
||||
debugUnitCommands,
|
||||
debugPathFinder
|
||||
};
|
||||
|
||||
class SystemFlagsType
|
||||
|
@@ -359,14 +359,22 @@ void SystemFlags::handleDebug(DebugType type, const char *fmt, ...) {
|
||||
|
||||
MutexSafeWrapper safeMutex(currentDebugLog.mutex);
|
||||
|
||||
(*currentDebugLog.fileStream) << "[" << szBuf2 << "] " << szBuf;
|
||||
if (type != debugPathFinder) {
|
||||
(*currentDebugLog.fileStream) << "[" << szBuf2 << "] " << szBuf;
|
||||
} else {
|
||||
(*currentDebugLog.fileStream) << szBuf;
|
||||
}
|
||||
(*currentDebugLog.fileStream).flush();
|
||||
|
||||
safeMutex.ReleaseLock();
|
||||
}
|
||||
// output to console
|
||||
else {
|
||||
printf("[%s] %s", szBuf2, szBuf);
|
||||
if (type != debugPathFinder) {
|
||||
printf("[%s] %s", szBuf2, szBuf);
|
||||
} else {
|
||||
printf("%s", szBuf);
|
||||
}
|
||||
}
|
||||
|
||||
va_end(argList);
|
||||
|
Reference in New Issue
Block a user