Started working on two new items: Straw totem and straw charge.

Added textures, crafting recipes and lang file entries.
Items are basic and don't do anything yet
This commit is contained in:
micle
2021-05-29 19:20:54 +01:00
parent 107eb688eb
commit 2274056c04
15 changed files with 177 additions and 1 deletions

View File

@ -30,5 +30,24 @@ public class ModRecipeProvider extends RecipeProvider {
.pattern("@E@")
.unlockedBy("has_item", has(ModItems.TOTEM_OF_REVIVING.get()))
.save(consumer);
ShapedRecipeBuilder.shaped(ModItems.STRAW_TOTEM.get())
.define('W', Items.WHEAT)
.define('/', Items.STICK)
.define('S', Items.STRING)
.define('N', Items.IRON_NUGGET)
.pattern("NSN")
.pattern("NWN")
.pattern("N/N")
.unlockedBy("has_item", has(Items.WHEAT))
.save(consumer);
ShapedRecipeBuilder.shaped(ModItems.STRAW_CHARGE.get())
.define('W', Items.WHEAT)
.define('E', Items.EMERALD)
.define('I', Items.IRON_INGOT)
.pattern("IWI")
.pattern("WEW")
.pattern("IWI")
.unlockedBy("has_item", has(Items.EMERALD))
.save(consumer);
}
}

View File

@ -23,6 +23,8 @@ public class ModItemModelProvider extends ItemModelProvider {
builder(item_generated, "totem_of_reviving");
builder(item_generated, "reviving_charge");
builder(item_generated, "straw_totem");
builder(item_generated, "straw_charge");
}
private ItemModelBuilder builder(ModelFile item_generated, String name) {

View File

@ -0,0 +1,10 @@
package com.micle.totemofreviving.items;
import net.minecraft.item.Item;
import net.minecraft.item.ItemGroup;
public class StrawChargeItem extends Item {
public StrawChargeItem() {
super(new Properties().tab(ItemGroup.TAB_MISC));
}
}

View File

@ -0,0 +1,10 @@
package com.micle.totemofreviving.items;
import net.minecraft.item.Item;
import net.minecraft.item.ItemGroup;
public class StrawTotemItem extends Item {
public StrawTotemItem() {
super(new Properties().tab(ItemGroup.TAB_MISC));
}
}

View File

@ -1,6 +1,8 @@
package com.micle.totemofreviving.setup;
import com.micle.totemofreviving.items.RevivingChargeItem;
import com.micle.totemofreviving.items.StrawChargeItem;
import com.micle.totemofreviving.items.StrawTotemItem;
import com.micle.totemofreviving.items.TotemOfRevivingItem;
import net.minecraft.item.Item;
import net.minecraft.item.ItemGroup;
@ -9,6 +11,8 @@ import net.minecraftforge.fml.RegistryObject;
public class ModItems {
public static final RegistryObject<Item> TOTEM_OF_REVIVING = Registration.ITEMS.register("totem_of_reviving", TotemOfRevivingItem::new);
public static final RegistryObject<Item> REVIVING_CHARGE = Registration.ITEMS.register("reviving_charge", RevivingChargeItem::new);
public static final RegistryObject<Item> STRAW_TOTEM = Registration.ITEMS.register("straw_totem", StrawTotemItem::new);
public static final RegistryObject<Item> STRAW_CHARGE = Registration.ITEMS.register("straw_charge", StrawChargeItem::new);
static void register() {
}