Fix issue with llGetTorque() where it would only ever return a zero vector.
parent
095b3e5756
commit
63bf710237
|
@ -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;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Apply physics to this part.
|
||||
/// </summary>
|
||||
|
|
|
@ -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);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue