aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2013-01-11 00:08:52 +0000
committerJustin Clark-Casey (justincc)2013-01-11 00:08:52 +0000
commit26347307ec39f05a138322554787b88d8d07be4a (patch)
tree6d9b1b60894c656d12af8e5974bbe2382e0d1eb9 /OpenSim
parentAdd "debug scene get" console command to list current scene options (diff)
downloadopensim-SC_OLD-26347307ec39f05a138322554787b88d8d07be4a.zip
opensim-SC_OLD-26347307ec39f05a138322554787b88d8d07be4a.tar.gz
opensim-SC_OLD-26347307ec39f05a138322554787b88d8d07be4a.tar.bz2
opensim-SC_OLD-26347307ec39f05a138322554787b88d8d07be4a.tar.xz
Fix a regression in the last few scene commands changes where setting these via the viewer estate dialog stopped working.
Forgot to register the new interface. Also removes some code which got included by adpating an existing module.
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Region/OptionalModules/World/SceneCommands/SceneCommandsModule.cs54
1 files changed, 2 insertions, 52 deletions
diff --git a/OpenSim/Region/OptionalModules/World/SceneCommands/SceneCommandsModule.cs b/OpenSim/Region/OptionalModules/World/SceneCommands/SceneCommandsModule.cs
index 5552317..8b8758e 100644
--- a/OpenSim/Region/OptionalModules/World/SceneCommands/SceneCommandsModule.cs
+++ b/OpenSim/Region/OptionalModules/World/SceneCommands/SceneCommandsModule.cs
@@ -51,7 +51,6 @@ namespace OpenSim.Region.OptionalModules.Avatar.Attachments
51 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); 51 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
52 52
53 private Scene m_scene; 53 private Scene m_scene;
54// private IAvatarFactoryModule m_avatarFactory;
55 54
56 public string Name { get { return "Scene Commands Module"; } } 55 public string Name { get { return "Scene Commands Module"; } }
57 56
@@ -77,6 +76,8 @@ namespace OpenSim.Region.OptionalModules.Avatar.Attachments
77// m_log.DebugFormat("[SCENE COMMANDS MODULE]: REGION {0} ADDED", scene.RegionInfo.RegionName); 76// m_log.DebugFormat("[SCENE COMMANDS MODULE]: REGION {0} ADDED", scene.RegionInfo.RegionName);
78 77
79 m_scene = scene; 78 m_scene = scene;
79
80 m_scene.RegisterModuleInterface<ISceneCommandsModule>(this);
80 } 81 }
81 82
82 public void RemoveRegion(Scene scene) 83 public void RemoveRegion(Scene scene)
@@ -222,56 +223,5 @@ namespace OpenSim.Region.OptionalModules.Avatar.Attachments
222 } 223 }
223 } 224 }
224 } 225 }
225
226 private void GetAttachmentsReport(ScenePresence sp, StringBuilder sb)
227 {
228 sb.AppendFormat("Attachments for {0}\n", sp.Name);
229
230 ConsoleDisplayTable ct = new ConsoleDisplayTable() { Indent = 2 };
231 ct.Columns.Add(new ConsoleDisplayTableColumn("Attachment Name", 50));
232 ct.Columns.Add(new ConsoleDisplayTableColumn("Local ID", 10));
233 ct.Columns.Add(new ConsoleDisplayTableColumn("Item ID", 36));
234 ct.Columns.Add(new ConsoleDisplayTableColumn("Attach Point", 14));
235 ct.Columns.Add(new ConsoleDisplayTableColumn("Position", 15));
236
237// sb.AppendFormat(
238// " {0,-36} {1,-10} {2,-36} {3,-14} {4,-15}\n",
239// "Attachment Name", "Local ID", "Item ID", "Attach Point", "Position");
240
241 List<SceneObjectGroup> attachmentObjects = sp.GetAttachments();
242 foreach (SceneObjectGroup attachmentObject in attachmentObjects)
243 {
244// InventoryItemBase attachmentItem
245// = m_scenes[0].InventoryService.GetItem(new InventoryItemBase(attachmentObject.FromItemID));
246
247// if (attachmentItem == null)
248// {
249// sb.AppendFormat(
250// "WARNING: Couldn't find attachment for item {0} at point {1}\n",
251// attachmentData.ItemID, (AttachmentPoint)attachmentData.AttachPoint);
252// continue;
253// }
254// else
255// {
256// sb.AppendFormat(
257// " {0,-36} {1,-10} {2,-36} {3,-14} {4,-15}\n",
258// attachmentObject.Name, attachmentObject.LocalId, attachmentObject.FromItemID,
259// (AttachmentPoint)attachmentObject.AttachmentPoint, attachmentObject.RootPart.AttachedPos);
260 ct.Rows.Add(
261 new ConsoleDisplayTableRow(
262 new List<string>()
263 {
264 attachmentObject.Name,
265 attachmentObject.LocalId.ToString(),
266 attachmentObject.FromItemID.ToString(),
267 ((AttachmentPoint)attachmentObject.AttachmentPoint).ToString(),
268 attachmentObject.RootPart.AttachedPos.ToString()
269 }));
270// }
271 }
272
273 ct.AddToStringBuilder(sb);
274 sb.Append("\n");
275 }
276 } 226 }
277} \ No newline at end of file 227} \ No newline at end of file