NBT
Documentation for NBT.
NBT.TagCompound
NBT.TagList
NBT.begin_compound
NBT.begin_compound
NBT.begin_list
NBT.begin_list
NBT.begin_nbt_file
NBT.end_compound
NBT.end_nbt_file
NBT.read_nbt_uncompressed
NBT.write_nbt_uncompressed
NBT.write_tag
NBT.write_tag
NBT.TagCompound
— Typestruct TagCompound{T}
Represents an NBT compound tag, containing an array of Pairs name => data. See minecraft wiki.
Properties
data::Vector{Pair{String, T}}
: The data in the tag.
NBT.TagList
— Typestruct TagList{T}
Represents an NBT list tag, containing an array of T. See minecraft wiki.
Properties
data::Vector{T}
: The data in the tag.
NBT.begin_compound
— Methodbegin_compound(io, name)
Begin an NBT Compound tag and return the number of bytes written. Use only for the root tag (with an empty name) or between begin_compound
and end_compound
.
NBT.begin_compound
— Methodbegin_compound(io)
Begin an NBT Compound tag and return the number of bytes written. Use only after begin_list
.
Note: This method just returns 0
, but is included for completeness and to allow for more readable code.
NBT.begin_list
— Methodbegin_list(io, length, type)
Begin an NBT List tag with the specified length and element type and return the number of bytes written. Use only after begin_list
.
NBT.begin_list
— Methodbegin_list(io, name, length, type)
Begin an NBT List tag with the specified length and element type and return the number of bytes written. Use only between begin_compound
and end_compound
.
NBT.begin_nbt_file
— Methodbegin_nbt_file(io)
Begin an NBT file and return a stream and the number of bytes written.
NBT.end_compound
— Methodend_compound(io)
End the current NBT Compound tag and return the number of bytes written.
NBT.end_nbt_file
— Methodend_nbt_file(io)
End an NBT file and return the number of bytes written.
NBT.read_nbt_uncompressed
— Methodread_nbt_uncompressed(io, ::Type{Tag})
Reads an nbt tag from an uncompressed IO
. Not exported.
NBT.write_nbt_uncompressed
— Methodwrite_nbt_uncompressed(io, tag)
Writes an nbt tag to an uncompressed IO
. Not exported.
NBT.write_tag
— Methodwrite_tag(io, data)
Write the data
tag and return the number of bytes written. Use only after begin_list
.
NBT.write_tag
— Methodwrite_tag(io, name => data)
Write the name => data
pair and return the number of bytes written. Use only between begin_compound
and end_compound
.