Fix all redundant hardcoding of modid

This commit is contained in:
Vincent Lee committed 2020-06-28 20:31:33 -05:00
1 parent bcecfa188c
commit 30e91eec9b
8 files changed
+11 -8

No files matched your search

@@ -44,7 +44,7 @@ public class BreweryRecipeCategory implements IRecipeCategory<IBrewRecipe> {
private final String localizedName;
public BreweryRecipeCategory(IGuiHelper guiHelper) {
ResourceLocation location = new ResourceLocation("botania", "textures/gui/nei_brewery.png");
ResourceLocation location = new ResourceLocation(LibMisc.MOD_ID, "textures/gui/nei_brewery.png");
background = guiHelper.createDrawable(location, 0, 0, 166, 65);
localizedName = I18n.format("botania.nei.brewery");
icon = guiHelper.createDrawableIngredient(new ItemStack(ModBlocks.brewery));
@@ -56,7 +56,7 @@ public class ElvenTradeRecipeCategory implements IRecipeCategory<IElvenTradeReci
public ElvenTradeRecipeCategory(IGuiHelper guiHelper) {
localizedName = I18n.format("botania.nei.elvenTrade");
background = guiHelper.createBlankDrawable(145, 95);
overlay = guiHelper.createDrawable(new ResourceLocation("botania", "textures/gui/elven_trade_overlay.png"), 0, 15, 140, 90);
overlay = guiHelper.createDrawable(new ResourceLocation(LibMisc.MOD_ID, "textures/gui/elven_trade_overlay.png"), 0, 15, 140, 90);
icon = guiHelper.createDrawableIngredient(new ItemStack(ModBlocks.alfPortal));
}
@@ -50,7 +50,7 @@ public class ManaPoolRecipeCategory implements IRecipeCategory<IManaInfusionReci
public ManaPoolRecipeCategory(IGuiHelper guiHelper) {
background = guiHelper.createBlankDrawable(168, 64);
localizedName = I18n.format("botania.nei.manaPool");
overlay = guiHelper.createDrawable(new ResourceLocation("botania", "textures/gui/pure_daisy_overlay.png"),
overlay = guiHelper.createDrawable(new ResourceLocation(LibMisc.MOD_ID, "textures/gui/pure_daisy_overlay.png"),
0, 0, 64, 46);
ItemNBTHelper.setBoolean(renderStack, "RenderFull", true);
icon = guiHelper.createDrawableIngredient(renderStack.copy());
@@ -26,6 +26,7 @@ import net.minecraft.tags.BlockTags;
import net.minecraft.util.ResourceLocation;
import vazkii.botania.client.integration.jei.JEIBotaniaPlugin;
import vazkii.botania.common.lib.LibMisc;
import javax.annotation.Nonnull;
@@ -44,7 +45,7 @@ public abstract class OrechidRecipeCategoryBase<T extends OrechidRecipeWrapper>
private final ItemStack inputStack;
public OrechidRecipeCategoryBase(IGuiHelper guiHelper, ItemStack iconStack, ItemStack inputStack, String localizedName) {
overlay = guiHelper.createDrawable(new ResourceLocation("botania", "textures/gui/pure_daisy_overlay.png"),
overlay = guiHelper.createDrawable(new ResourceLocation(LibMisc.MOD_ID, "textures/gui/pure_daisy_overlay.png"),
0, 0, 64, 46);
background = guiHelper.createBlankDrawable(168, 64);
this.localizedName = localizedName;
@@ -47,7 +47,7 @@ public class PetalApothecaryRecipeCategory implements IRecipeCategory<IPetalReci
public PetalApothecaryRecipeCategory(IGuiHelper guiHelper) {
background = guiHelper.createBlankDrawable(150, 110);
localizedName = I18n.format("botania.nei.petalApothecary");
overlay = guiHelper.createDrawable(new ResourceLocation("botania", "textures/gui/petal_overlay.png"),
overlay = guiHelper.createDrawable(new ResourceLocation(LibMisc.MOD_ID, "textures/gui/petal_overlay.png"),
0, 0, 150, 110);
icon = guiHelper.createDrawableIngredient(new ItemStack(ModBlocks.defaultAltar));
}
@@ -50,7 +50,7 @@ public class PureDaisyRecipeCategory implements IRecipeCategory<IPureDaisyRecipe
public PureDaisyRecipeCategory(IGuiHelper guiHelper) {
background = guiHelper.createBlankDrawable(168, 46);
localizedName = I18n.format("botania.nei.pureDaisy");
overlay = guiHelper.createDrawable(new ResourceLocation("botania", "textures/gui/pure_daisy_overlay.png"),
overlay = guiHelper.createDrawable(new ResourceLocation(LibMisc.MOD_ID, "textures/gui/pure_daisy_overlay.png"),
0, 0, 64, 46);
icon = guiHelper.createDrawableIngredient(new ItemStack(ModSubtiles.pureDaisy));
}
@@ -48,7 +48,7 @@ public class RunicAltarRecipeCategory implements IRecipeCategory<IRuneAltarRecip
public RunicAltarRecipeCategory(IGuiHelper guiHelper) {
background = guiHelper.createBlankDrawable(150, 110);
localizedName = I18n.format("botania.nei.runicAltar");
overlay = guiHelper.createDrawable(new ResourceLocation("botania", "textures/gui/petal_overlay.png"),
overlay = guiHelper.createDrawable(new ResourceLocation(LibMisc.MOD_ID, "textures/gui/petal_overlay.png"),
0, 0, 150, 110);
icon = guiHelper.createDrawableIngredient(new ItemStack(ModBlocks.runeAltar));
}
@@ -8,9 +8,11 @@
*/
package vazkii.botania.common.lib;
import vazkii.botania.api.BotaniaAPI;
public final class LibMisc {
public static final String MOD_ID = "botania";
public static final String MOD_ID = BotaniaAPI.MODID;
public static final String MOD_NAME = "Botania";
public static final int PASSIVE_FLOWER_DECAY = 72000;