From 217b2d93ae77925e9ebbb0ef3e9b44d47e4234db Mon Sep 17 00:00:00 2001 From: Melanie Thielker Date: Sat, 11 Apr 2009 16:51:27 +0000 Subject: Adding a script event, changed(CHANGED_ANIMATION) This is sent to all root prims of all attachments of an avatar when the animation state changes. llGetAnimation() can thenbe used to find the new movement animation. This eliminates the need for fast timers in AOs --- OpenSim/Region/ScriptEngine/DotNetEngine/ScriptEngine.cs | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'OpenSim/Region/ScriptEngine/DotNetEngine/ScriptEngine.cs') diff --git a/OpenSim/Region/ScriptEngine/DotNetEngine/ScriptEngine.cs b/OpenSim/Region/ScriptEngine/DotNetEngine/ScriptEngine.cs index 34a7c7a..c3b52df 100644 --- a/OpenSim/Region/ScriptEngine/DotNetEngine/ScriptEngine.cs +++ b/OpenSim/Region/ScriptEngine/DotNetEngine/ScriptEngine.cs @@ -222,6 +222,15 @@ namespace OpenSim.Region.ScriptEngine.DotNetEngine return PostScriptEvent(itemID, new EventParams(name, p, new DetectParams[0])); } + public bool PostObjectEvent(UUID itemID, string name, Object[] p) + { + SceneObjectPart part = m_Scene.GetSceneObjectPart(itemID); + if (part == null) + return false; + + return PostObjectEvent(part.LocalId, new EventParams(name, p, new DetectParams[0])); + } + public DetectParams GetDetectParams(UUID itemID, int number) { uint localID = m_ScriptManager.GetLocalID(itemID); -- cgit v1.1