From 54359ab17b7cfd1e0ad34a40cbb18435f415a89c Mon Sep 17 00:00:00 2001 From: Adam Frisby Date: Sat, 8 Mar 2008 21:49:26 +0000 Subject: * By popular demand, implemented "script terrain fill " --- OpenSim/Region/Environment/Modules/Terrain/TerrainModule.cs | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'OpenSim/Region') diff --git a/OpenSim/Region/Environment/Modules/Terrain/TerrainModule.cs b/OpenSim/Region/Environment/Modules/Terrain/TerrainModule.cs index 491d2e0..b58cce7 100644 --- a/OpenSim/Region/Environment/Modules/Terrain/TerrainModule.cs +++ b/OpenSim/Region/Environment/Modules/Terrain/TerrainModule.cs @@ -315,6 +315,7 @@ namespace OpenSim.Region.Environment.Modules.Terrain string command = args[1]; string param = args[2]; + int x, y; switch (command) { @@ -325,6 +326,11 @@ namespace OpenSim.Region.Environment.Modules.Terrain case "save": SaveToFile(param); break; + case "fill": + for (x = 0; x < m_channel.Width; x++) + for (y = 0; y < m_channel.Height; y++) + m_channel[x, y] = Double.Parse(param); + break; default: m_log.Warn("Unknown terrain command."); break; -- cgit v1.1