diff options
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Common')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Common/LSL_Types.cs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/OpenSim/Region/ScriptEngine/Common/LSL_Types.cs b/OpenSim/Region/ScriptEngine/Common/LSL_Types.cs index be790d6..7274fa5 100644 --- a/OpenSim/Region/ScriptEngine/Common/LSL_Types.cs +++ b/OpenSim/Region/ScriptEngine/Common/LSL_Types.cs | |||
@@ -1422,6 +1422,16 @@ namespace OpenSim.Region.ScriptEngine.Common | |||
1422 | 1422 | ||
1423 | #region Operators | 1423 | #region Operators |
1424 | 1424 | ||
1425 | static public implicit operator int(LSLFloat f) | ||
1426 | { | ||
1427 | return (int)f.value; | ||
1428 | } | ||
1429 | |||
1430 | static public implicit operator uint(LSLFloat f) | ||
1431 | { | ||
1432 | return (uint) Math.Abs(f.value); | ||
1433 | } | ||
1434 | |||
1425 | static public implicit operator Boolean(LSLFloat f) | 1435 | static public implicit operator Boolean(LSLFloat f) |
1426 | { | 1436 | { |
1427 | if (f.value == 0.0) | 1437 | if (f.value == 0.0) |