Thank you kindly, CMickeyb for a patch that:
Moved intialization of appearance from the SendInitialData event handler into CompleteMovement handler. That ensures that m_appearance is initialized before the inventory is retrieved (so there is a place to check on attachments).0.6.0-stable
parent
e946b40fdd
commit
1d5e870ee2
|
@ -722,6 +722,12 @@ namespace OpenSim.Data.MySQL
|
|||
reader.Dispose();
|
||||
result.Dispose();
|
||||
|
||||
if (null == appearance)
|
||||
{
|
||||
m_log.WarnFormat("[USER DB] No appearance found for user {0}", user.ToString());
|
||||
return null;
|
||||
}
|
||||
|
||||
appearance.SetAttachments(GetUserAttachments(user));
|
||||
|
||||
return appearance;
|
||||
|
|
|
@ -805,6 +805,11 @@ namespace OpenSim.Region.Environment.Scenes
|
|||
|
||||
m_controllingClient.MoveAgentIntoRegion(m_regionInfo, AbsolutePosition, look);
|
||||
|
||||
// Moved this from SendInitialData to ensure that m_appearance is initialized
|
||||
// before the inventory is processed in MakeRootAgent. This fixes a race condition
|
||||
// related to the handling of attachments
|
||||
m_scene.GetAvatarAppearance(m_controllingClient, out m_appearance);
|
||||
|
||||
if (m_isChildAgent)
|
||||
{
|
||||
m_isChildAgent = false;
|
||||
|
@ -1712,14 +1717,14 @@ namespace OpenSim.Region.Environment.Scenes
|
|||
m_scene.AddAgentTime(System.Environment.TickCount - m_perfMonMS);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Do everything required once a client completes its movement into a region
|
||||
/// </summary>
|
||||
public void SendInitialData()
|
||||
{
|
||||
// Needed for standalone
|
||||
m_scene.GetAvatarAppearance(m_controllingClient, out m_appearance);
|
||||
// Moved this into CompleteMovement to ensure that m_appearance is initialized before
|
||||
// the inventory arrives
|
||||
// m_scene.GetAvatarAppearance(m_controllingClient, out m_appearance);
|
||||
|
||||
// Note: because Quaternion is a struct, it can't be null
|
||||
Quaternion rot = m_bodyRot;
|
||||
|
|
Loading…
Reference in New Issue