diff options
Diffstat (limited to 'OpenSim/Region/CoreModules/Avatar/Attachments')
-rw-r--r-- | OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs index d56145a..de65460 100644 --- a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs | |||
@@ -173,16 +173,12 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments | |||
173 | UUID itemID = UUID.Zero; | 173 | UUID itemID = UUID.Zero; |
174 | if (sp != null) | 174 | if (sp != null) |
175 | { | 175 | { |
176 | foreach(SceneObjectGroup grp in sp.Attachments) | 176 | foreach(SceneObjectGroup grp in sp.GetAttachments(AttachmentPt)) |
177 | { | 177 | { |
178 | if (grp.GetAttachmentPoint() == (byte)AttachmentPt) | 178 | itemID = grp.GetFromItemID(); |
179 | { | 179 | if (itemID != UUID.Zero) |
180 | itemID = grp.GetFromItemID(); | 180 | DetachSingleAttachmentToInv(itemID, remoteClient); |
181 | break; | 181 | } |
182 | } | ||
183 | } | ||
184 | if (itemID != UUID.Zero) | ||
185 | DetachSingleAttachmentToInv(itemID, remoteClient); | ||
186 | } | 182 | } |
187 | 183 | ||
188 | if (group.GetFromItemID() == UUID.Zero) | 184 | if (group.GetFromItemID() == UUID.Zero) |