示例#1
0
        internal override void Write(NBTStream stream)
        {
            int len = this.Data.Length;

            stream.WriteInt(len);
            stream.Reservation(len);
            stream.WriteBytes(this.Data);
        }
示例#2
0
        internal override void WriteTag(NBTStream stream)
        {
            int len = this.Data.Length;

            if (this.Name != null)
            {
                stream.WriteByte((byte)this.TagType);
                stream.WriteString(this.Name);
                stream.WriteInt(len);
                stream.Reservation(len);
                stream.WriteBytes(this.Data);
            }
            else
            {
                throw new NullReferenceException("Tag Name Null");
            }
        }