aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/ScenePresence.cs
diff options
context:
space:
mode:
authorMelanie2011-10-11 22:42:18 +0100
committerMelanie2011-10-11 22:42:18 +0100
commit652c59c0a9e7ac16127f0358e91fd216576c0ad0 (patch)
treee967460e6e83aa88bd49865af312b1b5738507fd /OpenSim/Region/Framework/Scenes/ScenePresence.cs
parentMerge commit '241e07d006fad1b54e088d8a9ddede0b98a1e800' into bigmerge (diff)
parentReinstate option to land an npc when it reaches a target. (diff)
downloadopensim-SC-652c59c0a9e7ac16127f0358e91fd216576c0ad0.zip
opensim-SC-652c59c0a9e7ac16127f0358e91fd216576c0ad0.tar.gz
opensim-SC-652c59c0a9e7ac16127f0358e91fd216576c0ad0.tar.bz2
opensim-SC-652c59c0a9e7ac16127f0358e91fd216576c0ad0.tar.xz
Merge commit 'd358125cac4e01194dae4b1f0bc9afc87e463f76' into bigmerge
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/ScenePresence.cs')
-rw-r--r--OpenSim/Region/Framework/Scenes/ScenePresence.cs11
1 files changed, 10 insertions, 1 deletions
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs
index 91052ec..09a8bb7 100644
--- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs
+++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs
@@ -236,6 +236,11 @@ namespace OpenSim.Region.Framework.Scenes
236 public Vector3 MoveToPositionTarget { get; private set; } 236 public Vector3 MoveToPositionTarget { get; private set; }
237 private Quaternion m_offsetRotation = new Quaternion(0.0f, 0.0f, 0.0f, 1.0f); 237 private Quaternion m_offsetRotation = new Quaternion(0.0f, 0.0f, 0.0f, 1.0f);
238 238
239 /// <summary>
240 /// Controls whether an avatar automatically moving to a target will land when it gets there (if flying).
241 /// </summary>
242 public bool LandAtTarget { get; private set; }
243
239 private bool m_followCamAuto; 244 private bool m_followCamAuto;
240 245
241 private int m_movementUpdateCount; 246 private int m_movementUpdateCount;
@@ -1829,7 +1834,10 @@ namespace OpenSim.Region.Framework.Scenes
1829 /// This is to allow movement to targets that are known to be on an elevated platform with a continuous path 1834 /// This is to allow movement to targets that are known to be on an elevated platform with a continuous path
1830 /// from start to finish. 1835 /// from start to finish.
1831 /// </param> 1836 /// </param>
1832 public void MoveToTarget(Vector3 pos, bool noFly) 1837 /// <param name="landAtTarget">
1838 /// If true and the avatar starts flying during the move then land at the target.
1839 /// </param>
1840 public void MoveToTarget(Vector3 pos, bool noFly, bool landAtTarget)
1833 { 1841 {
1834 m_log.DebugFormat( 1842 m_log.DebugFormat(
1835 "[SCENE PRESENCE]: Avatar {0} received request to move to position {1} in {2}", 1843 "[SCENE PRESENCE]: Avatar {0} received request to move to position {1} in {2}",
@@ -1868,6 +1876,7 @@ namespace OpenSim.Region.Framework.Scenes
1868 else if (pos.Z > terrainHeight) 1876 else if (pos.Z > terrainHeight)
1869 PhysicsActor.Flying = true; 1877 PhysicsActor.Flying = true;
1870 1878
1879 LandAtTarget = landAtTarget;
1871 MovingToTarget = true; 1880 MovingToTarget = true;
1872 MoveToPositionTarget = pos; 1881 MoveToPositionTarget = pos;
1873 1882