Reimplemented tools
This commit is contained in:
parent
2de4c458c0
commit
6b1b1646a3
@ -29,5 +29,6 @@ public class VPItems {
|
||||
VPItemGroups.init();
|
||||
VPFood.init();
|
||||
VPArmor.init();
|
||||
VPTools.init();
|
||||
}
|
||||
}
|
||||
|
@ -1,16 +1,29 @@
|
||||
package tech.nevets.vplus.items;
|
||||
|
||||
import net.minecraft.item.AxeItem;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.SwordItem;
|
||||
import net.minecraft.util.Identifier;
|
||||
import net.minecraft.util.registry.Registry;
|
||||
import tech.nevets.vplus.items.tools.*;
|
||||
|
||||
public class VPTools {
|
||||
|
||||
public VPTools() {}
|
||||
|
||||
private static void register(String id) {
|
||||
Registry.register(Registry.ITEM, new Identifier("vplus", id + "_axe"), new AxeItem(VPMaterials.COPPER, new Item.Settings()));
|
||||
|
||||
static {
|
||||
register(VPMaterials.COPPER);
|
||||
register(VPMaterials.EMERALD);
|
||||
register(VPMaterials.SAPPHIRE);
|
||||
register(VPMaterials.RUBY);
|
||||
register(VPMaterials.JADE);
|
||||
}
|
||||
|
||||
private static void register(VPMaterials material) {
|
||||
Registry.register(Registry.ITEM, new Identifier("vplus", material.getName() + "_axe"), new AxeBase(material, new Item.Settings()));
|
||||
Registry.register(Registry.ITEM, new Identifier("vplus", material.getName() + "_hoe"), new HoeBase(material, new Item.Settings()));
|
||||
Registry.register(Registry.ITEM, new Identifier("vplus", material.getName() + "_pickaxe"), new PickaxeBase(material, new Item.Settings()));
|
||||
Registry.register(Registry.ITEM, new Identifier("vplus", material.getName() + "_shovel"), new ShovelBase(material, new Item.Settings()));
|
||||
Registry.register(Registry.ITEM, new Identifier("vplus", material.getName() + "_sword"), new SwordBase(material, new Item.Settings()));
|
||||
}
|
||||
|
||||
public static void init() {}
|
||||
}
|
||||
|
@ -1,4 +1,12 @@
|
||||
package tech.nevets.vplus.items.tools;
|
||||
|
||||
public class AxeBase {
|
||||
import net.minecraft.item.AxeItem;
|
||||
import net.minecraft.item.ToolMaterial;
|
||||
import tech.nevets.vplus.items.VPItemGroups;
|
||||
|
||||
public class AxeBase extends AxeItem {
|
||||
|
||||
public AxeBase(ToolMaterial material, Settings settings) {
|
||||
super(material, 5, -3.0F, settings.group(VPItemGroups.TOOLS));
|
||||
}
|
||||
}
|
||||
|
@ -1,4 +1,11 @@
|
||||
package tech.nevets.vplus.items.tools;
|
||||
|
||||
public class HoeBase {
|
||||
import net.minecraft.item.HoeItem;
|
||||
import net.minecraft.item.ToolMaterial;
|
||||
import tech.nevets.vplus.items.VPItemGroups;
|
||||
|
||||
public class HoeBase extends HoeItem {
|
||||
public HoeBase(ToolMaterial material, Settings settings) {
|
||||
super(material, -3, 0F, settings.group(VPItemGroups.TOOLS));
|
||||
}
|
||||
}
|
||||
|
@ -1,4 +1,12 @@
|
||||
package tech.nevets.vplus.items.tools;
|
||||
|
||||
public class PickaxeBase {
|
||||
import net.minecraft.item.PickaxeItem;
|
||||
import net.minecraft.item.ToolMaterial;
|
||||
import tech.nevets.vplus.items.VPItemGroups;
|
||||
import tech.nevets.vplus.items.VPTools;
|
||||
|
||||
public class PickaxeBase extends PickaxeItem {
|
||||
public PickaxeBase(ToolMaterial material, Settings settings) {
|
||||
super(material, 1, -2.8F, settings.group(VPItemGroups.TOOLS));
|
||||
}
|
||||
}
|
||||
|
@ -1,4 +1,11 @@
|
||||
package tech.nevets.vplus.items.tools;
|
||||
|
||||
public class ShovelBase {
|
||||
import net.minecraft.item.ShovelItem;
|
||||
import net.minecraft.item.ToolMaterial;
|
||||
import tech.nevets.vplus.items.VPItemGroups;
|
||||
|
||||
public class ShovelBase extends ShovelItem {
|
||||
public ShovelBase(ToolMaterial material, Settings settings) {
|
||||
super(material, 1, -3F, settings.group(VPItemGroups.TOOLS));
|
||||
}
|
||||
}
|
||||
|
@ -1,4 +1,11 @@
|
||||
package tech.nevets.vplus.items.tools;
|
||||
|
||||
public class SwordBase {
|
||||
import net.minecraft.item.AxeItem;
|
||||
import net.minecraft.item.ToolMaterial;
|
||||
import tech.nevets.vplus.items.VPItemGroups;
|
||||
|
||||
public class SwordBase extends AxeItem {
|
||||
public SwordBase(ToolMaterial material, Settings settings) {
|
||||
super(material, 2, -2.4F, settings.group(VPItemGroups.COMBAT));
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user