This repository is a balanced template for creating Minecraft datapacks and resource packs (Java edition). You can use it as:
- a datapack-only project (logic + functions),
- a resource-pack-only project (assets like textures/models/sounds), or
- a combined development workspace (both
data/andassets/present).
Two short install flows below are split so you can quickly follow the one you need.
- Download or clone this repository.
- Copy the
data/folder (or the whole repository) to your world'sdatapacksfolder:- Location:
.minecraft/saves/[Your World Name]/datapacks/
- Location:
- In-game run
/reloador restart the world. Verifyload.mcfunctionran (usesay/tellrawtests inload.mcfunction).
Important
Datapacks must live in a world's datapacks/ folder (not in resourcepacks/). If you copy the whole repo, make sure you place it inside the world save datapacks/ directory.
Tip
Keep assets/ in the repository during datapack development if you also use resource assets locally; it will not interfere with datapack execution and simplifies testing.
- Download or clone this repository.
- Copy the
assets/folder (or the whole repository) to your Minecraftresourcepacksfolder:- Location:
~/.minecraft/resourcepacks/(or%appdata%/Roaming/.minecraft/resourcepacks/on Windows)
- Location:
- In Minecraft: Options → Resource Packs → Open Pack Folder (or use the resource pack menu) and enable the pack.
Important
Resource packs must be placed in Minecraft's resourcepacks/ folder (not datapacks/). Ensure pack.mcmeta has the correct pack_format for the target Minecraft version.
Tip
To distribute, create a ZIP containing assets/ and pack.mcmeta (optionally pack.png) and share that as the resource pack.
If you want both datapack logic and resource assets during development, keep both data/ and assets/ in the repo. For local testing:
- Copy
data/into your world'sdatapacks/and copyassets/into~/.minecraft/resourcepacks/. - Alternatively use the helper scripts included to move/backup unwanted directories automatically.
Caution
Using the helper scripts will move or delete directories by design. The scripts create timestamped backups by default — review backups after running. Use DRYRUN=1 when running via the Makefile to preview actions.
data/<namespace>/functions/: your functions and entry points (load.mcfunction,tick.mcfunction, etc.).data/minecraft/tags/functions/: tags (load.json,tick.json) that call your namespace functions automatically.pack.mcmeta(datapack): contains apack.pack_formatnumber appropriate for datapacks. Update this when targeting different Minecraft versions.- Namespace: a short identifier (example:
abc) used asabc:<function_name>when calling functions.
Quick checklist:
- Create/adjust
data/<namespace>/functions/load.mcfunctionfor setup commands. - Add
data/minecraft/tags/functions/load.jsonthat references your namespace load function.
Note
Datapack pack_format values are version-dependent. When in doubt, check the official Minecraft datapack documentation for the correct pack_format for your target versions.
assets/<namespace>/textures/(orassets/minecraft/textures/) for images and models.pack.mcmeta(resource pack): containspack.pack_formatfor resource packs — this value differs from datapackpack_formatand is version-dependent.pack.png(optional): 128×128 PNG shown in the resource pack selector.
Quick checklist:
- Place textures under
assets/minecraft/textures/...or under your namespace folder for namespaced assets. - Update
pack.mcmetawith a resource packpack_formatcompatible with your target Minecraft versions.
Warning
Resource pack pack_format differs from datapack pack_format. Using the wrong pack_format may prevent the pack from appearing or working correctly in some Minecraft versions.
pack.mcmeta: required for both pack types; containspack.pack_formatanddescription. Make sure it uses the correctpack_formatfor the pack type (datapack vs resource pack).data/: datapack logic (commands, functions, tags).assets/: resource pack content (textures, models, sounds).README.md,LICENSE,pack.png: docs, license, and optional icon.
Included in this template:
data/— a minimal datapack namespace (abc) withfunctions/load,tick,exampleandtests/scaffolding.assets/— a minimal resource-pack structure andREADME.mdwith.gitkeepinassets/minecraft/textures/so the folder is preserved in Git.Makefile— convenience targets to run helper scripts safely (includesDRYRUNand confirmation behavior).make-datapack.sh/make-resourcepack.sh— helpers to move or delete directories with backups by default..gitignore— updated with sensible defaults for development and helper-script backups.
Not included (by design):
- Full build tooling (Gradle, Maven, npm) — this template is intentionally lightweight and does not include language-specific build systems.
- Binary or compiled artifacts — compiled mod JARs or exported zipped releases are not stored here.
- CI workflows — sample workflow filenames and descriptions are suggested below, but workflow files are not included by default.
If you want any of the above added (for example a Gradle wrapper or a GitHub Actions workflow), tell me which and I can scaffold it.
Two scripts are included to help convert the repo into the variant you want:
make-datapack.sh— moves or deletesassets/so the repo becomes datapack-only.make-resourcepack.sh— moves or deletesdata/so the repo becomes resource-pack-only.
Usage (make executable first):
chmod +x make-datapack.sh make-resourcepack.sh
./make-datapack.sh # default: move 'assets' to a timestamped backup
./make-resourcepack.sh # default: move 'data' to a timestamped backup
./make-datapack.sh --delete # permanently delete 'assets'
./make-resourcepack.sh --delete # permanently delete 'data'Warning
The --delete option permanently removes files without creating a backup. Only use --delete if you are certain you do not need the removed directory.
Tip
Use the Makefile dry-run mode to preview script actions without performing them: make make-datapack DRYRUN=1 or make make-resourcepack DRYRUN=1.
- For datapacks: set your namespace, update
pack.mcmetapack_format, and document functions indata/<namespace>/README.md. - For resource packs: add
pack.png, organize textures underassets/, and set the resource packpack_format. - Use Git for version control and keep backups when deleting directories.
Important
Never commit API tokens, private keys, or other secrets into source. Use your Git hosting provider's encrypted secrets feature (e.g., GitHub Secrets) for CI workflows.
- I can make the helper scripts executable and commit the permission change.
- I can add a small
data/<namespace>/README.mdscaffold documenting the included functions. - I can add a
Makefileor simplepackage.jsonscripts to run the helper scripts consistently.
Which of the above would you like me to do next? (Pick one or say "none")
If you plan to publish releases automatically (for example via GitHub Actions) and upload to Modrinth, add these repository secrets to your repository settings:
MODRINTH_API_TOKEN: a Modrinth API token with project publishing permissions. Create this token in your Modrinth account settings → API tokens.MODRINTH_PROJECT_ID: the Modrinth project ID for your mod/resource (can be found in the project's Modrinth page URL or in project settings).
Notes:
- Store these values as encrypted repository secrets (e.g., GitHub: Settings → Secrets → Actions) rather than committing them into source.
- Typical CI usage: the action reads these secrets to authenticate to Modrinth and upload a build/artifact.
- I can add a sample GitHub Actions workflow that builds a ZIP and uploads a release to Modrinth using these secrets — tell me if you want that.
See LICENSE for details.