Skip to content

liucard/datapack-python-translator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

#📄 Project Description – translator

This project is an automatic translator for Minecraft datapacks. It scans folders containing .mcfunction and .json files and replaces the original texts with their translations (e.g., Japanese → English or Portuguese). This way, you can quickly translate datapacks or resource files without editing each file manually.

Main features:

Bulk translation of .mcfunction and .json files.

Keeps the original folder structure.

Multi-language support (configurable).

🛠️ Requirements

Before running the script you need:

Python 3.10+ Official Python download page

pip (Python package manager)

Included with recent Python versions.

Python libraries used by the script (for example: googletrans, polib or similar – depends on the code inside the zip).

📥 Installation and Setup

  1. Download and extract the project

Save translator.zip to your computer.

Right-click and select Extract here (Windows) or run unzip translator.zip on Linux.

This creates a folder, e.g. translator/.

  1. (Optional) Create a virtual environment cd translator python -m venv venv

Activate the environment:

Windows:

venv\Scripts\activate

Linux/Mac:

source venv/bin/activate

  1. Install dependencies

Inside the project folder:

pip install -r requirements.txt

(If there’s no requirements.txt, send me the .py file content from the zip so I can list the exact packages.)

  1. Run the script

The main script should be something like translator.py (check inside the folder).

python translator.py

It will prompt you for:

Source folder (where the original files are).

Target language (e.g., pt for Portuguese).

Output folder (optional).

  1. Check the result

After running, the output folder will contain the translated files ready for use.

💡 Tip

If you want to translate an existing datapack, just point the source folder to the datapack’s folder.

To customize languages, either edit the variables at the top of the .py file or pass them as arguments.

About

automated translator in python to translate mcfunction and json files of datapacks without altering the structure

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages