Import textures

This commit is contained in:
2026-10-12 17:39:48 -03:00
parent 355e7a21ca
commit e5baeab193
7 changed files with 419 additions and 152 deletions
+9 -1
View File
@@ -108,7 +108,7 @@ vanilla ids go, and later kinds add sections for items, blocks and fluids.
| Kind | Java | bworld | Status |
| ------------ | -------------------------------------------- | ------------------------------------------------------------------------- | ------ |
| `model` | `assets/*/models/**.json` | `models/`, parents flattened in, faces renamed, Blockbench extras dropped | Built |
| `texture` | `assets/*/textures/**.png` and `.png.mcmeta` | `textures/`, with animations | |
| `texture` | `assets/*/textures/**.png` and `.png.mcmeta` | `textures/`, with animations | Built |
| `blockstate` | `assets/*/blockstates/*.json` | `variants` or `parts` on `blocks/*.json`, string states made numeric | |
| `lang` | `assets/*/lang/en_us.json` | item and block names | |
| `recipe` | `data/*/recipe(s)/**.json` | `recipes/`: vanilla types to bworld's, a mod's own types kept as they are | |
@@ -133,6 +133,14 @@ Run over Create 0.5.0.j's 2237 model files it converts 2099, all passing `valida
50 OBJ or composite models, 9 that are only parents, and 3 name clashes fixed with one remap line. 26 vanilla textures
they use (pistons, redstone torches, rails) aren't in bworld yet.
**What `texture` does today.** It copies PNGs keeping their folders, since bworld already names a texture in a subfolder
by joining the folders with `_`, which is the same id the converted models use. A `.png.mcmeta` becomes the `.json` next
to the png, keeping only its `animation` section: bworld reads the same format. It checks every texture against the
limits a `.bmod` checks, skips Minecraft's own textures (the remap points at bworld's), and needs `--namespace` when a
folder holds textures of more than one mod, since a texture's namespace comes from the mod it ends up in. For Create
0.5.0.j it copies 989 textures and 11 animations, and skips the six 512×512 title screen panoramas. Its textures and
models together make a mod `check-mods` accepts, with warnings only for the 27 missing textures.
**For Create**, `mods/create/import/` keeps the remap file and the block table. Re-running the import is one command,
and hand-written files are never in the folders it writes.