Skip to main content

# minecraftmap Simple Python 3 editor for Minecraft Maps in NBT format. Allows editing the map image with the Python Image Library or by editing bytes in the native format.

The Map class defined in the module provides convenient reading and writing of minecraft map nbt data using Thomas Woolford’s nbt library. It allows for direct reading and writing in minecraft’s native color format with the getbyte(), setbyte(), getpoint(), and setpoint() methods, and it allows for PIL-based editing using the draw attribute. The saveimagebmp() and saveimagepng() methods are front-ends for PIL’s Image.save(), and the savenbt() method allows for saving the nbt data into the same file, or into a new one. Be careful that the draw (PIL) and file (nbt) attributes are not syncronized and must be updated manually with genimage() and imagetonbt() methods. Also use caution when drawing in color, as any non-minecraft colors (check allcolors on an initiated Map) will raise a ColorError.

Maps are initiated with the filename of the nbt map file and optionally with eco=True, which removes the resource-intensive genimage() on startup. The font included in the package as Map.font is Andrew Tyler’s Minecraftia. The PIL method text() of the draw attribute can take it as the font= named argument.

Requires PIL and Thomas Woolford’s NBT library. Includes Andrew Tyler’s Minecraftia font.

Metadata

Release files for minecraftmap 0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for minecraftmap 0.1
File Size Uploaded
minecraftmap-0.1.zip 14.5 kB Details

Release files / minecraftmap-0.1.zip

Download URL minecraftmap-0.1.zip
Size 14.5 kB
Tags Source
SHA-256 checksum
How to use checksums
cc71384091ff885a4362cf0d96e2bed973f8232785641c7a2b0e15e0ce19950a
BLAKE2b-256 checksum
How to use checksums
08befcb4747015f8e36b80b20954803a06f22e0370081d92325d3990647d85de
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

0.3

1 release file

0.2

1 release file

0.1.1

1 release file

This release

0.1 This release

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page