Tutorials/Creating a resource pack

Getting started
Note: This tutorial should take around 1 to 1.5 hours 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":
 * Do anything that violates Mojang's terms of use for Minecraft.
 * Release Minecraft versions or modifications that allow you 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 our  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 in the 'Tutorial_Resource_Pack' folder and create a new text document. Name this file “pack.mcmeta”.

Requirement

 * Any text editor should work but the suggested is a text editor using some sort of programming IDE. Notepad++ is an excellent, and FREE, text editor with syntax highlighting for lots of programming languages. You can download Notepad++ from here :

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 turn 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 (You should change   depending on your Minecraft version):

{   "pack": { "pack_format": 4, "description": "Tutorial Resource Pack" } }
 * pack.mcmeta

requires  in 1.6-1.8,   in 1.9 and 1.10,   in 1.11 and 1.12, and   in 1.13. (In pack format 3 and higher (1.11 and higher) all of the file names in the resource pack should have small letters only)

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 curly or square 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.

Creating an Icon
As you may have noticed, our pack does not have an icon! If you do not specify an icon, a grayscale icon will show up next to your pack.

Requirement

 * MS Paint will work for modifying most textures, but will not work for saving out textures that have transparency (like the chicken’s). GIMP (GNU Image Manipulation Program) is a free image editing program that will allow you to save out transparent images. You can download GIMP from here:

In the image editor of your choice, create a new image with a size of 128 by 128 pixels.

To do this with MS Paint:


 * 1) Click resize
 * 2) Change from percentage to pixels in the resize dialog that pops up
 * 3) Uncheck maintain aspect ratio
 * 4) Type in 128 in both horizontal and vertical text entry boxes
 * 5) Click OK

Once you have the correct canvas size, draw whatever you want your icon to be. For this tutorial, we’ve created a crudely drawn smiley face:



Save your icon with the name “pack” and make sure that it is saved as a. Save it into the same folder that we put our  file. For reference, our folder should look like this now:



Now if we launch the game and go to the resource packs list it should look something like this:



Apply the tutorial resource pack!

Modifying an Entity’s texture
Now that we have our resource pack set up, let’s modify the creepers 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. Located in Windows as:  C:\Users\name\AppData\Roaming\.minecraft\versions\1.13 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. I’m 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.'''

Modelling 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 Modelling Editor like opl's Model Creator or Blockbench. You can use other modelling editors but it is recommended to use this because it is easier to use and can export to  format.
 * A ZIP viewer like WinRAR 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 modelling editor.

Modelling the Ladder
In modelling the ladder, we will use the recommended opl's Model Creator. To open it, simply double-click it. After it has opened, press  to open the ladder model. After the open dialog has appeared, paste in  in the "File Name" box.

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


 * Press  to create a new block.
 * Resize the model to as small as one of the rungs of the ladder. Then, on the menu bar, go to "View -> Dialog -> Texture Manager"
 * Type in the first box to "texture" and the second to "blocks/ladder" and the last, double-click the "C" button and paste in the box,
 * In the next row, type in the first box "particle", then follow the third step above.

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

To assign a texture to a block, select all its faces and press  to toggle face visibility, then go to "View -> Dialog -> UV Editor". Put on the texture. This part is a little bit hard to document, so try to do it yourself.

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.

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": 3, "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, 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

All you really need to make a texture animated is the following code, though it will make each frame last only one frame:
 * Note

{  "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.

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 your 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.