Ejemplo n.º 1
0
        /// <summary>
        /// Serialization this instance.
        /// </summary>
        public virtual CustomerArray <byte> Serialization()
        {
            CustomerArray <byte> b = new CustomerArray <byte>();

            int start = 0;

            start += BitConvert.MemoryCopy(MsgID, ref b, start);
            start += BitConvert.MemoryCopy(MsgType, ref b, start);
            start += BitConvert.MemoryCopy(MsgSeq, ref b, start);
            start += BitConvert.MemoryCopy(SourceType, ref b, start);
            start += BitConvert.MemoryCopy(DestType, ref b, start);
            start += BitConvert.MemoryCopy(Session.PlayerID, ref b, start);
            start += BitConvert.MemoryCopy(DestId, ref b, start);
            return(b);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Serialization this instance.
        /// </summary>
        public override CustomerArray <byte> Serialization()
        {
            CustomerArray <byte> b = base.Serialization();

            if (b == null)
            {
                return(null);
            }

            int offset = b.CurrentLength;

            offset += BitConvert.MemoryCopy(Name, ref b, offset);
            offset += BitConvert.MemoryCopy(Password, ref b, offset);

            return(b);
        }
Ejemplo n.º 3
0
        /// <summary>
        /// Serialization this instance.
        /// </summary>
        public override CustomerArray <byte> Serialization()
        {
            CustomerArray <byte> b = base.Serialization();

            if (b == null)
            {
                return(null);
            }

            int offset = b.CurrentLength;

            offset += BitConvert.MemoryCopy((UInt64)Session.Uid, ref b, offset);
            offset += BitConvert.MemoryCopy(0, ref b, offset); //time.

            return(b);
        }
Ejemplo n.º 4
0
        /// <summary>
        /// Serialization this instance.
        /// </summary>
        public override CustomerArray <byte> Serialization()
        {
            CustomerArray <byte> b = base.Serialization();

            if (b == null)
            {
                return(null);
            }

            int offset = b.CurrentLength;

            offset += BitConvert.MemoryCopy((UInt64)Session.Uid, ref b, offset);
            offset += BitConvert.MemoryCopy(0, ref b, offset); //time.
            offset += BitConvert.MemoryCopy((ushort)subOperation.CurrentLength, ref b, offset);
            for (int i = 0, max = subOperation.CurrentLength, j = b.CurrentLength; i < max; i++, j++)
            {
                b[j] = subOperation[i];
            }

            return(b);
        }