From 4350613f1d7cb6cd187f3cbd94d293a53e924381 Mon Sep 17 00:00:00 2001 From: Charles Krinke Date: Wed, 16 Jul 2008 03:07:54 +0000 Subject: Mantis#1746. Thank you kindly, nlin for pointing out that I needed to apply the patch a little better then last night for: Dot product operator in LSL_Types.cs incorrectly returns a component-wise vector multiplication; it should return a scalar dot product. Thanks to M. Igarashi for the patch. --- OpenSim/Region/ScriptEngine/Common/LSL_Types.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'OpenSim/Region/ScriptEngine') diff --git a/OpenSim/Region/ScriptEngine/Common/LSL_Types.cs b/OpenSim/Region/ScriptEngine/Common/LSL_Types.cs index eb13f45..3dfa711 100644 --- a/OpenSim/Region/ScriptEngine/Common/LSL_Types.cs +++ b/OpenSim/Region/ScriptEngine/Common/LSL_Types.cs @@ -141,9 +141,9 @@ namespace OpenSim.Region.ScriptEngine.Common return new Vector3(lhs.x - rhs.x, lhs.y - rhs.y, lhs.z - rhs.z); } - public static Vector3 operator *(Vector3 lhs, Vector3 rhs) + public static LSLFloat operator *(Vector3 lhs, Vector3 rhs) { - return new Vector3(lhs.x * rhs.x, lhs.y * rhs.y, lhs.z * rhs.z); + return Dot(lhs, rhs); } public static Vector3 operator %(Vector3 v1, Vector3 v2) -- cgit v1.1