Simplify AddFullUpdateToAvatars()/AddPartialUpdateToAvatars() by calling the object's corresponding single avatar update method, rather than calling the sceneviewer directly

soprefactor
Justin Clark-Casey (justincc) 2010-05-28 17:58:51 +01:00
parent 596001632b
commit 877fe774ef
1 changed files with 5 additions and 2 deletions

View File

@ -1278,10 +1278,13 @@ namespace OpenSim.Region.Framework.Scenes
{ {
m_parentGroup.Scene.ForEachScenePresence(delegate(ScenePresence avatar) m_parentGroup.Scene.ForEachScenePresence(delegate(ScenePresence avatar)
{ {
avatar.SceneViewer.QueuePartForUpdate(this); AddFullUpdateToAvatar(avatar);
}); });
} }
/// <summary>
/// Tell the scene presence that it should send updates for this part to its client
/// </summary>
public void AddFullUpdateToAvatar(ScenePresence presence) public void AddFullUpdateToAvatar(ScenePresence presence)
{ {
presence.SceneViewer.QueuePartForUpdate(this); presence.SceneViewer.QueuePartForUpdate(this);
@ -1302,7 +1305,7 @@ namespace OpenSim.Region.Framework.Scenes
{ {
m_parentGroup.Scene.ForEachScenePresence(delegate(ScenePresence avatar) m_parentGroup.Scene.ForEachScenePresence(delegate(ScenePresence avatar)
{ {
avatar.SceneViewer.QueuePartForUpdate(this); AddTerseUpdateToAvatar(avatar);
}); });
} }