tutorial:blocks
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
tutorial:blocks [2022/04/29 09:57] – [Custom VoxelShape] solidblock | tutorial:blocks [2022/12/16 01:07] – [Adding a Block] solidblock | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Adding a Block ====== | ====== Adding a Block ====== | ||
- | Adding blocks to your mod follows a similar process to [[tutorial: | + | Adding blocks to your mod follows a similar process to [[tutorial: |
===== Creating a Block ===== | ===== Creating a Block ===== | ||
Line 137: | Line 137: | ||
In minecraft 1.17, there has been a change for breaking blocks. Now, to define harvest tools and harvest levels, we need to use tags. Read about tags at: [[tutorial: | In minecraft 1.17, there has been a change for breaking blocks. Now, to define harvest tools and harvest levels, we need to use tags. Read about tags at: [[tutorial: | ||
- | Harvest tool: src/ | + | Harvest tool: src/ |
Harvest level: src/ | Harvest level: src/ | ||
Line 190: | Line 190: | ||
public ActionResult onUse(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit) { | public ActionResult onUse(BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit) { | ||
if (!world.isClient) { | if (!world.isClient) { | ||
- | player.sendMessage(new LiteralText(" | + | player.sendMessage(Text.of(" |
} | } | ||
tutorial/blocks.txt · Last modified: 2024/08/26 01:22 by solidblock