Example #1
0
    internal static void Execute(object msg, NetConnection conn, NetworkSystem networkSystem)
    {
        Msg_RC_ControlObject _msg = msg as Msg_RC_ControlObject;

        if (null == _msg)
        {
            return;
        }
    }
Example #2
0
        internal static Msg_RC_ControlObject BuildControlObjectMessage(int controller, int controlled, bool isControl)
        {
            Msg_RC_ControlObject builder = new Msg_RC_ControlObject();

            builder.controller_id      = controller;
            builder.controlled_id      = controlled;
            builder.control_or_release = isControl;
            return(builder);
        }
Example #3
0
        private void ReleaseControl(NpcInfo npc)
        {
            if (null != npc.ControllerObject)
            {
                int controller = npc.ControllerObject.GetId();
                int controlled = npc.GetId();
                CharacterInfo.ReleaseControlObject(npc.ControllerObject, npc);

                Msg_RC_ControlObject builder = DataSyncUtility.BuildControlObjectMessage(controller, controlled, false);
                NotifyAllUser(builder);
            }
        }
Example #4
0
        private void ReleaseControl(UserInfo user)
        {
            if (null != user.ControlledObject)
            {
                int controller = user.GetId();
                int controlled = user.ControlledObject.GetId();
                CharacterInfo.ReleaseControlObject(user, user.ControlledObject);

                Msg_RC_ControlObject builder = DataSyncUtility.BuildControlObjectMessage(controller, controlled, false);
                NotifyAllUser(builder);
            }
        }