Added osGetRegionStats() function, to return a number of sim statistics

mysql-performance
Jeff Lee 2009-11-23 11:53:37 -05:00 committed by Melanie
parent d39c300d11
commit 9d05962029
1 changed files with 8 additions and 1 deletions

View File

@ -1949,9 +1949,16 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
return key.ToString(); return key.ToString();
} }
/// <summary>
/// Return information regarding various simulator statistics (sim fps, physics fps, time
/// dilation, total number of prims, total number of active scripts, script lps, various
/// timing data, packets in/out, etc. Basically much the information that's shown in the
/// client's Statistics Bar (Ctrl-Shift-1)
/// </summary>
/// <returns>List of floats</returns>
public LSL_List osGetRegionStats() public LSL_List osGetRegionStats()
{ {
CheckThreatLevel(ThreatLevel.High, "osGetRegionStats"); CheckThreatLevel(ThreatLevel.Moderate, "osGetRegionStats");
m_host.AddScriptLPS(1); m_host.AddScriptLPS(1);
LSL_List ret = new LSL_List(); LSL_List ret = new LSL_List();
float[] stats = World.SimulatorStats; float[] stats = World.SimulatorStats;