aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine/DotNetEngine
diff options
context:
space:
mode:
authorAdam Frisby2007-12-27 05:48:27 +0000
committerAdam Frisby2007-12-27 05:48:27 +0000
commit2cb222806b596b7233f30b2bab9eb7cca4d619d1 (patch)
treed4b3f25fd667a8fdd3063761a429aa797bf5fb5f /OpenSim/Region/ScriptEngine/DotNetEngine
parent* Added Sit Target persistence over sim restarts for mySQL and MonoSQLite. (diff)
downloadopensim-SC_OLD-2cb222806b596b7233f30b2bab9eb7cca4d619d1.zip
opensim-SC_OLD-2cb222806b596b7233f30b2bab9eb7cca4d619d1.tar.gz
opensim-SC_OLD-2cb222806b596b7233f30b2bab9eb7cca4d619d1.tar.bz2
opensim-SC_OLD-2cb222806b596b7233f30b2bab9eb7cca4d619d1.tar.xz
* Fixed compile issue caused by half-refactoring (sorrry!)
Diffstat (limited to 'OpenSim/Region/ScriptEngine/DotNetEngine')
-rw-r--r--OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/Server_API/LSL_BuiltIn_Commands.cs13
1 files changed, 12 insertions, 1 deletions
diff --git a/OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/Server_API/LSL_BuiltIn_Commands.cs b/OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/Server_API/LSL_BuiltIn_Commands.cs
index d4f8548..63b4773 100644
--- a/OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/Server_API/LSL_BuiltIn_Commands.cs
+++ b/OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/Server_API/LSL_BuiltIn_Commands.cs
@@ -2878,6 +2878,9 @@ namespace OpenSim.Region.ScriptEngine.DotNetEngine.Compiler
2878 // 2878 //
2879 public int osTerrainSetHeight(int x, int y, double val) 2879 public int osTerrainSetHeight(int x, int y, double val)
2880 { 2880 {
2881 if (x > 255 || x < 0 || y > 255 || y < 0)
2882 LSLError("osTerrainSetHeight: Coordinate out of bounds");
2883
2881 if (World.PermissionsMngr.CanTerraform(m_host.OwnerID, new LLVector3(x, y, 0))) 2884 if (World.PermissionsMngr.CanTerraform(m_host.OwnerID, new LLVector3(x, y, 0)))
2882 { 2885 {
2883 World.Terrain.Set(x, y, val); 2886 World.Terrain.Set(x, y, val);
@@ -2891,6 +2894,9 @@ namespace OpenSim.Region.ScriptEngine.DotNetEngine.Compiler
2891 2894
2892 public double osTerrainGetHeight(int x, int y) 2895 public double osTerrainGetHeight(int x, int y)
2893 { 2896 {
2897 if (x > 255 || x < 0 || y > 255 || y < 0)
2898 LSLError("osTerrainGetHeight: Coordinate out of bounds");
2899
2894 return World.Terrain.GetHeight(x, y); 2900 return World.Terrain.GetHeight(x, y);
2895 } 2901 }
2896 2902
@@ -2898,7 +2904,7 @@ namespace OpenSim.Region.ScriptEngine.DotNetEngine.Compiler
2898 { 2904 {
2899 if (World.PermissionsMngr.CanRestartSim(m_host.OwnerID)) 2905 if (World.PermissionsMngr.CanRestartSim(m_host.OwnerID))
2900 { 2906 {
2901 World.Restart((float)ms); 2907 World.Restart((float)seconds);
2902 return 1; 2908 return 1;
2903 } 2909 }
2904 else 2910 else
@@ -2936,5 +2942,10 @@ namespace OpenSim.Region.ScriptEngine.DotNetEngine.Compiler
2936 if (throwErrorOnNotImplemented) 2942 if (throwErrorOnNotImplemented)
2937 throw new NotImplementedException("Command not implemented: " + Command); 2943 throw new NotImplementedException("Command not implemented: " + Command);
2938 } 2944 }
2945
2946 private void LSLError(string msg)
2947 {
2948 throw new Exception("LSL Runtime Error: " + msg);
2949 }
2939 } 2950 }
2940} 2951}