aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim.RegionServer/world
diff options
context:
space:
mode:
authorMW2007-05-22 11:25:34 +0000
committerMW2007-05-22 11:25:34 +0000
commiteafd91ba809c839e99c27055f38fe038e317f08d (patch)
tree864d4d1e33c95a52f672886b1065897775449dbf /OpenSim.RegionServer/world
parentMore work on adding Events to ClientView (and registering to handle those eve... (diff)
downloadopensim-SC_OLD-eafd91ba809c839e99c27055f38fe038e317f08d.zip
opensim-SC_OLD-eafd91ba809c839e99c27055f38fe038e317f08d.tar.gz
opensim-SC_OLD-eafd91ba809c839e99c27055f38fe038e317f08d.tar.bz2
opensim-SC_OLD-eafd91ba809c839e99c27055f38fe038e317f08d.tar.xz
More refactoring.
Diffstat (limited to 'OpenSim.RegionServer/world')
-rw-r--r--OpenSim.RegionServer/world/Avatar.Update.cs5
-rw-r--r--OpenSim.RegionServer/world/World.PacketHandlers.cs14
-rw-r--r--OpenSim.RegionServer/world/World.cs2
3 files changed, 21 insertions, 0 deletions
diff --git a/OpenSim.RegionServer/world/Avatar.Update.cs b/OpenSim.RegionServer/world/Avatar.Update.cs
index ee72ba3..266fc38 100644
--- a/OpenSim.RegionServer/world/Avatar.Update.cs
+++ b/OpenSim.RegionServer/world/Avatar.Update.cs
@@ -93,6 +93,11 @@ namespace OpenSim.world
93 } 93 }
94 94
95 } 95 }
96 public void SendUpdateToOtherClient(Avatar RemoteAvatar)
97 {
98 ObjectUpdatePacket objupdate = CreateUpdatePacket();
99 RemoteAvatar.SendPacketToViewer(objupdate);
100 }
96 101
97 public ObjectUpdatePacket CreateUpdatePacket() 102 public ObjectUpdatePacket CreateUpdatePacket()
98 { 103 {
diff --git a/OpenSim.RegionServer/world/World.PacketHandlers.cs b/OpenSim.RegionServer/world/World.PacketHandlers.cs
index d12013a..119bb19 100644
--- a/OpenSim.RegionServer/world/World.PacketHandlers.cs
+++ b/OpenSim.RegionServer/world/World.PacketHandlers.cs
@@ -168,6 +168,20 @@ namespace OpenSim.world
168 return true; 168 return true;
169 } 169 }
170 170
171 public void SendAvatarsToClient(ClientView RemoteClient)
172 {
173 foreach (ClientView client in m_clientThreads.Values)
174 {
175 if (client.AgentID != RemoteClient.AgentID)
176 {
177 // ObjectUpdatePacket objupdate = client.ClientAvatar.CreateUpdatePacket();
178 // RemoteClient.OutPacket(objupdate);
179 client.ClientAvatar.SendUpdateToOtherClient(RemoteClient.ClientAvatar);
180 client.ClientAvatar.SendAppearanceToOtherAgent(RemoteClient.ClientAvatar);
181 }
182 }
183 }
184
171 /* 185 /*
172 public void RequestMapBlock(ClientView simClient, int minX, int minY, int maxX, int maxY) 186 public void RequestMapBlock(ClientView simClient, int minX, int minY, int maxX, int maxY)
173 { 187 {
diff --git a/OpenSim.RegionServer/world/World.cs b/OpenSim.RegionServer/world/World.cs
index 70ca680..99fb8e0 100644
--- a/OpenSim.RegionServer/world/World.cs
+++ b/OpenSim.RegionServer/world/World.cs
@@ -538,6 +538,8 @@ namespace OpenSim.world
538 agentClient.OnModifyTerrain += new ClientView.ModifyTerrain(this.ModifyTerrain); 538 agentClient.OnModifyTerrain += new ClientView.ModifyTerrain(this.ModifyTerrain);
539 agentClient.OnRegionHandShakeReply += new ClientView.GenericCall(this.SendLayerData); 539 agentClient.OnRegionHandShakeReply += new ClientView.GenericCall(this.SendLayerData);
540 agentClient.OnRequestWearables += new ClientView.GenericCall(this.GetInitialPrims); 540 agentClient.OnRequestWearables += new ClientView.GenericCall(this.GetInitialPrims);
541 agentClient.OnRequestAvatarsData += new ClientView.GenericCall(this.SendAvatarsToClient);
542
541 try 543 try
542 { 544 {
543 OpenSim.Framework.Console.MainConsole.Instance.WriteLine(OpenSim.Framework.Console.LogPriority.LOW, "World.cs:AddViewerAgent() - Creating new avatar for remote viewer agent"); 545 OpenSim.Framework.Console.MainConsole.Instance.WriteLine(OpenSim.Framework.Console.LogPriority.LOW, "World.cs:AddViewerAgent() - Creating new avatar for remote viewer agent");