Beispiel #1
0
 internal override void WriteData(NbtWriter writeStream)
 {
     foreach (NbtTag tag in tags.Values)
     {
         tag.WriteTag(writeStream, true);
     }
     writeStream.Write(NbtTagType.End);
 }
Beispiel #2
0
 internal override void WriteData(NbtWriter writeStream)
 {
     writeStream.Write(Value.Length);
     for (int i = 0; i < Value.Length; i++)
     {
         writeStream.Write(Value[i]);
     }
 }
Beispiel #3
0
 internal override void WriteTag(NbtWriter writeStream, bool writeName)
 {
     writeStream.Write(NbtTagType.IntArray);
     if (writeName)
     {
         if (Name == null)
         {
             throw new NbtFormatException("Name is null");
         }
         writeStream.Write(Name);
     }
     WriteData(writeStream);
 }
Beispiel #4
0
 internal override void WriteTag(NbtWriter writeStream, bool writeName)
 {
     writeStream.Write(NbtTagType.Double);
     if (writeName)
     {
         if (Name == null)
         {
             throw new NbtFormatException("Name is null");
         }
         writeStream.Write(Name);
     }
     writeStream.Write(Value);
 }
Beispiel #5
0
 internal override void WriteData(NbtWriter writeStream)
 {
     if (ListType == NbtTagType.Unknown)
     {
         throw new NbtFormatException("NbtList had no elements and an Unknown ListType");
     }
     writeStream.Write(ListType);
     writeStream.Write(tags.Count);
     foreach (NbtTag tag in tags)
     {
         tag.WriteData(writeStream);
     }
 }
Beispiel #6
0
 internal override void WriteTag( NbtWriter writeStream, bool writeName )
 {
     writeStream.Write( NbtTagType.ByteArray );
     if( writeName ) {
         if( Name == null ) throw new NbtFormatException( "Name is null" );
         writeStream.Write( Name );
     }
     WriteData( writeStream );
 }
Beispiel #7
0
 internal override void WriteData( NbtWriter writeStream )
 {
     writeStream.Write( Value.Length );
     writeStream.Write( Value, 0, Value.Length );
 }
Beispiel #8
0
 internal override void WriteData(NbtWriter writeStream)
 {
     writeStream.Write(Value);
 }
Beispiel #9
0
 internal override void WriteTag( NbtWriter writeStream, bool writeName )
 {
     writeStream.Write( NbtTagType.Double );
     if( writeName ) {
         if( Name == null ) throw new NbtFormatException( "Name is null" );
         writeStream.Write( Name );
     }
     writeStream.Write( Value );
 }
Beispiel #10
0
 internal override void WriteData( NbtWriter writeStream )
 {
     writeStream.Write( Value );
 }
Beispiel #11
0
 internal override void WriteData(NbtWriter writeStream)
 {
     writeStream.Write(Value.Length);
     writeStream.Write(Value, 0, Value.Length);
 }
Beispiel #12
0
 internal override void WriteData( NbtWriter writeStream )
 {
     writeStream.Write( Value.Length );
     for( int i = 0; i < Value.Length; i++ ) {
         writeStream.Write( Value[i] );
     }
 }
Beispiel #13
0
 // WriteData does not write the tag's ID byte or the name
 internal abstract void WriteData([NotNull] NbtWriter writeReader);
Beispiel #14
0
 internal abstract void WriteTag([NotNull] NbtWriter writeReader, bool writeName);