Tutorials/Creating a resource pack

Getting started
Note: This tutorial should take around 1 hour to 1 hour and 30 minutes to complete.

Resource packs can modify textures, models, animations, music, sounds, user interfaces, and languages.

What not to do
There are some things that you should not do before creating a resource pack. Here is a list of "don'ts":


 * Anything that violates Mojang's terms of use for Minecraft.
 * Release Minecraft versions or modifications that allow players to play without having bought Minecraft from Mojang.
 * Release the decompiled source code of Minecraft in any way.

Creating a resource pack
Start off by navigating to your  folder. To find the folder, you must first locate the Minecraft folder. Once you are in the resource pack folder, create a new folder and name it: "Tutorial_Resource_Pack". Then, open that folder.

The first thing we need to do is create a  file. This lets Minecraft know that the folder is a resource pack and it also allows you to customize the description that appears when you're selecting which resource pack to use in the game.

Creating an MCMETA file
To create an MCMETA file, right click the 'Tutorial_Resource_Pack' folder and create a new text document. Name this file "pack.mcmeta".

Requirement

 * Any text editor should work but suggested is a text editor using some sort of programming IDE.

Make sure the file extension is  and not   when you rename it. You may be warned that changing a file name extension could make the file unusable. This is okay!
 * Note

If you can't see file extensions, you can show them on by going to the View menu of the file explorer and checking the check box for file name extensions.



Open  in a text editor of your choice and copy or type the following:

{   "pack": { "pack_format": 5, "description": "My first resource pack!" } }

pack_format
If you are using an older version, you'll need to replace the  after   depending on your version.

Note that this guide assumes that you are creating your resource pack in the latest version of Minecraft, meaning that your resource pack might not work in an older version.

requires:


 * in 1.6 - 1.8,


 * in 1.9 and 1.10,


 * in 1.11 and 1.12,


 * in 1.13 and 1.14.


 * in 1.15 and 1.16.

(In pack format 3 and higher (1.11 and higher) all of the file names in the resource pack should have small letters only)

Description
You can leave the description or you can change it to something more exciting. If you decide you need something with fancy characters, you can look up the code for it here. Say you want to use the letter thorn: Þ. You'd put that in as. Just make sure you use a backslash and not a forward slash. (Only the characters 0000-FFFF (BMP) are supported in Minecraft)

This file is written in JSON! We won't go into specifics about the format now, but be aware about how things are laid out. '''Be very careful not to forget quotation marks, colons, and braces "{ }" or brackets "[ ]". Missing one of these can lead to your resource pack not working correctly!'''
 * Note

Testing our Pack
Now we are ready to test it out in game! Launch Minecraft and open the options, then click on Resource Packs. Your game should look something like this if you used the above code:



Troubleshooting
If you don't see your pack in game, make sure your pack.mcmeta is correct. If it isn't, look for any missing curly brackets { }, commas, colons :, quotation marks "", or square brackets [ ]. Remember for each open brace, quotation, or square bracket, you must have a closing brace, quotation, or square bracket. Also make sure that the file is in plain text format, not rich text.

Pack icon
If an icon is not specified, a cobblestone icon will show up next to the pack. Any image can be used here, as long as it is called. The file must be 64 x 64 pixels for your custom image to render properly.

Modifying an Entity's texture
Now that we have our resource pack set up, let's modify the creeper's texture!

However, before we can do some painting, we need to set up the folder structure that Minecraft expects resource packs to be in. To do this, do the following:


 * 1) Create a folder named "assets" in our Tutorial_resource_pack folder
 * 2) Inside "assets", create a folder called "minecraft"
 * 3) Inside "minecraft", create a folder called "textures"
 * 4) Inside "textures", create a folder called "entity"
 * 5) Inside "entity", create a folder called "creeper"
 * 6) Copy the creeper texture from the Vanilla Minecraft resource pack into our newly created creeper folder. (Note: You will need to use a file archiver, such as 7zip, to extract the files for the Vanilla textures. Navigate to  Windows:  C:\Users\name\AppData\Roaming\.minecraft\versions\your Minecraft version  Linux: ~/.minecraft/versions/your Minecraft version  and extract the .jar file. In the new folder locate assets/minecraft/textures/entity.)

Now that we have the normal creeper texture, open it up in the image editor of your choice. It should look something like this:



You might notice your texture looking small, make sure to zoom in on the texture. In MS Paint you can control magnification in the bottom right hand corner of the window with the slider.



If you've never seen a texture before, the above image might surprise you. The best way to think about it is like wrapping a gift with wrapping paper, but instead our wrapping paper is our texture. Here is how the creeper's texture is laid out:
 * A quick note on textures



Areas with matching colors face the same direction (i.e. Red areas are always the front of a cube).

How this looks in game:



Now it's time to be creative! Edit the creeper however you want. We're just going to add a headband for sake of simplicity.



Once you are happy with your texture, save out the file as a  and 'make sure that the file name is "creeper''". The game will only look for files with the correct name.'''

Modeling Blocks/Items
Sometimes you may want to change one of the Minecraft models. Here is a quick and easy way on how to do it.

Requirement

 * A 3D Modeling Editor like Blockbench. You can use other modeling editors but it is recommended to use this because it is easier to use and can export to  format.
 * A ZIP viewer like 7zip for Windows. Other ZIP viewers can be used but this can view JAR files as well.

Replacing a Block
Because the default ladder in Minecraft isn't 3D, you can replace it with your own model. First, get all the ladder's files into this resource pack:


 * 1) Open the Minecraft JAR file using a ZIP viewer of your choice.
 * Navigate into the  folder, then extract   to
 * Navigate into the  folder, then extract   to
 * Navigate into the  folder, then extract   to
 * Lastly, navigate into the  folder, then extract   to.

Now you can either edit the  using your preferred image editor, or you can edit it in your preferred modeling editor.

Modeling the Ladder
In modeling the ladder, we will use the recommended Blockbench. To open it, simply double-click it. After it has opened, press  to open the ladder model. After the open dialog has appeared, go to the location where you saved it and double click.

You then should be facing a ladder which is on the south side of the box.


 * On the menu bar, go to "Edit -> Add Cube" to create a new block.
 * Resize the model to a full sized cube. Then, under Textured on the left panel right click, then click Apply to Untextured Faces.
 * In the top left, there will be an image of the ladder, with a 1x1 highlighted region. Move this to change the texture to what you want it to be. Repeat until all sides of the block are as wanted.
 * Press  to save in   (Replace "blocks" with "block" for 1.13 and above).

Now we have created the particle texture of the block when broken and the main texture.

Finishing off
When you have completed the 3D model of the ladder and saved it, launch Minecraft, and test it out. Place a ladder on a wall, and you should see its replaced model.

Custom music and sounds
You can change or add new music using a resource pack.

Changing music
In this example, you will learn how to change the boss music in the ender dragon fight.

Finding a sound's path
If you want to change sounds, you'll first need to know the path of the sound you want to change.


 * 1) Inside your .minecraft folder, navigate to.
 * 2) Find the   file corresponding to your Minecraft version (e.g.  ), and open it with a text editor.
 * 3) In this file you can find all the sounds found in Minecraft. Press  to search for your sound.
 * 4) * For a list of filenames for music, you can check Music
 * 5) Your sound path will look something like this:

Modifying the sound

 * 1) Inside your resource pack folder, navigate to.
 * 2) Create a new folder named.
 * 3) Now inside your   folder, you need to create new folders depending on you sound's path. For example, if your path is , you need to create the folders.
 * 4) In the last folder (in this example, it's  ) you can put in your new sound file. Make sure you named the file to the file that you're replacing, or in this example,.
 * 5) * Note that this file must be a  file. To convert your sound file to a   file, you can use the free website Online-Convert.com

Testing your sound
If everything went according to plan, you have now replaced a sound in Minecraft. To test it:
 * 1) Make sure you have enabled your resource pack.
 * 2) * If you already had Minecraft open with your resource pack enabled, you can press to reload all resource packs.
 * 3) Use the  command to play your sound. In our example, type:

Adding new sounds or music
In this example, a new player hurt sound can be added without replacing any of the current player hurt sounds.

Finding the location of the sounds
In order to add a sound, you'll need to know where it should actually go by determining its path. Unlike replacing sounds, you will go straight to your resource pack folder and search in there.


 * 1) Inside your .minecraft folder, navigate to.
 * 2) Find the  file corresponding to your Minecraft version (e.g.  ), and open it.
 * 3) Press  to search for your sound path.
 * 4) *In this case, the location for the player hurt sounds will look like this:.

Adding the folders and sound in your resource pack

 * 1) Inside your resource pack folder, navigate to.
 * 2) Create a new folder named.
 * 3) Create another sub-folder. Its name will depend on the path's name that you found. So in this case, in your   folder, create a folder named.
 * 4) Add your sound here.
 * 5) * Note that the sound must be a  file. Like in the previous section, you may use the free website Online-Convert.com.
 * 6) * Also note the already existing files seen in your  file from above. In this case, five other hurt sounds exist within the   folder, two for falling at different heights (  and  ) and the other three are when the player actually gets hurt (,  , and  ) Since we want to add a fourth sound to the existing three hurt sounds, we cannot reuse those file names. For simplicity, name your sound.

Creating the sounds.json file
Because we are adding a sound, we must define where it will be used in.


 * 1) Go back to   in your resource pack folder.
 * 2) Create a text file named  . Do make sure that the file format is indeed .json and nothing else.
 * 3) At your choice, paste the following template into.
 * 4) * The above code only applies to this example. Replace/rename anything necessary to allow it to apply to your chosen sound.
 * 5) * You can find out the id used by Minecraft for each sound folder. By using  in-game, you can determine this id. In this case, using   will confirm that the player's hurt sound is indeed classified as.
 * 6) Correct   formatting is required! Any missing bracket, comma, etc. will result in the resource pack failing to work properly.

Testing your sound
If everything went according to plan, you have now added a sound in Minecraft. To test it:


 * 1) Make sure you have enabled your resource pack.
 * 2) * If you already had Minecraft open with your resource pack enabled, you can press to reload all resource packs.
 * 3) Use the  command once again to play your sound. In our example, type:  . For this example, it will likely require multiple tries, as hurt sounds are chosen randomly.

Adding Languages
You can add new languages to Minecraft using a resource pack. Assume your language code is 'LANG' and country/region code is 'COUNTRY',  will look like:

{   "pack": { "pack_format": 5, "description": "Tutorial Resource Pack" },   "language": { " LANG_COUNTRY ": { "name": " Tutorial Language ", "region": " Country/region name ", "bidirectional": false }   } }
 * pack.mcmeta

If you want your language to be right-to-left, set  to.

Then, put  in   inside your resource pack. When you launch the game, choose your resource pack, open the Language selection screen, and your new language will be there.

The  goes in the root folder of your resource pack, not in the   folder. Also note that the above  is the same file as the   file that you have created a while ago. As of 1.7-pre, you can choose multiple resource packs at once. If you want to use your new language and resource pack for before 1.7, you need to combine them manually because multiple resource packs could not be selected before the version.
 * Notes

Animation Properties
An example of an animation file is this:

{    "animation": { "interpolate": true, "width": 1, "height": 7, "frametime": 1, "frames": [ {            "index": 0, "time": 0 },         1, 2, 3, 4, 5, 6, 4, 2       ]    } }
 * stone.png.mcmeta


 * Note

All you really need to make a texture animated is the following code. By default, it will make each frame last only one tick:

{  "animation": {} }
 * stone.png.mcmeta

Save the file as the same name as the texture you want animated with an  in the same folder as your texture.

Texture Properties
An example of a texture property is this:

{    "texture": { "blur": false, "clamp": true } }
 * shadow.png.mcmeta

Fonts
Character sizes in fonts are determined by the last line of pixels that contains pixels which contain a non-zero alpha. This allows additional padding to be added around characters by adding a color with an alpha level of 1, which Minecraft will consider as part of the character.

Testing your Resource Pack

 * Launch the game
 * Click on Options
 * Click on Resource Packs
 * Find "Tutorial Resource Pack" in the list on the left and click the arrow next to it
 * Click Done

If you decide you want to make some changes to your resource pack, just close the game, edit your resource pack, relaunch the game, and follow the steps above to test your resource pack again. Alternatively, saving the texture to the resource pack and pressing will reload the pack without the need to close the game.

Packaging Resource Packs with Worlds
For using in singleplayer worlds, you can package your resource pack as a ZIP file named  inside the world directory. This will then be automatically used when playing the singleplayer world.

Server Resource Packs
If you are the owner of a server, you may set it as the resource pack of your server.
 * 1) Make sure, that your pack format is a .zip-folder.
 * 2) Upload the pack on a filehosting website, for example Dropbox(https://www.dropbox.com).
 * 3) Copy the download link of your pack. IMPORTANT: It has to be the direct download link, as an example for Dropbox the URL will end with "dl=0" If you're using Dropbox, all you have to do is changing it to "dl=1".
 * 4) Open the server.properties with a text editor.
 * 5) Search for the line "resource-pack=".
 * 6) Paste the download link behind the equal sign.
 * 7) Save your changes to the server-properties and restart your server.
 * 8) Enjoy!

Servers can have an icon that will show up in the Multiplayer list.
 * 1) Create a PNG image with a size of 64 by 64 pixels, transparency is supported.
 * 2) Save (or rename) it to.
 * 3) Move it to the server's directory.
 * 4) Restart the server.
 * 5) Server icons will display next to the server name.