aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
diff options
context:
space:
mode:
authorMelanie2013-06-06 03:03:05 +0100
committerMelanie2013-06-06 03:03:05 +0100
commit81ad9255b5f44d988bf37cfaf6dc59b05fd744b7 (patch)
tree201e5f412c3f12e0f94424362fffb0c635343af3 /OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
parentCommitting Avination's Keyframe module. This is not hooked up yet and will do... (diff)
downloadopensim-SC_OLD-81ad9255b5f44d988bf37cfaf6dc59b05fd744b7.zip
opensim-SC_OLD-81ad9255b5f44d988bf37cfaf6dc59b05fd744b7.tar.gz
opensim-SC_OLD-81ad9255b5f44d988bf37cfaf6dc59b05fd744b7.tar.bz2
opensim-SC_OLD-81ad9255b5f44d988bf37cfaf6dc59b05fd744b7.tar.xz
Hook up Keyframe motion to almost everything. Failing to cross a sim border
may yield unexpected results in some cases. No database persistence yet,
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/SceneObjectPart.cs')
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneObjectPart.cs15
1 files changed, 15 insertions, 0 deletions
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
index ea8c3c5..ff3f738 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
@@ -354,6 +354,13 @@ namespace OpenSim.Region.Framework.Scenes
354 private UUID m_collisionSound; 354 private UUID m_collisionSound;
355 private float m_collisionSoundVolume; 355 private float m_collisionSoundVolume;
356 356
357 private KeyframeMotion m_keyframeMotion = null;
358
359 public KeyframeMotion KeyframeMotion
360 {
361 get; set;
362 }
363
357 #endregion Fields 364 #endregion Fields
358 365
359// ~SceneObjectPart() 366// ~SceneObjectPart()
@@ -1799,6 +1806,8 @@ namespace OpenSim.Region.Framework.Scenes
1799 Array.Copy(Shape.ExtraParams, extraP, extraP.Length); 1806 Array.Copy(Shape.ExtraParams, extraP, extraP.Length);
1800 dupe.Shape.ExtraParams = extraP; 1807 dupe.Shape.ExtraParams = extraP;
1801 1808
1809 // safeguard actual copy is done in sog.copy
1810 dupe.KeyframeMotion = null;
1802 dupe.PayPrice = (int[])PayPrice.Clone(); 1811 dupe.PayPrice = (int[])PayPrice.Clone();
1803 1812
1804 dupe.DynAttrs.CopyFrom(DynAttrs); 1813 dupe.DynAttrs.CopyFrom(DynAttrs);
@@ -2001,6 +2010,9 @@ namespace OpenSim.Region.Framework.Scenes
2001 { 2010 {
2002 if (UsePhysics) 2011 if (UsePhysics)
2003 { 2012 {
2013 if (ParentGroup.RootPart.KeyframeMotion != null)
2014 ParentGroup.RootPart.KeyframeMotion.Stop();
2015 ParentGroup.RootPart.KeyframeMotion = null;
2004 ParentGroup.Scene.AddPhysicalPrim(1); 2016 ParentGroup.Scene.AddPhysicalPrim(1);
2005 2017
2006 pa.OnRequestTerseUpdate += PhysicsRequestingTerseUpdate; 2018 pa.OnRequestTerseUpdate += PhysicsRequestingTerseUpdate;
@@ -4327,6 +4339,9 @@ namespace OpenSim.Region.Framework.Scenes
4327 4339
4328 if (isPhysical) 4340 if (isPhysical)
4329 { 4341 {
4342 if (ParentGroup.RootPart.KeyframeMotion != null)
4343 ParentGroup.RootPart.KeyframeMotion.Stop();
4344 ParentGroup.RootPart.KeyframeMotion = null;
4330 ParentGroup.Scene.AddPhysicalPrim(1); 4345 ParentGroup.Scene.AddPhysicalPrim(1);
4331 4346
4332 pa.OnRequestTerseUpdate += PhysicsRequestingTerseUpdate; 4347 pa.OnRequestTerseUpdate += PhysicsRequestingTerseUpdate;