From 54e1988d85c9e6afb4bd3c22480b4c4cd4f08191 Mon Sep 17 00:00:00 2001 From: Homer Horwitz Date: Sat, 13 Sep 2008 21:54:07 +0000 Subject: Fixing a bug in DNE which caused the face-colors to be inverted when set via script. --- .../Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs b/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs index 1ec88f8..f2add80 100644 --- a/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs +++ b/OpenSim/Region/ScriptEngine/Common/LSL_BuiltIn_Commands.cs @@ -1181,9 +1181,9 @@ namespace OpenSim.Region.ScriptEngine.Common if (face > -1) { texcolor = tex.CreateFace((uint)face).RGBA; - texcolor.R = (float)Math.Abs(color.x - 1); - texcolor.G = (float)Math.Abs(color.y - 1); - texcolor.B = (float)Math.Abs(color.z - 1); + texcolor.R = (float)color.x; + texcolor.G = (float)color.y; + texcolor.B = (float)color.z; tex.FaceTextures[face].RGBA = texcolor; part.UpdateTexture(tex); return; @@ -1195,15 +1195,15 @@ namespace OpenSim.Region.ScriptEngine.Common if (tex.FaceTextures[i] != null) { texcolor = tex.FaceTextures[i].RGBA; - texcolor.R = (float)Math.Abs(color.x - 1); - texcolor.G = (float)Math.Abs(color.y - 1); - texcolor.B = (float)Math.Abs(color.z - 1); + texcolor.R = (float)color.x; + texcolor.G = (float)color.y; + texcolor.B = (float)color.z; tex.FaceTextures[i].RGBA = texcolor; } texcolor = tex.DefaultTexture.RGBA; - texcolor.R = (float)Math.Abs(color.x - 1); - texcolor.G = (float)Math.Abs(color.y - 1); - texcolor.B = (float)Math.Abs(color.z - 1); + texcolor.R = (float)color.x; + texcolor.G = (float)color.y; + texcolor.B = (float)color.z; tex.DefaultTexture.RGBA = texcolor; } part.UpdateTexture(tex); -- cgit v1.1