diff options
-rw-r--r-- | OpenSim/Region/Framework/Scenes/ScenePresence.cs | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index 715a9b6..576b8c2 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs | |||
@@ -1057,30 +1057,32 @@ namespace OpenSim.Region.Framework.Scenes | |||
1057 | 1057 | ||
1058 | m_scene.EventManager.TriggerSetRootAgentScene(m_uuid, m_scene); | 1058 | m_scene.EventManager.TriggerSetRootAgentScene(m_uuid, m_scene); |
1059 | 1059 | ||
1060 | UUID groupUUID = UUID.Zero; | 1060 | UUID groupUUID = ControllingClient.ActiveGroupId; |
1061 | string GroupName = string.Empty; | 1061 | string groupName = string.Empty; |
1062 | ulong groupPowers = 0; | 1062 | ulong groupPowers = 0; |
1063 | 1063 | ||
1064 | // ---------------------------------- | 1064 | // ---------------------------------- |
1065 | // Previous Agent Difference - AGNI sends an unsolicited AgentDataUpdate upon root agent status | 1065 | // Previous Agent Difference - AGNI sends an unsolicited AgentDataUpdate upon root agent status |
1066 | try | 1066 | try |
1067 | { | 1067 | { |
1068 | if (gm != null) | 1068 | if (groupUUID != UUID.Zero && gm != null) |
1069 | { | 1069 | { |
1070 | groupUUID = ControllingClient.ActiveGroupId; | ||
1071 | GroupRecord record = gm.GetGroupRecord(groupUUID); | 1070 | GroupRecord record = gm.GetGroupRecord(groupUUID); |
1072 | if (record != null) | 1071 | if (record != null) |
1073 | GroupName = record.GroupName; | 1072 | groupName = record.GroupName; |
1073 | |||
1074 | GroupMembershipData groupMembershipData = gm.GetMembershipData(groupUUID, m_uuid); | 1074 | GroupMembershipData groupMembershipData = gm.GetMembershipData(groupUUID, m_uuid); |
1075 | |||
1075 | if (groupMembershipData != null) | 1076 | if (groupMembershipData != null) |
1076 | groupPowers = groupMembershipData.GroupPowers; | 1077 | groupPowers = groupMembershipData.GroupPowers; |
1077 | } | 1078 | } |
1078 | ControllingClient.SendAgentDataUpdate(m_uuid, groupUUID, Firstname, Lastname, groupPowers, GroupName, | 1079 | |
1079 | Grouptitle); | 1080 | ControllingClient.SendAgentDataUpdate( |
1081 | m_uuid, groupUUID, Firstname, Lastname, groupPowers, groupName, Grouptitle); | ||
1080 | } | 1082 | } |
1081 | catch (Exception e) | 1083 | catch (Exception e) |
1082 | { | 1084 | { |
1083 | m_log.Debug("[AGENTUPDATE]: " + e.ToString()); | 1085 | m_log.Error("[AGENTUPDATE]: Error ", e); |
1084 | } | 1086 | } |
1085 | // ------------------------------------ | 1087 | // ------------------------------------ |
1086 | 1088 | ||