aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment/Modules/World/Terrain/PaintBrushes/RevertSphere.cs
diff options
context:
space:
mode:
authorCharles Krinke2008-10-06 00:58:43 +0000
committerCharles Krinke2008-10-06 00:58:43 +0000
commite575ef7ad2245aad17f57273f6bd7b774f99f057 (patch)
treea85fd727bac7f3d39259df3aaea6c93f3f32ba05 /OpenSim/Region/Environment/Modules/World/Terrain/PaintBrushes/RevertSphere.cs
parentMantis#2336. Thank you kindly, Ralphos for a patch that: (diff)
downloadopensim-SC_OLD-e575ef7ad2245aad17f57273f6bd7b774f99f057.zip
opensim-SC_OLD-e575ef7ad2245aad17f57273f6bd7b774f99f057.tar.gz
opensim-SC_OLD-e575ef7ad2245aad17f57273f6bd7b774f99f057.tar.bz2
opensim-SC_OLD-e575ef7ad2245aad17f57273f6bd7b774f99f057.tar.xz
Revert r6697 patch as the build fails.
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/Environment/Modules/World/Terrain/PaintBrushes/RevertSphere.cs9
1 files changed, 7 insertions, 2 deletions
diff --git a/OpenSim/Region/Environment/Modules/World/Terrain/PaintBrushes/RevertSphere.cs b/OpenSim/Region/Environment/Modules/World/Terrain/PaintBrushes/RevertSphere.cs
index d3a1d3d..7a1ec72 100644
--- a/OpenSim/Region/Environment/Modules/World/Terrain/PaintBrushes/RevertSphere.cs
+++ b/OpenSim/Region/Environment/Modules/World/Terrain/PaintBrushes/RevertSphere.cs
@@ -41,7 +41,7 @@ namespace OpenSim.Region.Environment.Modules.World.Terrain.PaintBrushes
41 41
42 #region ITerrainPaintableEffect Members 42 #region ITerrainPaintableEffect Members
43 43
44 public void PaintEffect(ITerrainChannel map, bool[,] mask, double rx, double ry, double rz, double strength, double duration) 44 public void PaintEffect(ITerrainChannel map, double rx, double ry, double strength, double duration)
45 { 45 {
46 strength = TerrainUtil.MetersToSphericalStrength(strength); 46 strength = TerrainUtil.MetersToSphericalStrength(strength);
47 duration = 0.03; //MCP Should be read from ini file 47 duration = 0.03; //MCP Should be read from ini file
@@ -54,10 +54,15 @@ namespace OpenSim.Region.Environment.Modules.World.Terrain.PaintBrushes
54 int x; 54 int x;
55 for (x = 0; x < map.Width; x++) 55 for (x = 0; x < map.Width; x++)
56 { 56 {
57 // Skip everything unlikely to be affected
58 if (Math.Abs(x - rx) > strength * 1.1)
59 continue;
60
57 int y; 61 int y;
58 for (y = 0; y < map.Height; y++) 62 for (y = 0; y < map.Height; y++)
59 { 63 {
60 if (!mask[x,y]) 64 // Skip everything unlikely to be affected
65 if (Math.Abs(y - ry) > strength * 1.1)
61 continue; 66 continue;
62 67
63 // Calculate a sphere and add it to the heighmap 68 // Calculate a sphere and add it to the heighmap