diff options
Diffstat (limited to 'OpenSim/Region/Framework')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/Scene.cs | 29 | ||||
-rw-r--r-- | OpenSim/Region/Framework/Scenes/SceneGraph.cs | 3 |
2 files changed, 15 insertions, 17 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs index ff2be05..73b0b3e 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.cs | |||
@@ -2496,24 +2496,20 @@ namespace OpenSim.Region.Framework.Scenes | |||
2496 | 2496 | ||
2497 | //RootPrim.SetParentLocalId(parentLocalID); | 2497 | //RootPrim.SetParentLocalId(parentLocalID); |
2498 | 2498 | ||
2499 | m_log.DebugFormat( | 2499 | m_log.DebugFormat("[ATTACHMENT]: Received " + |
2500 | "[ATTACHMENT]: Received attachment {0}, inworld asset id {1}", | 2500 | "attachment {0}, inworld asset id {1}", |
2501 | //grp.RootPart.LastOwnerID.ToString(), | 2501 | //grp.RootPart.LastOwnerID.ToString(), |
2502 | grp.GetFromItemID(), | 2502 | grp.GetFromItemID(), |
2503 | grp.UUID.ToString()); | 2503 | grp.UUID.ToString()); |
2504 | 2504 | ||
2505 | //grp.SetFromAssetID(grp.RootPart.LastOwnerID); | 2505 | //grp.SetFromAssetID(grp.RootPart.LastOwnerID); |
2506 | m_log.DebugFormat( | 2506 | m_log.DebugFormat("[ATTACHMENT]: Attach " + |
2507 | "[ATTACHMENT]: Attach to avatar {0} at position {1}", sp.UUID.ToString(), grp.AbsolutePosition); | 2507 | "to avatar {0} at position {1}", |
2508 | 2508 | sp.UUID.ToString(), grp.AbsolutePosition); | |
2509 | if ( | 2509 | AttachObject(sp.ControllingClient, |
2510 | AttachObject( | 2510 | grp.LocalId, (uint)0, |
2511 | sp.ControllingClient, grp.LocalId, (uint)0, grp.GroupRotation, grp.AbsolutePosition, false)) | 2511 | grp.GroupRotation, |
2512 | { | 2512 | grp.AbsolutePosition, false); |
2513 | // Do this last so that event listeners have access to all the effects of the attachment | ||
2514 | EventManager.TriggerOnAttach(grp.LocalId, UUID.Zero, sp.UUID); | ||
2515 | } | ||
2516 | |||
2517 | RootPrim.RemFlag(PrimFlags.TemporaryOnRez); | 2513 | RootPrim.RemFlag(PrimFlags.TemporaryOnRez); |
2518 | grp.SendGroupFullUpdate(); | 2514 | grp.SendGroupFullUpdate(); |
2519 | } | 2515 | } |
@@ -2522,6 +2518,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
2522 | RootPrim.RemFlag(PrimFlags.TemporaryOnRez); | 2518 | RootPrim.RemFlag(PrimFlags.TemporaryOnRez); |
2523 | RootPrim.AddFlag(PrimFlags.TemporaryOnRez); | 2519 | RootPrim.AddFlag(PrimFlags.TemporaryOnRez); |
2524 | } | 2520 | } |
2521 | |||
2525 | } | 2522 | } |
2526 | else | 2523 | else |
2527 | { | 2524 | { |
diff --git a/OpenSim/Region/Framework/Scenes/SceneGraph.cs b/OpenSim/Region/Framework/Scenes/SceneGraph.cs index b508af5..1ac061a 100644 --- a/OpenSim/Region/Framework/Scenes/SceneGraph.cs +++ b/OpenSim/Region/Framework/Scenes/SceneGraph.cs | |||
@@ -627,10 +627,11 @@ namespace OpenSim.Region.Framework.Scenes | |||
627 | } | 627 | } |
628 | 628 | ||
629 | m_parentScene.AttachObject(remoteClient, AttachmentPt, itemId, group); | 629 | m_parentScene.AttachObject(remoteClient, AttachmentPt, itemId, group); |
630 | |||
630 | group.AttachToAgent(remoteClient.AgentId, AttachmentPt, attachPos, silent); | 631 | group.AttachToAgent(remoteClient.AgentId, AttachmentPt, attachPos, silent); |
631 | |||
632 | // In case it is later dropped again, don't let | 632 | // In case it is later dropped again, don't let |
633 | // it get cleaned up | 633 | // it get cleaned up |
634 | // | ||
634 | group.RootPart.RemFlag(PrimFlags.TemporaryOnRez); | 635 | group.RootPart.RemFlag(PrimFlags.TemporaryOnRez); |
635 | group.HasGroupChanged = false; | 636 | group.HasGroupChanged = false; |
636 | } | 637 | } |