aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs7
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneObjectPart.cs3
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs1
3 files changed, 11 insertions, 0 deletions
diff --git a/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs b/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs
index f41e89e..ee9961f 100644
--- a/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs
+++ b/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs
@@ -371,14 +371,19 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess
371 : objectGroup.AbsolutePosition.Y, 371 : objectGroup.AbsolutePosition.Y,
372 objectGroup.AbsolutePosition.Z); 372 objectGroup.AbsolutePosition.Z);
373 373
374 Quaternion inventoryStoredRotation = objectGroup.GroupRotation;
374 originalPositions[objectGroup.UUID] = objectGroup.AbsolutePosition; 375 originalPositions[objectGroup.UUID] = objectGroup.AbsolutePosition;
375 376
376 // Restore attachment data after trip through the sim 377 // Restore attachment data after trip through the sim
377 if (objectGroup.RootPart.AttachPoint > 0) 378 if (objectGroup.RootPart.AttachPoint > 0)
379 {
378 inventoryStoredPosition = objectGroup.RootPart.AttachOffset; 380 inventoryStoredPosition = objectGroup.RootPart.AttachOffset;
381 inventoryStoredRotation = objectGroup.RootPart.AttachRotation;
382 }
379 objectGroup.RootPart.Shape.State = objectGroup.RootPart.AttachPoint; 383 objectGroup.RootPart.Shape.State = objectGroup.RootPart.AttachPoint;
380 384
381 objectGroup.AbsolutePosition = inventoryStoredPosition; 385 objectGroup.AbsolutePosition = inventoryStoredPosition;
386 objectGroup.RootPart.RotationOffset = inventoryStoredRotation;
382 387
383 // Make sure all bits but the ones we want are clear 388 // Make sure all bits but the ones we want are clear
384 // on take. 389 // on take.
@@ -768,6 +773,7 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess
768 { 773 {
769 g.RootPart.AttachPoint = g.RootPart.Shape.State; 774 g.RootPart.AttachPoint = g.RootPart.Shape.State;
770 g.RootPart.AttachOffset = g.AbsolutePosition; 775 g.RootPart.AttachOffset = g.AbsolutePosition;
776 g.RootPart.AttachRotation = g.GroupRotation;
771 g.RootPart.Shape.State = 0; 777 g.RootPart.Shape.State = 0;
772 } 778 }
773 779
@@ -801,6 +807,7 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess
801 SceneObjectGroup g = SceneObjectSerializer.FromOriginalXmlFormat(n.OuterXml); 807 SceneObjectGroup g = SceneObjectSerializer.FromOriginalXmlFormat(n.OuterXml);
802 g.RootPart.AttachPoint = g.RootPart.Shape.State; 808 g.RootPart.AttachPoint = g.RootPart.Shape.State;
803 g.RootPart.AttachOffset = g.AbsolutePosition; 809 g.RootPart.AttachOffset = g.AbsolutePosition;
810 g.RootPart.AttachRotation = g.GroupRotation;
804 g.RootPart.Shape.State = 0; 811 g.RootPart.Shape.State = 0;
805 812
806 objlist.Add(g); 813 objlist.Add(g);
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
index b198ca7..b0bc188 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
@@ -197,6 +197,9 @@ namespace OpenSim.Region.Framework.Scenes
197 public Vector3 AttachOffset = Vector3.Zero; 197 public Vector3 AttachOffset = Vector3.Zero;
198 198
199 [XmlIgnore] 199 [XmlIgnore]
200 public Quaternion AttachRotation = Quaternion.Identity;
201
202 [XmlIgnore]
200 public int STATUS_ROTATE_X; 203 public int STATUS_ROTATE_X;
201 204
202 public int STATUS_ROTATE_Y; 205 public int STATUS_ROTATE_Y;
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs
index a2649ee..959046a 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs
@@ -812,6 +812,7 @@ namespace OpenSim.Region.Framework.Scenes
812 812
813 group.RootPart.AttachPoint = group.RootPart.Shape.State; 813 group.RootPart.AttachPoint = group.RootPart.Shape.State;
814 group.RootPart.AttachOffset = group.AbsolutePosition; 814 group.RootPart.AttachOffset = group.AbsolutePosition;
815 group.RootPart.AttachRotation = group.GroupRotation;
815 816
816 group.ResetIDs(); 817 group.ResetIDs();
817 818