diff options
author | Melanie | 2012-07-05 22:17:39 +0100 |
---|---|---|
committer | Melanie | 2012-07-05 22:17:39 +0100 |
commit | 5776351f6abd4ca8cca7344b26ab989425c67687 (patch) | |
tree | fe0c0355ceb25db47125525b9b72d2077cc3c29f /OpenSim/Region/CoreModules | |
parent | Merge branch 'master' into careminster (diff) | |
parent | minor: add client name to various login service log messages to disambiguate ... (diff) | |
download | opensim-SC-5776351f6abd4ca8cca7344b26ab989425c67687.zip opensim-SC-5776351f6abd4ca8cca7344b26ab989425c67687.tar.gz opensim-SC-5776351f6abd4ca8cca7344b26ab989425c67687.tar.bz2 opensim-SC-5776351f6abd4ca8cca7344b26ab989425c67687.tar.xz |
Merge branch 'master' into careminster
Conflicts:
OpenSim/Region/Framework/Scenes/Scene.cs
OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
Diffstat (limited to 'OpenSim/Region/CoreModules')
3 files changed, 37 insertions, 3 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/Attachments/Tests/AttachmentsModuleTests.cs b/OpenSim/Region/CoreModules/Avatar/Attachments/Tests/AttachmentsModuleTests.cs index df99d0c..2eb0ac5 100644 --- a/OpenSim/Region/CoreModules/Avatar/Attachments/Tests/AttachmentsModuleTests.cs +++ b/OpenSim/Region/CoreModules/Avatar/Attachments/Tests/AttachmentsModuleTests.cs | |||
@@ -122,7 +122,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments.Tests | |||
122 | 122 | ||
123 | string attName = "att"; | 123 | string attName = "att"; |
124 | 124 | ||
125 | SceneObjectGroup so = SceneHelpers.AddSceneObject(scene, attName, sp.UUID).ParentGroup; | 125 | SceneObjectGroup so = SceneHelpers.AddSceneObject(scene, attName, sp.UUID); |
126 | 126 | ||
127 | scene.AttachmentsModule.AttachObject(sp, so, (uint)AttachmentPoint.Chest, false, false); | 127 | scene.AttachmentsModule.AttachObject(sp, so, (uint)AttachmentPoint.Chest, false, false); |
128 | 128 | ||
diff --git a/OpenSim/Region/CoreModules/World/Media/Moap/Tests/MoapTests.cs b/OpenSim/Region/CoreModules/World/Media/Moap/Tests/MoapTests.cs index 0545250..396095a 100644 --- a/OpenSim/Region/CoreModules/World/Media/Moap/Tests/MoapTests.cs +++ b/OpenSim/Region/CoreModules/World/Media/Moap/Tests/MoapTests.cs | |||
@@ -63,7 +63,7 @@ namespace OpenSim.Region.CoreModules.World.Media.Moap.Tests | |||
63 | TestHelpers.InMethod(); | 63 | TestHelpers.InMethod(); |
64 | // log4net.Config.XmlConfigurator.Configure(); | 64 | // log4net.Config.XmlConfigurator.Configure(); |
65 | 65 | ||
66 | SceneObjectPart part = SceneHelpers.AddSceneObject(m_scene); | 66 | SceneObjectPart part = SceneHelpers.AddSceneObject(m_scene).RootPart; |
67 | MediaEntry me = new MediaEntry(); | 67 | MediaEntry me = new MediaEntry(); |
68 | 68 | ||
69 | m_module.SetMediaEntry(part, 1, me); | 69 | m_module.SetMediaEntry(part, 1, me); |
@@ -88,7 +88,7 @@ namespace OpenSim.Region.CoreModules.World.Media.Moap.Tests | |||
88 | 88 | ||
89 | string homeUrl = "opensimulator.org"; | 89 | string homeUrl = "opensimulator.org"; |
90 | 90 | ||
91 | SceneObjectPart part = SceneHelpers.AddSceneObject(m_scene); | 91 | SceneObjectPart part = SceneHelpers.AddSceneObject(m_scene).RootPart; |
92 | MediaEntry me = new MediaEntry() { HomeURL = homeUrl }; | 92 | MediaEntry me = new MediaEntry() { HomeURL = homeUrl }; |
93 | 93 | ||
94 | m_module.SetMediaEntry(part, 1, me); | 94 | m_module.SetMediaEntry(part, 1, me); |
diff --git a/OpenSim/Region/CoreModules/World/Terrain/TerrainModule.cs b/OpenSim/Region/CoreModules/World/Terrain/TerrainModule.cs index 5b03ac7..402b9fb 100644 --- a/OpenSim/Region/CoreModules/World/Terrain/TerrainModule.cs +++ b/OpenSim/Region/CoreModules/World/Terrain/TerrainModule.cs | |||
@@ -1110,6 +1110,32 @@ namespace OpenSim.Region.CoreModules.World.Terrain | |||
1110 | CheckForTerrainUpdates(); | 1110 | CheckForTerrainUpdates(); |
1111 | } | 1111 | } |
1112 | 1112 | ||
1113 | private void InterfaceMinTerrain(Object[] args) | ||
1114 | { | ||
1115 | int x, y; | ||
1116 | for (x = 0; x < m_channel.Width; x++) | ||
1117 | { | ||
1118 | for (y = 0; y < m_channel.Height; y++) | ||
1119 | { | ||
1120 | m_channel[x, y] = Math.Max((double)args[0], m_channel[x, y]); | ||
1121 | } | ||
1122 | } | ||
1123 | CheckForTerrainUpdates(); | ||
1124 | } | ||
1125 | |||
1126 | private void InterfaceMaxTerrain(Object[] args) | ||
1127 | { | ||
1128 | int x, y; | ||
1129 | for (x = 0; x < m_channel.Width; x++) | ||
1130 | { | ||
1131 | for (y = 0; y < m_channel.Height; y++) | ||
1132 | { | ||
1133 | m_channel[x, y] = Math.Min((double)args[0], m_channel[x, y]); | ||
1134 | } | ||
1135 | } | ||
1136 | CheckForTerrainUpdates(); | ||
1137 | } | ||
1138 | |||
1113 | private void InterfaceShowDebugStats(Object[] args) | 1139 | private void InterfaceShowDebugStats(Object[] args) |
1114 | { | 1140 | { |
1115 | double max = Double.MinValue; | 1141 | double max = Double.MinValue; |
@@ -1250,6 +1276,12 @@ namespace OpenSim.Region.CoreModules.World.Terrain | |||
1250 | rescaleCommand.AddArgument("min", "min terrain height after rescaling", "Double"); | 1276 | rescaleCommand.AddArgument("min", "min terrain height after rescaling", "Double"); |
1251 | rescaleCommand.AddArgument("max", "max terrain height after rescaling", "Double"); | 1277 | rescaleCommand.AddArgument("max", "max terrain height after rescaling", "Double"); |
1252 | 1278 | ||
1279 | Command minCommand = new Command("min", CommandIntentions.COMMAND_HAZARDOUS, InterfaceMinTerrain, "Sets the minimum terrain height to the specified value."); | ||
1280 | minCommand.AddArgument("min", "terrain height to use as minimum", "Double"); | ||
1281 | |||
1282 | Command maxCommand = new Command("max", CommandIntentions.COMMAND_HAZARDOUS, InterfaceMaxTerrain, "Sets the maximum terrain height to the specified value."); | ||
1283 | maxCommand.AddArgument("min", "terrain height to use as maximum", "Double"); | ||
1284 | |||
1253 | 1285 | ||
1254 | // Debug | 1286 | // Debug |
1255 | Command showDebugStatsCommand = | 1287 | Command showDebugStatsCommand = |
@@ -1281,6 +1313,8 @@ namespace OpenSim.Region.CoreModules.World.Terrain | |||
1281 | m_commander.RegisterCommand("effect", pluginRunCommand); | 1313 | m_commander.RegisterCommand("effect", pluginRunCommand); |
1282 | m_commander.RegisterCommand("flip", flipCommand); | 1314 | m_commander.RegisterCommand("flip", flipCommand); |
1283 | m_commander.RegisterCommand("rescale", rescaleCommand); | 1315 | m_commander.RegisterCommand("rescale", rescaleCommand); |
1316 | m_commander.RegisterCommand("min", minCommand); | ||
1317 | m_commander.RegisterCommand("max", maxCommand); | ||
1284 | 1318 | ||
1285 | // Add this to our scene so scripts can call these functions | 1319 | // Add this to our scene so scripts can call these functions |
1286 | m_scene.RegisterModuleCommander(m_commander); | 1320 | m_scene.RegisterModuleCommander(m_commander); |