mirror of
https://github.com/opensim/opensim.git
synced 2026-08-04 16:22:50 +08:00
Fixed the update of items in the priority queue to enable both
types of property updates to be specified. Not sure if one form of property update should supercede another. But for now the old OpenSim behavior is preserved by sending both.
This commit is contained in:
@@ -4032,26 +4032,34 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||
private class ObjectPropertyUpdate : IEntityUpdate
|
||||
{
|
||||
internal bool SendFamilyProps;
|
||||
internal bool SendObjectProps;
|
||||
|
||||
public ObjectPropertyUpdate(ISceneEntity entity, uint flags, bool sendfam)
|
||||
public ObjectPropertyUpdate(ISceneEntity entity, uint flags, bool sendfam, bool sendobj)
|
||||
: base(entity,flags)
|
||||
{
|
||||
SendFamilyProps = sendfam;
|
||||
SendObjectProps = sendobj;
|
||||
}
|
||||
public void Update(ObjectPropertyUpdate update)
|
||||
{
|
||||
SendFamilyProps = SendFamilyProps || update.SendFamilyProps;
|
||||
SendObjectProps = SendObjectProps || update.SendObjectProps;
|
||||
Flags |= update.Flags;
|
||||
}
|
||||
}
|
||||
|
||||
public void SendObjectPropertiesFamilyData(ISceneEntity entity, uint requestFlags)
|
||||
{
|
||||
uint priority = m_prioritizer.GetUpdatePriority(this, entity);
|
||||
uint priority = 0; // time based ordering only
|
||||
lock (m_entityProps.SyncRoot)
|
||||
m_entityProps.Enqueue(priority, new ObjectPropertyUpdate(entity,requestFlags,true));
|
||||
m_entityProps.Enqueue(priority, new ObjectPropertyUpdate(entity,requestFlags,true,false));
|
||||
}
|
||||
|
||||
public void SendObjectPropertiesReply(ISceneEntity entity)
|
||||
{
|
||||
uint priority = m_prioritizer.GetUpdatePriority(this, entity);
|
||||
uint priority = 0; // time based ordering only
|
||||
lock (m_entityProps.SyncRoot)
|
||||
m_entityProps.Enqueue(priority, new ObjectPropertyUpdate(entity,0,false));
|
||||
m_entityProps.Enqueue(priority, new ObjectPropertyUpdate(entity,0,false,true));
|
||||
}
|
||||
|
||||
private void ProcessEntityPropertyRequests(int maxUpdates)
|
||||
@@ -4082,7 +4090,8 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||
objectFamilyBlocks.Value.Add(objPropDB);
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
if (update.SendObjectProps)
|
||||
{
|
||||
if (update.Entity is SceneObjectPart)
|
||||
{
|
||||
|
||||
@@ -87,7 +87,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||
if (m_lookupTable.TryGetValue(localid, out lookup))
|
||||
{
|
||||
entry = lookup.Heap[lookup.Handle].EntryOrder;
|
||||
value.Flags |= lookup.Heap[lookup.Handle].Value.Flags;
|
||||
value.Update(lookup.Heap[lookup.Handle].Value);
|
||||
lookup.Heap.Remove(lookup.Handle);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user