当前位置: 首页>>代码示例>>C#>>正文


C# IClientAPI.SendAgentDropGroup方法代码示例

本文整理汇总了C#中IClientAPI.SendAgentDropGroup方法的典型用法代码示例。如果您正苦于以下问题:C# IClientAPI.SendAgentDropGroup方法的具体用法?C# IClientAPI.SendAgentDropGroup怎么用?C# IClientAPI.SendAgentDropGroup使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在IClientAPI的用法示例。


在下文中一共展示了IClientAPI.SendAgentDropGroup方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: LeaveGroupRequest

        public void LeaveGroupRequest(IClientAPI remoteClient, UUID groupID)
        {
            if (m_debugEnabled) m_log.DebugFormat("[Groups]: {0} called", System.Reflection.MethodBase.GetCurrentMethod().Name);

            m_groupData.RemoveAgentFromGroup(GetRequestingAgentIDStr(remoteClient), GetRequestingAgentIDStr(remoteClient), groupID);

            remoteClient.SendLeaveGroupReply(groupID, true);

            remoteClient.SendAgentDropGroup(groupID);

            // SL sends out notifcations to the group messaging session that the person has left
            // Should this also update everyone who is in the group?
            SendAgentGroupDataUpdate(remoteClient, GetRequestingAgentID(remoteClient));
        }
开发者ID:JamesStallings,项目名称:opensimulator,代码行数:14,代码来源:GroupsModule.cs

示例2: LeaveGroupRequest

        public void LeaveGroupRequest(IClientAPI remoteClient, UUID groupID)
        {
            if (m_debugEnabled)
                MainConsole.Instance.DebugFormat("[GROUPS]: {0} called", MethodBase.GetCurrentMethod().Name);

            if (
                !m_groupData.RemoveAgentFromGroup(GetRequestingAgentID(remoteClient), GetRequestingAgentID(remoteClient),
                                                  groupID))
                return;

            m_cachedGroupMemberships.Remove(remoteClient.AgentId);
            remoteClient.SendLeaveGroupReply(groupID, true);

            remoteClient.SendAgentDropGroup(groupID);
            RemoveFromGroupPowersCache(remoteClient.AgentId, groupID);

            if (remoteClient.ActiveGroupId == groupID)
                GroupTitleUpdate(remoteClient, UUID.Zero, UUID.Zero);

            SendAgentGroupDataUpdate(remoteClient, GetRequestingAgentID(remoteClient));

            if (m_imService != null)
            {
                // SL sends out notifications to the group messaging session that the person has left
                GridInstantMessage im = new GridInstantMessage
                                            {
                                                FromAgentID = groupID,
                                                Dialog = (byte) InstantMessageDialog.SessionSend,
                                                BinaryBucket = new byte[0],
                                                FromAgentName = "System",
                                                FromGroup = true,
                                                SessionID = groupID,
                                                Message = remoteClient.Name + " has left the group.",
                                                Offline = 1,
                                                RegionID = remoteClient.Scene.RegionInfo.RegionID,
                                                Timestamp = (uint) Util.UnixTimeSinceEpoch(),
                                                ToAgentID = UUID.Zero
                                            };

                m_imService.EnsureSessionIsStarted(groupID);
                m_imService.SendChatToSession(UUID.Zero, im);
            }
        }
开发者ID:BogusCurry,项目名称:WhiteCore-Dev,代码行数:43,代码来源:GroupsModule.cs

示例3: LeaveGroupRequest

        public void LeaveGroupRequest(IClientAPI remoteClient, UUID groupID)
        {
            if (m_debugEnabled) m_log.DebugFormat("[GROUPS]: {0} called", System.Reflection.MethodBase.GetCurrentMethod().Name);

            if (!m_groupData.RemoveAgentFromGroup(GetRequestingAgentID(remoteClient), GetRequestingAgentID(remoteClient), groupID))
                return;

            remoteClient.SendLeaveGroupReply(groupID, true);

            remoteClient.SendAgentDropGroup(groupID);

            SendAgentGroupDataUpdate(remoteClient, GetRequestingAgentID(remoteClient));

            if (m_groupsMessagingModule != null)
            {
                // SL sends out notifcations to the group messaging session that the person has left
                GridInstantMessage im = new GridInstantMessage();
                im.fromAgentID = groupID.Guid;
                im.dialog = (byte)InstantMessageDialog.SessionSend;
                im.binaryBucket = new byte[0];
                im.fromAgentName = "System";
                im.fromGroup = true;
                im.imSessionID = groupID.Guid;
                im.message = remoteClient.Name + " has left the group.";
                im.offline = 1;
                im.RegionID = remoteClient.Scene.RegionInfo.RegionID.Guid;
                im.timestamp = (uint)Util.UnixTimeSinceEpoch();
                im.toAgentID = Guid.Empty;

                m_groupsMessagingModule.SendMessageToGroup(im, groupID);
            }
        }
开发者ID:KristenMynx,项目名称:Aurora-Sim,代码行数:32,代码来源:GroupsModule.cs

示例4: LeaveGroupRequest

        public void LeaveGroupRequest(IClientAPI remoteClient, UUID groupID)
        {
            if (m_debugEnabled) MainConsole.Instance.DebugFormat("[GROUPS]: {0} called", MethodBase.GetCurrentMethod().Name);

            if (
                !m_groupData.RemoveAgentFromGroup(GetRequestingAgentID(remoteClient), GetRequestingAgentID(remoteClient),
                                                  groupID))
                return;

            remoteClient.SendLeaveGroupReply(groupID, true);

            remoteClient.SendAgentDropGroup(groupID);

            if (remoteClient.ActiveGroupId == groupID)
                GroupTitleUpdate(remoteClient, UUID.Zero, UUID.Zero);

            SendAgentGroupDataUpdate(remoteClient, GetRequestingAgentID(remoteClient));

            if (m_groupsMessagingModule != null)
            {
                // SL sends out notifcations to the group messaging session that the person has left
                GridInstantMessage im = new GridInstantMessage
                                            {
                                                fromAgentID = groupID,
                                                dialog = (byte) InstantMessageDialog.SessionSend,
                                                binaryBucket = new byte[0],
                                                fromAgentName = "System",
                                                fromGroup = true,
                                                imSessionID = groupID,
                                                message = remoteClient.Name + " has left the group.",
                                                offline = 1,
                                                RegionID = remoteClient.Scene.RegionInfo.RegionID,
                                                timestamp = (uint) Util.UnixTimeSinceEpoch(),
                                                toAgentID = UUID.Zero
                                            };

                m_groupsMessagingModule.EnsureGroupChatIsStarted(groupID);
                m_groupsMessagingModule.SendMessageToGroup(im, groupID);
            }
        }
开发者ID:Gnu32,项目名称:Silverfin,代码行数:40,代码来源:GroupsModule.cs


注:本文中的IClientAPI.SendAgentDropGroup方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。