diff options
author | Melanie | 2011-12-12 11:08:50 +0100 |
---|---|---|
committer | Melanie | 2011-12-12 11:08:50 +0100 |
commit | 943b37b8e66f21cab9c52e6f5120d86085d0179c (patch) | |
tree | dd311f72a060abd60130781dfe92d6ad02454589 /OpenSim | |
parent | Fix a regression that causes data from the attachments module to fail loading (diff) | |
download | opensim-SC-943b37b8e66f21cab9c52e6f5120d86085d0179c.zip opensim-SC-943b37b8e66f21cab9c52e6f5120d86085d0179c.tar.gz opensim-SC-943b37b8e66f21cab9c52e6f5120d86085d0179c.tar.bz2 opensim-SC-943b37b8e66f21cab9c52e6f5120d86085d0179c.tar.xz |
Send changed animation event asynchronously
Diffstat (limited to 'OpenSim')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/ScenePresence.cs | 31 |
1 files changed, 17 insertions, 14 deletions
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index 4034621..32e44fb 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs | |||
@@ -3556,26 +3556,29 @@ namespace OpenSim.Region.Framework.Scenes | |||
3556 | /// <param name="args">The arguments for the event</param> | 3556 | /// <param name="args">The arguments for the event</param> |
3557 | public void SendScriptEventToAttachments(string eventName, Object[] args) | 3557 | public void SendScriptEventToAttachments(string eventName, Object[] args) |
3558 | { | 3558 | { |
3559 | if (m_scriptEngines.Length == 0) | 3559 | Util.FireAndForget(delegate(object x) |
3560 | return; | ||
3561 | |||
3562 | lock (m_attachments) | ||
3563 | { | 3560 | { |
3564 | foreach (SceneObjectGroup grp in m_attachments) | 3561 | if (m_scriptEngines.Length == 0) |
3562 | return; | ||
3563 | |||
3564 | lock (m_attachments) | ||
3565 | { | 3565 | { |
3566 | // 16384 is CHANGED_ANIMATION | 3566 | foreach (SceneObjectGroup grp in m_attachments) |
3567 | // | ||
3568 | // Send this to all attachment root prims | ||
3569 | // | ||
3570 | foreach (IScriptModule m in m_scriptEngines) | ||
3571 | { | 3567 | { |
3572 | if (m == null) // No script engine loaded | 3568 | // 16384 is CHANGED_ANIMATION |
3573 | continue; | 3569 | // |
3570 | // Send this to all attachment root prims | ||
3571 | // | ||
3572 | foreach (IScriptModule m in m_scriptEngines) | ||
3573 | { | ||
3574 | if (m == null) // No script engine loaded | ||
3575 | continue; | ||
3574 | 3576 | ||
3575 | m.PostObjectEvent(grp.RootPart.UUID, "changed", new Object[] { (int)Changed.ANIMATION }); | 3577 | m.PostObjectEvent(grp.RootPart.UUID, "changed", new Object[] { (int)Changed.ANIMATION }); |
3578 | } | ||
3576 | } | 3579 | } |
3577 | } | 3580 | } |
3578 | } | 3581 | }); |
3579 | } | 3582 | } |
3580 | 3583 | ||
3581 | internal void PushForce(Vector3 impulse) | 3584 | internal void PushForce(Vector3 impulse) |