aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs')
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs38
1 files changed, 19 insertions, 19 deletions
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs
index a2c3c07..6c1f3c2 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs
@@ -1563,23 +1563,6 @@ namespace OpenSim.Region.Framework.Scenes
1563 if (userExposed) 1563 if (userExposed)
1564 dupe.m_rootPart.TrimPermissions(); 1564 dupe.m_rootPart.TrimPermissions();
1565 1565
1566 /// may need to create a new Physics actor.
1567 if (dupe.RootPart.PhysActor != null && userExposed)
1568 {
1569 PrimitiveBaseShape pbs = dupe.RootPart.Shape;
1570
1571 dupe.RootPart.PhysActor = m_scene.PhysicsScene.AddPrimShape(
1572 dupe.RootPart.Name,
1573 pbs,
1574 dupe.RootPart.AbsolutePosition,
1575 dupe.RootPart.Scale,
1576 dupe.RootPart.RotationOffset,
1577 dupe.RootPart.PhysActor.IsPhysical);
1578
1579 dupe.RootPart.PhysActor.LocalID = dupe.RootPart.LocalId;
1580 dupe.RootPart.DoPhysicsPropertyUpdate(dupe.RootPart.PhysActor.IsPhysical, true);
1581 }
1582
1583 List<SceneObjectPart> partList; 1566 List<SceneObjectPart> partList;
1584 1567
1585 lock (m_parts) 1568 lock (m_parts)
@@ -1598,11 +1581,28 @@ namespace OpenSim.Region.Framework.Scenes
1598 if (part.UUID != m_rootPart.UUID) 1581 if (part.UUID != m_rootPart.UUID)
1599 { 1582 {
1600 SceneObjectPart newPart = dupe.CopyPart(part, OwnerID, GroupID, userExposed); 1583 SceneObjectPart newPart = dupe.CopyPart(part, OwnerID, GroupID, userExposed);
1601
1602 newPart.LinkNum = part.LinkNum; 1584 newPart.LinkNum = part.LinkNum;
1603 } 1585 }
1604 }
1605 1586
1587 // Need to duplicate the physics actor as well
1588 if (part.PhysActor != null && userExposed)
1589 {
1590 PrimitiveBaseShape pbs = part.Shape;
1591
1592 part.PhysActor
1593 = m_scene.PhysicsScene.AddPrimShape(
1594 part.Name,
1595 pbs,
1596 part.AbsolutePosition,
1597 part.Scale,
1598 part.RotationOffset,
1599 part.PhysActor.IsPhysical);
1600
1601 part.PhysActor.LocalID = part.LocalId;
1602 part.DoPhysicsPropertyUpdate(part.PhysActor.IsPhysical, true);
1603 }
1604 }
1605
1606 if (userExposed) 1606 if (userExposed)
1607 { 1607 {
1608 dupe.UpdateParentIDs(); 1608 dupe.UpdateParentIDs();