aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/CoreModules
diff options
context:
space:
mode:
authorDan Lake2010-03-19 05:58:34 -0700
committerJohn Hurliman2010-03-19 15:16:44 -0700
commit62e0b53ca4697a852ee1e36e86da6a32e93bd55e (patch)
treeaacaa4c84a0b7e61784909ca76fb1528ca06938b /OpenSim/Region/CoreModules
parentCleaned up access to scenepresences in scenegraph. GetScenePresences and GetA... (diff)
downloadopensim-SC_OLD-62e0b53ca4697a852ee1e36e86da6a32e93bd55e.zip
opensim-SC_OLD-62e0b53ca4697a852ee1e36e86da6a32e93bd55e.tar.gz
opensim-SC_OLD-62e0b53ca4697a852ee1e36e86da6a32e93bd55e.tar.bz2
opensim-SC_OLD-62e0b53ca4697a852ee1e36e86da6a32e93bd55e.tar.xz
Renamed TryGetAvatar to TryGetScenePresence on SceneManager, SceneBase, Scene and SceneGraph. This was the only change in this patch to keep it isolated from other recent changes to the same set of files.
Diffstat (limited to 'OpenSim/Region/CoreModules')
-rw-r--r--OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs8
-rw-r--r--OpenSim/Region/CoreModules/Avatar/Inventory/Transfer/InventoryTransferModule.cs2
-rw-r--r--OpenSim/Region/CoreModules/Avatar/ObjectCaps/ObjectAdd.cs2
-rw-r--r--OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs2
-rw-r--r--OpenSim/Region/CoreModules/InterGrid/OpenGridProtocolModule.cs2
-rw-r--r--OpenSim/Region/CoreModules/ServiceConnectorsOut/Inventory/HGInventoryBroker.cs4
-rw-r--r--OpenSim/Region/CoreModules/ServiceConnectorsOut/Inventory/InventoryCache.cs2
-rw-r--r--OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/PresenceDetector.cs2
-rw-r--r--OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs4
9 files changed, 14 insertions, 14 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
index f54e41a..23828ef 100644
--- a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
+++ b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
@@ -86,7 +86,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
86 86
87 // Save avatar attachment information 87 // Save avatar attachment information
88 ScenePresence presence; 88 ScenePresence presence;
89 if (m_scene.AvatarFactory != null && m_scene.TryGetAvatar(remoteClient.AgentId, out presence)) 89 if (m_scene.AvatarFactory != null && m_scene.TryGetScenePresence(remoteClient.AgentId, out presence))
90 { 90 {
91 m_log.Info( 91 m_log.Info(
92 "[ATTACHMENTS MODULE]: Saving avatar attachment. AgentID: " + remoteClient.AgentId 92 "[ATTACHMENTS MODULE]: Saving avatar attachment. AgentID: " + remoteClient.AgentId
@@ -255,7 +255,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
255 AttachmentPt = att.RootPart.AttachmentPoint; 255 AttachmentPt = att.RootPart.AttachmentPoint;
256 256
257 ScenePresence presence; 257 ScenePresence presence;
258 if (m_scene.TryGetAvatar(remoteClient.AgentId, out presence)) 258 if (m_scene.TryGetScenePresence(remoteClient.AgentId, out presence))
259 { 259 {
260 InventoryItemBase item = new InventoryItemBase(itemID, remoteClient.AgentId); 260 InventoryItemBase item = new InventoryItemBase(itemID, remoteClient.AgentId);
261 item = m_scene.InventoryService.GetItem(item); 261 item = m_scene.InventoryService.GetItem(item);
@@ -299,7 +299,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
299 } 299 }
300 300
301 ScenePresence presence; 301 ScenePresence presence;
302 if (m_scene.TryGetAvatar(remoteClient.AgentId, out presence)) 302 if (m_scene.TryGetScenePresence(remoteClient.AgentId, out presence))
303 { 303 {
304 // XXYY!! 304 // XXYY!!
305 InventoryItemBase item = new InventoryItemBase(itemID, remoteClient.AgentId); 305 InventoryItemBase item = new InventoryItemBase(itemID, remoteClient.AgentId);
@@ -314,7 +314,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
314 public void ShowDetachInUserInventory(UUID itemID, IClientAPI remoteClient) 314 public void ShowDetachInUserInventory(UUID itemID, IClientAPI remoteClient)
315 { 315 {
316 ScenePresence presence; 316 ScenePresence presence;
317 if (m_scene.TryGetAvatar(remoteClient.AgentId, out presence)) 317 if (m_scene.TryGetScenePresence(remoteClient.AgentId, out presence))
318 { 318 {
319 presence.Appearance.DetachAttachment(itemID); 319 presence.Appearance.DetachAttachment(itemID);
320 320
diff --git a/OpenSim/Region/CoreModules/Avatar/Inventory/Transfer/InventoryTransferModule.cs b/OpenSim/Region/CoreModules/Avatar/Inventory/Transfer/InventoryTransferModule.cs
index 4f03b0e..be89740 100644
--- a/OpenSim/Region/CoreModules/Avatar/Inventory/Transfer/InventoryTransferModule.cs
+++ b/OpenSim/Region/CoreModules/Avatar/Inventory/Transfer/InventoryTransferModule.cs
@@ -358,7 +358,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Transfer
358 { 358 {
359 ScenePresence presence; 359 ScenePresence presence;
360 360
361 if (s.TryGetAvatar(agentID, out presence)) 361 if (s.TryGetScenePresence(agentID, out presence))
362 { 362 {
363 // If the agent is in this scene, then we 363 // If the agent is in this scene, then we
364 // are being called twice in a single 364 // are being called twice in a single
diff --git a/OpenSim/Region/CoreModules/Avatar/ObjectCaps/ObjectAdd.cs b/OpenSim/Region/CoreModules/Avatar/ObjectCaps/ObjectAdd.cs
index 63a93aa..c011776 100644
--- a/OpenSim/Region/CoreModules/Avatar/ObjectCaps/ObjectAdd.cs
+++ b/OpenSim/Region/CoreModules/Avatar/ObjectCaps/ObjectAdd.cs
@@ -82,7 +82,7 @@ namespace OpenSim.Region.CoreModules.Avatar.ObjectCaps
82 responsedata["str_response_string"] = "Request wasn't what was expected"; 82 responsedata["str_response_string"] = "Request wasn't what was expected";
83 ScenePresence avatar; 83 ScenePresence avatar;
84 84
85 if (!m_scene.TryGetAvatar(AgentId, out avatar)) 85 if (!m_scene.TryGetScenePresence(AgentId, out avatar))
86 return responsedata; 86 return responsedata;
87 87
88 88
diff --git a/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs b/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs
index 25f5154..93aeb94 100644
--- a/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs
+++ b/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs
@@ -190,7 +190,7 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess
190 if (account == null) // foreign 190 if (account == null) // foreign
191 { 191 {
192 ScenePresence sp = null; 192 ScenePresence sp = null;
193 if (m_Scene.TryGetAvatar(userID, out sp)) 193 if (m_Scene.TryGetScenePresence(userID, out sp))
194 { 194 {
195 AgentCircuitData aCircuit = m_Scene.AuthenticateHandler.GetAgentCircuitData(sp.ControllingClient.CircuitCode); 195 AgentCircuitData aCircuit = m_Scene.AuthenticateHandler.GetAgentCircuitData(sp.ControllingClient.CircuitCode);
196 if (aCircuit.ServiceURLs.ContainsKey("AssetServerURI")) 196 if (aCircuit.ServiceURLs.ContainsKey("AssetServerURI"))
diff --git a/OpenSim/Region/CoreModules/InterGrid/OpenGridProtocolModule.cs b/OpenSim/Region/CoreModules/InterGrid/OpenGridProtocolModule.cs
index 8cf4619..e95d2f8 100644
--- a/OpenSim/Region/CoreModules/InterGrid/OpenGridProtocolModule.cs
+++ b/OpenSim/Region/CoreModules/InterGrid/OpenGridProtocolModule.cs
@@ -1206,7 +1206,7 @@ namespace OpenSim.Region.CoreModules.InterGrid
1206 { 1206 {
1207 Scene homeScene = GetRootScene(); 1207 Scene homeScene = GetRootScene();
1208 ScenePresence avatar = null; 1208 ScenePresence avatar = null;
1209 if (homeScene.TryGetAvatar(avatarId,out avatar)) 1209 if (homeScene.TryGetScenePresence(avatarId,out avatar))
1210 { 1210 {
1211 KillAUser ku = new KillAUser(avatar,mod); 1211 KillAUser ku = new KillAUser(avatar,mod);
1212 Watchdog.StartThread(ku.ShutdownNoLogout, "OGPShutdown", ThreadPriority.Normal, true); 1212 Watchdog.StartThread(ku.ShutdownNoLogout, "OGPShutdown", ThreadPriority.Normal, true);
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Inventory/HGInventoryBroker.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Inventory/HGInventoryBroker.cs
index c6312e0..54508cc 100644
--- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Inventory/HGInventoryBroker.cs
+++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Inventory/HGInventoryBroker.cs
@@ -502,7 +502,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Inventory
502 private UUID GetSessionID(UUID userID) 502 private UUID GetSessionID(UUID userID)
503 { 503 {
504 ScenePresence sp = null; 504 ScenePresence sp = null;
505 if (m_Scene.TryGetAvatar(userID, out sp)) 505 if (m_Scene.TryGetScenePresence(userID, out sp))
506 { 506 {
507 return sp.ControllingClient.SessionId; 507 return sp.ControllingClient.SessionId;
508 } 508 }
@@ -521,7 +521,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Inventory
521 if (account == null) // foreign user 521 if (account == null) // foreign user
522 { 522 {
523 ScenePresence sp = null; 523 ScenePresence sp = null;
524 m_Scene.TryGetAvatar(userID, out sp); 524 m_Scene.TryGetScenePresence(userID, out sp);
525 if (sp != null) 525 if (sp != null)
526 { 526 {
527 AgentCircuitData aCircuit = m_Scene.AuthenticateHandler.GetAgentCircuitData(sp.ControllingClient.CircuitCode); 527 AgentCircuitData aCircuit = m_Scene.AuthenticateHandler.GetAgentCircuitData(sp.ControllingClient.CircuitCode);
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Inventory/InventoryCache.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Inventory/InventoryCache.cs
index 3c3534f..5e06580 100644
--- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Inventory/InventoryCache.cs
+++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Inventory/InventoryCache.cs
@@ -100,7 +100,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Inventory
100 ScenePresence sp = null; 100 ScenePresence sp = null;
101 foreach (Scene s in m_Scenes) 101 foreach (Scene s in m_Scenes)
102 { 102 {
103 s.TryGetAvatar(clientID, out sp); 103 s.TryGetScenePresence(clientID, out sp);
104 if ((sp != null) && !sp.IsChildAgent && (s != scene)) 104 if ((sp != null) && !sp.IsChildAgent && (s != scene))
105 { 105 {
106 m_log.DebugFormat("[INVENTORY CACHE]: OnClientClosed in {0}, but user {1} still in sim. Keeping system folders in cache", 106 m_log.DebugFormat("[INVENTORY CACHE]: OnClientClosed in {0}, but user {1} still in sim. Keeping system folders in cache",
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/PresenceDetector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/PresenceDetector.cs
index e98df28..7a75a89 100644
--- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/PresenceDetector.cs
+++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/PresenceDetector.cs
@@ -88,7 +88,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Presence
88 Vector3 position = new Vector3(128, 128, 0); 88 Vector3 position = new Vector3(128, 128, 0);
89 Vector3 lookat = new Vector3(0, 1, 0); 89 Vector3 lookat = new Vector3(0, 1, 0);
90 90
91 if (client.Scene.TryGetAvatar(client.AgentId, out sp)) 91 if (client.Scene.TryGetScenePresence(client.AgentId, out sp))
92 { 92 {
93 if (sp is ScenePresence) 93 if (sp is ScenePresence)
94 { 94 {
diff --git a/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs b/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs
index f1cc0dd..2b0e83f 100644
--- a/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs
+++ b/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs
@@ -210,7 +210,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap
210 // this is here because CAPS map requests work even beyond the 10,000 limit. 210 // this is here because CAPS map requests work even beyond the 10,000 limit.
211 ScenePresence avatarPresence = null; 211 ScenePresence avatarPresence = null;
212 212
213 m_scene.TryGetAvatar(agentID, out avatarPresence); 213 m_scene.TryGetScenePresence(agentID, out avatarPresence);
214 214
215 if (avatarPresence != null) 215 if (avatarPresence != null)
216 { 216 {
@@ -489,7 +489,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap
489 if (mrs.agentID != UUID.Zero) 489 if (mrs.agentID != UUID.Zero)
490 { 490 {
491 ScenePresence av = null; 491 ScenePresence av = null;
492 m_scene.TryGetAvatar(mrs.agentID, out av); 492 m_scene.TryGetScenePresence(mrs.agentID, out av);
493 if (av != null) 493 if (av != null)
494 { 494 {
495 if (response.ContainsKey(mrs.itemtype.ToString())) 495 if (response.ContainsKey(mrs.itemtype.ToString()))