Add scraper tool
This commit is contained in:
parent
f58a2f76f5
commit
f30c8380a3
src/main
java/dev/agatharose/asbestos/item
resources
assets/asbestos
data/asbestos/recipes
|
@ -0,0 +1,15 @@
|
|||
package dev.agatharose.asbestos.item;
|
||||
|
||||
import java.util.Set;
|
||||
|
||||
import dev.agatharose.asbestos.Asbestos;
|
||||
import net.minecraft.item.MiningToolItem;
|
||||
import net.minecraft.item.ToolMaterial;
|
||||
|
||||
public class ScraperItem extends MiningToolItem {
|
||||
|
||||
public ScraperItem(ToolMaterial material, float attackDamage, float attackSpeed, Settings settings) {
|
||||
super(attackDamage, attackSpeed, material, Set.of(Asbestos.ASBESTOS_BLOCK /* TODO add other blocks here */),
|
||||
settings);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,40 @@
|
|||
package dev.agatharose.asbestos.item;
|
||||
|
||||
import net.minecraft.item.Items;
|
||||
import net.minecraft.item.ToolMaterial;
|
||||
import net.minecraft.recipe.Ingredient;
|
||||
|
||||
public class ScraperToolMaterial implements ToolMaterial {
|
||||
|
||||
public static final ScraperToolMaterial INSTANCE = new ScraperToolMaterial();
|
||||
|
||||
@Override
|
||||
public int getDurability() {
|
||||
return 300;
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getMiningSpeedMultiplier() {
|
||||
return 5.0f;
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getAttackDamage() {
|
||||
return 2.5f;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getMiningLevel() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getEnchantability() {
|
||||
return 10;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Ingredient getRepairIngredient() {
|
||||
return Ingredient.ofItems(Items.IRON_INGOT);
|
||||
}
|
||||
}
|
|
@ -1,4 +1,5 @@
|
|||
{
|
||||
"block.asbestos.asbestos_block": "Asbestos Block",
|
||||
"item.asbestos.asbestos_fibers": "Asbests Fibers"
|
||||
"item.asbestos.asbestos_fibers": "Asbests Fibers",
|
||||
"item.asbestos.iron_scraper": "Asbestos Scraper"
|
||||
}
|
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"parent": "minecraft:item/handheld",
|
||||
"textures": {
|
||||
"layer0": "asbestos:item/iron_scraper"
|
||||
}
|
||||
}
|
Binary file not shown.
After (image error) Size: 284 B |
|
@ -0,0 +1,22 @@
|
|||
{
|
||||
"type": "minecraft:crafting_shaped",
|
||||
"pattern": [
|
||||
" NI",
|
||||
" IN",
|
||||
"S "
|
||||
],
|
||||
"key": {
|
||||
"N": {
|
||||
"item": "minecraft:iron_nugget"
|
||||
},
|
||||
"I": {
|
||||
"item": "minecraft:iron_ingot"
|
||||
},
|
||||
"S": {
|
||||
"item": "minecraft:stick"
|
||||
}
|
||||
},
|
||||
"result": {
|
||||
"item": "asbestos:iron_scraper"
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue