Not possible with your code except if you initialize Perf Counter elsewhere...CPU=0,6% DOL=0,0% pg/s=0,0 dsk/s=1,6
DOL.WeakMulticastDelegate - InvokeSafe took 1217ms! method: DOL.GS.GameEvents.StatPrint.OnScriptCompiled target: null
public static void OnScriptCompiled(DOLEvent e, object sender, EventArgs args)
{
lock (typeof(StatPrint))
{
m_timerStatsByMgr = new Hashtable();
m_timer = new Timer(new TimerCallback(PrintStats), null, 10000, 0);
// Create performance counters
if (m_systemCpuUsedCounter == null) m_systemCpuUsedCounter = CreatePerformanceCounter("Processor", "% processor time", "_total");
if (m_processCpuUsedCounter == null) m_processCpuUsedCounter = CreatePerformanceCounter("Process", "% processor time", GetProcessCounterName());
if (m_memoryPages == null) m_memoryPages = CreatePerformanceCounter("Memory", "Pages/sec", null);
if (m_physycalDisk == null) m_physycalDisk = CreatePerformanceCounter("PhysicalDisk", "Disk Transfers/sec", "_Total");
}
}
Return to “%s” DOL SVN Commits
Users browsing this forum: No registered users and 1 guest