diff options
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Shared')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs index 5c6d382..7e57603 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | |||
@@ -6889,10 +6889,15 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
6889 | if (cut.y > 1f) | 6889 | if (cut.y > 1f) |
6890 | { | 6890 | { |
6891 | cut.y = 1f; | 6891 | cut.y = 1f; |
6892 | } | 6892 | } |
6893 | if (cut.y - cut.x < 0.05f) | 6893 | if (cut.y - cut.x < 0.05f) |
6894 | { | 6894 | { |
6895 | cut.x = cut.y - 0.05f; | 6895 | cut.x = cut.y - 0.05f; |
6896 | if (cut.x < 0.0f) | ||
6897 | { | ||
6898 | cut.x = 0.0f; | ||
6899 | cut.y = 0.05f; | ||
6900 | } | ||
6896 | } | 6901 | } |
6897 | shapeBlock.ProfileBegin = (ushort)(50000 * cut.x); | 6902 | shapeBlock.ProfileBegin = (ushort)(50000 * cut.x); |
6898 | shapeBlock.ProfileEnd = (ushort)(50000 * (1 - cut.y)); | 6903 | shapeBlock.ProfileEnd = (ushort)(50000 * (1 - cut.y)); |
@@ -7097,9 +7102,14 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
7097 | { | 7102 | { |
7098 | profilecut.y = 1f; | 7103 | profilecut.y = 1f; |
7099 | } | 7104 | } |
7100 | if (profilecut.y - cut.x < 0.05f) | 7105 | if (profilecut.y - profilecut.x < 0.05f) |
7101 | { | 7106 | { |
7102 | profilecut.x = cut.y - 0.05f; | 7107 | profilecut.x = profilecut.y - 0.05f; |
7108 | if (profilecut.x < 0.0f) | ||
7109 | { | ||
7110 | profilecut.x = 0.0f; | ||
7111 | profilecut.y = 0.05f; | ||
7112 | } | ||
7103 | } | 7113 | } |
7104 | shapeBlock.ProfileBegin = (ushort)(50000 * profilecut.x); | 7114 | shapeBlock.ProfileBegin = (ushort)(50000 * profilecut.x); |
7105 | shapeBlock.ProfileEnd = (ushort)(50000 * (1 - profilecut.y)); | 7115 | shapeBlock.ProfileEnd = (ushort)(50000 * (1 - profilecut.y)); |