Skip to content

Latest commit

 

History

History
44 lines (31 loc) · 1.21 KB

README.md

File metadata and controls

44 lines (31 loc) · 1.21 KB

NBT

Hex pm

Functions for parsing Named Binary Tag files, common to Minecraft save files.

Installation

NBT is available on hex.pm. The package can be installed by adding nbt to your list of dependencies in mix.exs:

def deps do
  [
    {:nbt, "~> 0.1.0"}
  ]
end

Documentation can be generated with ExDoc and found online at https://hexdocs.pm/nbt.

Usage

This library does not currently handle file management or compression. I recommend some research into the build-in :zlib Erlang module for the various compression tools you will need for parsing minecraft files.

"test/fixtures/bigtest.nbt"
|> File.read!()
|> :zlib.gunzip()
|> NBT.parse

Resources

For the curious, here is a list of pages that I found useful in writing this library.