Minecraft Modding Folder Structure

The folder structure for Minecraft Modding is essential for Forge. If anything is misspelled or misplaced this might result in textures not displaying properly or loot tables and recipes not being recognized.

That is why it is crucial to get the folder structure right and this is what I will explain with this post. There is some flexibility with some of the folder which is going to come apparent. In the end this is the folder structure we wanna end up with:

The resulting folder structure

We are starting with this as the folder structure:

src/
├── generated [main]/
│   └── ...
├── main/
│   ├── java/
│   └── resources/
│       ├── META-INF/
│       │   └── mods.toml
│       └── pack.mcmeta
└── test/
    └── ...

Only the contents of main > resources really interest us for this tutorial (for future displays I will start from the resources folder for ease!). We’ll first create two folder under the resources folder called assets and data. Make sure all is written in lower-case and has the correct spelling.

resources/
├── assets/
├── data/
├── META-INF/
│   └── mods.toml
└── pack.mcmeta

Is the structure we now have. Because the data folder is a bit easier, we’ll tackle that one first.

Data Folder

Inside the data folder things like loot tables, recipes, custom structures and even more. For our purposes we will only add the folders for loot tables and recipes. Everything else is far more advanced.

Firstly we will need a folder with our mod id as its name. If you have also chosen tutorialmod as your mod id and this is the name of the folder. Make sure it is written correctly, this is super important!

Loot Table and Recipes Folder

Inside of that new folder we can now create the loot_tables folder and the recipes folder. Inside the loot_tables folder we can also immediately add the blocks folder. This is needed if we want to add drops when we destroy blocks. For example the block itself is also a loot table. Loot tables themselves will be discussed much later. For the time being I recommend taking a look at this wiki article right here.

Our structure now looks like this:

resources/
├── assets/
├── data/
│   └── tutorialmod/
│       ├── loot_tables/
│       │    └── blocks/
│       └── recipes/
├── META-INF/
│   └── mods.toml
└── pack.mcmeta

We’re getting closer to the end. However, now the more “difficult” part the assets folder. Here we will place JSON files which will hold blockstate information, model information for both items and blocks as well as texture files.

Assets folders

We’ll once again start with a folder with the same name as our mod id tutorialmod. We will then proceed to create four folder: blockstates, lang, models and textures.

  1. The blockstates folder contains JSON files which can alter a block model by looking at the current blockstate.
  2. The lang folder contains the translation strings for given keys. This will be explained in a future post.
  3. The models folder hold model files for items and blocks.
  4. The textures folder should be self-explanatory and holds textures files in the PNG format!

Lastly we will add an item and a block folder to both the models and the textures folders. We will now end up with this folder structure:

resources/
├── assets/
│   └── tutorialmod/
│       ├── blockstates/
│       ├── lang/
│       ├── models/
│       │    ├── block/
│       │    └── item/
│       └── textures/
│            ├── block/
│            └── item/
├── data/
│   └── tutorialmod/
│       ├── loot_tables/
│       │    └── blocks/
│       └── recipes/
├── META-INF/
│   └── mods.toml
└── pack.mcmeta

The thing that is not strictly necessary is the folders inside the textures folder. These could in theory be named in whatever way you wish. I would however not recommend to stray to far away from the way Minecraft does it. We’ll go into a bit more detail with this when I talk about the Forge JSON files.

Overall that would be it for the time being. The folder structure for Minecraft Modding might be a be weird topic to discuss, but I’ve seen plenty of mistakes when it came to that.

If you want to, you can also check out the same content as a video on my YT Channel.

Was this helpful?

35 / 1

Leave a Reply 0

Your email address will not be published. Required fields are marked *