示例#1
0
    internal static void Execute(object msg, NetConnection conn, NetworkSystem networkSystem)
    {
        Msg_CRC_StopSkill skill_msg = msg as Msg_CRC_StopSkill;

        if (null == skill_msg)
        {
            return;
        }
    }
示例#2
0
    internal static void Execute(object msg, RoomPeer peer)
    {
        Msg_CRC_StopSkill stopskill_msg = msg as Msg_CRC_StopSkill;

        if (null == stopskill_msg)
        {
            return;
        }
        stopskill_msg.role_id = peer.RoleId;
        peer.BroadCastMsgToRoom(stopskill_msg);
    }
        private void OnUserStopSkill(UserInfo user)
        {
            Scene scene = user.SceneContext.CustomData as Scene;

            if (null != scene)
            {
                SkillInfo skillInfo = user.GetSkillStateInfo().GetCurSkillInfo();
                if (null == skillInfo || skillInfo.IsSkillActivated)
                {
                    scene.SkillSystem.StopSkill(user.GetId());
                }

                Msg_CRC_StopSkill skillBuilder = new Msg_CRC_StopSkill();
                skillBuilder.role_id = user.GetId();

                LogSystem.Debug("Send Msg_CRC_StopSkill, EntityId={0}",
                                user.GetId());
                scene.NotifyAreaUser(user, skillBuilder, false);
            }
        }
示例#4
0
        internal static void Execute(object msg, User user)
        {
            Msg_CRC_StopSkill end_skill = msg as Msg_CRC_StopSkill;

            if (end_skill == null)
            {
                return;
            }
            CharacterInfo charactor = user.Info;

            if (charactor == null)
            {
                LogSys.Log(LOG_TYPE.ERROR, "StopSkillHandler, charactor {0} not exist", user.RoleId);
                return;
            }
            Scene scene = user.OwnRoom.GetActiveScene();

            if (null != scene)
            {
                scene.SkillSystem.StopSkill(user.RoleId);
            }
        }