Remove things that shouldn't be there
This commit is contained in:
parent
de5e23e6c4
commit
c66b99b535
|
@ -1,59 +0,0 @@
|
|||
package WayofTime.bloodmagic.compat.direwolf;
|
||||
|
||||
import WayofTime.bloodmagic.api.Constants;
|
||||
import WayofTime.bloodmagic.api.altar.EnumAltarTier;
|
||||
import WayofTime.bloodmagic.api.event.AltarCraftedEvent;
|
||||
import WayofTime.bloodmagic.api.registry.AltarRecipeRegistry;
|
||||
import WayofTime.bloodmagic.compat.ICompatibility;
|
||||
import WayofTime.bloodmagic.util.helper.TextHelper;
|
||||
import net.minecraft.init.Items;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraftforge.common.MinecraftForge;
|
||||
import net.minecraftforge.event.entity.player.ItemTooltipEvent;
|
||||
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
|
||||
|
||||
public class CompatibilityDirewolf implements ICompatibility
|
||||
{
|
||||
@Override
|
||||
public void loadCompatibility(InitializationPhase phase)
|
||||
{
|
||||
if (phase == InitializationPhase.POST_INIT)
|
||||
{
|
||||
AltarRecipeRegistry.registerRecipe(new AltarRecipeRegistry.AltarRecipe(new ItemStack(Items.BREAD), new ItemStack(Items.BREAD), EnumAltarTier.ONE, 10, 1, 0));
|
||||
MinecraftForge.EVENT_BUS.register(this);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getModId()
|
||||
{
|
||||
return Constants.Mod.MODID;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean enableCompat()
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
@SubscribeEvent
|
||||
public void onAltarCrafted(AltarCraftedEvent event)
|
||||
{
|
||||
if (event.getOutput().getItem() == Items.BREAD)
|
||||
{
|
||||
event.getOutput().setTagCompound(new NBTTagCompound());
|
||||
event.getOutput().setStackDisplayName(TextHelper.localizeEffect("secret.BloodMagic.bread.bloody"));
|
||||
event.getOutput().getTagCompound().setBoolean("bloody", true);
|
||||
}
|
||||
}
|
||||
|
||||
@SubscribeEvent
|
||||
public void onTooltip(ItemTooltipEvent event)
|
||||
{
|
||||
if (event.getItemStack().getItem() == Items.BREAD)
|
||||
if (event.getItemStack().hasTagCompound())
|
||||
if (event.getItemStack().getTagCompound().hasKey("bloody"))
|
||||
event.getToolTip().add(TextHelper.localizeEffect("secret.BloodMagic.bread.bloody.desc"));
|
||||
}
|
||||
}
|
|
@ -1,7 +0,0 @@
|
|||
@ParametersAreNonnullByDefault
|
||||
@MethodsReturnNonnullByDefault
|
||||
package WayofTime.bloodmagic.compat.direwolf;
|
||||
|
||||
import mcp.MethodsReturnNonnullByDefault;
|
||||
|
||||
import javax.annotation.ParametersAreNonnullByDefault;
|
|
@ -1,41 +0,0 @@
|
|||
//package WayofTime.bloodmagic.compat.guideapi;
|
||||
//
|
||||
//import WayofTime.bloodmagic.api.altar.EnumAltarTier;
|
||||
//import WayofTime.bloodmagic.api.registry.AltarRecipeRegistry;
|
||||
//import WayofTime.bloodmagic.compat.ICompatibility;
|
||||
//import amerifrance.guideapi.api.GuideAPI;
|
||||
//import net.minecraft.init.Items;
|
||||
//import net.minecraft.item.ItemStack;
|
||||
//import net.minecraftforge.fml.common.registry.GameRegistry;
|
||||
//
|
||||
//public class CompatibilityGuideAPI implements ICompatibility {
|
||||
//
|
||||
// @Override
|
||||
// public void loadCompatibility(InitializationPhase phase) {
|
||||
// switch (phase) {
|
||||
// case PRE_INIT: {
|
||||
// GuideBloodMagic.initBook();
|
||||
// AltarRecipeRegistry.registerRecipe(new AltarRecipeRegistry.AltarRecipe(new ItemStack(Items.BOOK), GuideAPI.getStackFromBook(GuideBloodMagic.guideBook), EnumAltarTier.ONE, 500, 2, 0));
|
||||
// break;
|
||||
// }
|
||||
// case INIT: {
|
||||
// break;
|
||||
// }
|
||||
// case POST_INIT: {
|
||||
// GuideBloodMagic.initCategories();
|
||||
// GameRegistry.register(GuideBloodMagic.guideBook);
|
||||
// break;
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// public String getModId() {
|
||||
// return "guideapi";
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// public boolean enableCompat() {
|
||||
// return true;
|
||||
// }
|
||||
//}
|
|
@ -1,56 +0,0 @@
|
|||
//package WayofTime.bloodmagic.compat.guideapi;
|
||||
//
|
||||
//import WayofTime.bloodmagic.compat.guideapi.book.*;
|
||||
//import WayofTime.bloodmagic.compat.jei.BloodMagicPlugin;
|
||||
//import WayofTime.bloodmagic.registry.ModBlocks;
|
||||
//import WayofTime.bloodmagic.registry.ModItems;
|
||||
//import amerifrance.guideapi.api.GuideAPI;
|
||||
//import amerifrance.guideapi.api.impl.Book;
|
||||
//import amerifrance.guideapi.api.util.NBTBookTags;
|
||||
//import amerifrance.guideapi.category.CategoryItemStack;
|
||||
//import net.minecraft.item.ItemStack;
|
||||
//import net.minecraftforge.fml.common.FMLCommonHandler;
|
||||
//import net.minecraftforge.fml.common.Loader;
|
||||
//import net.minecraftforge.fml.relauncher.Side;
|
||||
//
|
||||
//import java.awt.Color;
|
||||
//
|
||||
//public class GuideBloodMagic {
|
||||
//
|
||||
// public static Book guideBook;
|
||||
//
|
||||
// public static void initBook() {
|
||||
// guideBook = new Book();
|
||||
// guideBook.setTitle("guide.BloodMagic.title");
|
||||
// guideBook.setDisplayName("guide.BloodMagic.display");
|
||||
// guideBook.setWelcomeMessage("guide.BloodMagic.welcome");
|
||||
// guideBook.setAuthor("guide.BloodMagic.author");
|
||||
// guideBook.setRegistryName("BloodMagic");
|
||||
// guideBook.setColor(Color.RED);
|
||||
//
|
||||
// if (FMLCommonHandler.instance().getSide() == Side.CLIENT)
|
||||
// GuideAPI.setModel(guideBook);
|
||||
// }
|
||||
//
|
||||
// public static void initCategories() {
|
||||
// guideBook.addCategory(new CategoryItemStack(CategoryAlchemy.buildCategory(), "guide.BloodMagic.category.alchemy", new ItemStack(ModItems.arcaneAshes)));
|
||||
// guideBook.addCategory(new CategoryItemStack(CategoryArchitect.buildCategory(), "guide.BloodMagic.category.architect", new ItemStack(ModItems.sigilDivination)));
|
||||
// guideBook.addCategory(new CategoryItemStack(CategoryDemon.buildCategory(), "guide.BloodMagic.category.demon", new ItemStack(ModItems.bloodShard)));
|
||||
// guideBook.addCategory(new CategoryItemStack(CategoryRitual.buildCategory(), "guide.BloodMagic.category.ritual", new ItemStack(ModBlocks.ritualController)));
|
||||
// guideBook.addCategory(new CategoryItemStack(CategorySpell.buildCategory(), "guide.BloodMagic.category.spell", new ItemStack(ModItems.ritualDiviner)));
|
||||
// }
|
||||
//
|
||||
// public static void initJEIBlacklist() {
|
||||
// if (Loader.isModLoaded("JEI"))
|
||||
// BloodMagicPlugin.jeiHelper.getNbtIgnoreList().ignoreNbtTagNames(
|
||||
// GuideAPI.guideBook,
|
||||
// NBTBookTags.BOOK_TAG,
|
||||
// NBTBookTags.CATEGORY_PAGE_TAG,
|
||||
// NBTBookTags.CATEGORY_TAG,
|
||||
// NBTBookTags.ENTRY_PAGE_TAG,
|
||||
// NBTBookTags.ENTRY_TAG,
|
||||
// NBTBookTags.KEY_TAG,
|
||||
// NBTBookTags.PAGE_TAG
|
||||
// );
|
||||
// }
|
||||
//}
|
|
@ -1,20 +0,0 @@
|
|||
//package WayofTime.bloodmagic.compat.guideapi.book;
|
||||
//
|
||||
//import WayofTime.bloodmagic.api.Constants;
|
||||
//import amerifrance.guideapi.api.impl.abstraction.EntryAbstract;
|
||||
//import net.minecraft.util.ResourceLocation;
|
||||
//
|
||||
//import java.util.HashMap;
|
||||
//import java.util.Map;
|
||||
//
|
||||
//public class CategoryAlchemy {
|
||||
//
|
||||
// public static Map<ResourceLocation, EntryAbstract> buildCategory() {
|
||||
// Map<ResourceLocation, EntryAbstract> entries = new HashMap<ResourceLocation, EntryAbstract>();
|
||||
// String keyBase = Constants.Mod.DOMAIN + "alchemy_";
|
||||
//
|
||||
//
|
||||
//
|
||||
// return entries;
|
||||
// }
|
||||
//}
|
|
@ -1,20 +0,0 @@
|
|||
//package WayofTime.bloodmagic.compat.guideapi.book;
|
||||
//
|
||||
//import WayofTime.bloodmagic.api.Constants;
|
||||
//import amerifrance.guideapi.api.impl.abstraction.EntryAbstract;
|
||||
//import net.minecraft.util.ResourceLocation;
|
||||
//
|
||||
//import java.util.HashMap;
|
||||
//import java.util.Map;
|
||||
//
|
||||
//public class CategoryArchitect {
|
||||
//
|
||||
// public static Map<ResourceLocation, EntryAbstract> buildCategory() {
|
||||
// Map<ResourceLocation, EntryAbstract> entries = new HashMap<ResourceLocation, EntryAbstract>();
|
||||
// String keyBase = Constants.Mod.DOMAIN + "architect_";
|
||||
//
|
||||
//
|
||||
//
|
||||
// return entries;
|
||||
// }
|
||||
//}
|
|
@ -1,20 +0,0 @@
|
|||
//package WayofTime.bloodmagic.compat.guideapi.book;
|
||||
//
|
||||
//import WayofTime.bloodmagic.api.Constants;
|
||||
//import amerifrance.guideapi.api.impl.abstraction.EntryAbstract;
|
||||
//import net.minecraft.util.ResourceLocation;
|
||||
//
|
||||
//import java.util.HashMap;
|
||||
//import java.util.Map;
|
||||
//
|
||||
//public class CategoryDemon {
|
||||
//
|
||||
// public static Map<ResourceLocation, EntryAbstract> buildCategory() {
|
||||
// Map<ResourceLocation, EntryAbstract> entries = new HashMap<ResourceLocation, EntryAbstract>();
|
||||
// String keyBase = Constants.Mod.DOMAIN + "demon_";
|
||||
//
|
||||
//
|
||||
//
|
||||
// return entries;
|
||||
// }
|
||||
//}
|
|
@ -1,34 +0,0 @@
|
|||
//package WayofTime.bloodmagic.compat.guideapi.book;
|
||||
//
|
||||
//import WayofTime.bloodmagic.api.Constants;
|
||||
//import WayofTime.bloodmagic.api.registry.RitualRegistry;
|
||||
//import WayofTime.bloodmagic.api.ritual.Ritual;
|
||||
//import WayofTime.bloodmagic.compat.guideapi.entry.EntryText;
|
||||
//import WayofTime.bloodmagic.util.helper.TextHelper;
|
||||
//import amerifrance.guideapi.api.IPage;
|
||||
//import amerifrance.guideapi.api.impl.abstraction.EntryAbstract;
|
||||
//import amerifrance.guideapi.api.util.PageHelper;
|
||||
//import amerifrance.guideapi.page.PageImage;
|
||||
//import net.minecraft.util.ResourceLocation;
|
||||
//
|
||||
//import java.util.ArrayList;
|
||||
//import java.util.HashMap;
|
||||
//import java.util.List;
|
||||
//import java.util.Map;
|
||||
//
|
||||
//public class CategoryRitual {
|
||||
//
|
||||
// public static Map<ResourceLocation, EntryAbstract> buildCategory() {
|
||||
// Map<ResourceLocation, EntryAbstract> entries = new HashMap<ResourceLocation, EntryAbstract>();
|
||||
// String keyBase = Constants.Mod.DOMAIN + "ritual_";
|
||||
//
|
||||
// for (Ritual ritual : RitualRegistry.getRituals()) {
|
||||
// List<IPage> ritualPages = new ArrayList<IPage>();
|
||||
// ritualPages.addAll(PageHelper.pagesForLongText(TextHelper.localize(ritual.getUnlocalizedName() + ".desc")));
|
||||
// ritualPages.add(new PageImage(new ResourceLocation("bloodmagicguide", "textures/guide/" + ritual.getName() + ".png")));
|
||||
// entries.put(new ResourceLocation(keyBase + ritual.getName()), new EntryText(ritualPages, TextHelper.localize(ritual.getUnlocalizedName()), true));
|
||||
// }
|
||||
//
|
||||
// return entries;
|
||||
// }
|
||||
//}
|
|
@ -1,20 +0,0 @@
|
|||
//package WayofTime.bloodmagic.compat.guideapi.book;
|
||||
//
|
||||
//import WayofTime.bloodmagic.api.Constants;
|
||||
//import amerifrance.guideapi.api.impl.abstraction.EntryAbstract;
|
||||
//import net.minecraft.util.ResourceLocation;
|
||||
//
|
||||
//import java.util.HashMap;
|
||||
//import java.util.Map;
|
||||
//
|
||||
//public class CategorySpell {
|
||||
//
|
||||
// public static Map<ResourceLocation, EntryAbstract> buildCategory() {
|
||||
// Map<ResourceLocation, EntryAbstract> entries = new HashMap<ResourceLocation, EntryAbstract>();
|
||||
// String keyBase = Constants.Mod.DOMAIN + "spell_";
|
||||
//
|
||||
//
|
||||
//
|
||||
// return entries;
|
||||
// }
|
||||
//}
|
|
@ -1,7 +0,0 @@
|
|||
@ParametersAreNonnullByDefault
|
||||
@MethodsReturnNonnullByDefault
|
||||
package WayofTime.bloodmagic.compat.guideapi.book;
|
||||
|
||||
import mcp.MethodsReturnNonnullByDefault;
|
||||
|
||||
import javax.annotation.ParametersAreNonnullByDefault;
|
|
@ -1,34 +0,0 @@
|
|||
//package WayofTime.bloodmagic.compat.guideapi.entry;
|
||||
//
|
||||
//import amerifrance.guideapi.api.IPage;
|
||||
//import amerifrance.guideapi.api.impl.Book;
|
||||
//import amerifrance.guideapi.api.impl.abstraction.CategoryAbstract;
|
||||
//import amerifrance.guideapi.api.util.GuiHelper;
|
||||
//import amerifrance.guideapi.entry.EntryResourceLocation;
|
||||
//import amerifrance.guideapi.gui.GuiBase;
|
||||
//import net.minecraft.client.Minecraft;
|
||||
//import net.minecraft.client.gui.FontRenderer;
|
||||
//import net.minecraft.client.renderer.GlStateManager;
|
||||
//import net.minecraft.util.ResourceLocation;
|
||||
//import net.minecraftforge.fml.relauncher.Side;
|
||||
//import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
//
|
||||
//import java.util.List;
|
||||
//
|
||||
//public class EntryText extends EntryResourceLocation {
|
||||
//
|
||||
// public EntryText(List<IPage> pageList, String unlocEntryName, boolean unicode) {
|
||||
// super(pageList, unlocEntryName, new ResourceLocation("bloodmagicguide", "textures/gui/bullet_point.png"), unicode);
|
||||
// }
|
||||
//
|
||||
// public EntryText(List<IPage> pageList, String unlocEntryName) {
|
||||
// this(pageList, unlocEntryName, false);
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// @SideOnly(Side.CLIENT)
|
||||
// public void drawExtras(Book book, CategoryAbstract category, int entryX, int entryY, int entryWidth, int entryHeight, int mouseX, int mouseY, GuiBase guiBase, FontRenderer fontRendererObj) {
|
||||
// Minecraft.getMinecraft().getTextureManager().bindTexture(image);
|
||||
// GuiHelper.drawSizedIconWithoutColor(entryX + 4, entryY + 2, 8, 8, 1F);
|
||||
// }
|
||||
//}
|
|
@ -1,7 +0,0 @@
|
|||
@ParametersAreNonnullByDefault
|
||||
@MethodsReturnNonnullByDefault
|
||||
package WayofTime.bloodmagic.compat.guideapi.entry;
|
||||
|
||||
import mcp.MethodsReturnNonnullByDefault;
|
||||
|
||||
import javax.annotation.ParametersAreNonnullByDefault;
|
|
@ -1,7 +0,0 @@
|
|||
//@ParametersAreNonnullByDefault
|
||||
//@MethodsReturnNonnullByDefault
|
||||
//package WayofTime.bloodmagic.compat.guideapi;
|
||||
//
|
||||
//import mcp.MethodsReturnNonnullByDefault;
|
||||
//
|
||||
//import javax.annotation.ParametersAreNonnullByDefault;
|
|
@ -1,70 +0,0 @@
|
|||
//package WayofTime.bloodmagic.compat.guideapi.page;
|
||||
//
|
||||
//import WayofTime.bloodmagic.api.registry.AltarRecipeRegistry;
|
||||
//import WayofTime.bloodmagic.util.helper.TextHelper;
|
||||
//import amerifrance.guideapi.api.impl.Book;
|
||||
//import amerifrance.guideapi.api.impl.Page;
|
||||
//import amerifrance.guideapi.api.impl.abstraction.CategoryAbstract;
|
||||
//import amerifrance.guideapi.api.impl.abstraction.EntryAbstract;
|
||||
//import amerifrance.guideapi.api.util.GuiHelper;
|
||||
//import amerifrance.guideapi.gui.GuiBase;
|
||||
//import net.minecraft.client.Minecraft;
|
||||
//import net.minecraft.client.gui.FontRenderer;
|
||||
//import net.minecraft.init.Blocks;
|
||||
//import net.minecraft.item.Item;
|
||||
//import net.minecraft.item.ItemStack;
|
||||
//import net.minecraft.util.ResourceLocation;
|
||||
//import net.minecraftforge.fml.relauncher.Side;
|
||||
//import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
//
|
||||
//import java.util.List;
|
||||
//
|
||||
//public class PageAltarRecipe extends Page {
|
||||
//
|
||||
// public List<ItemStack> input;
|
||||
// public ItemStack output;
|
||||
// public int tier;
|
||||
// public int bloodRequired;
|
||||
//
|
||||
// public PageAltarRecipe(AltarRecipeRegistry.AltarRecipe recipe) {
|
||||
// this.input = recipe.getInput();
|
||||
// this.output = recipe.getOutput();
|
||||
// this.tier = recipe.getMinTier().toInt();
|
||||
// this.bloodRequired = recipe.getSyphon();
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// @SideOnly(Side.CLIENT)
|
||||
// public void draw(Book book, CategoryAbstract category, EntryAbstract entry, int guiLeft, int guiTop, int mouseX, int mouseY, GuiBase guiBase, FontRenderer fontRenderer) {
|
||||
//
|
||||
// Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation("alchemicalwizardry" + ":textures/gui/guide/altar.png"));
|
||||
// guiBase.drawTexturedModalRect(guiLeft + 42, guiTop + 53, 0, 87, 146, 104);
|
||||
//
|
||||
// guiBase.drawCenteredString(fontRenderer, TextHelper.localize("text.recipe.altar"), guiLeft + guiBase.xSize / 2, guiTop + 12, 0);
|
||||
//
|
||||
// int inputX = (1 + 1) * 20 + (guiLeft + guiBase.xSize / 7) + 1;
|
||||
// int inputY = (20) + (guiTop + guiBase.ySize / 5) - 1; //1 * 20
|
||||
// GuiHelper.drawItemStack(input.get(0), inputX, inputY);
|
||||
// if (GuiHelper.isMouseBetween(mouseX, mouseY, inputX, inputY, 15, 15)) {
|
||||
// guiBase.renderToolTip(input.get(0), mouseX, mouseY);
|
||||
// }
|
||||
//
|
||||
// if (output == null) {
|
||||
// output = new ItemStack(Blocks.BARRIER);
|
||||
// }
|
||||
// int outputX = (5 * 20) + (guiLeft + guiBase.xSize / 7) + 1;
|
||||
// int outputY = (20) + (guiTop + guiBase.xSize / 5) - 1; // 1 * 20
|
||||
// GuiHelper.drawItemStack(output, outputX, outputY);
|
||||
// if (GuiHelper.isMouseBetween(mouseX, mouseY, outputX, outputY, 15, 15)) {
|
||||
// guiBase.renderToolTip(output, outputX, outputY);
|
||||
// }
|
||||
//
|
||||
// if (output.getItem() == Item.getItemFromBlock(Blocks.BARRIER)) {
|
||||
// guiBase.drawCenteredString(fontRenderer, TextHelper.localize("text.furnace.error"), guiLeft + guiBase.xSize / 2, guiTop + 4 * guiBase.ySize / 6, 0xED073D);
|
||||
// guiBase.drawCenteredString(fontRenderer, TextHelper.localize("bm.string.tier") + ": " + String.valueOf(tier), guiLeft + guiBase.xSize / 2, guiTop + 4 * guiBase.ySize / 6 + 15, 0);
|
||||
// guiBase.drawCenteredString(fontRenderer, "LP: " + String.valueOf(bloodRequired), guiLeft + guiBase.xSize / 2, guiTop + 4 * guiBase.ySize / 6 + 30, 0);
|
||||
// }
|
||||
// guiBase.drawCenteredString(fontRenderer, TextHelper.localize("text.recipe.altar.tier", String.valueOf(tier)), guiLeft + guiBase.xSize / 2, guiTop + 4 * guiBase.ySize / 6, 0);
|
||||
// guiBase.drawCenteredString(fontRenderer, TextHelper.localize("text.recipe.altar.bloodRequired", String.valueOf(bloodRequired)), guiLeft + guiBase.xSize / 2, guiTop + 4 * guiBase.ySize / 6 + 15, 0);
|
||||
// }
|
||||
//}
|
|
@ -1,7 +0,0 @@
|
|||
@ParametersAreNonnullByDefault
|
||||
@MethodsReturnNonnullByDefault
|
||||
package WayofTime.bloodmagic.compat.guideapi.page;
|
||||
|
||||
import mcp.MethodsReturnNonnullByDefault;
|
||||
|
||||
import javax.annotation.ParametersAreNonnullByDefault;
|
|
@ -1,128 +0,0 @@
|
|||
//package WayofTime.bloodmagic.compat.guideapi.page.recipeRenderer;
|
||||
//
|
||||
//import WayofTime.bloodmagic.api.recipe.ShapedBloodOrbRecipe;
|
||||
//import WayofTime.bloodmagic.api.recipe.ShapelessBloodOrbRecipe;
|
||||
//import WayofTime.bloodmagic.api.registry.OrbRegistry;
|
||||
//import WayofTime.bloodmagic.util.helper.TextHelper;
|
||||
//import amerifrance.guideapi.GuideMod;
|
||||
//import amerifrance.guideapi.api.IRecipeRenderer;
|
||||
//import amerifrance.guideapi.api.impl.Book;
|
||||
//import amerifrance.guideapi.api.impl.abstraction.CategoryAbstract;
|
||||
//import amerifrance.guideapi.api.impl.abstraction.EntryAbstract;
|
||||
//import amerifrance.guideapi.api.util.GuiHelper;
|
||||
//import amerifrance.guideapi.gui.GuiBase;
|
||||
//import net.minecraft.client.Minecraft;
|
||||
//import net.minecraft.client.gui.FontRenderer;
|
||||
//import net.minecraft.item.ItemStack;
|
||||
//import net.minecraft.item.crafting.IRecipe;
|
||||
//import net.minecraft.util.ResourceLocation;
|
||||
//import net.minecraftforge.fml.relauncher.ReflectionHelper;
|
||||
//
|
||||
//import java.util.ArrayList;
|
||||
//import java.util.List;
|
||||
//
|
||||
//public class OrbRecipeRenderer implements IRecipeRenderer
|
||||
//{
|
||||
// public IRecipe recipe;
|
||||
//
|
||||
// public OrbRecipeRenderer(IRecipe recipe)
|
||||
// {
|
||||
// this.recipe = recipe;
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// public void draw(Book book, CategoryAbstract category, EntryAbstract entry, int guiLeft, int guiTop, int mouseX, int mouseY, GuiBase guiBase, FontRenderer fontRenderer) {
|
||||
// Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation(GuideMod.GUITEXLOC + "recipe_elements.png"));
|
||||
// guiBase.drawTexturedModalRect(guiLeft + 42, guiTop + 53, 0, 0, 105, 65);
|
||||
//
|
||||
// guiBase.drawCenteredString(fontRenderer, TextHelper.localize("text.recipe.shapedOrb"), guiLeft + guiBase.xSize / 2, guiTop + 12, 0);
|
||||
// if(recipe instanceof ShapelessBloodOrbRecipe)
|
||||
// {
|
||||
// ShapelessBloodOrbRecipe shapelessBloodOrbRecipe = (ShapelessBloodOrbRecipe) recipe;
|
||||
// List<Object> list = shapelessBloodOrbRecipe.getInput();
|
||||
//
|
||||
// int width = 3;
|
||||
// int height = 3;
|
||||
// for (int y = 0; y < height; y++) {
|
||||
// for (int x = 0; x < width; x++) {
|
||||
// if(list.size() - 1 < y * width + x)
|
||||
// {
|
||||
// continue;
|
||||
// }
|
||||
//
|
||||
// int stackX = (x + 1) * 18 + (guiLeft + guiBase.xSize / 7);
|
||||
// int stackY = (y + 1) * 18 + (guiTop + guiBase.ySize / 5);
|
||||
//
|
||||
// Object component = list.get(y * width + x);
|
||||
// if (component != null) {
|
||||
// if (component instanceof ItemStack) {
|
||||
// GuiHelper.drawItemStack((ItemStack) component, stackX, stackY);
|
||||
// if (GuiHelper.isMouseBetween(mouseX, mouseY, stackX, stackY, 15, 15)) {
|
||||
// guiBase.renderToolTip((ItemStack) component, stackX, stackY);
|
||||
// }
|
||||
// } else if (component instanceof Integer) {
|
||||
// GuiHelper.drawItemStack(OrbRegistry.getOrbsForTier((Integer) component).get(0), stackX, stackY);
|
||||
// if (GuiHelper.isMouseBetween(mouseX, mouseY, stackX, stackY, 15, 15)) {
|
||||
// guiBase.renderToolTip(OrbRegistry.getOrbsForTier((Integer) component).get(0), stackX, stackY);
|
||||
// }
|
||||
// } else {
|
||||
// if (((ArrayList<ItemStack>) component).isEmpty()) return;
|
||||
// GuiHelper.drawItemStack(((ArrayList<ItemStack>) component).get(0), stackX, stackY);
|
||||
// if (GuiHelper.isMouseBetween(mouseX, mouseY, stackX, stackY, 15, 15)) {
|
||||
// guiBase.renderToolTip(((ArrayList<ItemStack>) component).get(0), stackX, stackY);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// int outputX = (5 * 18) + (guiLeft + guiBase.xSize / 7);
|
||||
// int outputY = (2 * 18) + (guiTop + guiBase.xSize / 5);
|
||||
// GuiHelper.drawItemStack(shapelessBloodOrbRecipe.getRecipeOutput(), outputX, outputY);
|
||||
// if (GuiHelper.isMouseBetween(mouseX, mouseY, outputX, outputY, 15, 15)) {
|
||||
// guiBase.renderToolTip(shapelessBloodOrbRecipe.getRecipeOutput(), outputX, outputY);
|
||||
// }
|
||||
// }else if (recipe instanceof ShapedBloodOrbRecipe)
|
||||
// {
|
||||
// ShapedBloodOrbRecipe shapedBloodOrbRecipe = (ShapedBloodOrbRecipe) recipe;
|
||||
// int width = ReflectionHelper.getPrivateValue(ShapedBloodOrbRecipe.class, shapedBloodOrbRecipe, 4);
|
||||
// int height = ReflectionHelper.getPrivateValue(ShapedBloodOrbRecipe.class, shapedBloodOrbRecipe, 5);
|
||||
// for (int y = 0; y < height; y++) {
|
||||
// for (int x = 0; x < width; x++) {
|
||||
// int stackX = (x + 1) * 18 + (guiLeft + guiBase.xSize / 7);
|
||||
// int stackY = (y + 1) * 18 + (guiTop + guiBase.ySize / 5);
|
||||
// Object component = shapedBloodOrbRecipe.getInput()[y * width + x];
|
||||
// if (component != null) {
|
||||
// if (component instanceof ItemStack) {
|
||||
// GuiHelper.drawItemStack((ItemStack) component, stackX, stackY);
|
||||
// if (GuiHelper.isMouseBetween(mouseX, mouseY, stackX, stackY, 15, 15)) {
|
||||
// guiBase.renderToolTip((ItemStack) component, stackX, stackY);
|
||||
// }
|
||||
// } else if (component instanceof Integer) {
|
||||
// GuiHelper.drawItemStack(OrbRegistry.getOrbsForTier((Integer) component).get(0), stackX, stackY);
|
||||
// if (GuiHelper.isMouseBetween(mouseX, mouseY, stackX, stackY, 15, 15)) {
|
||||
// guiBase.renderToolTip(OrbRegistry.getOrbsForTier((Integer) component).get(0), stackX, stackY);
|
||||
// }
|
||||
// } else {
|
||||
// if (((ArrayList<ItemStack>) component).isEmpty()) return;
|
||||
// GuiHelper.drawItemStack(((ArrayList<ItemStack>) component).get(0), stackX, stackY);
|
||||
// if (GuiHelper.isMouseBetween(mouseX, mouseY, stackX, stackY, 15, 15)) {
|
||||
// guiBase.renderToolTip(((ArrayList<ItemStack>) component).get(0), stackX, stackY);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// int outputX = (5 * 18) + (guiLeft + guiBase.xSize / 7);
|
||||
// int outputY = (2 * 18) + (guiTop + guiBase.xSize / 5);
|
||||
// GuiHelper.drawItemStack(shapedBloodOrbRecipe.getRecipeOutput(), outputX, outputY);
|
||||
// if (GuiHelper.isMouseBetween(mouseX, mouseY, outputX, outputY, 15, 15)) {
|
||||
// guiBase.renderToolTip(shapedBloodOrbRecipe.getRecipeOutput(), outputX, outputY);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// public void drawExtras(Book book, CategoryAbstract category, EntryAbstract entry, int guiLeft, int guiTop, int mouseX, int mouseY, GuiBase guiBase, FontRenderer fontRenderer) {
|
||||
//
|
||||
// }
|
||||
//}
|
|
@ -1,7 +0,0 @@
|
|||
@ParametersAreNonnullByDefault
|
||||
@MethodsReturnNonnullByDefault
|
||||
package WayofTime.bloodmagic.compat.guideapi.page.recipeRenderer;
|
||||
|
||||
import mcp.MethodsReturnNonnullByDefault;
|
||||
|
||||
import javax.annotation.ParametersAreNonnullByDefault;
|
Binary file not shown.
Before Width: | Height: | Size: 17 KiB |
Loading…
Reference in a new issue