aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorUbitUmarov2015-12-21 18:13:07 +0000
committerUbitUmarov2015-12-21 18:13:07 +0000
commit88a63ecc39032ebb256caf34aec330d1cbb3d9c1 (patch)
tree90799b0a54c5304c75f8168b2607dcf484563138
parentclean a bit (diff)
downloadopensim-SC-88a63ecc39032ebb256caf34aec330d1cbb3d9c1.zip
opensim-SC-88a63ecc39032ebb256caf34aec330d1cbb3d9c1.tar.gz
opensim-SC-88a63ecc39032ebb256caf34aec330d1cbb3d9c1.tar.bz2
opensim-SC-88a63ecc39032ebb256caf34aec330d1cbb3d9c1.tar.xz
drop attachments to ground a bit in front of the avatar, not on his location
-rw-r--r--OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs7
1 files changed, 5 insertions, 2 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
index ad889cb..d199a35 100644
--- a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
+++ b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
@@ -675,7 +675,10 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
675 675
676 public void DetachSingleAttachmentToGround(IScenePresence sp, uint soLocalId) 676 public void DetachSingleAttachmentToGround(IScenePresence sp, uint soLocalId)
677 { 677 {
678 DetachSingleAttachmentToGround(sp, soLocalId, sp.AbsolutePosition, Quaternion.Identity); 678 Vector3 pos = new Vector3(2.5f, 0f, 0f);
679 pos *= ((ScenePresence)sp).Rotation;
680 pos += sp.AbsolutePosition;
681 DetachSingleAttachmentToGround(sp, soLocalId, pos, Quaternion.Identity);
679 } 682 }
680 683
681 public void DetachSingleAttachmentToGround(IScenePresence sp, uint soLocalId, Vector3 absolutePos, Quaternion absoluteRot) 684 public void DetachSingleAttachmentToGround(IScenePresence sp, uint soLocalId, Vector3 absolutePos, Quaternion absoluteRot)
@@ -740,7 +743,6 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
740 743
741 so.ApplyPhysics(); 744 so.ApplyPhysics();
742 745
743 so.HasGroupChanged = true;
744 rootPart.Rezzed = DateTime.Now; 746 rootPart.Rezzed = DateTime.Now;
745 so.AttachToBackup(); 747 so.AttachToBackup();
746 m_scene.EventManager.TriggerParcelPrimCountTainted(); 748 m_scene.EventManager.TriggerParcelPrimCountTainted();
@@ -757,6 +759,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
757 759
758 // Attach (NULL) stops scripts. We don't want that. Resume them. 760 // Attach (NULL) stops scripts. We don't want that. Resume them.
759 so.ResumeScripts(); 761 so.ResumeScripts();
762 so.HasGroupChanged = true;
760 so.RootPart.ScheduleFullUpdate(); 763 so.RootPart.ScheduleFullUpdate();
761 so.ScheduleGroupForTerseUpdate(); 764 so.ScheduleGroupForTerseUpdate();
762 } 765 }