aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Services
diff options
context:
space:
mode:
authorDiva Canto2010-01-10 15:34:56 -0800
committerDiva Canto2010-01-10 15:34:56 -0800
commit4dd523b45d1e635c66eb4e556764fabe29dbfc58 (patch)
treedbd92b59418535e6c2967021124a906a9987088d /OpenSim/Services
parent* Last reference to CommsManager.UserProfileCacheService removed (diff)
downloadopensim-SC-4dd523b45d1e635c66eb4e556764fabe29dbfc58.zip
opensim-SC-4dd523b45d1e635c66eb4e556764fabe29dbfc58.tar.gz
opensim-SC-4dd523b45d1e635c66eb4e556764fabe29dbfc58.tar.bz2
opensim-SC-4dd523b45d1e635c66eb4e556764fabe29dbfc58.tar.xz
* Changed IPresenceService Logout, so that it takes a position and a lookat
* CommsManager.AvatarService rerouted
Diffstat (limited to 'OpenSim/Services')
-rw-r--r--OpenSim/Services/Connectors/Presence/PresenceServiceConnector.cs4
-rw-r--r--OpenSim/Services/Interfaces/IPresenceService.cs2
-rw-r--r--OpenSim/Services/LLLoginService/LLLoginService.cs6
-rw-r--r--OpenSim/Services/PresenceService/PresenceService.cs4
4 files changed, 10 insertions, 6 deletions
diff --git a/OpenSim/Services/Connectors/Presence/PresenceServiceConnector.cs b/OpenSim/Services/Connectors/Presence/PresenceServiceConnector.cs
index 29cfd6e..fac3d1f 100644
--- a/OpenSim/Services/Connectors/Presence/PresenceServiceConnector.cs
+++ b/OpenSim/Services/Connectors/Presence/PresenceServiceConnector.cs
@@ -132,7 +132,7 @@ namespace OpenSim.Services.Connectors
132 132
133 } 133 }
134 134
135 public bool LogoutAgent(UUID sessionID) 135 public bool LogoutAgent(UUID sessionID, Vector3 position, Vector3 lookat)
136 { 136 {
137 Dictionary<string, object> sendData = new Dictionary<string, object>(); 137 Dictionary<string, object> sendData = new Dictionary<string, object>();
138 //sendData["SCOPEID"] = scopeID.ToString(); 138 //sendData["SCOPEID"] = scopeID.ToString();
@@ -141,6 +141,8 @@ namespace OpenSim.Services.Connectors
141 sendData["METHOD"] = "logout"; 141 sendData["METHOD"] = "logout";
142 142
143 sendData["SessionID"] = sessionID.ToString(); 143 sendData["SessionID"] = sessionID.ToString();
144 sendData["Position"] = position.ToString();
145 sendData["LookAt"] = lookat.ToString();
144 146
145 string reqString = ServerUtils.BuildQueryString(sendData); 147 string reqString = ServerUtils.BuildQueryString(sendData);
146 // m_log.DebugFormat("[PRESENCE CONNECTOR]: queryString = {0}", reqString); 148 // m_log.DebugFormat("[PRESENCE CONNECTOR]: queryString = {0}", reqString);
diff --git a/OpenSim/Services/Interfaces/IPresenceService.cs b/OpenSim/Services/Interfaces/IPresenceService.cs
index a010611..b4c1859 100644
--- a/OpenSim/Services/Interfaces/IPresenceService.cs
+++ b/OpenSim/Services/Interfaces/IPresenceService.cs
@@ -115,7 +115,7 @@ namespace OpenSim.Services.Interfaces
115 public interface IPresenceService 115 public interface IPresenceService
116 { 116 {
117 bool LoginAgent(string userID, UUID sessionID, UUID secureSessionID); 117 bool LoginAgent(string userID, UUID sessionID, UUID secureSessionID);
118 bool LogoutAgent(UUID sessionID); 118 bool LogoutAgent(UUID sessionID, Vector3 position, Vector3 lookAt);
119 bool LogoutRegionAgents(UUID regionID); 119 bool LogoutRegionAgents(UUID regionID);
120 120
121 bool ReportAgent(UUID sessionID, UUID regionID, Vector3 position, Vector3 lookAt); 121 bool ReportAgent(UUID sessionID, UUID regionID, Vector3 position, Vector3 lookAt);
diff --git a/OpenSim/Services/LLLoginService/LLLoginService.cs b/OpenSim/Services/LLLoginService/LLLoginService.cs
index 2ae552f..47d1b16 100644
--- a/OpenSim/Services/LLLoginService/LLLoginService.cs
+++ b/OpenSim/Services/LLLoginService/LLLoginService.cs
@@ -163,7 +163,7 @@ namespace OpenSim.Services.LLLoginService
163 GridRegion destination = FindDestination(account, presence, session, startLocation, out where, out position, out lookAt); 163 GridRegion destination = FindDestination(account, presence, session, startLocation, out where, out position, out lookAt);
164 if (destination == null) 164 if (destination == null)
165 { 165 {
166 m_PresenceService.LogoutAgent(session); 166 m_PresenceService.LogoutAgent(session, presence.Position, presence.LookAt);
167 m_log.InfoFormat("[LLOGIN SERVICE]: Login failed, reason: destination not found"); 167 m_log.InfoFormat("[LLOGIN SERVICE]: Login failed, reason: destination not found");
168 return LLFailedLoginResponse.GridProblem; 168 return LLFailedLoginResponse.GridProblem;
169 } 169 }
@@ -195,7 +195,7 @@ namespace OpenSim.Services.LLLoginService
195 } 195 }
196 if (aCircuit == null) 196 if (aCircuit == null)
197 { 197 {
198 m_PresenceService.LogoutAgent(session); 198 m_PresenceService.LogoutAgent(session, presence.Position, presence.LookAt);
199 m_log.InfoFormat("[LLOGIN SERVICE]: Login failed, reason: {0}", reason); 199 m_log.InfoFormat("[LLOGIN SERVICE]: Login failed, reason: {0}", reason);
200 return LLFailedLoginResponse.AuthorizationProblem; 200 return LLFailedLoginResponse.AuthorizationProblem;
201 } 201 }
@@ -212,7 +212,7 @@ namespace OpenSim.Services.LLLoginService
212 { 212 {
213 m_log.WarnFormat("[LLOGIN SERVICE]: Exception processing login for {0} {1}: {2}", firstName, lastName, e.StackTrace); 213 m_log.WarnFormat("[LLOGIN SERVICE]: Exception processing login for {0} {1}: {2}", firstName, lastName, e.StackTrace);
214 if (m_PresenceService != null) 214 if (m_PresenceService != null)
215 m_PresenceService.LogoutAgent(session); 215 m_PresenceService.LogoutAgent(session, new Vector3(128, 128, 0), new Vector3(0, 1, 0));
216 return LLFailedLoginResponse.InternalError; 216 return LLFailedLoginResponse.InternalError;
217 } 217 }
218 } 218 }
diff --git a/OpenSim/Services/PresenceService/PresenceService.cs b/OpenSim/Services/PresenceService/PresenceService.cs
index 2884199..34a3154 100644
--- a/OpenSim/Services/PresenceService/PresenceService.cs
+++ b/OpenSim/Services/PresenceService/PresenceService.cs
@@ -87,7 +87,7 @@ namespace OpenSim.Services.PresenceService
87 return true; 87 return true;
88 } 88 }
89 89
90 public bool LogoutAgent(UUID sessionID) 90 public bool LogoutAgent(UUID sessionID, Vector3 position, Vector3 lookat)
91 { 91 {
92 PresenceData data = m_Database.Get(sessionID); 92 PresenceData data = m_Database.Get(sessionID);
93 if (data == null) 93 if (data == null)
@@ -103,6 +103,8 @@ namespace OpenSim.Services.PresenceService
103 103
104 data.Data["Online"] = "false"; 104 data.Data["Online"] = "false";
105 data.Data["Logout"] = Util.UnixTimeSinceEpoch().ToString(); 105 data.Data["Logout"] = Util.UnixTimeSinceEpoch().ToString();
106 data.Data["Position"] = position.ToString();
107 data.Data["LookAt"] = lookat.ToString();
106 108
107 m_Database.Store(data); 109 m_Database.Store(data);
108 110