From 81ad9255b5f44d988bf37cfaf6dc59b05fd744b7 Mon Sep 17 00:00:00 2001 From: Melanie Date: Thu, 6 Jun 2013 03:03:05 +0100 Subject: Hook up Keyframe motion to almost everything. Failing to cross a sim border may yield unexpected results in some cases. No database persistence yet, --- OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs') diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs index df23cc5..da80e4f 100644 --- a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs +++ b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs @@ -455,6 +455,9 @@ namespace OpenSim.Region.Framework.Scenes || Scene.TestBorderCross(val, Cardinals.S)) && !IsAttachmentCheckFull() && (!Scene.LoadingPrims)) { + if (m_rootPart.KeyframeMotion != null) + m_rootPart.KeyframeMotion.StartCrossingCheck(); + m_scene.CrossPrimGroupIntoNewRegion(val, this, true); } } @@ -578,6 +581,8 @@ namespace OpenSim.Region.Framework.Scenes childPa.Selected = value; } } + if (RootPart.KeyframeMotion != null) + RootPart.KeyframeMotion.Selected = value; } } @@ -1551,6 +1556,8 @@ namespace OpenSim.Region.Framework.Scenes newPart.DoPhysicsPropertyUpdate(originalPartPa.IsPhysical, true); } + if (part.KeyframeMotion != null) + newPart.KeyframeMotion = part.KeyframeMotion.Copy(dupe); } if (userExposed) @@ -1578,6 +1585,12 @@ namespace OpenSim.Region.Framework.Scenes public void ScriptSetPhysicsStatus(bool usePhysics) { + if (usePhysics) + { + if (RootPart.KeyframeMotion != null) + RootPart.KeyframeMotion.Stop(); + RootPart.KeyframeMotion = null; + } UpdatePrimFlags(RootPart.LocalId, usePhysics, IsTemporary, IsPhantom, IsVolumeDetect); } -- cgit v1.1