From 6554c7bac53f60caad21623670ae9e595e38acb3 Mon Sep 17 00:00:00 2001 From: mingchen Date: Fri, 25 Jul 2008 03:39:38 +0000 Subject: *Fixes #0001818: typecast string to float --- OpenSim/Region/ScriptEngine/Common/LSL_Types.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/OpenSim/Region/ScriptEngine/Common/LSL_Types.cs b/OpenSim/Region/ScriptEngine/Common/LSL_Types.cs index 7274fa5..9bde177 100644 --- a/OpenSim/Region/ScriptEngine/Common/LSL_Types.cs +++ b/OpenSim/Region/ScriptEngine/Common/LSL_Types.cs @@ -1189,6 +1189,10 @@ namespace OpenSim.Region.ScriptEngine.Common { return new Vector3(s.m_string); } + public static implicit operator LSLFloat(LSLString s) + { + return new LSLFloat(Convert.ToDouble(s.m_string)); + } #endregion -- cgit v1.1