Merge branch 'master' into careminster-presence-refactor
commit
d457b4c4b1
|
@ -328,7 +328,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
|||
/// thread servicing the m_primFullUpdates queue after a kill. If this happens the object persists as an
|
||||
/// ownerless phantom.
|
||||
///
|
||||
/// All manipulation of this set has to occur under an m_entityUpdates.SyncRoot lock
|
||||
/// All manipulation of this set has to occur under a lock
|
||||
///
|
||||
/// </value>
|
||||
protected HashSet<uint> m_killRecord;
|
||||
|
@ -1536,11 +1536,14 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
|||
OutPacket(kill, ThrottleOutPacketType.State);
|
||||
return;
|
||||
}
|
||||
lock (m_killRecord)
|
||||
{
|
||||
m_killRecord.Add(localIDs[0]);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
lock (m_entityUpdates.SyncRoot)
|
||||
lock (m_killRecord)
|
||||
{
|
||||
foreach (uint localID in localIDs)
|
||||
m_killRecord.Add(localID);
|
||||
|
@ -3595,6 +3598,8 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
|||
int updatesThisCall = 0;
|
||||
|
||||
EntityUpdate update;
|
||||
lock (m_killRecord)
|
||||
{
|
||||
while (updatesThisCall < maxUpdates)
|
||||
{
|
||||
lock (m_entityUpdates.SyncRoot)
|
||||
|
@ -3651,6 +3656,8 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
|||
continue;
|
||||
}
|
||||
|
||||
if (part.ParentGroup.IsAttachment && m_disableFacelights)
|
||||
{
|
||||
if (part.ParentGroup.IsAttachment && m_disableFacelights)
|
||||
{
|
||||
if (part.ParentGroup.RootPart.Shape.State != (byte)AttachmentPoint.LeftHand &&
|
||||
|
@ -3725,36 +3732,36 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
|||
}
|
||||
else
|
||||
{
|
||||
// if (update.Entity is SceneObjectPart && ((SceneObjectPart)update.Entity).IsAttachment)
|
||||
// {
|
||||
// SceneObjectPart sop = (SceneObjectPart)update.Entity;
|
||||
// string text = sop.Text;
|
||||
// if (text.IndexOf("\n") >= 0)
|
||||
// text = text.Remove(text.IndexOf("\n"));
|
||||
//
|
||||
// if (m_attachmentsSent.Contains(sop.ParentID))
|
||||
// {
|
||||
//// m_log.DebugFormat(
|
||||
//// "[CLIENT]: Sending full info about attached prim {0} text {1}",
|
||||
//// sop.LocalId, text);
|
||||
//
|
||||
// objectUpdateBlocks.Value.Add(CreatePrimUpdateBlock(sop, this.m_agentId));
|
||||
//
|
||||
// m_attachmentsSent.Add(sop.LocalId);
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// m_log.DebugFormat(
|
||||
// "[CLIENT]: Requeueing full update of prim {0} text {1} since we haven't sent its parent {2} yet",
|
||||
// sop.LocalId, text, sop.ParentID);
|
||||
//
|
||||
// m_entityUpdates.Enqueue(double.MaxValue, update, sop.LocalId);
|
||||
// }
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// if (update.Entity is SceneObjectPart && ((SceneObjectPart)update.Entity).IsAttachment)
|
||||
// {
|
||||
// SceneObjectPart sop = (SceneObjectPart)update.Entity;
|
||||
// string text = sop.Text;
|
||||
// if (text.IndexOf("\n") >= 0)
|
||||
// text = text.Remove(text.IndexOf("\n"));
|
||||
//
|
||||
// if (m_attachmentsSent.Contains(sop.ParentID))
|
||||
// {
|
||||
//// m_log.DebugFormat(
|
||||
//// "[CLIENT]: Sending full info about attached prim {0} text {1}",
|
||||
//// sop.LocalId, text);
|
||||
//
|
||||
// objectUpdateBlocks.Value.Add(CreatePrimUpdateBlock(sop, this.m_agentId));
|
||||
//
|
||||
// m_attachmentsSent.Add(sop.LocalId);
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// m_log.DebugFormat(
|
||||
// "[CLIENT]: Requeueing full update of prim {0} text {1} since we haven't sent its parent {2} yet",
|
||||
// sop.LocalId, text, sop.ParentID);
|
||||
//
|
||||
// m_entityUpdates.Enqueue(double.MaxValue, update, sop.LocalId);
|
||||
// }
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
objectUpdateBlocks.Value.Add(CreatePrimUpdateBlock((SceneObjectPart)update.Entity, this.m_agentId));
|
||||
// }
|
||||
// }
|
||||
}
|
||||
}
|
||||
else if (!canUseImproved)
|
||||
|
@ -3838,6 +3845,8 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
|||
|
||||
OutPacket(packet, ThrottleOutPacketType.Task, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endregion Packet Sending
|
||||
}
|
||||
|
|
|
@ -152,7 +152,7 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
private int m_update_backup = 200;
|
||||
private int m_update_terrain = 50;
|
||||
private int m_update_land = 1;
|
||||
private int m_update_coarse_locations = 50;
|
||||
private int m_update_coarse_locations = 80;
|
||||
|
||||
private int frameMS;
|
||||
private int physicsMS2;
|
||||
|
@ -181,6 +181,8 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
private object m_deleting_scene_object = new object();
|
||||
private object m_cleaningAttachments = new object();
|
||||
|
||||
private bool m_cleaningTemps = false;
|
||||
|
||||
private UpdatePrioritizationSchemes m_priorityScheme = UpdatePrioritizationSchemes.Time;
|
||||
private bool m_reprioritizationEnabled = true;
|
||||
private double m_reprioritizationInterval = 5000.0;
|
||||
|
@ -1296,10 +1298,11 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
physicsMS = Util.EnvironmentTickCountSubtract(tmpPhysicsMS);
|
||||
|
||||
// Delete temp-on-rez stuff
|
||||
if (m_frame % m_update_backup == 0)
|
||||
if (m_frame % 1000 == 0 && !m_cleaningTemps)
|
||||
{
|
||||
int tmpTempOnRezMS = Util.EnvironmentTickCount();
|
||||
CleanTempObjects();
|
||||
m_cleaningTemps = true;
|
||||
Util.FireAndForget(delegate { CleanTempObjects(); m_cleaningTemps = false; });
|
||||
tempOnRezMS = Util.EnvironmentTickCountSubtract(tmpTempOnRezMS);
|
||||
}
|
||||
|
||||
|
@ -1326,12 +1329,12 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
terrainMS = Util.EnvironmentTickCountSubtract(terMS);
|
||||
}
|
||||
|
||||
if (m_frame % m_update_land == 0)
|
||||
{
|
||||
int ldMS = Util.EnvironmentTickCount();
|
||||
UpdateLand();
|
||||
landMS = Util.EnvironmentTickCountSubtract(ldMS);
|
||||
}
|
||||
//if (m_frame % m_update_land == 0)
|
||||
//{
|
||||
// int ldMS = Util.EnvironmentTickCount();
|
||||
// UpdateLand();
|
||||
// landMS = Util.EnvironmentTickCountSubtract(ldMS);
|
||||
//}
|
||||
|
||||
frameMS = Util.EnvironmentTickCountSubtract(tmpFrameMS);
|
||||
otherMS = tempOnRezMS + eventMS + backupMS + terrainMS + landMS;
|
||||
|
@ -1424,14 +1427,13 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
|
||||
private void CheckAtTargets()
|
||||
{
|
||||
Dictionary<UUID, SceneObjectGroup>.ValueCollection objs;
|
||||
lock (m_groupsWithTargets)
|
||||
{
|
||||
foreach (SceneObjectGroup entry in m_groupsWithTargets.Values)
|
||||
{
|
||||
objs = m_groupsWithTargets.Values;
|
||||
|
||||
foreach (SceneObjectGroup entry in objs)
|
||||
entry.checkAtTargets();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
|
@ -4539,6 +4541,7 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public void DeleteFromStorage(UUID uuid)
|
||||
|
|
|
@ -2635,6 +2635,8 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
|
||||
#region Overridden Methods
|
||||
|
||||
private bool sendingPrims = false;
|
||||
|
||||
public override void Update()
|
||||
{
|
||||
const float ROTATION_TOLERANCE = 0.01f;
|
||||
|
@ -2642,7 +2644,8 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
const float POSITION_TOLERANCE = 0.05f;
|
||||
//const int TIME_MS_TOLERANCE = 3000;
|
||||
|
||||
|
||||
if (!sendingPrims)
|
||||
Util.FireAndForget(delegate { sendingPrims = true; SendPrimUpdates(); sendingPrims = false; });
|
||||
|
||||
if (m_isChildAgent == false)
|
||||
{
|
||||
|
@ -2670,6 +2673,7 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
// followed suggestion from mic bowman. reversed the two lines below.
|
||||
if (m_parentID == 0 && m_physicsActor != null || m_parentID != 0) // Check that we have a physics actor or we're sitting on something
|
||||
CheckForBorderCrossing();
|
||||
|
||||
CheckForSignificantMovement(); // sends update to the modules.
|
||||
}
|
||||
|
||||
|
|
|
@ -3037,6 +3037,7 @@
|
|||
<Reference name="OpenSim.Framework.Statistics"/>
|
||||
<Reference name="OpenSim.Region.Framework"/>
|
||||
<Reference name="OpenSim.Region.CoreModules"/>
|
||||
<Reference name="OpenSim.Region.OptionalModules"/>
|
||||
<Reference name="OpenSim.Region.Physics.Manager"/>
|
||||
<Reference name="OpenSim.Services.Interfaces"/>
|
||||
|
||||
|
|
Loading…
Reference in New Issue