Script that allows you to extract and scale Minecraft's item and block textures.
Project description
textureminer
A Python script that allows you to extract and scale Minecraft's item and block textures. It automates the process of downloading the necessary files and performing the required operations.
Table of Contents
Getting Started
Prerequisites
Install Git if you plan on using the Bedrock edition.
You can install Git using your system's package manager, or by downloading the installer from the official website.
-
Linux
sudo apt install git
-
MacOS
brew install git
-
Windows
winget install Git.Git
Install/update the pip package manager.
python3 -m pip install --upgrade pip
It's also recommended to use a virtual environment.
-
Linux / MacOS
python3 -m venv <venv-name> source venv/bin/activate
-
Windows
python3 -m venv <venv-name> <venv-name>/Scripts/activate
Installation
Use pip to install textureminer
package.
pip install --upgrade textureminer
After installing the package, textureminer
will be available as a command line tool.
Usage
The base syntax for textureminer
is textureminer [version] [flags]
. If version is omitted, the latest version of Minecraft will be used. If no edition flags are specified, the Java edition will be used.
To download and scale textures for the most recent Java version, run the following command.
textureminer
Add --bedrock
or -b
to use the Bedrock edition.
textureminer --bedrock # or -b
You can also pick a specific update or update channel of Minecraft to download textures for.
textureminer 1.17.1 # a java stable release
textureminer 22w14a # a java snapshot
textureminer v1.20.0.1 # a bedrock release
textureminer v1.20.50.22-preview # a bedrock preview
# update channels, gets latest version from channel, by default using java edition if no edition is specified
textureminer stable # stable version
textureminer experimental # snapshot/preview version depending on edition
textureminer snapshot # java snapshot
textureminer preview # bedrock preview, no need to specify edition
There is also options for the scale factor and output directory. Get more information with the --help
flag.
textureminer --help
At a high level, the script follows the following steps:
- Download files.
- If Java edition, download the client
.jar
file for the specified version from Mojang's servers. - If Bedrock edition, clone the Mojang/bedrock-samples repository from GitHub.
- If Java edition, download the client
- Extract correct files.
- If Java edition, extract the textures from the
.jar
file. - If Bedrock edition, change to the specified version tag.
- If Java edition, extract the textures from the
- Filter files, only leaving item and block textures to the specified output directory (default:
~/Downloads/textureminer/<edition>/<version>/
). - Scale textures by a specified factor (default: 100).
- Merge block and item textures into a single directory by default.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for textureminer-2.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0444b9e0b02453834fec587751b577b7db502a7acba76e32e680c6be480b8cf5 |
|
MD5 | 1c01235ba15a1ef11275409450840e33 |
|
BLAKE2b-256 | aa14c973c1eafad6d682ec1ff5a9b4abc3abb8aa483bada987a730a57059e955 |