NBT
NBT copied to clipboard
Opening servers.dat.
I want to try adding some servers to the list using python, and seems this library would work. Testing it out does not go so well tho. I opened the .minecraft folder in a terminal, and in the python shell wrote the following:
>>> from nbt import nbt
>>> nbtfile = nbt.NBTFile('./servers.dat')
I get this error:
gzip.BadGzipFile: Not a gzipped file (b'\n\x00')
How do i fix this? Do i need to GZip it first?
Same for
from nbt import nbt
og_servers_dat = "src_servers.dat"
with open(og_servers_dat, "rb") as input_file:
nbtfile = nbt.NBTFile(fileobj=input_file)
gzip.BadGzipFile: Not a gzipped file (b'\n\x00')