/// <summary>
        /// Wrap all contents into a byte array for sending
        /// </summary>
        public override byte[] Pack()
        {
            var buffer = new byte[SizeOf + 2];
            base.Pack(ref buffer, buffer.Length);

            var packer = new SledNetworkBufferPacker(ref buffer, SizeOf);
            packer.PackInt16(StackLevel);

            return buffer;
        }
        /// <summary>
        /// Wrap all contents into a byte array for sending
        /// </summary>
        public override byte[] Pack()
        {
            int size
                = SizeOf            // Base
                + 1                 // Byte     - what
                + 1                 // Byte     - context
                + 2                 // UInt16   - key value pairs count
                + 2                 // Int16    - stack level
                + 4                 // Int32    - index
                + 2 + Encoding.UTF32.GetBytes(Value).Length // string length + string
                + 2;                // Int16    - value type

            foreach (var kv in LookUp.NamesAndTypes)
            {
                var bytes = Encoding.UTF8.GetBytes(kv.Name);

                size += 2;              // UInt16   - length of string that follows
                size += bytes.Length;   // UInt16   - string
                size += 2;              // UInt16   - name lua_t<type>
            }

            var buffer = new byte[size];
            base.Pack(ref buffer, buffer.Length);

            var packer = new SledNetworkBufferPacker(ref buffer, SizeOf);
            packer.PackByte((Byte)(int)LookUp.Scope);
            packer.PackByte((Byte)(int)LookUp.Context);
            packer.PackUInt16((UInt16)LookUp.NamesAndTypes.Count);
            packer.PackInt16((Int16)LookUp.StackLevel);
            packer.PackInt32(LookUp.Index);
            packer.PackString(Value);
            packer.PackInt16(ValueType);

            foreach (var kv in LookUp.NamesAndTypes)
            {
                packer.PackString(kv.Name);
                packer.PackUInt16((UInt16)kv.NameType);
            }

            return buffer;
        }