aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/CoreModules/Framework
diff options
context:
space:
mode:
authorDiva Canto2010-05-07 21:29:56 -0700
committerDiva Canto2010-05-07 21:29:56 -0700
commita58859a0d4206c194c9c56212218e2cafc2cc373 (patch)
treefed51a4e40c344b76f6b8b4d5c5b2ec0d2e142e4 /OpenSim/Region/CoreModules/Framework
parentimprove handling of undersize sculpt textures (diff)
downloadopensim-SC-a58859a0d4206c194c9c56212218e2cafc2cc373.zip
opensim-SC-a58859a0d4206c194c9c56212218e2cafc2cc373.tar.gz
opensim-SC-a58859a0d4206c194c9c56212218e2cafc2cc373.tar.bz2
opensim-SC-a58859a0d4206c194c9c56212218e2cafc2cc373.tar.xz
GridUserService in place. Replaces the contrived concept of storing user's home and position info in the presence service. WARNING: I violated a taboo by deleting 2 migration files and simplifying the original table creation for Presence. This should not cause any problems to anyone, though. Things will work with the new simplified table, as well as with the previous contrived one. If there are any problems, solving them is as easy as dropping the presence table and deleting its row in the migrations table. The presence info only exists during a user's session anyway.
BTW, the Meshing files want to be committed too -- EOFs.
Diffstat (limited to 'OpenSim/Region/CoreModules/Framework')
-rw-r--r--OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs9
-rw-r--r--OpenSim/Region/CoreModules/Framework/EntityTransfer/HGEntityTransferModule.cs9
2 files changed, 13 insertions, 5 deletions
diff --git a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs
index f2b03e4..ef37f63 100644
--- a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs
+++ b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs
@@ -526,11 +526,12 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
526 { 526 {
527 m_log.DebugFormat("[ENTITY TRANSFER MODULE]: Request to teleport {0} {1} home", client.FirstName, client.LastName); 527 m_log.DebugFormat("[ENTITY TRANSFER MODULE]: Request to teleport {0} {1} home", client.FirstName, client.LastName);
528 528
529 OpenSim.Services.Interfaces.PresenceInfo pinfo = m_aScene.PresenceService.GetAgent(client.SessionId); 529 //OpenSim.Services.Interfaces.PresenceInfo pinfo = m_aScene.PresenceService.GetAgent(client.SessionId);
530 GridUserInfo uinfo = m_aScene.GridUserService.GetGridUserInfo(client.AgentId.ToString());
530 531
531 if (pinfo != null) 532 if (uinfo != null)
532 { 533 {
533 GridRegion regionInfo = m_aScene.GridService.GetRegionByUUID(UUID.Zero, pinfo.HomeRegionID); 534 GridRegion regionInfo = m_aScene.GridService.GetRegionByUUID(UUID.Zero, uinfo.HomeRegionID);
534 if (regionInfo == null) 535 if (regionInfo == null)
535 { 536 {
536 // can't find the Home region: Tell viewer and abort 537 // can't find the Home region: Tell viewer and abort
@@ -539,7 +540,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
539 } 540 }
540 // a little eekie that this goes back to Scene and with a forced cast, will fix that at some point... 541 // a little eekie that this goes back to Scene and with a forced cast, will fix that at some point...
541 ((Scene)(client.Scene)).RequestTeleportLocation( 542 ((Scene)(client.Scene)).RequestTeleportLocation(
542 client, regionInfo.RegionHandle, pinfo.HomePosition, pinfo.HomeLookAt, 543 client, regionInfo.RegionHandle, uinfo.HomePosition, uinfo.HomeLookAt,
543 (uint)(Constants.TeleportFlags.SetLastToTarget | Constants.TeleportFlags.ViaHome)); 544 (uint)(Constants.TeleportFlags.SetLastToTarget | Constants.TeleportFlags.ViaHome));
544 } 545 }
545 } 546 }
diff --git a/OpenSim/Region/CoreModules/Framework/EntityTransfer/HGEntityTransferModule.cs b/OpenSim/Region/CoreModules/Framework/EntityTransfer/HGEntityTransferModule.cs
index 28593fc..137dfec 100644
--- a/OpenSim/Region/CoreModules/Framework/EntityTransfer/HGEntityTransferModule.cs
+++ b/OpenSim/Region/CoreModules/Framework/EntityTransfer/HGEntityTransferModule.cs
@@ -154,7 +154,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
154 bool success = connector.LoginAgentToGrid(agentCircuit, reg, finalDestination, out reason); 154 bool success = connector.LoginAgentToGrid(agentCircuit, reg, finalDestination, out reason);
155 if (success) 155 if (success)
156 // Log them out of this grid 156 // Log them out of this grid
157 m_aScene.PresenceService.LogoutAgent(agentCircuit.SessionID, sp.AbsolutePosition, sp.Lookat); 157 m_aScene.PresenceService.LogoutAgent(agentCircuit.SessionID);
158 158
159 return success; 159 return success;
160 } 160 }
@@ -238,6 +238,13 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
238 { 238 {
239 if (obj.IsLoggingOut) 239 if (obj.IsLoggingOut)
240 { 240 {
241 object sp = null;
242 if (obj.Scene.TryGetScenePresence(obj.AgentId, out sp))
243 {
244 if (((ScenePresence)sp).IsChildAgent)
245 return;
246 }
247
241 AgentCircuitData aCircuit = ((Scene)(obj.Scene)).AuthenticateHandler.GetAgentCircuitData(obj.CircuitCode); 248 AgentCircuitData aCircuit = ((Scene)(obj.Scene)).AuthenticateHandler.GetAgentCircuitData(obj.CircuitCode);
242 249
243 if (aCircuit.ServiceURLs.ContainsKey("HomeURI")) 250 if (aCircuit.ServiceURLs.ContainsKey("HomeURI"))