aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/CoreModules
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2010-12-14 00:11:41 +0000
committerJustin Clark-Casey (justincc)2010-12-14 00:11:41 +0000
commite62b3dba8a1b8c816d6b09dc1f14b915f1560afe (patch)
tree19d945106d9d3c1147d441ab9351e9f33c910a36 /OpenSim/Region/CoreModules
parentTrigger event with flag CHANGED_LINK when agent sits on objects that have not... (diff)
downloadopensim-SC-e62b3dba8a1b8c816d6b09dc1f14b915f1560afe.zip
opensim-SC-e62b3dba8a1b8c816d6b09dc1f14b915f1560afe.tar.gz
opensim-SC-e62b3dba8a1b8c816d6b09dc1f14b915f1560afe.tar.bz2
opensim-SC-e62b3dba8a1b8c816d6b09dc1f14b915f1560afe.tar.xz
reinstate IAttachmentsModule.UpdateAttachmentPosition() since this is being used by a 3rd party region module and contains non-obvious attachment specific code
There are no functional changes. UpdateAttachmentPosition() is adapted to the new approach of only saving attachment state on logout
Diffstat (limited to 'OpenSim/Region/CoreModules')
-rw-r--r--OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs16
1 files changed, 16 insertions, 0 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
index 1f49a01..360a014 100644
--- a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
+++ b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
@@ -484,6 +484,22 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
484 } 484 }
485 } 485 }
486 486
487 public void UpdateAttachmentPosition(SceneObjectGroup sog, Vector3 pos)
488 {
489 // First we save the
490 // attachment point information, then we update the relative
491 // positioning. Then we have to mark the object as NOT an
492 // attachment. This is necessary in order to correctly save
493 // and retrieve GroupPosition information for the attachment.
494 // Finally, we restore the object's attachment status.
495 byte attachmentPoint = sog.GetAttachmentPoint();
496 sog.UpdateGroupPosition(pos);
497 sog.RootPart.IsAttachment = false;
498 sog.AbsolutePosition = sog.RootPart.AttachedPos;
499 sog.SetAttachmentPoint(attachmentPoint);
500 sog.HasGroupChanged = true;
501 }
502
487 /// <summary> 503 /// <summary>
488 /// Update the attachment asset for the new sog details if they have changed. 504 /// Update the attachment asset for the new sog details if they have changed.
489 /// </summary> 505 /// </summary>