minor: refactor part of LLClientView.ProcessEntityUpdates() to remove duplicate code

0.7.3-extended
Justin Clark-Casey (justincc) 2012-06-13 23:54:32 +01:00
parent 6a8e3907ca
commit 719efdaf1f
1 changed files with 7 additions and 5 deletions

View File

@ -3783,16 +3783,19 @@ namespace OpenSim.Region.ClientStack.LindenUDP
if (!canUseImproved && !canUseCompressed)
{
ObjectUpdatePacket.ObjectDataBlock updateBlock;
if (update.Entity is ScenePresence)
{
objectUpdateBlocks.Value.Add(CreateAvatarUpdateBlock((ScenePresence)update.Entity));
objectUpdates.Value.Add(update);
updateBlock = CreateAvatarUpdateBlock((ScenePresence)update.Entity);
}
else
{
objectUpdateBlocks.Value.Add(CreatePrimUpdateBlock((SceneObjectPart)update.Entity, this.m_agentId));
objectUpdates.Value.Add(update);
updateBlock = CreatePrimUpdateBlock((SceneObjectPart)update.Entity, AgentId);
}
objectUpdateBlocks.Value.Add(updateBlock);
objectUpdates.Value.Add(update);
}
else if (!canUseImproved)
{
@ -3818,7 +3821,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP
#endregion Block Construction
}
#region Packet Sending
ushort timeDilation = Utils.FloatToUInt16(avgTimeDilation, 0.0f, 1.0f);