diff options
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/ScenePresence.cs')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/ScenePresence.cs | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index 0cb1556..fd7f7d8 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs | |||
@@ -3541,6 +3541,25 @@ namespace OpenSim.Region.Framework.Scenes | |||
3541 | } | 3541 | } |
3542 | 3542 | ||
3543 | /// <summary> | 3543 | /// <summary> |
3544 | /// A float the value is a representative execution time in milliseconds of all scripts in all attachments. | ||
3545 | /// </summary> | ||
3546 | public float ScriptExecutionTime() | ||
3547 | { | ||
3548 | float time = 0.0f; | ||
3549 | lock (m_attachments) | ||
3550 | { | ||
3551 | foreach (SceneObjectGroup gobj in m_attachments) | ||
3552 | { | ||
3553 | if (gobj != null) | ||
3554 | { | ||
3555 | time += gobj.ScriptExecutionTime(); | ||
3556 | } | ||
3557 | } | ||
3558 | } | ||
3559 | return time; | ||
3560 | } | ||
3561 | |||
3562 | /// <summary> | ||
3544 | /// Returns the total count of running scripts in all parts. | 3563 | /// Returns the total count of running scripts in all parts. |
3545 | /// </summary> | 3564 | /// </summary> |
3546 | public int RunningScriptCount() | 3565 | public int RunningScriptCount() |