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.cs39
1 files changed, 39 insertions, 0 deletions
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs
index 38a0cff..ab7abbe 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs
@@ -1726,6 +1726,45 @@ namespace OpenSim.Region.Framework.Scenes
1726 } 1726 }
1727 } 1727 }
1728 1728
1729 public void rotLookAt(Quaternion target, float strength, float damping)
1730 {
1731 SceneObjectPart rootpart = m_rootPart;
1732 if (rootpart != null)
1733 {
1734 if (IsAttachment)
1735 {
1736 /*
1737 ScenePresence avatar = m_scene.GetScenePresence(rootpart.AttachedAvatar);
1738 if (avatar != null)
1739 {
1740 Rotate the Av?
1741 } */
1742 }
1743 else
1744 {
1745 if (rootpart.PhysActor != null)
1746 {
1747 rootpart.PhysActor.APIDTarget = new Quaternion(target.X, target.Y, target.Z, target.W);
1748 rootpart.PhysActor.APIDStrength = strength;
1749 rootpart.PhysActor.APIDDamping = damping;
1750 rootpart.PhysActor.APIDActive = true;
1751 }
1752 }
1753 }
1754 }
1755 public void stopLookAt()
1756 {
1757 SceneObjectPart rootpart = m_rootPart;
1758 if (rootpart != null)
1759 {
1760 if (rootpart.PhysActor != null)
1761 {
1762 rootpart.PhysActor.APIDActive = false;
1763 }
1764 }
1765
1766 }
1767
1729 /// <summary> 1768 /// <summary>
1730 /// Uses a PID to attempt to clamp the object on the Z axis at the given height over tau seconds. 1769 /// Uses a PID to attempt to clamp the object on the Z axis at the given height over tau seconds.
1731 /// </summary> 1770 /// </summary>