Added code in SceneGraph.AddSceneObjectByStateSynch to handle attachment objects.

dsg
Huaiyu (Kitty) Liu 2011-02-18 15:49:01 -08:00
parent 3d1048f1e2
commit 10a41ad5b5
2 changed files with 9 additions and 4 deletions

View File

@ -601,7 +601,7 @@ namespace OpenSim.Region.CoreModules.RegionSync.RegionSyncModule
public void SendPrimUpdate(ISceneEntity entity, PrimUpdateFlags updateFlags)
{
m_log.Debug("[REGION SYNC AVATAR] SendPrimUpdate");
//m_log.Debug("[REGION SYNC AVATAR] SendPrimUpdate");
}
public virtual void AttachObject(uint localID, Quaternion rotation, byte attachPoint, UUID ownerID)

View File

@ -2059,10 +2059,15 @@ namespace OpenSim.Region.Framework.Scenes
}
m_numPrim += children.Length;
//SYMMETRIC SYNC,
sceneObject.AttachToScene(m_parentScene);
//sceneObject.AttachToSceneBySync(m_parentScene);
//end of SYMMETRIC SYNC,
//Take some special care of the case of this object being an attachment
sceneObject.RootPart.SetAttachmentPoint(sceneObject.RootPart.AttachmentPoint);
if (sceneObject.IsAttachment)
{
ScenePresence avatar = m_parentScene.GetScenePresence(sceneObject.RootPart.AttachedAvatar);
sceneObject.RootPart.SetParentLocalId(avatar.LocalId);
}
//SYMMETRIC SYNC,
sceneObject.ScheduleGroupForFullUpdate_SyncInfoUnchanged();