aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
authorAdam Johnson2009-08-16 15:06:06 +0900
committerAdam Johnson2009-08-16 15:06:06 +0900
commita42569d89675430087d32332e168429d4185311c (patch)
treece80fd881347e31cd47ba9725a0899fb752af326 /OpenSim
parentMerge branch 'master' of ssh://opensimulator.org/var/git/opensim (diff)
downloadopensim-SC_OLD-a42569d89675430087d32332e168429d4185311c.zip
opensim-SC_OLD-a42569d89675430087d32332e168429d4185311c.tar.gz
opensim-SC_OLD-a42569d89675430087d32332e168429d4185311c.tar.bz2
opensim-SC_OLD-a42569d89675430087d32332e168429d4185311c.tar.xz
Thanks dmiles for a patch that adds PacketType.RequestMultipleObjects Packet Handler - ref mantis #4010
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Client/MXP/ClientStack/MXPClientView.cs1
-rw-r--r--OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs1
-rw-r--r--OpenSim/Framework/IClientAPI.cs3
-rw-r--r--OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs25
-rw-r--r--OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs1
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs23
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.cs1
-rw-r--r--OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs1
-rw-r--r--OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs1
-rw-r--r--OpenSim/Tests/Common/Mock/TestClient.cs1
10 files changed, 58 insertions, 0 deletions
diff --git a/OpenSim/Client/MXP/ClientStack/MXPClientView.cs b/OpenSim/Client/MXP/ClientStack/MXPClientView.cs
index a7bcc07..104f2d5 100644
--- a/OpenSim/Client/MXP/ClientStack/MXPClientView.cs
+++ b/OpenSim/Client/MXP/ClientStack/MXPClientView.cs
@@ -612,6 +612,7 @@ namespace OpenSim.Client.MXP.ClientStack
612 public event SpinStop OnSpinStop; 612 public event SpinStop OnSpinStop;
613 public event UpdateShape OnUpdatePrimShape; 613 public event UpdateShape OnUpdatePrimShape;
614 public event ObjectExtraParams OnUpdateExtraParams; 614 public event ObjectExtraParams OnUpdateExtraParams;
615 public event ObjectRequest OnObjectRequest;
615 public event ObjectSelect OnObjectSelect; 616 public event ObjectSelect OnObjectSelect;
616 public event ObjectDeselect OnObjectDeselect; 617 public event ObjectDeselect OnObjectDeselect;
617 public event GenericCall7 OnObjectDescription; 618 public event GenericCall7 OnObjectDescription;
diff --git a/OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs b/OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs
index 324b5af..bfca954 100644
--- a/OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs
+++ b/OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs
@@ -259,6 +259,7 @@ namespace OpenSim.Client.VWoHTTP.ClientStack
259 public event SpinStop OnSpinStop = delegate { }; 259 public event SpinStop OnSpinStop = delegate { };
260 public event UpdateShape OnUpdatePrimShape = delegate { }; 260 public event UpdateShape OnUpdatePrimShape = delegate { };
261 public event ObjectExtraParams OnUpdateExtraParams = delegate { }; 261 public event ObjectExtraParams OnUpdateExtraParams = delegate { };
262 public event ObjectRequest OnObjectRequest = delegate { };
262 public event ObjectSelect OnObjectSelect = delegate { }; 263 public event ObjectSelect OnObjectSelect = delegate { };
263 public event ObjectDeselect OnObjectDeselect = delegate { }; 264 public event ObjectDeselect OnObjectDeselect = delegate { };
264 public event GenericCall7 OnObjectDescription = delegate { }; 265 public event GenericCall7 OnObjectDescription = delegate { };
diff --git a/OpenSim/Framework/IClientAPI.cs b/OpenSim/Framework/IClientAPI.cs
index 1594c44..e451dd8 100644
--- a/OpenSim/Framework/IClientAPI.cs
+++ b/OpenSim/Framework/IClientAPI.cs
@@ -111,6 +111,8 @@ namespace OpenSim.Framework
111 111
112 public delegate void ObjectSelect(uint localID, IClientAPI remoteClient); 112 public delegate void ObjectSelect(uint localID, IClientAPI remoteClient);
113 113
114 public delegate void ObjectRequest(uint localID, IClientAPI remoteClient);
115
114 public delegate void RequestObjectPropertiesFamily( 116 public delegate void RequestObjectPropertiesFamily(
115 IClientAPI remoteClient, UUID AgentID, uint RequestFlags, UUID TaskID); 117 IClientAPI remoteClient, UUID AgentID, uint RequestFlags, UUID TaskID);
116 118
@@ -622,6 +624,7 @@ namespace OpenSim.Framework
622 624
623 event UpdateShape OnUpdatePrimShape; 625 event UpdateShape OnUpdatePrimShape;
624 event ObjectExtraParams OnUpdateExtraParams; 626 event ObjectExtraParams OnUpdateExtraParams;
627 event ObjectRequest OnObjectRequest;
625 event ObjectSelect OnObjectSelect; 628 event ObjectSelect OnObjectSelect;
626 event ObjectDeselect OnObjectDeselect; 629 event ObjectDeselect OnObjectDeselect;
627 event GenericCall7 OnObjectDescription; 630 event GenericCall7 OnObjectDescription;
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
index 7633b7b..12c2d86 100644
--- a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
+++ b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
@@ -197,6 +197,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
197 private ObjectExtraParams handlerUpdateExtraParams; //OnUpdateExtraParams; 197 private ObjectExtraParams handlerUpdateExtraParams; //OnUpdateExtraParams;
198 private ObjectDuplicate handlerObjectDuplicate; 198 private ObjectDuplicate handlerObjectDuplicate;
199 private ObjectDuplicateOnRay handlerObjectDuplicateOnRay; 199 private ObjectDuplicateOnRay handlerObjectDuplicateOnRay;
200 private ObjectRequest handlerObjectRequest;
200 private ObjectSelect handlerObjectSelect; 201 private ObjectSelect handlerObjectSelect;
201 private ObjectDeselect handlerObjectDeselect; 202 private ObjectDeselect handlerObjectDeselect;
202 private ObjectIncludeInSearch handlerObjectIncludeInSearch; 203 private ObjectIncludeInSearch handlerObjectIncludeInSearch;
@@ -1083,6 +1084,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
1083 public event GodKickUser OnGodKickUser; 1084 public event GodKickUser OnGodKickUser;
1084 public event ObjectExtraParams OnUpdateExtraParams; 1085 public event ObjectExtraParams OnUpdateExtraParams;
1085 public event UpdateShape OnUpdatePrimShape; 1086 public event UpdateShape OnUpdatePrimShape;
1087 public event ObjectRequest OnObjectRequest;
1086 public event ObjectSelect OnObjectSelect; 1088 public event ObjectSelect OnObjectSelect;
1087 public event ObjectDeselect OnObjectDeselect; 1089 public event ObjectDeselect OnObjectDeselect;
1088 public event GenericCall7 OnObjectDescription; 1090 public event GenericCall7 OnObjectDescription;
@@ -5937,6 +5939,29 @@ namespace OpenSim.Region.ClientStack.LindenUDP
5937 5939
5938 break; 5940 break;
5939 5941
5942 case PacketType.RequestMultipleObjects:
5943 RequestMultipleObjectsPacket incomingRequest = (RequestMultipleObjectsPacket)Pack;
5944
5945 #region Packet Session and User Check
5946 if (m_checkPackets)
5947 {
5948 if (incomingRequest.AgentData.SessionID != SessionId ||
5949 incomingRequest.AgentData.AgentID != AgentId)
5950 break;
5951 }
5952 #endregion
5953
5954 handlerObjectRequest = null;
5955
5956 for (int i = 0; i < incomingRequest.ObjectData.Length; i++)
5957 {
5958 handlerObjectRequest = OnObjectRequest;
5959 if (handlerObjectRequest != null)
5960 {
5961 handlerObjectRequest(incomingRequest.ObjectData[i].ID, this);
5962 }
5963 }
5964 break;
5940 case PacketType.ObjectSelect: 5965 case PacketType.ObjectSelect:
5941 ObjectSelectPacket incomingselect = (ObjectSelectPacket)Pack; 5966 ObjectSelectPacket incomingselect = (ObjectSelectPacket)Pack;
5942 5967
diff --git a/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs b/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs
index 62779e7..e9c35e9 100644
--- a/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs
+++ b/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs
@@ -107,6 +107,7 @@ namespace OpenSim.Region.Examples.SimpleModule
107 public event UpdateShape OnUpdatePrimShape; 107 public event UpdateShape OnUpdatePrimShape;
108 public event ObjectExtraParams OnUpdateExtraParams; 108 public event ObjectExtraParams OnUpdateExtraParams;
109 public event RequestObjectPropertiesFamily OnRequestObjectPropertiesFamily; 109 public event RequestObjectPropertiesFamily OnRequestObjectPropertiesFamily;
110 public event ObjectRequest OnObjectRequest;
110 public event ObjectSelect OnObjectSelect; 111 public event ObjectSelect OnObjectSelect;
111 public event GenericCall7 OnObjectDescription; 112 public event GenericCall7 OnObjectDescription;
112 public event GenericCall7 OnObjectName; 113 public event GenericCall7 OnObjectName;
diff --git a/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs b/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs
index 113918d..1a7f8f8 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs
@@ -109,6 +109,29 @@ namespace OpenSim.Region.Framework.Scenes
109 } 109 }
110 110
111 /// <summary> 111 /// <summary>
112 /// Invoked when the client requests a prim.
113 /// </summary>
114 /// <param name="primLocalID"></param>
115 /// <param name="remoteClient"></param>
116 public void RequestPrim(uint primLocalID, IClientAPI remoteClient)
117 {
118 PacketType i = PacketType.ObjectUpdate;
119 List<EntityBase> EntityList = GetEntities();
120
121 foreach (EntityBase ent in EntityList)
122 {
123 if (ent is SceneObjectGroup)
124 {
125 if (((SceneObjectGroup)ent).LocalId == primLocalID)
126 {
127 ((SceneObjectGroup)ent).SendFullUpdateToClient(remoteClient);
128 return;
129 }
130 }
131 }
132 }
133
134 /// <summary>
112 /// Invoked when the client selects a prim. 135 /// Invoked when the client selects a prim.
113 /// </summary> 136 /// </summary>
114 /// <param name="primLocalID"></param> 137 /// <param name="primLocalID"></param>
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs
index 18d7bad..a2275f8 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.cs
@@ -2076,6 +2076,7 @@ namespace OpenSim.Region.Framework.Scenes
2076 client.OnUpdatePrimTexture += m_sceneGraph.UpdatePrimTexture; 2076 client.OnUpdatePrimTexture += m_sceneGraph.UpdatePrimTexture;
2077 client.OnTeleportLocationRequest += RequestTeleportLocation; 2077 client.OnTeleportLocationRequest += RequestTeleportLocation;
2078 client.OnTeleportLandmarkRequest += RequestTeleportLandmark; 2078 client.OnTeleportLandmarkRequest += RequestTeleportLandmark;
2079 client.OnObjectRequest += RequestPrim;
2079 client.OnObjectSelect += SelectPrim; 2080 client.OnObjectSelect += SelectPrim;
2080 client.OnObjectDeselect += DeselectPrim; 2081 client.OnObjectDeselect += DeselectPrim;
2081 client.OnGrabUpdate += m_sceneGraph.MoveObject; 2082 client.OnGrabUpdate += m_sceneGraph.MoveObject;
diff --git a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs
index 08fc61f..a3be181 100644
--- a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs
+++ b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs
@@ -686,6 +686,7 @@ namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server
686 public event SpinStop OnSpinStop; 686 public event SpinStop OnSpinStop;
687 public event UpdateShape OnUpdatePrimShape; 687 public event UpdateShape OnUpdatePrimShape;
688 public event ObjectExtraParams OnUpdateExtraParams; 688 public event ObjectExtraParams OnUpdateExtraParams;
689 public event ObjectRequest OnObjectRequest;
689 public event ObjectSelect OnObjectSelect; 690 public event ObjectSelect OnObjectSelect;
690 public event ObjectDeselect OnObjectDeselect; 691 public event ObjectDeselect OnObjectDeselect;
691 public event GenericCall7 OnObjectDescription; 692 public event GenericCall7 OnObjectDescription;
diff --git a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs
index 4a8ba8c..f0bdf3b 100644
--- a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs
+++ b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs
@@ -213,6 +213,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC
213 public event UpdateShape OnUpdatePrimShape; 213 public event UpdateShape OnUpdatePrimShape;
214 public event ObjectExtraParams OnUpdateExtraParams; 214 public event ObjectExtraParams OnUpdateExtraParams;
215 public event RequestObjectPropertiesFamily OnRequestObjectPropertiesFamily; 215 public event RequestObjectPropertiesFamily OnRequestObjectPropertiesFamily;
216 public event ObjectRequest OnObjectRequest;
216 public event ObjectSelect OnObjectSelect; 217 public event ObjectSelect OnObjectSelect;
217 public event GenericCall7 OnObjectDescription; 218 public event GenericCall7 OnObjectDescription;
218 public event GenericCall7 OnObjectName; 219 public event GenericCall7 OnObjectName;
diff --git a/OpenSim/Tests/Common/Mock/TestClient.cs b/OpenSim/Tests/Common/Mock/TestClient.cs
index bf4ddf0..fe31729 100644
--- a/OpenSim/Tests/Common/Mock/TestClient.cs
+++ b/OpenSim/Tests/Common/Mock/TestClient.cs
@@ -120,6 +120,7 @@ namespace OpenSim.Tests.Common.Mock
120 public event ObjectExtraParams OnUpdateExtraParams; 120 public event ObjectExtraParams OnUpdateExtraParams;
121 public event RequestObjectPropertiesFamily OnRequestObjectPropertiesFamily; 121 public event RequestObjectPropertiesFamily OnRequestObjectPropertiesFamily;
122 public event ObjectSelect OnObjectSelect; 122 public event ObjectSelect OnObjectSelect;
123 public event ObjectRequest OnObjectRequest;
123 public event GenericCall7 OnObjectDescription; 124 public event GenericCall7 OnObjectDescription;
124 public event GenericCall7 OnObjectName; 125 public event GenericCall7 OnObjectName;
125 public event GenericCall7 OnObjectClickAction; 126 public event GenericCall7 OnObjectClickAction;