aboutsummaryrefslogtreecommitdiff
path: root/src/trinitycore/CliRunnable.cpp
diff options
context:
space:
mode:
authormegamage <none@none>2009-01-01 19:32:44 -0600
committermegamage <none@none>2009-01-01 19:32:44 -0600
commit704be96b4c25fa4566da22940f436eadc43679a1 (patch)
treeeedb1e47a5004d552761cdf13698387d9b9fd101 /src/trinitycore/CliRunnable.cpp
parent95d6015cb0b4801fca2a617d5d2209091433f750 (diff)
*Add console command "difftime" to change the interval to record diff time in log.
--HG-- branch : trunk
Diffstat (limited to 'src/trinitycore/CliRunnable.cpp')
-rw-r--r--src/trinitycore/CliRunnable.cpp20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/trinitycore/CliRunnable.cpp b/src/trinitycore/CliRunnable.cpp
index 7fe2ab784a6..78c6e0dbb85 100644
--- a/src/trinitycore/CliRunnable.cpp
+++ b/src/trinitycore/CliRunnable.cpp
@@ -272,6 +272,26 @@ bool ChatHandler::HandleServerSetLogLevelCommand(const char *args)
return true;
}
+/// set diff time record interval
+bool ChatHandler::HandleServerSetDiffTimeCommand(const char *args)
+{
+ if(!*args)
+ return false;
+
+ char *NewTimeStr = strtok((char*)args, " ");
+ if(!NewTimeStr)
+ return false;
+
+ int32 NewTime =atoi(NewTimeStr);
+ if(NewTime < 0)
+ return false;
+
+ sWorld.SetRecordDiffInterval(NewTime);
+ printf( "Record diff every %u ms\n", NewTime);
+ return true;
+}
+
+
/// @}
#ifdef linux