From 63bf71023772ea9c54687c5006fcf6649eb1139f Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Thu, 1 Sep 2011 01:37:35 +0100 Subject: Fix issue with llGetTorque() where it would only ever return a zero vector. --- OpenSim/Region/Framework/Scenes/SceneObjectPart.cs | 9 --------- OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | 2 +- 2 files changed, 1 insertion(+), 10 deletions(-) (limited to 'OpenSim') diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs index 4e7504a..982c492 100644 --- a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs +++ b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs @@ -1536,15 +1536,6 @@ namespace OpenSim.Region.Framework.Scenes m_parentGroup.setAngularImpulse(impulse); } - public Vector3 GetTorque() - { - if (m_parentGroup != null) - { - m_parentGroup.GetTorque(); - } - return Vector3.Zero; - } - /// /// Apply physics to this part. /// diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs index dff7269..8d95546 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs @@ -2202,7 +2202,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api public LSL_Vector llGetTorque() { m_host.AddScriptLPS(1); - Vector3 torque = m_host.GetTorque(); + Vector3 torque = m_host.ParentGroup.GetTorque(); return new LSL_Vector(torque.X,torque.Y,torque.Z); } -- cgit v1.1