mirror of
https://github.com/opensim/opensim.git
synced 2026-08-07 01:35:46 +08:00
This hopefully fixes all issues with online/offline notifications across grids. http://opensimulator.org/mantis/view.php?id=5528
This commit is contained in:
@@ -830,10 +830,10 @@ namespace OpenSim.Region.CoreModules.Avatar.Friends
|
||||
|
||||
public bool LocalStatusNotification(UUID userID, UUID friendID, bool online)
|
||||
{
|
||||
m_log.DebugFormat("[FRIENDS]: Local Status Notify {0} that user {1} is {2}", friendID, userID, online);
|
||||
IClientAPI friendClient = LocateClientObject(friendID);
|
||||
if (friendClient != null)
|
||||
{
|
||||
//m_log.DebugFormat("[FRIENDS]: Local Status Notify {0} that user {1} is {2}", friendID, userID, online);
|
||||
// the friend in this sim as root agent
|
||||
if (online)
|
||||
friendClient.SendAgentOnline(new UUID[] { userID });
|
||||
|
||||
@@ -75,7 +75,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Friends
|
||||
/// <param name="friendID">friend whose status changed</param>
|
||||
/// <param name="online">status</param>
|
||||
/// <returns></returns>
|
||||
public bool StatusNotify(UUID userID, UUID friendID, bool online)
|
||||
public bool StatusNotify(UUID friendID, UUID userID, bool online)
|
||||
{
|
||||
return LocalStatusNotification(friendID, userID, online);
|
||||
}
|
||||
@@ -279,7 +279,14 @@ namespace OpenSim.Region.CoreModules.Avatar.Friends
|
||||
foreach (FriendInfo f in kvp.Value)
|
||||
ids.Add(f.Friend);
|
||||
UserAgentServiceConnector uConn = new UserAgentServiceConnector(kvp.Key);
|
||||
uConn.StatusNotification(ids, userID, online);
|
||||
List<UUID> friendsOnline = uConn.StatusNotification(ids, userID, online);
|
||||
// need to debug this here
|
||||
if (online)
|
||||
{
|
||||
IClientAPI client = LocateClientObject(userID);
|
||||
if (client != null)
|
||||
client.SendAgentOnline(friendsOnline.ToArray());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user