diff --git a/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs b/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs index 6eb8749386..a03d8a62eb 100644 --- a/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs +++ b/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs @@ -6869,19 +6869,22 @@ namespace OpenSim.Region.ScriptEngine.Common param.Add(o.ToString()); } + LLVector3 position = m_host.AbsolutePosition; + LLVector3 velocity = m_host.Velocity; + LLQuaternion rotation = m_host.RotationOffset; + ScenePresence scenePresence = World.GetScenePresence(m_host.ObjectOwner); + RegionInfo regionInfo = World.RegionInfo; + Dictionary httpHeaders = new Dictionary(); httpHeaders["X-SecondLife-Shard"] = "OpenSim"; httpHeaders["X-SecondLife-Object-Name"] = m_host.Name; httpHeaders["X-SecondLife-Object-Key"] = m_itemID.ToString(); - httpHeaders["X-SecondLife-Region"] = World.RegionInfo.RegionName; - httpHeaders["X-SecondLife-Local-Position"] = m_host.AbsolutePosition.ToString(); - httpHeaders["X-SecondLife-Local-Velocity"] = m_host.Velocity.ToString(); - httpHeaders["X-SecondLife-Local-Rotation"] = m_host.RotationOffset.ToString(); - - ScenePresence scenePresence = World.GetScenePresence(m_host.ObjectOwner); - httpHeaders["X-SecondLife-Owner-Name"] = scenePresence == null ? string.Empty : scenePresence.Name; - + httpHeaders["X-SecondLife-Region"] = string.Format("{0} ({1}, {2})", regionInfo.RegionName, regionInfo.RegionLocX, regionInfo.RegionLocY); + httpHeaders["X-SecondLife-Local-Position"] = string.Format("({0:0.000000}, {1:0.000000}, {2:0.000000})", position.X, position.Y, position.Z); + httpHeaders["X-SecondLife-Local-Velocity"] = string.Format("({0:0.000000}, {1:0.000000}, {2:0.000000})", velocity.X, velocity.Y, velocity.Z); + httpHeaders["X-SecondLife-Local-Rotation"] = string.Format("({0:0.000000}, {1:0.000000}, {2:0.000000}, {3:0.000000})", rotation.X, rotation.Y, rotation.Z, rotation.W); + httpHeaders["X-SecondLife-Owner-Name"] = scenePresence == null ? string.Empty : scenePresence.ControllingClient.Name; httpHeaders["X-SecondLife-Owner-Key"] = m_host.ObjectOwner.ToString(); LLUUID reqID = httpScriptMod. diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs index 507a1327fd..bb292f194d 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs @@ -6649,19 +6649,22 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api param.Add(o.ToString()); } + LLVector3 position = m_host.AbsolutePosition; + LLVector3 velocity = m_host.Velocity; + LLQuaternion rotation = m_host.RotationOffset; + ScenePresence scenePresence = World.GetScenePresence(m_host.ObjectOwner); + RegionInfo regionInfo = World.RegionInfo; + Dictionary httpHeaders = new Dictionary(); httpHeaders["X-SecondLife-Shard"] = "OpenSim"; httpHeaders["X-SecondLife-Object-Name"] = m_host.Name; httpHeaders["X-SecondLife-Object-Key"] = m_itemID.ToString(); - httpHeaders["X-SecondLife-Region"] = World.RegionInfo.RegionName; - httpHeaders["X-SecondLife-Local-Position"] = m_host.AbsolutePosition.ToString(); - httpHeaders["X-SecondLife-Local-Velocity"] = m_host.Velocity.ToString(); - httpHeaders["X-SecondLife-Local-Rotation"] = m_host.RotationOffset.ToString(); - - ScenePresence scenePresence = World.GetScenePresence(m_host.ObjectOwner); - httpHeaders["X-SecondLife-Owner-Name"] = scenePresence == null ? string.Empty : scenePresence.Name; - + httpHeaders["X-SecondLife-Region"] = string.Format("{0} ({1}, {2})", regionInfo.RegionName, regionInfo.RegionLocX, regionInfo.RegionLocY); + httpHeaders["X-SecondLife-Local-Position"] = string.Format("({0:0.000000}, {1:0.000000}, {2:0.000000})", position.X, position.Y, position.Z); + httpHeaders["X-SecondLife-Local-Velocity"] = string.Format("({0:0.000000}, {1:0.000000}, {2:0.000000})", velocity.X, velocity.Y, velocity.Z); + httpHeaders["X-SecondLife-Local-Rotation"] = string.Format("({0:0.000000}, {1:0.000000}, {2:0.000000}, {3:0.000000})", rotation.X, rotation.Y, rotation.Z, rotation.W); + httpHeaders["X-SecondLife-Owner-Name"] = scenePresence == null ? string.Empty : scenePresence.ControllingClient.Name; httpHeaders["X-SecondLife-Owner-Key"] = m_host.ObjectOwner.ToString(); LLUUID reqID = httpScriptMod.