From dd277a0d02f1aa79f4fcb5d108cbc696e90500c2 Mon Sep 17 00:00:00 2001 From: John Hurliman Date: Fri, 10 Sep 2010 12:04:12 -0700 Subject: First pass at cleaning up thread safety in EntityManager and SceneGraph --- OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs') diff --git a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs index dd7d831..7270304 100644 --- a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs @@ -436,7 +436,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments // We can NOT use the dictionries here, as we are looking // for an entity by the fromAssetID, which is NOT the prim UUID - List detachEntities = m_scene.GetEntities(); + EntityBase[] detachEntities = m_scene.GetEntities(); SceneObjectGroup group; foreach (EntityBase entity in detachEntities) -- cgit v1.1 From f1f0bc23f4501ba99035283d3407ddad2b21b785 Mon Sep 17 00:00:00 2001 From: Jeff Ames Date: Sun, 12 Sep 2010 13:43:49 -0400 Subject: Formatting cleanup. --- .../Avatar/Attachments/AttachmentsModule.cs | 24 +++++++++++----------- 1 file changed, 12 insertions(+), 12 deletions(-) (limited to 'OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs') diff --git a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs index 7270304..5604f49 100644 --- a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs @@ -48,8 +48,8 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments protected Scene m_scene = null; - public string Name { get { return "Attachments Module"; } } - public Type ReplaceableInterface { get { return null; } } + public string Name { get { return "Attachments Module"; } } + public Type ReplaceableInterface { get { return null; } } public void Initialise(IConfigSource source) {} @@ -80,7 +80,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments client.OnRezMultipleAttachmentsFromInv += RezMultipleAttachmentsFromInventory; client.OnObjectAttach += AttachObject; client.OnObjectDetach += DetachObject; - client.OnDetachAttachmentIntoInv += ShowDetachInUserInventory; + client.OnDetachAttachmentIntoInv += ShowDetachInUserInventory; } public void UnsubscribeFromClientEvents(IClientAPI client) @@ -89,7 +89,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments client.OnRezMultipleAttachmentsFromInv -= RezMultipleAttachmentsFromInventory; client.OnObjectAttach -= AttachObject; client.OnObjectDetach -= DetachObject; - client.OnDetachAttachmentIntoInv -= ShowDetachInUserInventory; + client.OnDetachAttachmentIntoInv -= ShowDetachInUserInventory; } /// @@ -173,12 +173,12 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments UUID itemID = UUID.Zero; if (sp != null) { - foreach(SceneObjectGroup grp in sp.GetAttachments(AttachmentPt)) + foreach (SceneObjectGroup grp in sp.GetAttachments(AttachmentPt)) { itemID = grp.GetFromItemID(); if (itemID != UUID.Zero) DetachSingleAttachmentToInv(itemID, remoteClient); - } + } } if (group.GetFromItemID() == UUID.Zero) @@ -225,7 +225,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments public UUID RezSingleAttachmentFromInventory( IClientAPI remoteClient, UUID itemID, uint AttachmentPt, bool updateInventoryStatus) - { + { SceneObjectGroup att = RezSingleAttachmentFromInventoryInternal(remoteClient, itemID, AttachmentPt); if (updateInventoryStatus) @@ -241,8 +241,8 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments if (null == att) return UUID.Zero; else - return att.UUID; - } + return att.UUID; + } protected SceneObjectGroup RezSingleAttachmentFromInventoryInternal( IClientAPI remoteClient, UUID itemID, uint AttachmentPt) @@ -298,7 +298,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments } return null; - } + } public UUID SetAttachmentInventoryStatus( SceneObjectGroup att, IClientAPI remoteClient, UUID itemID, uint AttachmentPt) @@ -473,7 +473,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments sog.RootPart.IsAttachment = false; sog.AbsolutePosition = sog.RootPart.AttachedPos; UpdateKnownItem(client, sog, sog.GetFromItemID(), sog.OwnerID); - sog.SetAttachmentPoint(attachmentPoint); + sog.SetAttachmentPoint(attachmentPoint); } /// @@ -600,7 +600,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments // In case it is later dropped again, don't let // it get cleaned up so.RootPart.RemFlag(PrimFlags.TemporaryOnRez); - so.HasGroupChanged = false; + so.HasGroupChanged = false; } } } -- cgit v1.1