Useful tools for Minecraft worlds such as removing unused chunks and finding blocks, command blocks or entities.
Project description
MCWorldTools
Useful tools for Minecraft worlds such as removing unused chunks and finding blocks, command blocks or entities.
Tested from 1.7.10
up to 1.18.2
.
Installation
pip install mcworldtools
Usage
You can simply run the command mcworldtools
in a Minecraft world folder.
The script will tell you the name of your Minecraft world and - if possible, it may not be in older versions - the Minecraft version of your world.
After that you can choose which tool you want to use by stating the number of the tool.
Warning
Do NOT use these tools for a world that is currently opened (i.e. in Minecraft Singleplayer or by a Minecraft server). Doing so may lead to unintended consequences. I do NOT take any responsibility for your Minecraft world if you do that.
Further usage
mcworldtools [-h] [-w WORLD] [-t TOOL] [-o OUTPUT_FILE] [-f {plain,json,yaml}] [--confirm]
Arguments
-h --help
Show the help message and exit.-v --version
Show the installed version and exit.-w WORLD, --world WORLD
Use a different world folder than the current working directory. You can provide this option multiple times for multiple words.-t TOOL, --tool TOOL
Choose the tool to use beforehand.-o OUTPUT_FILE, --output-file OUTPUT_FILE
Select a file to write the output statistics to. This option is mandatory when searching for something.-f {plain,json,yaml}, --output-format {plain,json,yaml}
The output file format. May beplain
(default),json
oryaml
.-i INPUT_FILE, --input-file INPUT_FILE
Select a file to read input values from. See below for more information.--confirm
Automatically confirm any confirmation requests.
Dimension notes
You can state dimensions in input files or when you are asked for locations when removing blocks or command blocks.
Dimensions will be returned when finding blocks, command blocks or entities.
A dimension may be one of overworld
, nether
or end
.
Please note that when using this tool on server worlds where nether and end are in seperate folders (world_nether
and world_the_end
) and you are executing the script on one of these, the dimension will be overworld
because there is no way of detecting to which dimension the world folder is belonging.
The dimensions nether
and end
will only be used if the nether and end files are in a folder named WORLD_FOLDER/DIM-1
(nether) or WORLD_FOLDER/DIM1
(end).
Input files
The content of the input files stated in the command have to be in valid json format.
You don't have to specify anything in the input file, but you won't get asked for something that you specified. That is useful for automated tasks.
Here is what you can change with these input files:
Remove unused chunks
{
"inhabited_time": 0
}
inhabited_time
- The time for how long a player may have been in a chunk for it to be deleted (in seconds). Defaults to 0.
Find/remove command blocks
Possibility 1: Finding command blocks
{
"action": 1,
"only_executing": false,
"dimension": "overworld"
}
action
-1
for finding command blocks.only_executing
- If enabled, only command blocks that are either powered or in automatic mode will be found.dimension
- The dimension in which command blocks should be searched. Set tonull
for all dimensions. See dimension notes for more information.
Possibility 2: Removing command blocks
{
"action": 2,
"locations": [
{
"dimension": "overworld",
"x": 3,
"y": 72,
"z": 6
},
{
"dimension": "nether",
"x": 5,
"y": 129,
"z": 200
}
]
}
action
-2
for removing command blocks.locations
- A list of locations where command blocks should be removed. Fordimension
see the dimension notes.
Find/remove entities
Possibility 1: Finding entities
{
"action": 1,
"id": "minecraft:zombie",
"dimension": "overworld",
"nbt_keys": ["OnGround", "Age"]
}
action
-1
for finding entities.id
- The entity id to filter entities. Set tonull
for all entities. You don't have to prepend it withminecraft:
dimension
- The dimension in which entities should be searched. Set tonull
for all dimensions. See dimension notes for more information.nbt_keys
- A list of NBT keys to be included in the output. Set to[]
(empty list) for all NBT keys. Set tonull
to not include any NBT keys.
Possibility 2: Removing entities by id
{
"action": 2,
"remove_by": "id",
"id": "minecraft:zombie"
}
action
-2
for removing entities.remove_by
-id
for removing by id.id
- The id of which entities should be removed.
Possibility 3: Removing entities by uuid
{
"action": 2,
"remove_by": "uuid",
"uuid": "325cdf04-8211-4f7d-8a47-79b291c1ca77"
}
action
-2
for removing entities.remove_by
-uuid
for removing by uuid.uuid
- The uuid of the entity to remove.
Possibility 4: Removing all entities
{
"action": 2,
"remove_by": "all"
}
action
-2
for removing entities.remove_by
-all
for removing all entities.
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
File details
Details for the file mcworldtools-1.2.6.tar.gz
.
File metadata
- Download URL: mcworldtools-1.2.6.tar.gz
- Upload date:
- Size: 28.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.26.0 requests-toolbelt/0.9.1 urllib3/1.26.7 tqdm/4.62.3 importlib-metadata/4.8.1 keyring/23.4.1 rfc3986/1.5.0 colorama/0.4.4 CPython/3.6.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 98a826d785e064cc99deeb377dfbb003a3bfc17a14f6879981b7adce19efcb2c |
|
MD5 | b72d9aa9631530c104aee6efd9d1db7d |
|
BLAKE2b-256 | b57f199814c0ee9a2593b28446d7ab1f0776066cdfeae57db8608f65aa000cb1 |
File details
Details for the file mcworldtools-1.2.6-py3-none-any.whl
.
File metadata
- Download URL: mcworldtools-1.2.6-py3-none-any.whl
- Upload date:
- Size: 32.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.26.0 requests-toolbelt/0.9.1 urllib3/1.26.7 tqdm/4.62.3 importlib-metadata/4.8.1 keyring/23.4.1 rfc3986/1.5.0 colorama/0.4.4 CPython/3.6.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 212203e0367c8cfcbd8933e248bc9a0b359cc7bee8db74f4f315b690bf9ce855 |
|
MD5 | c3e1a5ba8e40f346d7d30ac4e7d2aa9b |
|
BLAKE2b-256 | 1db4fd362111f1388d47c43f9ed41db26387a0a071dbd05f161969c54ba70f61 |