From 577064fb9dfa2fa3429e3d3408e055b44636655c Mon Sep 17 00:00:00 2001
From: Justin Clarke Casey
Date: Wed, 4 Feb 2009 20:37:20 +0000
Subject: * minor: remove deprecated and unused terrain method from
SceneManager * other minor tidy up
---
OpenSim/Region/Application/OpenSim.cs | 7 +++++--
OpenSim/Region/Environment/Scenes/SceneManager.cs | 25 ++++++++---------------
2 files changed, 14 insertions(+), 18 deletions(-)
(limited to 'OpenSim')
diff --git a/OpenSim/Region/Application/OpenSim.cs b/OpenSim/Region/Application/OpenSim.cs
index 802adcd..ac6a5c1 100644
--- a/OpenSim/Region/Application/OpenSim.cs
+++ b/OpenSim/Region/Application/OpenSim.cs
@@ -1085,14 +1085,16 @@ namespace OpenSim
///
/// Runs the best matching plugin command
- ///
- /// returns true if a match was found, false otherwise.
///
+ ///
+ ///
+ /// true if a match was found, false otherwise
public bool RunPluginCommands(string cmd, string[] withParams)
{
ConsolePluginCommand bestMatch = null;
int bestLength = 0;
String cmdWithParams = cmd + " " + String.Join(" ",withParams);
+
foreach (ConsolePluginCommand cmdinfo in m_PluginCommandInfos)
{
int matchLen = cmdinfo.matchLength(cmdWithParams);
@@ -1102,6 +1104,7 @@ namespace OpenSim
bestLength = matchLen;
}
}
+
if (bestMatch == null) return false;
bestMatch.Run(cmd,withParams);//.Substring(bestLength));
return true;
diff --git a/OpenSim/Region/Environment/Scenes/SceneManager.cs b/OpenSim/Region/Environment/Scenes/SceneManager.cs
index 884bd79..b28eef2 100644
--- a/OpenSim/Region/Environment/Scenes/SceneManager.cs
+++ b/OpenSim/Region/Environment/Scenes/SceneManager.cs
@@ -264,13 +264,6 @@ namespace OpenSim.Region.Environment.Scenes
CurrentOrFirstScene.Heightmap.LoadFromXmlString(mapData);
}
- [Obsolete("TODO: Remove this warning by 0.7")]
- public bool RunTerrainCmdOnCurrentScene(string[] cmdparams, ref string result)
- {
- m_log.Warn("DEPRECATED: The terrain engine has been replaced with a new terrain plugin module. Please type 'plugin terrain help' for new commands.");
- return false;
- }
-
public void SendCommandToPluginModules(string[] cmdparams)
{
ForEachCurrentScene(delegate(Scene scene) { scene.SendCommandToPlugins(cmdparams); });
@@ -377,6 +370,7 @@ namespace OpenSim.Region.Environment.Scenes
return true;
}
}
+
scene = null;
return false;
}
@@ -392,6 +386,7 @@ namespace OpenSim.Region.Environment.Scenes
return true;
}
}
+
scene = null;
return false;
}
@@ -407,6 +402,7 @@ namespace OpenSim.Region.Environment.Scenes
return true;
}
}
+
scene = null;
return false;
}
@@ -602,18 +598,18 @@ namespace OpenSim.Region.Environment.Scenes
}
#endregion
- int entries_per_thread = (assetRequestList.Count/threads) + 1;
+ int entries_per_thread = (assetRequestList.Count / threads) + 1;
UUID[] arrAssetRequestList = assetRequestList.ToArray();
List arrvalus = new List();
//split into separate arrays
- for (int j=0;j val = new List();
- for (int k=j*entries_per_thread; k < ((j+1)* entries_per_thread);k++)
+ for (int k = j * entries_per_thread; k < ((j + 1) * entries_per_thread); k++)
{
if (k < arrAssetRequestList.Length)
{
@@ -624,7 +620,7 @@ namespace OpenSim.Region.Environment.Scenes
arrvalus.Add(val.ToArray());
}
- for (int l=0;l