From 7aecb3c7d9262b7dcd43b45736bb008a2f1ca742 Mon Sep 17 00:00:00 2001 From: onefang Date: Thu, 15 Aug 2019 02:18:35 +1000 Subject: Bandaid for ghost users, check and remove them from Presence when they log on. Once again OOP proves it's worse that spaghetti, but cutting up the spaghetti and hiding it all over the kitchen. Note the commented out bits from GateKeeperService.cs, this stuff is checked TWICE, though this time is for HGers, or not. --- .../ServiceConnectorsOut/Presence/BasePresenceServiceConnector.cs | 5 +++++ OpenSim/Region/Framework/Interfaces/IPresenceModule.cs | 8 ++++++++ 2 files changed, 13 insertions(+) (limited to 'OpenSim/Region') diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/BasePresenceServiceConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/BasePresenceServiceConnector.cs index fdbe10a..e014a57 100644 --- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/BasePresenceServiceConnector.cs +++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/BasePresenceServiceConnector.cs @@ -123,6 +123,11 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Presence return m_PresenceService.GetAgent(sessionID); } + public PresenceInfo GetAgentByUser(UUID userID) + { + return m_PresenceService.GetAgentByUser(userID); + } + public PresenceInfo[] GetAgents(string[] userIDs) { // Don't bother potentially making a useless network call if we not going to ask for any users anyway. diff --git a/OpenSim/Region/Framework/Interfaces/IPresenceModule.cs b/OpenSim/Region/Framework/Interfaces/IPresenceModule.cs index fb5933c..398611c 100644 --- a/OpenSim/Region/Framework/Interfaces/IPresenceModule.cs +++ b/OpenSim/Region/Framework/Interfaces/IPresenceModule.cs @@ -33,11 +33,19 @@ namespace OpenSim.Region.Framework.Interfaces { public string UserID; public UUID RegionID; + public UUID SessionID; + public PresenceInfo(string userID, UUID regionID, UUID sessionID) + { + UserID = userID; + RegionID = regionID; + SessionID = sessionID; + } public PresenceInfo(string userID, UUID regionID) { UserID = userID; RegionID = regionID; + SessionID = UUID.Zero; } } -- cgit v1.1