Fabric Modding Tutorial - Minecraft 1.20: Custom Loot Tables | #5

Modding by Kaupenjoe
18 Jul 202315:28

Summary

TLDRThis video tutorial covers how to add custom loot tables to blocks in a Minecraft mod. Loot tables dictate what items drop when blocks are broken, or when chests or entities are interacted with. The tutorial guides you through setting up JSON files for loot tables, managing conditions like block destruction from explosions, and tagging blocks for tool requirements. It also covers ore block settings, including experience drops, and ensures blocks are minable with the appropriate tools. The video concludes with in-game testing of the custom loot and ore blocks.

Takeaways

  • 🔨 The tutorial focuses on adding custom loot tables to Minecraft modding, which determine item drops from blocks or entities.
  • 📂 A new directory structure is created for loot tables, including 'loot_tables' and 'blocks' folders within the mod's data directory.
  • 📝 Loot tables are defined in JSON files, specifying the type, pools, bonus rolls, conditions, and entries for item drops.
  • 💥 A condition 'survives_explosion' is used to ensure blocks drop when exploded, demonstrating the versatility of conditions in loot tables.
  • 🛠️ The 'requires_tool' setting on blocks affects loot drops, requiring specific tools to mine blocks and receive drops.
  • 🏷️ Blocks are added to 'minable' tags to define mining capabilities with different tools, such as pickaxes, axes, shovels, and hoes.
  • 🛡️ Higher tier tool tags like 'needs_iron_tool' and 'needs_diamond_tool' are used to set mining requirements for blocks.
  • 🌌 The tutorial covers creating experience dropping ores, adjusting block strength, and setting experience drop rates.
  • 📈 The process of balancing loot tables is discussed, including adjusting drop rates and experience values for custom ores.
  • 🔗 External resources like the Minecraft loot table Wiki and loot table generators are recommended for further understanding and ease of creation.

Q & A

  • What is the primary purpose of loot tables in Minecraft modding?

    -Loot tables in Minecraft modding determine what items are dropped when a block is destroyed or what items are contained within chests in certain structures, as well as what different entities drop.

  • How do you create a loot table for a custom block in Minecraft?

    -To create a loot table for a custom block, you need to create a JSON file within the 'data/<modid>/loot_tables/blocks' directory, with the file name matching the block's name. The file specifies the items and conditions for the block to drop.

  • What are the steps to ensure a custom block drops items in Minecraft?

    -To ensure a custom block drops items, you must add the loot table to the block, and then add the block to a specific tag that determines whether it can be mined with a pickaxe, axe, shovel, or hoe.

  • Why is it necessary to add a custom block to a tag in Minecraft modding?

    -Adding a custom block to a tag is necessary to define the mining tool requirements and the conditions under which the block will drop items, such as whether it requires a specific tool tier or can be mined without a tool.

  • What is the 'needs_tool_level' tag used for in Minecraft modding?

    -The 'needs_tool_level' tag is used to specify the minimum tool tier required to mine a block. It ensures that the block will only drop items if the correct tier of tool is used.

  • How can you make a block only mineable with a specific tool tier in Minecraft?

    -To make a block only mineable with a specific tool tier, you add the block to a 'needs_tool_level' tag corresponding to that tool tier, such as 'needs_iron_tool' for iron tier tools.

  • What is the difference between 'minable' and 'needs_tool_level' tags in Minecraft modding?

    -The 'minable' tag determines if a block can be mined with basic tools like a pickaxe, while the 'needs_tool_level' tag specifies the minimum tool tier required to mine the block.

  • How do you duplicate a loot table for multiple custom blocks in Minecraft?

    -You can duplicate a loot table for multiple custom blocks by copying the existing JSON file and renaming it for each block, then adjusting the block names and any specific values within the JSON file for each block.

  • What is the role of the 'experience_dropping' block in Minecraft modding?

    -The 'experience_dropping' block in Minecraft modding is used to define how much experience is dropped when the block is mined, allowing for customization of the experience gain.

  • How can you customize the amount of experience dropped by a block in Minecraft?

    -You can customize the amount of experience dropped by a block by using the 'experience_dropping' block type and specifying a 'uniformintprovider' with the desired minimum and maximum values for the experience range.

Outlines

00:00

💾 Introduction to Custom Loot Tables in Minecraft Modding

This paragraph introduces the concept of adding custom loot tables to Minecraft blocks through modding. Loot tables determine what items are dropped when blocks are destroyed or what items can be found in chests within certain structures. The tutorial aims to add custom loot tables to a mod's blocks and then add these blocks to specific tags to control their behavior when mined. The process involves creating a 'loot_tables' directory with a 'blocks' subdirectory and naming the JSON files according to the block names in the mod's 'modblocks' class. The JSON file for a 'Ruby_block' is outlined, which includes a loot table type, pools, conditions, and entries that define the item to be dropped. The importance of matching the JSON file name to the block name in the mod is emphasized.

05:00

🛠️ Setting Up Loot Tables and Tags for Block Mining

The second paragraph delves into the specifics of setting up loot tables for ores and the necessity of adding blocks to mining tags. It explains how to create JSON files for different mining tools such as pickaxe, shovel, and axe, and how to specify the mining requirements for each block using tags like 'needs_iron_tool' and 'needs_diamond_tool'. The tutorial demonstrates how to adjust the mining requirements for different block types, such as making a block only mineable with an iron pickaxe or a stone pickaxe. The paragraph also covers how to create directories for tags and the importance of placing the correct JSON files in the appropriate directories to define the mining capabilities and requirements for the custom blocks.

10:04

🔩 Advanced Loot Table Configuration and In-Game Testing

This paragraph focuses on the advanced configuration of loot tables for ore blocks and the in-game testing of the custom blocks' mining and dropping behavior. It discusses creating new ore blocks with specific mining times and experience drop rates, and how to duplicate and modify existing block settings for different types of ores. The tutorial also covers how to add these ore blocks to the creative mode tab and to the appropriate mining tags, such as 'needs_diamond_tool' for blocks that require a diamond pickaxe to drop items. The paragraph concludes with a demonstration of the in-game functionality, showing the correct dropping of items and experience when the custom blocks are mined with the appropriate tools.

15:04

🎮 Conclusion and Preview of Future Tutorials

The final paragraph wraps up the tutorial by summarizing the achievements, which include successfully setting up custom loot tables and tags for mining custom blocks in Minecraft. It highlights the successful in-game testing of the ore blocks, which now drop raw materials and experience as intended. The paragraph ends with a teaser for the next tutorial, which promises to cover advanced item creation, suggesting that the series will continue to explore more complex aspects of Minecraft modding.

Mindmap

Keywords

💡Loot tables

Loot tables in Minecraft determine what items are dropped when a player interacts with blocks, mobs, or containers. In the video, loot tables are explained as a way to specify what should be dropped when a custom block, such as a Ruby block, is destroyed. The tutorial covers how to set up loot tables for both custom blocks and ores.

💡Custom blocks

Custom blocks are unique blocks added through Minecraft modding. The video explains how to add custom blocks like 'Ruby block' and 'Raw Ruby block' into a mod, specifying their loot tables and behavior when destroyed. These blocks require specific conditions like the correct tools to drop items.

💡Conditions

Conditions in Minecraft modding define specific criteria that must be met for something to happen, such as blocks dropping items. In the video, the condition 'Minecraft:survives_explosion' is used to make sure that the Ruby block can drop its item even when destroyed by an explosion. Conditions help modders control how and when items are dropped from blocks.

💡Tags

Tags are used in Minecraft to group together blocks, items, or other entities that share similar behaviors. In this tutorial, tags are applied to custom blocks to determine what tools are needed to mine them (e.g., pickaxe or axe) and the tier of the tool required (stone, iron, etc.). Tags ensure proper mining behavior for different blocks.

💡Fabric modding

Fabric is a modding framework for Minecraft that allows developers to create and implement mods efficiently. In the video, Fabric is used to create custom blocks and loot tables, with special directories and files such as 'needs_tool_level' being placed in Fabric's data folder to control item drops and mining behavior.

💡Json files

Json files are data files used in Minecraft modding to define various settings such as loot tables, tags, and block properties. The video shows how Json files are used to configure blocks like Ruby ore and Raw Ruby block, specifying their loot tables and conditions for dropping items when mined.

💡Minable tag

The 'minable' tag in Minecraft specifies which tools can be used to mine specific blocks. In the video, this tag is added to the custom Ruby blocks to indicate that they must be mined with a pickaxe. This ensures that blocks drop the correct items only when mined with the right tool, preventing drops if mined with inappropriate tools like axes.

💡Experience dropping blocks

Experience dropping blocks in Minecraft release experience points when mined. In the video, the Ruby ore is defined as an 'experience dropping block,' meaning players will receive experience points when mining it. The video demonstrates how to customize the amount of experience that can drop from these blocks, using values similar to those of vanilla ores like Lapis or Diamond.

💡Ore blocks

Ore blocks are special types of blocks that contain valuable materials, such as Ruby ore in this modding tutorial. The video walks through the process of creating different types of Ruby ore blocks, including Deep Slate Ruby ore and Nether Ruby ore, and how to assign them loot tables and mining conditions.

💡Tool level

Tool level determines what tier of tool (e.g., stone, iron, diamond) is required to mine a block. In the video, tool levels are set for custom blocks like Ruby ore, with the 'needs_tool_level' tag ensuring that only certain pickaxes can mine them. This level dictates whether the block can be mined and if it will drop items.

Highlights

Introduction to adding custom loot tables in Minecraft modding.

Explanation of loot tables determining drops from blocks or entities.

Tutorial on creating a loot table for custom blocks.

Step-by-step guide to naming and structuring loot table folders and files.

Details on defining loot table entries and conditions.

Example of a condition that makes a block drop when exploded.

Recommendation to use loot table resources for reference.

Process of adding blocks to mining tags for tool requirements.

Demonstration of creating JSON files for tool tags.

Explanation of how to make blocks only mineable with specific tool tiers.

In-game testing of block drops with different tools.

Discussion on creating custom ore blocks with experience drop mechanics.

Guide to adjusting block strength and experience drop rates for ores.

Instructions for adding custom ores to mining tags.

Tips for creating loot tables for ores with specific drop conditions.

Final in-game demonstration of custom ore blocks dropping items.

Conclusion and预告 of the next tutorial on advanced item mechanics.

Transcripts

play00:00

let's add drops to our blocks with loot

play00:02

tables

play00:03

Minecraft modding courses with close to

play00:04

100 topics ranging from Custom tools and

play00:06

armor to custom block entities all the

play00:08

way to custom mobs Linked In the

play00:10

description below oh really fences back

play00:12

until everyone's more and in this

play00:13

tutorial we're gonna be adding a custom

play00:15

loot tables to Minecraft and our mod and

play00:18

loot tables basically determine what is

play00:20

going to be dropped for example when you

play00:22

destroy a block or they can also

play00:24

determine other things like what types

play00:26

of items are going to be inside of luge

play00:29

chests right in certain structures what

play00:31

different entities drop all of those

play00:33

things governed by loot tables and in

play00:35

this tutorial we're first of all going

play00:36

to add the loot table to our custom

play00:38

blocks and then there's a second part of

play00:40

this tutorial where we'll actually have

play00:42

to also add our blocks to a certain tag

play00:44

in order for the blocks to actually drop

play00:46

something but one step after the other

play00:48

first of all you need tutorial mode data

play00:49

folder we can right click new directory

play00:51

called loot underscore tables make sure

play00:54

that this is written correctly loot

play00:55

underscore tables exactly like this

play00:57

nothing else and inside of that folder

play00:59

another folder called blocks please make

play01:02

sure that this is done correctly I've

play01:03

seen Every Which Way that this has been

play01:06

written wrong it has to be data folder

play01:08

tutorial mode or your mod ID load

play01:10

underscore tables and then blocks and

play01:12

then here in this case the name of the

play01:13

Json file actually once again has to

play01:15

match the name given right here in the

play01:16

modblocks class so Ruby underscore block

play01:18

and raw Ruby underscore block let's

play01:20

start with the Ruby blocks let's create

play01:22

a new file over here Ruby underscore

play01:24

block dot Json here in this case there

play01:26

you go and once again I will just type

play01:28

out the contents here and then we'll go

play01:30

through and see what all of this

play01:32

craziness is so first of all this is of

play01:33

course once again a type and the type

play01:35

here is a Minecraft colon block because

play01:37

this is a block loot table we then

play01:39

Define some pools so pools is once again

play01:41

a list here in this case or an array and

play01:43

in this case we will only Define one

play01:45

pool and the pool has zero bonus rules

play01:48

bonus rolls of zero and then conditions

play01:52

are going to be a standard condition and

play01:54

that is going to be condition Minecraft

play01:57

colon survives

play01:59

underscore explosion after the list of

play02:02

the conditions you then Define entries

play02:04

in this case we have an entries list

play02:06

over here we're going to have a one

play02:08

entry that is going to be of type

play02:10

Minecraft

play02:12

colon item and the name of this item is

play02:15

going to be tutorial mod colon Ruby

play02:18

underscore block

play02:20

and this whole thing is done with the

play02:23

number of rolls of one awesome the first

play02:26

question you might ask is what the frick

play02:27

is this condition well the condition

play02:28

basically just means that the Ruby block

play02:30

will also fall when an explosion

play02:32

destroys this block should be fairly

play02:33

self-explanatory and what is going to

play02:35

drop is exactly what we Define in this

play02:36

entry over here and that's the Ruby

play02:38

block I highly recommend checking out

play02:40

either the loot table fandom Wiki

play02:41

article over here or the loot table

play02:43

generator for misode which is going to

play02:45

be very useful indeed as long as we

play02:48

don't have the data generation that's

play02:49

going to make the loot tables about a

play02:51

million times easier those basically

play02:53

tell you a bunch of stuff that the loot

play02:55

tables can contain and what everything

play02:56

means I will link those in the

play02:57

description below but just like the

play02:59

recipes of course give access to all of

play03:01

the loot tables in the external

play03:02

libraries which is going to go down all

play03:03

the way here to the Minecraft merge

play03:05

project and we will look in the data

play03:06

folder Minecraft loot tables we are

play03:09

going to go into the blocks folder and

play03:11

here we go every single loot table for

play03:13

every single block that exists in

play03:15

Minecraft it couldn't be easier how to

play03:17

Planck's drop well I mean they literally

play03:19

drop exactly the same way as the Ruby

play03:21

over here they just drop themselves

play03:22

right so most of this stuff is going to

play03:24

look very similar the only things that

play03:26

might look a little bit different are

play03:27

ore blocks let's cover first of all the

play03:29

raw Ruby block for this we're just going

play03:30

to drag the same adjacent file into the

play03:32

same folder while holding Ctrl and we're

play03:34

just going to rename this to Raw Ruby

play03:36

block and similar here this is just the

play03:38

raw Ruby block as of right now your

play03:40

blocks will still not drop something

play03:41

because they have the block setting

play03:43

inherited from the iron block that is

play03:45

called requires tool and if requires

play03:47

tool is called on your particular block

play03:49

that means that it can only be mined or

play03:53

it only will drop something if the

play03:55

correct tool is going to be used for

play03:58

this and for that you need to add this

play03:59

to a tag now in the highest level

play04:01

overview tags are simply collections of

play04:05

blocks items or sometimes some other

play04:07

things that have a similar purpose and

play04:10

in our case we need to add our blocks to

play04:12

a minable tag that's going to determine

play04:14

whether or not it can be mined with a

play04:16

pickaxe an ax a shovel or a hoe and we

play04:19

can also add it to a needs extrude tag

play04:21

which basically determines whether or

play04:23

not it has to have a certain tier of

play04:25

tool to be minable this happens in the

play04:27

data folder again but this time instead

play04:29

of the Minecraft directory inside they

play04:31

will make a new directory called Tags

play04:33

and inside of there once again we want

play04:35

to make a new directory called blocks

play04:36

and lastly we also want to make another

play04:38

new directory called minable now in the

play04:40

mindable folder we'll create four Json

play04:42

files this is going to be the ax.json

play04:44

I'll already put the Json file contents

play04:47

in here so you can see a Json file is

play04:49

very very straightforward it's just the

play04:50

curly brackets then a replace faults and

play04:52

then a list of values this time it's

play04:54

empty because I just wanted to copy over

play04:56

this Json file for all the other tags

play04:58

that we need because it's quite a few

play05:00

actually so when you have this you can

play05:02

of course also take a look at all the

play05:03

Json files in the description below in

play05:05

the GitHub repository and what you can

play05:06

do is we can just drag this into the

play05:08

same folder and we can call this the

play05:10

pickaxe.json and then we can drag this

play05:12

into the same folder again once again

play05:14

while holding Ctrl we can call this the

play05:15

shovel and then lastly the whole and

play05:17

then there's extremely important the

play05:19

other ones traded in the locks folder

play05:21

not the minable folder so we drag this

play05:23

into the blocks folder this time I'm

play05:25

going to call this the needs underscore

play05:27

iron underscore tool and then once again

play05:29

dragging this into the blocks folder

play05:30

needs Diamond Tool and this actually

play05:33

also needs

play05:34

Stone tool so those are the different

play05:37

levels if you want to require nether

play05:39

right or higher what you have to do is

play05:40

you have to do this in another folder is

play05:42

a little annoying but it is what it is

play05:43

so in the data folder right click new

play05:45

directory called Fabric and then inside

play05:47

of there we want to make a new directory

play05:48

called Tags and then another new

play05:50

directory called the blocks and then

play05:52

inside there we can make the following

play05:55

Json file and that's the needs

play05:57

underscore tool underscore level

play05:59

underscore 4. and the needs underscore

play06:01

tool underscore level underscore for

play06:03

Json file under the fabric folder here

play06:05

that's quite important that one

play06:07

basically allows you to make your block

play06:09

only minable with netherrite let's start

play06:12

with the pickaxe Json because in our

play06:14

case well obviously the Ruby block in

play06:16

the Raw Ruby block should only be

play06:17

minable with a pickaxe here so we're

play06:19

going to add those tutorial mod colon

play06:21

Ruby underscore block and then similarly

play06:24

the second one is just going to be the

play06:26

raw Ruby block there we go in this case

play06:28

if we leave it like this now our Ruby

play06:30

block and our raw Ruby block can be

play06:32

mined with any pickaxe including it will

play06:34

wooden pickaxe if we then say you know

play06:36

what I actually want my raw Ruby block

play06:38

to only be mineable with an iron pickaxe

play06:40

then we just add it right here and then

play06:42

for example maybe we say you know what

play06:43

and then I only want my Ruby block to be

play06:45

minable with a stone pickaxe let's say

play06:47

there we go now this is going to be done

play06:48

do keep in mind that when you have the

play06:50

need Stone tool for example your Ruby

play06:52

block now would also be minable with

play06:54

iron diamond and netherride and anything

play06:55

above it so it always is basically this

play06:58

particular two level or higher I do not

play07:00

believe there is an easy way to make

play07:01

this function a different way just keep

play07:03

that in mind and with this way the Ruby

play07:04

Rock and the raw Ruby block given the

play07:06

correct tools will now drop something

play07:08

and we'll actually take a look at this

play07:09

and then we'll take a look at the ores

play07:11

as well but first of all let's go into

play07:12

the game and see our blocks drop

play07:14

something all right fine stuff in

play07:15

Minecraft and I've prepared all of our

play07:16

blocks over here and I've also prepared

play07:19

well some of my pickaxes so in this case

play07:22

neither the Ruby block nor the raw Ruby

play07:24

block should be mindable with a well

play07:26

normal pickaxe here in this case a

play07:28

wooden pickaxe and you can see it

play07:30

already takes a really long time and

play07:32

there's a very good indication that this

play07:34

is probably not going to work but we'll

play07:36

just let this run through and there we

play07:37

go nothing dropped if I use a stone

play07:39

pickaxe however let's see this is a

play07:41

little bit faster and there we go a Ruby

play07:44

block drop awesome now the raw Ruby we

play07:46

defined only being able to be mindable

play07:48

with a iron pickaxe so if we use Stone

play07:50

right here it is okay in terms of speed

play07:53

but you will see it is not going to drop

play07:55

anything

play07:56

there we go got nothing however with an

play07:58

iron pickaxe it is going to drop awesome

play08:01

and of course also with an ax this does

play08:02

not work you can see it is already

play08:04

taking way too long like you would

play08:06

probably never do this similar with this

play08:08

one right here even with the never light

play08:09

ax doesn't work however higher tiers

play08:11

such as Diamond that works totally fine

play08:13

and then similar netherride also works

play08:15

totally fine for all of our blocks here

play08:17

as I've said the tools here that you

play08:18

define is always the one that it needs

play08:20

or higher than that and now let's also

play08:22

take a look at some ore so for this I

play08:24

will be copying over four different

play08:25

blocks that we're going to need and what

play08:28

I mean by copying over is I'm going to

play08:30

create one of them and then the other

play08:31

three I'm just going to well basically

play08:33

copy over all of the code is of course

play08:35

available to you in the description

play08:36

below so no worries at all so you should

play08:38

be totally fine all right so to add ore

play08:40

we're just going to do a public static

play08:42

final and there's going to be a block

play08:44

once again this is going to be the Ruby

play08:46

underscore or this will be equal to the

play08:48

register block method I'm going to call

play08:49

this the Ruby underscore or right here

play08:51

now instead of a new block this is going

play08:53

to be a new experience dropping block

play08:56

here in this case and the first

play08:57

parameter of which is just going to be

play08:59

fabric block settings dot copy of and

play09:01

we're going to copy block start Stone we

play09:03

can then also Define the strength over

play09:06

here this is just going to be how long

play09:07

it's going to take to actually break

play09:09

this particular Block in this case so

play09:11

maybe we want this to be you know taking

play09:13

a little bit longer than stone stone for

play09:15

reference over here we can take a look

play09:16

at this has a strength of 1.5 so maybe

play09:19

we say that this has a strength of two

play09:21

and then after the first closing

play09:22

parenthesis after the strength over here

play09:23

we then also wanted to add a uniformind

play09:26

provider dot create and this is going to

play09:29

determine how much experience this block

play09:32

will drop when you actually destroy it

play09:34

so for example we're just going to

play09:35

choose between two and five over here

play09:37

ended with a semicolon here at the end

play09:39

and then your Ruby or has been created

play09:41

to double check the vanilla values of

play09:43

the ore blocks just middle Mouse one

play09:45

click on the experience dropping block

play09:46

over here middle Mouse one click here

play09:48

again and in the blocks class you will

play09:50

be able to find lapis for example or

play09:51

Diamond let's just take a look at lapis

play09:53

at the very end over here we'll be able

play09:54

to find that lapis drops between 2 and 5

play09:56

as well and we can take a look at the

play09:58

other ore blocks as well so for example

play10:00

emerald ore that's going to be in 628 in

play10:03

see that one drops between three and

play10:05

seven the numbers those are always

play10:07

things that you have to take a look at

play10:08

yourself and basically change in

play10:10

whatever which way you like to balance

play10:12

your mod properly but that's going to be

play10:13

a good idea here for the moment I don't

play10:15

want to end with Ruby or no no I want to

play10:17

duplicate this four times so just select

play10:19

it press Ctrl D to duplicate and I also

play10:21

want the Deep slate Ruby ore of course

play10:23

very important that we change the name

play10:25

right here if you do not change the name

play10:27

inside of the register block method that

play10:29

you give it then we will run into an

play10:31

error and the actual game will not start

play10:33

here we of course want to copy the

play10:35

blocks.deep slate in order to get the

play10:37

Deep slight sounds

play10:39

and the strength might be 4 because it's

play10:41

a little bit hard we are also going to

play10:42

get the nether Ruby ore this is going to

play10:45

be the nether Ruby ore there we go

play10:47

and this is of course going to copy well

play10:50

Netherrack and maybe this is actually a

play10:51

little bit of a lesser strength because

play10:53

Netherrack is not really that strong

play10:55

and then lastly we have end we have end

play10:58

stone ruby ore and of course changing

play11:00

the name here as well and stone ruby ore

play11:04

and this is going to be copying the end

play11:06

stone block

play11:08

and here once again maybe with a little

play11:09

bit more strength because why not you

play11:11

can of course also play around with the

play11:13

in providers over here so for example oh

play11:15

the end or that's going to give you way

play11:16

more experience because the wall is way

play11:18

crazier and way more harder way harder

play11:20

to get to the end to actually mine this

play11:21

ore so there you go that could be one of

play11:23

the reasons why you would do that there

play11:25

we go I've added all of the oars to the

play11:27

creative mode tab this really shouldn't

play11:28

be anything crazy let's just add the

play11:30

translation all of this should be fairly

play11:32

self-explanatory at the end of the day

play11:33

it literally is just changing the name

play11:35

right here and then changing whatever

play11:36

the translation is it should be pretty

play11:38

trivial at this point then of course now

play11:40

to have the blocks properly added yes we

play11:42

do need to add all of the Json files

play11:43

that is a little bit of annoying thing

play11:45

but like I said just give it a few more

play11:47

tutorials and then we're going to add

play11:48

this in record speed yes in this case we

play11:51

do need to copy them over now I'm going

play11:52

to cheat and I have already prepared

play11:54

them and I'm just going to copy them

play11:55

over like this but you can see the

play11:57

contents of them are literally exactly

play11:58

the same compared to the Ruby block and

play12:00

the raw Ruby block so really it

play12:02

shouldn't be any issue at all and of

play12:03

course the contents you can always take

play12:05

a look at those in the GitHub repository

play12:06

as well alright the textures here as

play12:09

well and those are of course always

play12:10

going to be available to you for

play12:11

download in the description below and

play12:13

now to the interesting thing and that is

play12:15

adding all of them to the tags so of

play12:17

course we can just add all of them to

play12:18

the pickaxe tag because all of those

play12:19

four ores would be minable with the

play12:21

pickaxe so there we go basically just

play12:22

add it to the pickaxe Json file and now

play12:24

let's just play around with this a

play12:25

little bit so let's for example say that

play12:27

the End Stone can only be mined with

play12:29

netherrite here so we're going to add

play12:30

this to the neat underscore tool

play12:32

underscore level underscore for Json

play12:33

file in the data fabric tags blocks

play12:35

folder over here very important and we

play12:38

will be able to see that we can only

play12:39

ever mine this with a netherride pickaxe

play12:41

or higher if we add custom levels and

play12:43

see that in a future tutorial as well

play12:44

and then let's say for example that the

play12:46

Deep State can only be mined with

play12:48

diamond here for example and now while

play12:49

they can be mined well they won't drop

play12:51

anything yet because we still haven't

play12:52

added the loot tables so you can see

play12:54

there is a little bit of a process over

play12:56

here but like I said once we go through

play12:58

this once you understand you have to

play13:00

understand sort of what the process is

play13:01

right what are loot tables what are they

play13:03

good for what are tags what are they

play13:05

good for what do they do especially the

play13:07

minable and the he needs you know X tool

play13:09

tag after you've understood what all of

play13:11

those do then we're going to be able to

play13:13

make them way easier with datagen but

play13:15

for the time being it's a little bit

play13:16

more of an involved process and for the

play13:18

ore blocks what I recommend is you go to

play13:20

the external libraries once again down

play13:22

to the emerge project over here to data

play13:24

loot tables blocks and you just take a

play13:27

look at for example the copper ore one

play13:29

now this one will actually shock you I'm

play13:31

gonna open this and you're gonna be like

play13:32

oh my Lord what is all of this craziness

play13:34

absolutely not to worry we're just going

play13:37

to copy this over so select it press

play13:39

Ctrl C to copy it and then Ctrl V

play13:41

pasting it into the correct folder over

play13:43

here I'm going to rename this to the

play13:45

Ruby or and then we just need to make

play13:47

sure that we change everything in the

play13:50

correct places so for example here where

play13:52

it drops the copper ore when we use silk

play13:55

touch we want it to drop tutorial mode

play13:57

colon Ruby underscore or and then down

play13:59

here instead of raw copper we wanted to

play14:01

drop raw Ruby of course making sure we

play14:04

also change Minecraft over here to

play14:05

tutorial mode this is extremely

play14:07

important and then down here we're just

play14:09

going to call this the tutorial mode

play14:10

blocks Ruby orb awesome and now we can

play14:12

just duplicate this a couple of times

play14:14

this is going to be the Deep slate

play14:15

underscore Ruby ore and then there's

play14:17

going to be the Deep slate Ruby ore and

play14:19

for the raw Ruby that's still going to

play14:20

drop and then here you can of course see

play14:22

this is a uniform distribution so it

play14:24

will drop between two and five you can

play14:26

of course change this you know so for

play14:27

example you might say oh for the website

play14:29

it should drop between three and six

play14:31

something like that you can always of

play14:32

course change the numbers highly

play14:34

recommended to try this out and and just

play14:36

play around with this a little bit

play14:37

alright and just for the sake of

play14:38

argument I've also added the Nether and

play14:39

the end stone ruby or block loot tables

play14:43

once again you can take a look at those

play14:44

in the GitHub repository and now we can

play14:46

go into the game we can see our ore and

play14:48

we can see them drop something when we

play14:49

mine them alright here we are in

play14:51

Minecraft and let's just try and mine

play14:53

our ores and you can see there we go so

play14:55

that works no worries at all diamond

play14:57

pickaxe or the Deep slight also works

play14:59

for the nether also works but here it

play15:02

should not work because the N Stone

play15:04

should only be minable exactly with

play15:06

netherrite and let's take a look and

play15:07

then we go so absolutely Works no

play15:10

worries at all absolutely amazing we got

play15:12

our ore drops they drop our raw Ruby

play15:14

they drop experience absolutely freaking

play15:16

fantastic right that's gonna be it for

play15:18

this tutorial right here next time we're

play15:20

gonna do an advanced item very cool

play15:22

stuff take a look at it here and I hope

play15:24

to see you there so yeah

Rate This

5.0 / 5 (0 votes)

Связанные теги
Minecraft ModdingLoot TablesCustom BlocksModding TutorialBlock EntitiesGame DevelopmentModding ToolsResource PacksCreative CodingEducational Content
Вам нужно краткое изложение на английском?