From e099d5b013610df0e2288e66a14cd7ad361ee480 Mon Sep 17 00:00:00 2001 From: Teravus Ovares Date: Fri, 6 Jun 2008 14:33:01 +0000 Subject: * How tall are you? Certainly not 127 meters! --- OpenSim/Region/Environment/Scenes/ScenePresence.cs | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'OpenSim/Region') diff --git a/OpenSim/Region/Environment/Scenes/ScenePresence.cs b/OpenSim/Region/Environment/Scenes/ScenePresence.cs index ec3137f..99b2085 100644 --- a/OpenSim/Region/Environment/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Environment/Scenes/ScenePresence.cs @@ -592,9 +592,16 @@ namespace OpenSim.Region.Environment.Scenes // Name, UUID, m_scene.RegionInfo.RegionName); m_isChildAgent = false; + + float localAVHeight = 1.56f; + if (m_avHeight != 127.0f) + { + localAVHeight = m_avHeight; + } + float posZLimit = (float)m_scene.GetLandHeight((int)pos.X, (int)pos.Y); - float newPosZ = posZLimit + m_avHeight; - if (posZLimit >= (pos.Z -(m_avHeight/2)) && !(Single.IsInfinity(newPosZ) || Single.IsNaN(newPosZ))) + float newPosZ = posZLimit + localAVHeight; + if (posZLimit >= (pos.Z - (localAVHeight / 2)) && !(Single.IsInfinity(newPosZ) || Single.IsNaN(newPosZ))) { pos.Z = newPosZ; } -- cgit v1.1