mirror of
https://github.com/Ellpeck/NaturesAura.git
synced 2024-12-22 14:59:22 +01:00
clarify what the aura bottles in altar recipes mean
This commit is contained in:
parent
b280ede21e
commit
5cfbb0f372
4 changed files with 16 additions and 3 deletions
|
@ -62,7 +62,7 @@ public class AltarCategory implements IRecipeCategory<AltarRecipe> {
|
|||
if (altarRecipe.catalyst != Ingredient.EMPTY)
|
||||
builder.add(altarRecipe.catalyst.getMatchingStacks());
|
||||
if (altarRecipe.requiredType != null)
|
||||
builder.add(ItemAuraBottle.setType(new ItemStack(ModItems.AURA_BOTTLE), altarRecipe.requiredType));
|
||||
builder.add(altarRecipe.getDimensionBottle());
|
||||
iIngredients.setInputs(VanillaTypes.ITEM, builder.build());
|
||||
iIngredients.setOutput(VanillaTypes.ITEM, altarRecipe.output);
|
||||
}
|
||||
|
@ -79,6 +79,6 @@ public class AltarCategory implements IRecipeCategory<AltarRecipe> {
|
|||
Collections.singletonList(this.altar) : Arrays.asList(recipe.catalyst.getMatchingStacks()));
|
||||
group.init(3, true, 51, 18);
|
||||
if (recipe.requiredType != null)
|
||||
group.set(3, ItemAuraBottle.setType(new ItemStack(ModItems.AURA_BOTTLE), recipe.requiredType));
|
||||
group.set(3, recipe.getDimensionBottle());
|
||||
}
|
||||
}
|
||||
|
|
|
@ -35,7 +35,7 @@ public class ProcessorAltar implements IComponentProcessor {
|
|||
return null;
|
||||
case "type":
|
||||
if (this.recipe.requiredType != null)
|
||||
return IVariable.from(ItemAuraBottle.setType(new ItemStack(ModItems.AURA_BOTTLE), this.recipe.requiredType));
|
||||
return IVariable.from(this.recipe.getDimensionBottle());
|
||||
else
|
||||
return null;
|
||||
case "name":
|
||||
|
|
|
@ -1,8 +1,11 @@
|
|||
package de.ellpeck.naturesaura.recipes;
|
||||
|
||||
import com.google.gson.JsonObject;
|
||||
import de.ellpeck.naturesaura.NaturesAura;
|
||||
import de.ellpeck.naturesaura.api.NaturesAuraAPI;
|
||||
import de.ellpeck.naturesaura.api.aura.type.IAuraType;
|
||||
import de.ellpeck.naturesaura.items.ItemAuraBottle;
|
||||
import de.ellpeck.naturesaura.items.ModItems;
|
||||
import net.minecraft.data.IFinishedRecipe;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.item.crafting.IRecipeSerializer;
|
||||
|
@ -10,6 +13,8 @@ import net.minecraft.item.crafting.IRecipeType;
|
|||
import net.minecraft.item.crafting.Ingredient;
|
||||
import net.minecraft.network.PacketBuffer;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.text.TextFormatting;
|
||||
import net.minecraft.util.text.TranslationTextComponent;
|
||||
import net.minecraftforge.common.crafting.CraftingHelper;
|
||||
import net.minecraftforge.registries.ForgeRegistryEntry;
|
||||
|
||||
|
@ -49,6 +54,12 @@ public class AltarRecipe extends ModRecipe {
|
|||
return ModRecipes.ALTAR_TYPE;
|
||||
}
|
||||
|
||||
public ItemStack getDimensionBottle() {
|
||||
ItemStack bottle = ItemAuraBottle.setType(new ItemStack(ModItems.AURA_BOTTLE), this.requiredType);
|
||||
bottle.setDisplayName(new TranslationTextComponent("info." + NaturesAura.MOD_ID + ".required_aura_type." + this.requiredType.getName()));
|
||||
return bottle;
|
||||
}
|
||||
|
||||
public static class Serializer extends ForgeRegistryEntry<IRecipeSerializer<?>> implements IRecipeSerializer<AltarRecipe> {
|
||||
|
||||
@Override
|
||||
|
|
|
@ -153,6 +153,8 @@
|
|||
"info.naturesaura.remaining": "%s remaining",
|
||||
"info.naturesaura.break_prevention": "Eir's Token applied",
|
||||
"info.naturesaura.broken": " (Broken)",
|
||||
"info.naturesaura.required_aura_type.naturesaura:overworld": "Requires Natural Altar",
|
||||
"info.naturesaura.required_aura_type.naturesaura:nether": "Requires Crimson Altar",
|
||||
"advancement.naturesaura.root": "Nature's Aura",
|
||||
"advancement.naturesaura.root.desc": "Becoming a magical botanist",
|
||||
"advancement.naturesaura.get_book": "Pages of Discovery",
|
||||
|
|
Loading…
Reference in a new issue