Bedrock Codebase: Shared textures and overlays [Tutorial]

I recently started looking in-depth into resourcepacks on the bedrock codebase version, which is windows 10, pocket edition and some console versions.

I made a quick resourcepack which uses a single texture for ores and applies an overlay which colours each ore differently, I also applied the same technique to wool.

oreswool

Firstly I recommend getting the default assets, which can be easily done with the resourcepack template although this template doesn’t include all the assets it contains enough to do this.

If you want to extract the default resources follow this tutorial on where windows apps are installed then go to Microsoft.MinecraftUWP…/data/resource_packs/vanilla

Change texture path

The main point of the resourcepack is that there is only one texture for multiple blocks with the same pattern, meaning that only one texture needs to be changed if you want to change the design of the blocks, this involves changing blocks to use the same texture instead of the separate texture by default.

This is done through the ‘terrain_texture.json’ located in the textures folder, inside the file look for a compound with the key “texture_data” changing the values inside this compound is how we can have several blocks use the exact same texture.
You only need to specify the blocks that you are changing inside the “texture_data” compound, I recommend removing all the blocks that you don’t change, like I did in my example.

Changing the texture is easy simply changing the “textures” value for the block ie

“gold_ore”: {
“textures”: “textures/blocks/ore_base”
},
“iron_ore”: {
“textures”: “textures/blocks/ore_base”
}

Coloured overlays

Adding a coloured overlay can be done to blocks in bedrock codebase again thorugh the ‘terrain_texture.json’, firstly you will need to change the “textures” value from a texture path to a compound containg the path with the key “path”:

“gold_ore”: {
“textures”: “textures/blocks/ore_base”
}

—– becomes —–

“gold_ore”: {
“textures”: {
“path”: “textures/blocks/ore_base”
}
}

Adding an overlay is done within this new compound added via the key “overlay_color” with the value being a hex value colour code ie “overlay_color”: “#fff056”

“gold_ore”: {
“textures”: {
“path”: “textures/blocks/ore_base”,
“overlay_color”: “#fff056”
}
}

Only tint certain parts of the texture

The final part of this example involves how to get certain parts of the texture not to be tinted, you can see this on the ore textures as the stone texture is not tinted, this is done through the use of a tga texture rather than the standard png texture.

The way that tga’s are used by the bedrock codebase is any part of the texture you don’t want to be tinted should have an alpha of 0, you will need to have the texture you want to not be tinted then set the alpha for the entire of that texture to 0 and the parts that need to be tinted will need an alpha of 255, you will need to save the texture as a tga not a png, you can’t just change the extension manually.

The stone texture has been reduced to 0 alpha which makes it invisible, but in game the stone is not tinted.

I have my example pack up for download you cansee what I did to help you learn how to do this, you can also see how I did the same for wool, as there is a slight difference in how wool is defined in ‘terrain_texture.json’.

Download the One Texture example pack

Bedrock Codebase: Shared textures and overlays [Tutorial]

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s