Bug fix on attachments: attach->drop->attach works now.
parent
2a71df1285
commit
e80cb815df
|
@ -25,6 +25,7 @@
|
||||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using log4net;
|
using log4net;
|
||||||
|
@ -72,6 +73,8 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
|
||||||
{
|
{
|
||||||
m_log.Debug("[ATTACHMENTS MODULE]: Invoking AttachObject");
|
m_log.Debug("[ATTACHMENTS MODULE]: Invoking AttachObject");
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
// If we can't take it, we can't attach it!
|
// If we can't take it, we can't attach it!
|
||||||
SceneObjectPart part = m_scene.GetSceneObjectPart(objectLocalID);
|
SceneObjectPart part = m_scene.GetSceneObjectPart(objectLocalID);
|
||||||
if (part == null)
|
if (part == null)
|
||||||
|
@ -97,6 +100,11 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
catch (Exception e)
|
||||||
|
{
|
||||||
|
m_log.DebugFormat("[ATTACHMENTS MODULE]: exception upon Attach Object {0}", e);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public bool AttachObject(
|
public bool AttachObject(
|
||||||
IClientAPI remoteClient, uint objectLocalID, uint AttachmentPt, Quaternion rot, Vector3 attachPos, bool silent)
|
IClientAPI remoteClient, uint objectLocalID, uint AttachmentPt, Quaternion rot, Vector3 attachPos, bool silent)
|
||||||
|
|
|
@ -1052,6 +1052,7 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
return;
|
return;
|
||||||
|
|
||||||
detachedpos = avatar.AbsolutePosition;
|
detachedpos = avatar.AbsolutePosition;
|
||||||
|
RootPart.FromItemID = UUID.Zero;
|
||||||
|
|
||||||
AbsolutePosition = detachedpos;
|
AbsolutePosition = detachedpos;
|
||||||
m_rootPart.AttachedAvatar = UUID.Zero;
|
m_rootPart.AttachedAvatar = UUID.Zero;
|
||||||
|
|
Loading…
Reference in New Issue