diff options
Diffstat (limited to 'OpenSim/Region/CoreModules/World/Terrain/FloodBrushes/SmoothArea.cs')
-rw-r--r-- | OpenSim/Region/CoreModules/World/Terrain/FloodBrushes/SmoothArea.cs | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/OpenSim/Region/CoreModules/World/Terrain/FloodBrushes/SmoothArea.cs b/OpenSim/Region/CoreModules/World/Terrain/FloodBrushes/SmoothArea.cs index 6b07747..6c0d60d 100644 --- a/OpenSim/Region/CoreModules/World/Terrain/FloodBrushes/SmoothArea.cs +++ b/OpenSim/Region/CoreModules/World/Terrain/FloodBrushes/SmoothArea.cs | |||
@@ -33,16 +33,17 @@ namespace OpenSim.Region.CoreModules.World.Terrain.FloodBrushes | |||
33 | { | 33 | { |
34 | #region ITerrainFloodEffect Members | 34 | #region ITerrainFloodEffect Members |
35 | 35 | ||
36 | public void FloodEffect(ITerrainChannel map, bool[,] fillArea, double strength) | 36 | public void FloodEffect(ITerrainChannel map, bool[,] fillArea, double strength, |
37 | int startX, int endX, int startY, int endY) | ||
37 | { | 38 | { |
38 | double area = strength; | 39 | double area = strength; |
39 | double step = strength / 4.0; | 40 | double step = strength / 4.0; |
40 | 41 | ||
41 | double[,] manipulate = new double[map.Width,map.Height]; | 42 | double[,] manipulate = new double[map.Width,map.Height]; |
42 | int x, y; | 43 | int x, y; |
43 | for (x = 0; x < map.Width; x++) | 44 | for (x = startX; x <= endX; x++) |
44 | { | 45 | { |
45 | for (y = 0; y < map.Height; y++) | 46 | for (y = startY; y <= endY; y++) |
46 | { | 47 | { |
47 | if (!fillArea[x, y]) | 48 | if (!fillArea[x, y]) |
48 | continue; | 49 | continue; |
@@ -64,9 +65,9 @@ namespace OpenSim.Region.CoreModules.World.Terrain.FloodBrushes | |||
64 | manipulate[x, y] = average / avgsteps; | 65 | manipulate[x, y] = average / avgsteps; |
65 | } | 66 | } |
66 | } | 67 | } |
67 | for (x = 0; x < map.Width; x++) | 68 | for (x = startX; x <= endX; x++) |
68 | { | 69 | { |
69 | for (y = 0; y < map.Height; y++) | 70 | for (y = startY; y <= endY; y++) |
70 | { | 71 | { |
71 | if (!fillArea[x, y]) | 72 | if (!fillArea[x, y]) |
72 | continue; | 73 | continue; |