User Tools

Site Tools


tutorial:blocks

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
tutorial:blocks [2021/06/17 13:56] – Fix typo redgrapefruittutorial:blocks [2021/09/08 11:06] – Fix incorrect path for tool usage legol
Line 131: Line 131:
       ]       ]
     }     }
 +  ]
 +}
 +</code>
 +
 +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:tags|Tags Tutorial]]. The tags that we need to add the block to are:
 +
 +  Harvest tool: src/main/resources/data/minecraft/tags/blocks/mineable/<tooltype>.json, Where 'tooltype' can be any of: 'axe', 'pickaxe', 'shovel' ore 'hoe'
 +  Harvest level: src/main/resources/data/minecraft/tags/blocks/needs_<tier>_tool.json, Where 'tier' can be any of: 'stone', 'iron' or 'diamond'
 +
 +<code JavaScript src/main/resources/data/minecraft/tags/blocks/mineable/pickaxe.json>
 +{
 +  "replace": false,
 +  "values": [
 +    "example:example_block"
 +  ]
 +}
 +</code>
 +
 +<code JavaScript src/main/resources/data/minecraft/tags/blocks/needs_stone_tool.json>
 +{
 +  "replace": false,
 +  "values": [
 +    "example:example_block"
   ]   ]
 } }
tutorial/blocks.txt · Last modified: 2024/06/21 21:37 by ryhon