Skip to content

Commit

Permalink
Add biomass tools and armor
Browse files Browse the repository at this point in the history
  • Loading branch information
IcarussOne committed Jun 8, 2024
1 parent 1bad72a commit 5dd19b7
Show file tree
Hide file tree
Showing 38 changed files with 335 additions and 2 deletions.
41 changes: 39 additions & 2 deletions src/main/java/mod/emt/harkenscythe/init/HSItems.java
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,31 @@ public class HSItems
@GameRegistry.ObjectHolder("shadow_book")
public static HSItem shadow_book;

@GameRegistry.ObjectHolder("biomass")
public static HSItem biomass;
@GameRegistry.ObjectHolder("biomass_sword")
public static HSSword biomass_sword;
@GameRegistry.ObjectHolder("biomass_shovel")
public static HSShovel biomass_shovel;
@GameRegistry.ObjectHolder("biomass_pickaxe")
public static HSPickaxe biomass_pickaxe;
@GameRegistry.ObjectHolder("biomass_axe")
public static HSAxe biomass_axe;
@GameRegistry.ObjectHolder("biomass_hoe")
public static HSHoe biomass_hoe;
@GameRegistry.ObjectHolder("biomass_helmet")
public static HSArmor biomass_helmet;
@GameRegistry.ObjectHolder("biomass_chestplate")
public static HSArmor biomass_chestplate;
@GameRegistry.ObjectHolder("biomass_leggings")
public static HSArmor biomass_leggings;
@GameRegistry.ObjectHolder("biomass_boots")
public static HSArmor biomass_boots;

@GameRegistry.ObjectHolder("livingmetal_ingot")
public static HSItem livingmetal_ingot;
@GameRegistry.ObjectHolder("livingmetal_sword")
public static HSSword livingmetal_sword;
@GameRegistry.ObjectHolder("livingmetal_shovel")
public static HSShovel livingmetal_shovel;
@GameRegistry.ObjectHolder("livingmetal_pickaxe")
Expand All @@ -102,9 +125,11 @@ public class HSItems
@GameRegistry.ObjectHolder("livingmetal_boots")
public static HSArmor livingmetal_boots;

public static ArmorMaterial ARMOR_LIVINGMETAL = EnumHelper.addArmorMaterial("livingmetal", "livingmetal", 26, new int[] {2, 5, 6, 2}, 20, SoundEvents.ITEM_ARMOR_EQUIP_IRON, 0.5F).setRepairItem(new ItemStack(livingmetal_ingot));
public static ArmorMaterial ARMOR_BIOMASS = EnumHelper.addArmorMaterial("biomass", "biomass", 14, new int[] {1, 4, 5, 2}, 17, SoundEvents.BLOCK_SLIME_PLACE, 0.5F).setRepairItem(new ItemStack(biomass));
public static ArmorMaterial ARMOR_LIVINGMETAL = EnumHelper.addArmorMaterial("livingmetal", "livingmetal", 24, new int[] {2, 5, 6, 2}, 20, SoundEvents.ITEM_ARMOR_EQUIP_IRON, 1.0F).setRepairItem(new ItemStack(livingmetal_ingot));

public static ToolMaterial TOOL_LIVINGMETAL = EnumHelper.addToolMaterial("livingmetal", 3, 521, 7.5F, 2.5F, 20).setRepairItem(new ItemStack(livingmetal_ingot));
public static ToolMaterial TOOL_BIOMASS = EnumHelper.addToolMaterial("biomass", 3, 151, 6.5F, 1.5F, 17).setRepairItem(new ItemStack(biomass));
public static ToolMaterial TOOL_LIVINGMETAL = EnumHelper.addToolMaterial("livingmetal", 3, 481, 7.5F, 2.5F, 20).setRepairItem(new ItemStack(livingmetal_ingot));

@SubscribeEvent
public static void onRegisterItemsEvent(@Nonnull final RegistryEvent.Register<Item> event)
Expand All @@ -125,15 +150,27 @@ public static void onRegisterItemsEvent(@Nonnull final RegistryEvent.Register<It
HSRegistry.setup(new HSScythe(ToolMaterial.IRON, 1.4F, EnumRarity.COMMON), "iron_scythe").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSScythe(ToolMaterial.GOLD, 1.4F, EnumRarity.COMMON), "golden_scythe").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSScythe(ToolMaterial.DIAMOND, 1.4F, EnumRarity.COMMON), "diamond_scythe").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSScythe(TOOL_BIOMASS, 1.45F, EnumRarity.UNCOMMON), "biomass_scythe").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSScythe(TOOL_LIVINGMETAL, 1.45F, EnumRarity.UNCOMMON), "livingmetal_scythe").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSGlaive(ToolMaterial.WOOD, 1.4F, EnumRarity.COMMON), "wooden_glaive").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSGlaive(ToolMaterial.STONE, 1.4F, EnumRarity.COMMON), "stone_glaive").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSGlaive(ToolMaterial.IRON, 1.4F, EnumRarity.COMMON), "iron_glaive").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSGlaive(ToolMaterial.GOLD, 1.4F, EnumRarity.COMMON), "golden_glaive").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSGlaive(ToolMaterial.DIAMOND, 1.4F, EnumRarity.COMMON), "diamond_glaive").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSGlaive(TOOL_BIOMASS, 1.45F, EnumRarity.UNCOMMON), "biomass_glaive").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSGlaive(TOOL_LIVINGMETAL, 1.45F, EnumRarity.UNCOMMON), "livingmetal_glaive").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSItem(EnumRarity.UNCOMMON), "carnage_book").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSItem(EnumRarity.UNCOMMON), "shadow_book").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSItem(EnumRarity.UNCOMMON), "biomass").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSSword(TOOL_BIOMASS, EnumRarity.UNCOMMON), "biomass_sword").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSShovel(TOOL_BIOMASS, EnumRarity.UNCOMMON), "biomass_shovel").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSPickaxe(TOOL_BIOMASS, EnumRarity.UNCOMMON), "biomass_pickaxe").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSAxe(TOOL_BIOMASS, 8.0F, -3.0F, EnumRarity.UNCOMMON), "biomass_axe").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSHoe(TOOL_BIOMASS, EnumRarity.UNCOMMON), "biomass_hoe").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSArmor(ARMOR_BIOMASS, 4, EntityEquipmentSlot.HEAD, EnumRarity.UNCOMMON), "biomass_helmet").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSArmor(ARMOR_BIOMASS, 4, EntityEquipmentSlot.CHEST, EnumRarity.UNCOMMON), "biomass_chestplate").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSArmor(ARMOR_BIOMASS, 4, EntityEquipmentSlot.LEGS, EnumRarity.UNCOMMON), "biomass_leggings").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSArmor(ARMOR_BIOMASS, 4, EntityEquipmentSlot.FEET, EnumRarity.UNCOMMON), "biomass_boots").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSItem(EnumRarity.UNCOMMON), "livingmetal_ingot").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSSword(TOOL_LIVINGMETAL, EnumRarity.UNCOMMON), "livingmetal_sword").setCreativeTab(HarkenScythe.TAB),
HSRegistry.setup(new HSShovel(TOOL_LIVINGMETAL, EnumRarity.UNCOMMON), "livingmetal_shovel").setCreativeTab(HarkenScythe.TAB),
Expand Down
10 changes: 10 additions & 0 deletions src/main/java/mod/emt/harkenscythe/items/HSArmor.java
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,16 @@ public String getArmorTexture(ItemStack stack, Entity entity, EntityEquipmentSlo
return new ResourceLocation(HarkenScythe.MOD_ID, "textures/models/armor/livingmetal_2.png").toString();
}

if (stack.getItem() == HSItems.biomass_helmet || stack.getItem() == HSItems.biomass_chestplate || stack.getItem() == HSItems.biomass_boots)
{
return new ResourceLocation(HarkenScythe.MOD_ID, "textures/models/armor/biomass_1.png").toString();
}

if (stack.getItem() == HSItems.biomass_leggings)
{
return new ResourceLocation(HarkenScythe.MOD_ID, "textures/models/armor/biomass_2.png").toString();
}

return new ResourceLocation(HarkenScythe.MOD_ID, "textures/models/armor/livingmetal_1.png").toString();
}

Expand Down
12 changes: 12 additions & 0 deletions src/main/resources/assets/harkenscythe/lang/en_us.lang
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,18 @@ tile.harkenscythe.soul_crucible.name=Soul Crucible
tile.harkenscythe.soul_altar.name=Altar of Souls

# ITEMS
item.harkenscythe.biomass.name=Biomass
item.harkenscythe.biomass_axe.name=Biomass Axe
item.harkenscythe.biomass_boots.name=Biomass Boots
item.harkenscythe.biomass_chestplate.name=Biomass Chestplate
item.harkenscythe.biomass_glaive.name=Biomass Glaive
item.harkenscythe.biomass_helmet.name=Biomass Mask
item.harkenscythe.biomass_hoe.name=Biomass Hoe
item.harkenscythe.biomass_leggings.name=Biomass Leggings
item.harkenscythe.biomass_pickaxe.name=Biomass Pickaxe
item.harkenscythe.biomass_scythe.name=Biomass Scythe
item.harkenscythe.biomass_shovel.name=Biomass Shovel
item.harkenscythe.biomass_sword.name=Biomass Sword
item.harkenscythe.carnage_book.name=Book of Carnage
item.harkenscythe.diamond_glaive.name=Diamond Glaive
item.harkenscythe.diamond_scythe.name=Diamond Scythe
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "item/generated",
"textures": {
"layer0": "harkenscythe:items/biomass"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "item/handheld",
"textures": {
"layer0": "harkenscythe:items/axe_biomass"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "item/generated",
"textures": {
"layer0": "harkenscythe:items/boots_biomass"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "item/generated",
"textures": {
"layer0": "harkenscythe:items/chestplate_biomass"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "item/handheld",
"textures": {
"layer0": "harkenscythe:items/glaive_biomass"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "item/generated",
"textures": {
"layer0": "harkenscythe:items/helmet_biomass"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "item/handheld",
"textures": {
"layer0": "harkenscythe:items/hoe_biomass"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "item/generated",
"textures": {
"layer0": "harkenscythe:items/leggings_biomass"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "item/handheld",
"textures": {
"layer0": "harkenscythe:items/pickaxe_biomass"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "item/handheld",
"textures": {
"layer0": "harkenscythe:items/scythe_biomass"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "item/handheld",
"textures": {
"layer0": "harkenscythe:items/shovel_biomass"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "item/handheld",
"textures": {
"layer0": "harkenscythe:items/sword_biomass"
}
}
20 changes: 20 additions & 0 deletions src/main/resources/assets/harkenscythe/recipes/biomass_axe.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"type": "forge:ore_shaped",
"pattern": [
"MM",
"MS",
" S"
],
"key": {
"M": {
"item": "harkenscythe:biomass"
},
"S": {
"type": "forge:ore_dict",
"ore": "stickWood"
}
},
"result": {
"item": "harkenscythe:biomass_axe"
}
}
15 changes: 15 additions & 0 deletions src/main/resources/assets/harkenscythe/recipes/biomass_boots.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"type": "forge:ore_shaped",
"pattern": [
"M M",
"M M"
],
"key": {
"M": {
"item": "harkenscythe:biomass"
}
},
"result": {
"item": "harkenscythe:biomass_boots"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"type": "forge:ore_shaped",
"pattern": [
"M M",
"MMM",
"MMM"
],
"key": {
"M": {
"item": "harkenscythe:biomass"
}
},
"result": {
"item": "harkenscythe:biomass_chestplate"
}
}
20 changes: 20 additions & 0 deletions src/main/resources/assets/harkenscythe/recipes/biomass_glaive.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"type": "forge:ore_shaped",
"pattern": [
" MM",
"MSM",
"SM "
],
"key": {
"M": {
"item": "harkenscythe:biomass"
},
"S": {
"type": "forge:ore_dict",
"ore": "stickWood"
}
},
"result": {
"item": "harkenscythe:biomass_glaive"
}
}
15 changes: 15 additions & 0 deletions src/main/resources/assets/harkenscythe/recipes/biomass_helmet.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"type": "forge:ore_shaped",
"pattern": [
"MMM",
"M M"
],
"key": {
"M": {
"item": "harkenscythe:biomass"
}
},
"result": {
"item": "harkenscythe:biomass_helmet"
}
}
20 changes: 20 additions & 0 deletions src/main/resources/assets/harkenscythe/recipes/biomass_hoe.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"type": "forge:ore_shaped",
"pattern": [
"MM",
" S",
" S"
],
"key": {
"M": {
"item": "harkenscythe:biomass"
},
"S": {
"type": "forge:ore_dict",
"ore": "stickWood"
}
},
"result": {
"item": "harkenscythe:biomass_hoe"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"type": "forge:ore_shaped",
"pattern": [
"MMM",
"M M",
"M M"
],
"key": {
"M": {
"item": "harkenscythe:biomass"
}
},
"result": {
"item": "harkenscythe:biomass_leggings"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"type": "forge:ore_shaped",
"pattern": [
"MMM",
" S ",
" S "
],
"key": {
"M": {
"item": "harkenscythe:biomass"
},
"S": {
"type": "forge:ore_dict",
"ore": "stickWood"
}
},
"result": {
"item": "harkenscythe:biomass_pickaxe"
}
}
20 changes: 20 additions & 0 deletions src/main/resources/assets/harkenscythe/recipes/biomass_scythe.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"type": "forge:ore_shaped",
"pattern": [
"MMM",
"M S",
" S "
],
"key": {
"M": {
"item": "harkenscythe:biomass"
},
"S": {
"type": "forge:ore_dict",
"ore": "stickWood"
}
},
"result": {
"item": "harkenscythe:biomass_scythe"
}
}
20 changes: 20 additions & 0 deletions src/main/resources/assets/harkenscythe/recipes/biomass_shovel.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"type": "forge:ore_shaped",
"pattern": [
"M",
"S",
"S"
],
"key": {
"M": {
"item": "harkenscythe:biomass"
},
"S": {
"type": "forge:ore_dict",
"ore": "stickWood"
}
},
"result": {
"item": "harkenscythe:biomass_shovel"
}
}
Loading

0 comments on commit 5dd19b7

Please sign in to comment.