summaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
authorOnyxDarkKnight <sor1n.iliutza16@gmail.com>2014-09-17 19:10:05 +0300
committerOnyxDarkKnight <sor1n.iliutza16@gmail.com>2014-09-17 19:10:05 +0300
commit06f62473f0622efe6decc32b70516a7c5d3d3572 (patch)
treeebf54c96117f9917cd93740a89763c26abde06af /src/main
parent852cfd0e13631320624d528213ec8c80cffe8743 (diff)
1.7.10
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/darkknight/jewelrycraft/CommonProxy.java9
-rw-r--r--src/main/java/darkknight/jewelrycraft/CreativeTabLiquids.java52
-rw-r--r--src/main/java/darkknight/jewelrycraft/CreativeTabNecklaces.java54
-rw-r--r--src/main/java/darkknight/jewelrycraft/CreativeTabRings.java55
-rw-r--r--src/main/java/darkknight/jewelrycraft/JewelrycraftMod.java140
-rw-r--r--src/main/java/darkknight/jewelrycraft/block/BlockDisplayer.java185
-rw-r--r--src/main/java/darkknight/jewelrycraft/block/BlockGlow.java39
-rw-r--r--src/main/java/darkknight/jewelrycraft/block/BlockJCOre.java15
-rw-r--r--src/main/java/darkknight/jewelrycraft/block/BlockJewelAltar.java119
-rw-r--r--src/main/java/darkknight/jewelrycraft/block/BlockJewelrsCraftingTable.java222
-rw-r--r--src/main/java/darkknight/jewelrycraft/block/BlockList.java68
-rw-r--r--src/main/java/darkknight/jewelrycraft/block/BlockMolder.java147
-rw-r--r--src/main/java/darkknight/jewelrycraft/block/BlockMoltenMetal.java275
-rw-r--r--src/main/java/darkknight/jewelrycraft/block/BlockShadow.java117
-rw-r--r--src/main/java/darkknight/jewelrycraft/block/BlockSmelter.java189
-rw-r--r--src/main/java/darkknight/jewelrycraft/client/ClientProxy.java21
-rw-r--r--src/main/java/darkknight/jewelrycraft/client/GuiGuide.java215
-rw-r--r--src/main/java/darkknight/jewelrycraft/client/GuiRingChest.java39
-rw-r--r--src/main/java/darkknight/jewelrycraft/config/ConfigHandler.java57
-rw-r--r--src/main/java/darkknight/jewelrycraft/container/ContainerGuide.java18
-rw-r--r--src/main/java/darkknight/jewelrycraft/container/ContainerRingChest.java71
-rw-r--r--src/main/java/darkknight/jewelrycraft/container/GuiHandler.java40
-rw-r--r--src/main/java/darkknight/jewelrycraft/container/GuiRectangle.java66
-rw-r--r--src/main/java/darkknight/jewelrycraft/container/GuiTab.java37
-rw-r--r--src/main/java/darkknight/jewelrycraft/container/GuiTabBlocks.java295
-rw-r--r--src/main/java/darkknight/jewelrycraft/container/GuiTabItems.java278
-rw-r--r--src/main/java/darkknight/jewelrycraft/container/GuiTabJewelsAndModifiers.java87
-rw-r--r--src/main/java/darkknight/jewelrycraft/container/GuiTabNecklaces.java380
-rw-r--r--src/main/java/darkknight/jewelrycraft/container/GuiTabRings.java587
-rw-r--r--src/main/java/darkknight/jewelrycraft/container/Page.java172
-rw-r--r--src/main/java/darkknight/jewelrycraft/container/SlotRingChest.java39
-rw-r--r--src/main/java/darkknight/jewelrycraft/events/BucketHandler.java60
-rw-r--r--src/main/java/darkknight/jewelrycraft/events/EntityEventHandler.java100
-rw-r--r--src/main/java/darkknight/jewelrycraft/events/EventHandler.java65
-rw-r--r--src/main/java/darkknight/jewelrycraft/item/ItemClayMolds.java72
-rw-r--r--src/main/java/darkknight/jewelrycraft/item/ItemCrystal.java58
-rw-r--r--src/main/java/darkknight/jewelrycraft/item/ItemGuide.java26
-rw-r--r--src/main/java/darkknight/jewelrycraft/item/ItemList.java73
-rw-r--r--src/main/java/darkknight/jewelrycraft/item/ItemMolds.java72
-rw-r--r--src/main/java/darkknight/jewelrycraft/item/ItemMoltenMetal.java128
-rw-r--r--src/main/java/darkknight/jewelrycraft/item/ItemMoltenMetalBucket.java309
-rw-r--r--src/main/java/darkknight/jewelrycraft/item/ItemNecklace.java272
-rw-r--r--src/main/java/darkknight/jewelrycraft/item/ItemRing.java605
-rw-r--r--src/main/java/darkknight/jewelrycraft/item/ItemThiefGloves.java113
-rw-r--r--src/main/java/darkknight/jewelrycraft/lib/Reference.java9
-rw-r--r--src/main/java/darkknight/jewelrycraft/model/ModelDisplayer.java241
-rw-r--r--src/main/java/darkknight/jewelrycraft/model/ModelJewlersCraftingBench.java140
-rw-r--r--src/main/java/darkknight/jewelrycraft/model/ModelMolder.java76
-rw-r--r--src/main/java/darkknight/jewelrycraft/model/ModelSmelter.java276
-rw-r--r--src/main/java/darkknight/jewelrycraft/recipes/CraftingRecipes.java54
-rw-r--r--src/main/java/darkknight/jewelrycraft/renders/TileEntityDisplayerRender.java235
-rw-r--r--src/main/java/darkknight/jewelrycraft/renders/TileEntityJewelrsCraftingTableRender.java165
-rw-r--r--src/main/java/darkknight/jewelrycraft/renders/TileEntityMolderRender.java123
-rw-r--r--src/main/java/darkknight/jewelrycraft/renders/TileEntitySmelterRender.java181
-rw-r--r--src/main/java/darkknight/jewelrycraft/tileentity/TileEntityAltar.java144
-rw-r--r--src/main/java/darkknight/jewelrycraft/tileentity/TileEntityBlockShadow.java74
-rw-r--r--src/main/java/darkknight/jewelrycraft/tileentity/TileEntityDisplayer.java108
-rw-r--r--src/main/java/darkknight/jewelrycraft/tileentity/TileEntityJewelrsCraftingTable.java141
-rw-r--r--src/main/java/darkknight/jewelrycraft/tileentity/TileEntityMolder.java127
-rw-r--r--src/main/java/darkknight/jewelrycraft/tileentity/TileEntitySmelter.java159
-rw-r--r--src/main/java/darkknight/jewelrycraft/util/BlockUtils.java122
-rw-r--r--src/main/java/darkknight/jewelrycraft/util/JewelryNBT.java626
-rw-r--r--src/main/java/darkknight/jewelrycraft/util/JewelrycraftUtil.java137
-rw-r--r--src/main/java/darkknight/jewelrycraft/util/PlayerUtils.java57
-rw-r--r--src/main/java/darkknight/jewelrycraft/worldGen/Generation.java48
-rw-r--r--src/main/java/darkknight/jewelrycraft/worldGen/village/ComponentJewelry.java362
-rw-r--r--src/main/java/darkknight/jewelrycraft/worldGen/village/JCTrades.java151
-rw-r--r--src/main/java/darkknight/jewelrycraft/worldGen/village/VillageJewelryHandler.java33
-rw-r--r--src/main/resources/assets/jewelrycraft/Changelog.txt83
-rw-r--r--src/main/resources/assets/jewelrycraft/lang/en_US.lang56
-rw-r--r--src/main/resources/assets/jewelrycraft/pack.mcmeta6
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/altar_bottom.pngbin391 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/altar_side.pngbin3220 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/altar_top.pngbin3125 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow0.pngbin177 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow1.pngbin315 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow10.pngbin316 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow11.pngbin316 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow12.pngbin316 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow13.pngbin316 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow14.pngbin316 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow15.pngbin288 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow2.pngbin316 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow3.pngbin316 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow4.pngbin316 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow5.pngbin316 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow6.pngbin312 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow7.pngbin316 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow8.pngbin315 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow9.pngbin316 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/displayer.pngbin3800 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/jewelrsCraftingTable.pngbin2064 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/molder.pngbin1060 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/moltenMetalFlow.pngbin10676 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/moltenMetalFlow.png.mcmeta5
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/moltenMetalStill.pngbin9922 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/moltenMetalStill.png.mcmeta45
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/oreShadow.pngbin462 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/blocks/smelter.pngbin537 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/entities/jeweler.pngbin1265 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/gui/chest_ring.pngbin1993 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/gui/guidePage.pngbin29547 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/gui/guidePageFlip.pngbin29469 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/bucketOverlay.pngbin293 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/clayIngotMold.pngbin493 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/clayNecklaceMold.pngbin584 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/clayRingMold.pngbin606 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/crystal.pngbin285 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/crystalOverlay.pngbin274 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/guide.pngbin350 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/ingot3.pngbin315 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/ingot4.pngbin308 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/ingot6.pngbin314 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/ingot7.pngbin307 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/ingotMold.pngbin500 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/ingotShadow.pngbin467 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/jewelNecklace.pngbin241 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/jewelRing.pngbin244 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/moltenMetalStill.pngbin9922 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/moltenMetalStill.png.mcmeta45
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/necklace.pngbin284 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/necklaceMold.pngbin551 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/ring.pngbin272 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/ringMold.pngbin580 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/test/ingot2.pngbin313 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/test/ingot5.pngbin301 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/items/thiefGloves.pngbin290 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/tileentities/Displayer.pngbin1232 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/tileentities/JewelrsCraftingBench.pngbin2005 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/tileentities/Molder.pngbin1020 -> 0 bytes
-rw-r--r--src/main/resources/assets/jewelrycraft/textures/tileentities/Smelter.pngbin886 -> 0 bytes
131 files changed, 0 insertions, 10070 deletions
diff --git a/src/main/java/darkknight/jewelrycraft/CommonProxy.java b/src/main/java/darkknight/jewelrycraft/CommonProxy.java
deleted file mode 100644
index 354f3a9..0000000
--- a/src/main/java/darkknight/jewelrycraft/CommonProxy.java
+++ /dev/null
@@ -1,9 +0,0 @@
-package darkknight.jewelrycraft;
-
-public class CommonProxy
-{
- public void registerRenderers()
- {
-
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/CreativeTabLiquids.java b/src/main/java/darkknight/jewelrycraft/CreativeTabLiquids.java
deleted file mode 100644
index e4329c8..0000000
--- a/src/main/java/darkknight/jewelrycraft/CreativeTabLiquids.java
+++ /dev/null
@@ -1,52 +0,0 @@
-package darkknight.jewelrycraft;
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import darkknight.jewelrycraft.item.ItemList;
-import darkknight.jewelrycraft.util.JewelryNBT;
-import darkknight.jewelrycraft.util.JewelrycraftUtil;
-
-import net.minecraft.creativetab.CreativeTabs;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.oredict.OreDictionary;
-
-public class CreativeTabLiquids extends CreativeTabs
-{
- public static ArrayList<ItemStack> metal = new ArrayList<ItemStack>();
-
- public CreativeTabLiquids(String par2Str)
- {
- super(par2Str);
- metal.add(new ItemStack(Items.gold_ingot));
- metal.add(new ItemStack(Items.iron_ingot));
- }
-
- @Override
- public Item getTabIconItem()
- {
- return ItemList.bucket;
- }
-
- @SuppressWarnings({ "rawtypes", "unchecked" })
- public void displayAllReleventItems(List par1List)
- {
- int index = 0, index2 = 0;
- while(index < OreDictionary.getOreNames().length)
- {
- Iterator<ItemStack> i = OreDictionary.getOres(OreDictionary.getOreNames()[index]).iterator();
-
- while (i.hasNext())
- {
- ItemStack nextStack = i.next();
-
- if ((nextStack.getItem().getUnlocalizedName().toLowerCase().contains("ingot") || nextStack.getItem().getUnlocalizedName().toLowerCase().contains("alloy")) && !metal.contains(nextStack)) metal.add(nextStack);
- }
- index++;
- }
- for(int i = 0; i < metal.size(); i++) par1List.add(ItemList.bucket.getModifiedItemStack(metal.get(i)));
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/CreativeTabNecklaces.java b/src/main/java/darkknight/jewelrycraft/CreativeTabNecklaces.java
deleted file mode 100644
index 524d31e..0000000
--- a/src/main/java/darkknight/jewelrycraft/CreativeTabNecklaces.java
+++ /dev/null
@@ -1,54 +0,0 @@
-package darkknight.jewelrycraft;
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import darkknight.jewelrycraft.item.ItemList;
-import darkknight.jewelrycraft.util.JewelrycraftUtil;
-
-import net.minecraft.creativetab.CreativeTabs;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.oredict.OreDictionary;
-
-public class CreativeTabNecklaces extends CreativeTabs
-{
- public static ArrayList<ItemStack> metal = new ArrayList<ItemStack>();
-
- public CreativeTabNecklaces(String par2Str)
- {
- super(par2Str);
- metal.add(new ItemStack(Items.gold_ingot));
- metal.add(new ItemStack(Items.iron_ingot));
- }
-
- @Override
- public Item getTabIconItem()
- {
- return ItemList.necklace;
- }
-
- @SuppressWarnings({ "rawtypes", "unchecked" })
- public void displayAllReleventItems(List par1List)
- {
- int index = 0, index2 = 0;
- while(index < OreDictionary.getOreNames().length)
- {
- Iterator<ItemStack> i = OreDictionary.getOres(OreDictionary.getOreNames()[index]).iterator();
-
- while (i.hasNext())
- {
- ItemStack nextStack = i.next();
-
- if ((nextStack.getItem().getUnlocalizedName().toLowerCase().contains("ingot") || nextStack.getItem().getUnlocalizedName().toLowerCase().contains("alloy")) && !metal.contains(nextStack)) metal.add(nextStack);
- }
- index++;
- }
- for(int i = 0; i < metal.size(); i++)
- for(int j = 0; j < JewelrycraftUtil.modifiers.size(); j++)
- for(int k = 0; k < JewelrycraftUtil.jewel.size(); k++)
- par1List.add(ItemList.necklace.getModifiedItemStack(metal.get(i), JewelrycraftUtil.modifiers.get(j), JewelrycraftUtil.jewel.get(k)));
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/CreativeTabRings.java b/src/main/java/darkknight/jewelrycraft/CreativeTabRings.java
deleted file mode 100644
index 5cbe496..0000000
--- a/src/main/java/darkknight/jewelrycraft/CreativeTabRings.java
+++ /dev/null
@@ -1,55 +0,0 @@
-package darkknight.jewelrycraft;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import net.minecraft.creativetab.CreativeTabs;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.oredict.OreDictionary;
-import darkknight.jewelrycraft.item.ItemList;
-import darkknight.jewelrycraft.util.JewelrycraftUtil;
-
-public class CreativeTabRings extends CreativeTabs
-{
- public static ArrayList<ItemStack> metal = new ArrayList<ItemStack>();
-
- public CreativeTabRings(String par2Str)
- {
- super(par2Str);
- metal.add(new ItemStack(Items.gold_ingot));
- metal.add(new ItemStack(Items.iron_ingot));
- }
-
- @Override
- public Item getTabIconItem()
- {
- return ItemList.ring;
- }
-
- @SuppressWarnings(
- { "rawtypes", "unchecked" })
- public void displayAllReleventItems(List par1List)
- {
- int index = 0, index2 = 0;
- while (index < OreDictionary.getOreNames().length)
- {
- Iterator<ItemStack> i = OreDictionary.getOres(OreDictionary.getOreNames()[index]).iterator();
-
- while (i.hasNext())
- {
- ItemStack nextStack = i.next();
-
- if ((nextStack.getItem().getUnlocalizedName().toLowerCase().contains("ingot") || nextStack.getItem().getUnlocalizedName().toLowerCase().contains("alloy")) && !metal.contains(nextStack)) metal.add(nextStack);
- }
- index++;
- }
- for (int i = 0; i < metal.size(); i++)
- for (int j = 0; j < JewelrycraftUtil.modifiers.size(); j++)
- for (int k = 0; k < JewelrycraftUtil.jewel.size(); k++)
- par1List.add(ItemList.ring.getModifiedItemStack(metal.get(i), JewelrycraftUtil.modifiers.get(j), JewelrycraftUtil.jewel.get(k)));
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/JewelrycraftMod.java b/src/main/java/darkknight/jewelrycraft/JewelrycraftMod.java
deleted file mode 100644
index 3ead767..0000000
--- a/src/main/java/darkknight/jewelrycraft/JewelrycraftMod.java
+++ /dev/null
@@ -1,140 +0,0 @@
-/*
- * Mod made by DarkKnight during the Modjam 3
- * It's an awesome mod
- * I love me! :D
- */
-
-package darkknight.jewelrycraft;
-
-import java.io.File;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.logging.Logger;
-
-import net.minecraft.client.Minecraft;
-import net.minecraft.creativetab.CreativeTabs;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.world.gen.structure.MapGenStructureIO;
-import net.minecraftforge.common.MinecraftForge;
-import net.minecraftforge.fluids.FluidContainerRegistry;
-import net.minecraftforge.fluids.FluidContainerRegistry.FluidContainerData;
-import net.minecraftforge.fluids.FluidStack;
-import net.minecraftforge.oredict.OreDictionary;
-import cpw.mods.fml.common.Mod;
-import cpw.mods.fml.common.Mod.EventHandler;
-import cpw.mods.fml.common.Mod.Instance;
-import cpw.mods.fml.common.Mod.Metadata;
-import cpw.mods.fml.common.ModMetadata;
-import cpw.mods.fml.common.SidedProxy;
-import cpw.mods.fml.common.event.FMLInitializationEvent;
-import cpw.mods.fml.common.event.FMLPostInitializationEvent;
-import cpw.mods.fml.common.event.FMLPreInitializationEvent;
-import cpw.mods.fml.common.registry.GameRegistry;
-import cpw.mods.fml.common.registry.VillagerRegistry;
-import darkknight.jewelrycraft.block.BlockList;
-import darkknight.jewelrycraft.config.ConfigHandler;
-import darkknight.jewelrycraft.container.GuiHandler;
-import darkknight.jewelrycraft.events.BucketHandler;
-import darkknight.jewelrycraft.events.EntityEventHandler;
-import darkknight.jewelrycraft.item.ItemList;
-import darkknight.jewelrycraft.lib.Reference;
-import darkknight.jewelrycraft.recipes.CraftingRecipes;
-import darkknight.jewelrycraft.util.JewelrycraftUtil;
-import darkknight.jewelrycraft.worldGen.Generation;
-import darkknight.jewelrycraft.worldGen.village.ComponentJewelry;
-import darkknight.jewelrycraft.worldGen.village.JCTrades;
-import darkknight.jewelrycraft.worldGen.village.VillageJewelryHandler;
-
-@Mod(modid = Reference.MODID, name = Reference.MODNAME, version = Reference.VERSION)
-public class JewelrycraftMod
-{
- @Instance(Reference.MODID)
- public static JewelrycraftMod instance;
-
- @Metadata(Reference.MODID)
- public static ModMetadata metadata;
-
- @SidedProxy(clientSide = "darkknight.jewelrycraft.client.ClientProxy", serverSide = "darkknight.jewelrycraft.CommonProxy")
- public static CommonProxy proxy;
-
- public static final Logger logger = Logger.getLogger("Jewelrycraft");
- public static File dir;
- //TODO Look at how you did in ChowTime for files
-
- public static CreativeTabs jewelrycraft = new CreativeTabs("JewelryCraft")
- {
- @Override
- public Item getTabIconItem()
- {
- return Item.getItemFromBlock(BlockList.jewelCraftingTable);
- }
- };
- public static CreativeTabs rings = new CreativeTabRings("Rings");
- public static CreativeTabs necklaces = new CreativeTabNecklaces("Necklaces");
- public static CreativeTabs liquids = new CreativeTabLiquids("Liquids");
- public static NBTTagCompound saveData = new NBTTagCompound();
- public static File liquidsConf;
-
- @EventHandler
- public void preInit(FMLPreInitializationEvent e) throws IOException
- {
- ConfigHandler.preInit(e);
- BlockList.preInit(e);
- ItemList.preInit(e);
- CraftingRecipes.preInit(e);
- OreDictionary.registerOre("ingotShadow", new ItemStack(ItemList.shadowIngot));
- OreDictionary.registerOre("ingot2", new ItemStack(ItemList.ingot2));
- OreDictionary.registerOre("ingot3", new ItemStack(ItemList.ingot3));
- OreDictionary.registerOre("ingot4", new ItemStack(ItemList.ingot4));
- OreDictionary.registerOre("ingot5", new ItemStack(ItemList.ingot5));
- OreDictionary.registerOre("ingot6", new ItemStack(ItemList.ingot6));
- OreDictionary.registerOre("ingot7", new ItemStack(ItemList.ingot7));
- OreDictionary.registerOre("oreShadow", new ItemStack(BlockList.shadowOre));
-
- VillagerRegistry.instance().registerVillagerId(3000);
- VillagerRegistry.instance().registerVillageTradeHandler(3000, new JCTrades());
- VillagerRegistry.instance().registerVillageCreationHandler(new VillageJewelryHandler());
- try
- {
- MapGenStructureIO.func_143031_a(ComponentJewelry.class, "Jewelrycraft:Jewelry");
- }
- catch (Throwable e2)
- {
- logger.severe("Error registering Jewelrycraft Structures with Vanilla Minecraft: this is expected in versions earlier than 1.7.2");
- }
- MinecraftForge.EVENT_BUS.register(new EntityEventHandler());
- MinecraftForge.EVENT_BUS.register(BucketHandler.INSTANCE);
- BucketHandler.INSTANCE.buckets.put(BlockList.moltenMetal, ItemList.bucket);
-
- proxy.registerRenderers();
- ModMetadata metadata = e.getModMetadata();
-
- List<String> authorList = new ArrayList<String>();
- authorList.add("DarkKnight (or sor1n)");
- authorList.add("bspkrs");
- dir = e.getModConfigurationDirectory();
-
- metadata.autogenerated = false;
- metadata.authorList = authorList;
- metadata.url = "https://github.com/sor1n/Modjam-Mod";
- }
-
- @EventHandler
- public void init(FMLInitializationEvent e)
- {
- GameRegistry.registerWorldGenerator(new Generation(), 0);
- new GuiHandler();
- }
-
- @EventHandler
- public void postInit(FMLPostInitializationEvent e)
- {
- JewelrycraftUtil.addMetals();
- JewelrycraftUtil.addStuff();
- JewelrycraftUtil.jamcrafters();
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/block/BlockDisplayer.java b/src/main/java/darkknight/jewelrycraft/block/BlockDisplayer.java
deleted file mode 100644
index efdddff..0000000
--- a/src/main/java/darkknight/jewelrycraft/block/BlockDisplayer.java
+++ /dev/null
@@ -1,185 +0,0 @@
-package darkknight.jewelrycraft.block;
-
-import java.util.Random;
-
-import net.minecraft.block.Block;
-import net.minecraft.block.BlockContainer;
-import net.minecraft.block.material.Material;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.MathHelper;
-import net.minecraft.world.IBlockAccess;
-import net.minecraft.world.World;
-import darkknight.jewelrycraft.tileentity.TileEntityDisplayer;
-
-public class BlockDisplayer extends BlockContainer
-{
- Random rand = new Random();
-
- protected BlockDisplayer(Material par2Material)
- {
- super(par2Material);
- }
-
- @Override
- public TileEntity createNewTileEntity(World world, int var2)
- {
- return new TileEntityDisplayer();
- }
-
- @Override
- public boolean renderAsNormalBlock()
- {
- return false;
- }
-
- @Override
- public boolean shouldSideBeRendered(IBlockAccess iblockaccess, int i, int j, int k, int l)
- {
- return false;
- }
-
- @Override
- public boolean isOpaqueCube()
- {
- return false;
- }
-
- @Override
- public int getRenderType()
- {
- return -1;
- }
-
- @Override
- public boolean onBlockActivated(World world, int i, int j, int k, EntityPlayer entityPlayer, int par6, float par7, float par8, float par9)
- {
- TileEntityDisplayer te = (TileEntityDisplayer) world.getTileEntity(i, j, k);
- ItemStack item = entityPlayer.inventory.getCurrentItem();
- if (te != null && item != null && item != new ItemStack(Item.getItemById(0), 0, 0) && !world.isRemote)
- {
- if(!te.hasObject)
- {
- te.object = item.copy();
- te.object.stackSize = 1;
- te.quantity += item.stackSize;
- te.hasObject = true;
- if (!entityPlayer.capabilities.isCreativeMode) item.stackSize = 0;
- te.isDirty = true;
- te.markDirty();
- }
- else if(te.object.getItem() == item.getItem() && te.object != null && te.object != new ItemStack(Item.getItemById(0), 0, 0) && te.object.getItemDamage() == item.getItemDamage())
- {
- if(te.object.hasTagCompound() && item.hasTagCompound() && te.object.getTagCompound().equals(item.getTagCompound()))
- {
- te.quantity += item.stackSize;
- te.object.stackSize = 1;
- if (!entityPlayer.capabilities.isCreativeMode) item.stackSize = 0;
- te.isDirty = true;
- te.markDirty();
- }
- else if(!te.object.hasTagCompound() && !item.hasTagCompound())
- {
- te.quantity += item.stackSize;
- te.object.stackSize = 1;
- if (!entityPlayer.capabilities.isCreativeMode) item.stackSize = 0;
- te.isDirty = true;
- te.markDirty();
- }
- }
- }
- return true;
- }
-
- @Override
- public void onBlockClicked(World world, int i, int j, int k, EntityPlayer player)
- {
- TileEntityDisplayer te = (TileEntityDisplayer) world.getTileEntity(i, j, k);
- if (te != null && !world.isRemote)
- {
- if (te.hasObject && te.object != null && te.object != new ItemStack(Item.getItemById(0), 0, 0) && player.inventory.addItemStackToInventory(te.object))
- {
- if(player.isSneaking())
- {
- if(te.quantity > te.object.getMaxStackSize())
- {
- te.object.stackSize = te.object.getMaxStackSize() - 1;
- player.inventory.addItemStackToInventory(te.object);
- te.object.stackSize = 1;
- te.quantity -= te.object.getMaxStackSize();
- }
- else
- {
- te.object.stackSize = te.quantity - 1;
- player.inventory.addItemStackToInventory(te.object);
- te.hasObject = false;
- te.object = new ItemStack(Item.getItemById(0), 0, 0);
- te.quantity = 0;
- }
- te.isDirty = true;
- te.markDirty();
- }
- else
- {
- if(te.quantity >= 2)
- {
- player.inventory.addItemStackToInventory(te.object);
- te.object.stackSize = 1;
- --te.quantity;
- }
- else
- {
- player.inventory.addItemStackToInventory(te.object);
- te.object.stackSize = 1;
- te.hasObject = false;
- te.object = new ItemStack(Item.getItemById(0), 0, 0);
- te.quantity = 0;
- }
- te.isDirty = true;
- te.markDirty();
- }
- }
- }
- }
-
- public void dropItem(World world, double x, double y, double z, ItemStack stack)
- {
- EntityItem entityitem = new EntityItem(world, x + 0.5D, y + 1.5D, z + 0.5D, stack);
- entityitem.motionX = 0;
- entityitem.motionZ = 0;
- entityitem.motionY = 0.11000000298023224D;
- world.spawnEntityInWorld(entityitem);
- }
-
- public void breakBlock(World world, int i, int j, int k, Block block, int par6)
- {
- TileEntityDisplayer te = (TileEntityDisplayer) world.getTileEntity(i, j, k);
-
- if (te != null && te.hasObject)
- {
- te.object.stackSize = te.quantity;
- dropItem(te.getWorldObj(), (double)te.xCoord, (double)te.yCoord, (double)te.zCoord, te.object);
- world.removeTileEntity(i, j, k);
- }
-
- super.breakBlock(world, i, j, k, block, par6);
- }
-
- @Override
- public void onBlockPlacedBy(World world, int i, int j, int k, EntityLivingBase entityLiving, ItemStack par6ItemStack)
- {
- int rotation = MathHelper.floor_double(entityLiving.rotationYaw * 4.0F / 360.0F + 0.5D) & 3;
- world.setBlockMetadataWithNotify(i, j, k, rotation, 2);
- }
-
- @Override
- public void registerBlockIcons(IIconRegister icon)
- {
- this.blockIcon = icon.registerIcon("jewelrycraft:displayer");
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/block/BlockGlow.java b/src/main/java/darkknight/jewelrycraft/block/BlockGlow.java
deleted file mode 100644
index f8a09d4..0000000
--- a/src/main/java/darkknight/jewelrycraft/block/BlockGlow.java
+++ /dev/null
@@ -1,39 +0,0 @@
-package darkknight.jewelrycraft.block;
-
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-import net.minecraft.util.AxisAlignedBB;
-import net.minecraft.world.World;
-
-public class BlockGlow extends Block
-{
- protected BlockGlow()
- {
- super(Material.air);
- }
-
- public AxisAlignedBB getCollisionBoundingBoxFromPool(World par1World, int par2, int par3, int i)
- {
- return null;
- }
-
- public boolean isCollidable()
- {
- return false;
- }
-
- public boolean isOpaqueCube()
- {
- return false;
- }
-
- public boolean renderAsNormalBlock()
- {
- return false;
- }
-
- public int getRenderType()
- {
- return -1;
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/block/BlockJCOre.java b/src/main/java/darkknight/jewelrycraft/block/BlockJCOre.java
deleted file mode 100644
index e6bb31c..0000000
--- a/src/main/java/darkknight/jewelrycraft/block/BlockJCOre.java
+++ /dev/null
@@ -1,15 +0,0 @@
-package darkknight.jewelrycraft.block;
-
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-import net.minecraft.util.AxisAlignedBB;
-import net.minecraft.world.World;
-
-public class BlockJCOre extends Block
-{
- protected BlockJCOre()
- {
- super(Material.rock);
- setHarvestLevel("pickaxe", 3);
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/block/BlockJewelAltar.java b/src/main/java/darkknight/jewelrycraft/block/BlockJewelAltar.java
deleted file mode 100644
index cbf7fef..0000000
--- a/src/main/java/darkknight/jewelrycraft/block/BlockJewelAltar.java
+++ /dev/null
@@ -1,119 +0,0 @@
-package darkknight.jewelrycraft.block;
-
-import net.minecraft.block.Block;
-import net.minecraft.block.BlockContainer;
-import net.minecraft.block.material.Material;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.IIcon;
-import net.minecraft.world.World;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import darkknight.jewelrycraft.item.ItemList;
-import darkknight.jewelrycraft.tileentity.TileEntityAltar;
-
-public class BlockJewelAltar extends BlockContainer
-{
- @SideOnly(Side.CLIENT)
- private IIcon altarSide;
- @SideOnly(Side.CLIENT)
- private IIcon altarBottom;
- @SideOnly(Side.CLIENT)
- private IIcon altarTop;
-
- public BlockJewelAltar()
- {
- super(Material.iron);
- }
-
- public static boolean isNormalCube(int par0)
- {
- return true;
- }
-
- public void registerBlockIcons(IIconRegister par1IconRegister)
- {
- this.altarSide = par1IconRegister.registerIcon(this.getTextureName() + "_" + "side");
- this.altarBottom = par1IconRegister.registerIcon(this.getTextureName() + "_" + "bottom");
- this.altarTop = par1IconRegister.registerIcon(this.getTextureName() + "_" + "top");
- }
-
- public IIcon getIcon(int par1, int par2)
- {
- return par1 == 1 ? this.altarTop : (par1 == 0 ? this.altarBottom : this.altarSide);
- }
-
- @Override
- public boolean onBlockActivated(World world, int i, int j, int k, EntityPlayer entityPlayer, int par6, float par7, float par8, float par9)
- {
- TileEntityAltar te = (TileEntityAltar) world.getTileEntity(i, j, k);
- ItemStack item = entityPlayer.inventory.getCurrentItem();
- if (te != null && !world.isRemote)
- {
- if(item != null && item != new ItemStack(Item.getItemById(0), 0, 0) && (item.getItem() == ItemList.ring || item.getItem() == ItemList.necklace) && !te.hasObject)
- {
- te.object = item.copy();
- item.stackSize = 0;
- te.playerName = entityPlayer.getDisplayName();
- te.isDirty = true;
- te.markDirty();
- te.hasObject = true;
- }
-
- if(te.object != null && te.object != new ItemStack(Item.getItemById(0), 0, 0) && te.hasObject && entityPlayer.isSneaking())
- {
- entityPlayer.inventory.addItemStackToInventory(te.object);
- te.object = new ItemStack(Item.getItemById(0), 0, 0);
- te.playerName = "";
- te.isDirty = true;
- te.markDirty();
- te.hasObject = false;
- }
- }
- return true;
- }
-
- @Override
- public void onBlockClicked(World world, int i, int j, int k, EntityPlayer player)
- {
- TileEntityAltar te = (TileEntityAltar) world.getTileEntity(i, j, k);
- if (te != null && !world.isRemote)
- {
- if (te.object != null && te.object != new ItemStack(Item.getItemById(0), 0, 0))
- {
- }
- }
- }
-
- public void dropItem(World world, double x, double y, double z, ItemStack stack)
- {
- EntityItem entityitem = new EntityItem(world, x + 0.5D, y + 1.5D, z + 0.5D, stack);
- entityitem.motionX = 0;
- entityitem.motionZ = 0;
- entityitem.motionY = 0.11000000298023224D;
- world.spawnEntityInWorld(entityitem);
- }
-
- public void breakBlock(World world, int i, int j, int k, Block block, int par6)
- {
- TileEntityAltar te = (TileEntityAltar) world.getTileEntity(i, j, k);
-
- if (te != null && te.object != null && te.object != new ItemStack(Item.getItemById(0), 0, 0))
- {
- dropItem(te.getWorldObj(), (double)te.xCoord, (double)te.yCoord, (double)te.zCoord, te.object);
- world.removeTileEntity(i, j, k);
- }
-
- super.breakBlock(world, i, j, k, block, par6);
- }
-
- @Override
- public TileEntity createNewTileEntity(World world, int var2)
- {
- return new TileEntityAltar();
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/block/BlockJewelrsCraftingTable.java b/src/main/java/darkknight/jewelrycraft/block/BlockJewelrsCraftingTable.java
deleted file mode 100644
index a701467..0000000
--- a/src/main/java/darkknight/jewelrycraft/block/BlockJewelrsCraftingTable.java
+++ /dev/null
@@ -1,222 +0,0 @@
-package darkknight.jewelrycraft.block;
-
-import java.util.Random;
-
-import net.minecraft.block.Block;
-import net.minecraft.block.BlockContainer;
-import net.minecraft.block.material.Material;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.ChatComponentText;
-import net.minecraft.util.MathHelper;
-import net.minecraft.util.StatCollector;
-import net.minecraft.world.IBlockAccess;
-import net.minecraft.world.World;
-import darkknight.jewelrycraft.config.ConfigHandler;
-import darkknight.jewelrycraft.tileentity.TileEntityJewelrsCraftingTable;
-import darkknight.jewelrycraft.util.JewelrycraftUtil;
-
-public class BlockJewelrsCraftingTable extends BlockContainer
-{
- Random rand = new Random();
-
- protected BlockJewelrsCraftingTable(Material par2Material)
- {
- super(par2Material);
- this.setBlockBounds(0.0F, 0F, 0.0F, 1.0F, 0.8F, 1.0F);
- }
-
- @Override
- public TileEntity createNewTileEntity(World world, int var2)
- {
- return new TileEntityJewelrsCraftingTable();
- }
-
- @Override
- public boolean renderAsNormalBlock()
- {
- return false;
- }
-
- @Override
- public boolean onBlockActivated(World world, int i, int j, int k, EntityPlayer entityPlayer, int par6, float par7, float par8, float par9)
- {
- TileEntityJewelrsCraftingTable te = (TileEntityJewelrsCraftingTable) world.getTileEntity(i, j, k);
- ItemStack item = entityPlayer.inventory.getCurrentItem();
- if (te != null && !world.isRemote)
- {
- if (!te.hasEndItem && !te.hasJewelry && item != null && JewelrycraftUtil.isJewelry(item))
- {
- if(te.hasModifier && te.hasJewel && item.hasTagCompound() && item.getTagCompound().hasKey("modifier") && item.getTagCompound().hasKey("jewel"))
- entityPlayer.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.table.jewelrymodifiedfull")));
- else if(te.hasJewel && item.hasTagCompound() && item.getTagCompound().hasKey("jewel"))
- entityPlayer.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.table.jewelrycontainsjewel")));
- else if(te.hasModifier && item.hasTagCompound() && item.getTagCompound().hasKey("modifier"))
- entityPlayer.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.table.jewelrycontainsmodifier")));
- else
- {
- te.jewelry = item.copy();
- te.hasJewelry = true;
- if (!entityPlayer.capabilities.isCreativeMode) --item.stackSize;
- entityPlayer.inventory.markDirty();
- world.setTileEntity(i, j, k, te);
- te.isDirty = true;
- te.markDirty();
- }
- }
- if (!te.hasEndItem && !te.hasModifier && item != null && JewelrycraftUtil.isModifier(item))
- {
- if(te.hasJewelry && te.jewelry.hasTagCompound() && te.jewelry.getTagCompound().hasKey("modifier"))
- entityPlayer.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.table.jewelrycontainsmodifier")));
- else
- {
- te.modifier = item.copy();
- te.modifier.stackSize = 1;
- te.hasModifier = true;
- if (!entityPlayer.capabilities.isCreativeMode) --item.stackSize;
- entityPlayer.inventory.markDirty();
- world.setTileEntity(i, j, k, te);
- te.isDirty = true;
- te.markDirty();
- }
- }
- if (!te.hasEndItem && !te.hasJewel && item != null && JewelrycraftUtil.isJewel(item))
- {
- if(te.hasJewelry && te.jewelry.hasTagCompound() && te.jewelry.getTagCompound().hasKey("jewel"))
- entityPlayer.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.table.jewelrycontainsjewel")));
- else
- {
- te.jewel = item.copy();
- te.jewel.stackSize = 1;
- te.hasJewel = true;
- if (!entityPlayer.capabilities.isCreativeMode) --item.stackSize;
- entityPlayer.inventory.markDirty();
- world.setTileEntity(i, j, k, te);
- te.isDirty = true;
- te.markDirty();
- }
- }
- if (te.timer <= 0 && !te.hasEndItem && te.hasJewelry && (te.hasModifier || te.hasJewel)){ te.timer = ConfigHandler.jewelryCraftingTime; te.angle = 0;}
- if (te.hasEndItem && item != null) entityPlayer.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.table.hasenditem")));
-
- if (te.hasModifier && entityPlayer.isSneaking())
- {
- dropItem(world, (double) te.xCoord, (double) te.yCoord, (double) te.zCoord, te.modifier.copy());
- te.modifier = new ItemStack(Item.getItemById(0), 0, 0);
- te.hasModifier = false;
- te.timer = 0;
- te.angle = 0F;
- te.isDirty = true;
- te.markDirty();
- world.markBlockForUpdate(i, j, k);
- world.setTileEntity(i, j, k, te);
- }
- if (te.hasJewelry && entityPlayer.isSneaking())
- {
- dropItem(world, (double) te.xCoord, (double) te.yCoord, (double) te.zCoord, te.jewelry.copy());
- te.jewelry = new ItemStack(Item.getItemById(0), 0, 0);
- te.hasJewelry = false;
- te.timer = 0;
- te.angle = 0F;
- te.isDirty = true;
- te.markDirty();
- world.markBlockForUpdate(i, j, k);
- world.setTileEntity(i, j, k, te);
- }
- if (te.hasJewel && entityPlayer.isSneaking())
- {
- dropItem(world, (double) te.xCoord, (double) te.yCoord, (double) te.zCoord, te.jewel.copy());
- te.jewel = new ItemStack(Item.getItemById(0), 0, 0);
- te.hasJewel = false;
- te.timer = 0;
- te.angle = 0F;
- te.isDirty = true;
- te.markDirty();
- world.markBlockForUpdate(i, j, k);
- world.setTileEntity(i, j, k, te);
- }
- }
- return true;
- }
-
- public void dropItem(World world, double x, double y, double z, ItemStack stack)
- {
- EntityItem entityitem = new EntityItem(world, x + 0.5D, y + 1D, z + 0.5D, stack);
- entityitem.motionX = 0;
- entityitem.motionZ = 0;
- entityitem.motionY = 0.21000000298023224D;
- world.spawnEntityInWorld(entityitem);
- }
-
- public void breakBlock(World world, int i, int j, int k, Block par5, int par6)
- {
- TileEntityJewelrsCraftingTable te = (TileEntityJewelrsCraftingTable) world.getTileEntity(i, j, k);
- if (te != null)
- {
- if (te.hasModifier) dropItem(world, (double) te.xCoord, (double) te.yCoord, (double) te.zCoord, te.modifier.copy());
- if (te.hasJewelry) dropItem(world, (double) te.xCoord, (double) te.yCoord, (double) te.zCoord, te.jewelry.copy());
- if (te.hasJewel) dropItem(world, (double) te.xCoord, (double) te.yCoord, (double) te.zCoord, te.jewel.copy());
- if (te.hasEndItem) dropItem(te.getWorldObj(), (double) te.xCoord, (double) te.yCoord, (double) te.zCoord, te.endItem.copy());
- world.removeTileEntity(i, j, k);
- }
- super.breakBlock(world, i, j, k, par5, par6);
- }
-
- @Override
- public void onBlockPlacedBy(World world, int i, int j, int k, EntityLivingBase entityLiving, ItemStack par6ItemStack)
- {
- int rotation = MathHelper.floor_double(entityLiving.rotationYaw * 4.0F / 360.0F + 0.5D) & 3;
- world.setBlockMetadataWithNotify(i, j, k, rotation, 2);
- }
-
- @Override
- public void onBlockClicked(World world, int i, int j, int k, EntityPlayer player)
- {
- TileEntityJewelrsCraftingTable te = (TileEntityJewelrsCraftingTable) world.getTileEntity(i, j, k);
- if (te != null && !world.isRemote)
- {
- if (te.hasEndItem)
- {
- dropItem(te.getWorldObj(), (double) te.xCoord, (double) te.yCoord, (double) te.zCoord, te.endItem.copy());
- te.endItem = new ItemStack(Item.getItemById(0), 0, 0);
- te.hasEndItem = false;
- te.isDirty = true;
- te.markDirty();
- world.markBlockForUpdate(i, j, k);
- world.setTileEntity(i, j, k, te);
- }
- else if (te.hasJewelry && (te.hasModifier || te.hasJewel) && te.timer > 0 && te.jewelry != null) player.addChatMessage(new ChatComponentText(StatCollector.translateToLocalFormatted("chatmessage.Jewelrycraft.table.iscrafting", te.jewelry.getDisplayName()) + " (" + ((ConfigHandler.jewelryCraftingTime - te.timer) * 100 / ConfigHandler.jewelryCraftingTime) + "%)"));
- else if ((!te.hasModifier || !te.hasJewel) && !te.hasJewelry) player.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.table.missingjewelryandmodifierorjewel")));
- else if (!te.hasJewelry) player.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.table.missingjewelry")));
- else if (!te.hasModifier || !te.hasJewel) player.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.table.missingmodifierorjewel")));
- }
- }
-
- @Override
- public boolean shouldSideBeRendered(IBlockAccess iblockaccess, int i, int j, int k, int l)
- {
- return false;
- }
-
- @Override
- public boolean isOpaqueCube()
- {
- return false;
- }
-
- @Override
- public int getRenderType()
- {
- return -1;
- }
-
- public void registerBlockIcons(IIconRegister icon)
- {
- this.blockIcon = icon.registerIcon("jewelrycraft:jewelrsCraftingTable");
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/block/BlockList.java b/src/main/java/darkknight/jewelrycraft/block/BlockList.java
deleted file mode 100644
index 60d4b96..0000000
--- a/src/main/java/darkknight/jewelrycraft/block/BlockList.java
+++ /dev/null
@@ -1,68 +0,0 @@
-package darkknight.jewelrycraft.block;
-
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-import net.minecraftforge.fluids.Fluid;
-import net.minecraftforge.fluids.FluidRegistry;
-import cpw.mods.fml.common.event.FMLPreInitializationEvent;
-import cpw.mods.fml.common.registry.GameRegistry;
-import darkknight.jewelrycraft.JewelrycraftMod;
-import darkknight.jewelrycraft.tileentity.TileEntityAltar;
-import darkknight.jewelrycraft.tileentity.TileEntityBlockShadow;
-import darkknight.jewelrycraft.tileentity.TileEntityDisplayer;
-import darkknight.jewelrycraft.tileentity.TileEntityJewelrsCraftingTable;
-import darkknight.jewelrycraft.tileentity.TileEntityMolder;
-import darkknight.jewelrycraft.tileentity.TileEntitySmelter;
-
-public class BlockList
-{
- public static Block shadowOre;
- public static Block glow;
- public static Block smelter;
- public static Block molder;
- public static Block displayer;
- public static Block jewelCraftingTable;
- public static Block shadowBlock;
- public static Block jewelAltar;
- public static BlockMoltenMetal moltenMetal;
- public static Fluid moltenMetalFluid;
-
- private static boolean isInitialized = false;
-
- public static void preInit(FMLPreInitializationEvent e)
- {
- if (!isInitialized)
- {
- shadowOre = new BlockJCOre().setHardness(3.0F).setResistance(5.0F).setStepSound(Block.soundTypeStone).setBlockTextureName("jewelrycraft:oreShadow").setBlockName("Jewelrycraft.oreShadow").setCreativeTab(JewelrycraftMod.jewelrycraft);
- glow = new BlockGlow().setBlockName("Jewelrycraft.glow").setLightLevel(1F);
- smelter = new BlockSmelter(Material.rock).setHardness(5.0F).setResistance(6.0F).setStepSound(Block.soundTypeStone).setBlockName("Jewelrycraft.smelter").setCreativeTab(JewelrycraftMod.jewelrycraft);
- molder = new BlockMolder(Material.rock).setHardness(5.0F).setResistance(6.0F).setStepSound(Block.soundTypeStone).setBlockName("Jewelrycraft.molder").setCreativeTab(JewelrycraftMod.jewelrycraft);
- displayer = new BlockDisplayer(Material.iron).setHardness(5.0F).setResistance(6.0F).setStepSound(Block.soundTypeMetal).setBlockName("Jewelrycraft.displayer").setCreativeTab(JewelrycraftMod.jewelrycraft);
- jewelCraftingTable = new BlockJewelrsCraftingTable(Material.rock).setHardness(3.0F).setResistance(5.0F).setStepSound(Block.soundTypeStone).setBlockName("Jewelrycraft.jewelCraftingTable").setCreativeTab(JewelrycraftMod.jewelrycraft);
- shadowBlock = new BlockShadow().setHardness(5.0F).setResistance(7.0F).setStepSound(Block.soundTypeMetal).setBlockTextureName("jewelrycraft:blockShadow").setBlockName("Jewelrycraft.blockShadow").setCreativeTab(JewelrycraftMod.jewelrycraft);
- jewelAltar = new BlockJewelAltar().setHardness(5.0F).setResistance(2.0F).setStepSound(Block.soundTypeMetal).setBlockTextureName("jewelrycraft:altar").setBlockName("Jewelrycraft.altar").setCreativeTab(JewelrycraftMod.jewelrycraft);
-
- GameRegistry.registerBlock(shadowOre, "shadowOre");
- GameRegistry.registerBlock(shadowBlock, "shadowBlock");
- GameRegistry.registerBlock(smelter, "Smelter");
- GameRegistry.registerBlock(molder, "Molder");
- GameRegistry.registerBlock(jewelCraftingTable, "jewelCraftingTable");
- GameRegistry.registerBlock(displayer, "Displayer");
- GameRegistry.registerBlock(jewelAltar, "Altar");
-
- GameRegistry.registerTileEntity(TileEntitySmelter.class, "30");
- GameRegistry.registerTileEntity(TileEntityMolder.class, "31");
- GameRegistry.registerTileEntity(TileEntityJewelrsCraftingTable.class, "32");
- GameRegistry.registerTileEntity(TileEntityDisplayer.class, "33");
- GameRegistry.registerTileEntity(TileEntityBlockShadow.class, "34");
- GameRegistry.registerTileEntity(TileEntityAltar.class, "35");
-
- moltenMetalFluid = new Fluid("metal.molten").setLuminosity(15).setDensity(3000).setTemperature(2000).setViscosity(6000);
- if (!FluidRegistry.registerFluid(moltenMetalFluid)) moltenMetalFluid = FluidRegistry.getFluid("metal.molten");
- moltenMetal = new BlockMoltenMetal(moltenMetalFluid, Material.lava);
- GameRegistry.registerBlock(moltenMetal, "moltenMetalLiquid");
-
- isInitialized = true;
- }
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/block/BlockMolder.java b/src/main/java/darkknight/jewelrycraft/block/BlockMolder.java
deleted file mode 100644
index 4b26044..0000000
--- a/src/main/java/darkknight/jewelrycraft/block/BlockMolder.java
+++ /dev/null
@@ -1,147 +0,0 @@
-package darkknight.jewelrycraft.block;
-
-import java.util.Random;
-
-import net.minecraft.block.Block;
-import net.minecraft.block.BlockContainer;
-import net.minecraft.block.material.Material;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.ChatComponentText;
-import net.minecraft.util.MathHelper;
-import net.minecraft.util.StatCollector;
-import net.minecraft.world.IBlockAccess;
-import net.minecraft.world.World;
-import darkknight.jewelrycraft.config.ConfigHandler;
-import darkknight.jewelrycraft.item.ItemList;
-import darkknight.jewelrycraft.tileentity.TileEntityMolder;
-
-public class BlockMolder extends BlockContainer
-{
- Random rand = new Random();
-
- protected BlockMolder(Material par2Material)
- {
- super(par2Material);
- this.setBlockBounds(0.1F, 0F, 0.1F, 0.9F, 0.2F, 0.9F);
- }
-
- @Override
- public TileEntity createNewTileEntity(World world, int var2)
- {
- return new TileEntityMolder();
- }
-
- @Override
- public boolean renderAsNormalBlock()
- {
- return false;
- }
-
- @Override
- public boolean onBlockActivated(World world, int i, int j, int k, EntityPlayer entityPlayer, int par6, float par7, float par8, float par9)
- {
- TileEntityMolder te = (TileEntityMolder) world.getTileEntity(i, j, k);
- ItemStack item = entityPlayer.inventory.getCurrentItem();
- if (te != null && !world.isRemote)
- {
- if(item != null && !te.hasMold && item.getItem() == ItemList.molds)
- {
- te.mold = item.copy();
- te.hasMold = true;
- if (!entityPlayer.capabilities.isCreativeMode) --item.stackSize;
- entityPlayer.addChatMessage(new ChatComponentText(StatCollector.translateToLocalFormatted("chatmessage.Jewelrycraft.molder.addedmold", te.mold.getDisplayName())));
- te.isDirty = true;
- }
- if (te.hasMold && entityPlayer.isSneaking() && !te.hasMoltenMetal)
- {
- dropItem(world, (double)te.xCoord, (double)te.yCoord, (double)te.zCoord, te.mold.copy());
- te.mold = new ItemStack(Item.getItemById(0), 0, 0);
- te.hasMold = false;
- te.isDirty = true;
- }
- else if(te.hasMoltenMetal) entityPlayer.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.molder.hasmoltenmetal")));
- }
- return true;
- }
-
- public void dropItem(World world, double x, double y, double z, ItemStack stack)
- {
- EntityItem entityitem = new EntityItem(world, x + 0.5D, y + 0.5D, z + 0.5D, stack);
- entityitem.motionX = 0;
- entityitem.motionZ = 0;
- entityitem.motionY = 0.11000000298023224D;
- world.spawnEntityInWorld(entityitem);
- }
-
- public void breakBlock(World world, int i, int j, int k, Block par5, int par6)
- {
- TileEntityMolder te = (TileEntityMolder) world.getTileEntity(i, j, k);
-
- if (te != null)
- {
- if(te.hasJewelBase) dropItem(te.getWorldObj(), (double)te.xCoord, (double)te.yCoord, (double)te.zCoord, te.jewelBase.copy());
- if(te.hasMold) dropItem(world, (double)te.xCoord, (double)te.yCoord, (double)te.zCoord, te.mold.copy());
- world.removeTileEntity(i, j, k);
- }
-
- super.breakBlock(world, i, j, k, par5, par6);
- }
-
- @Override
- public void onBlockPlacedBy(World world, int i, int j, int k, EntityLivingBase entityLiving, ItemStack par6ItemStack)
- {
- int rotation = MathHelper.floor_double(entityLiving.rotationYaw * 4.0F / 360.0F + 0.5D) & 3;
- world.setBlockMetadataWithNotify(i, j, k, rotation, 2);
- }
-
- @Override
- public void onBlockClicked(World world, int i, int j, int k, EntityPlayer player)
- {
- TileEntityMolder me = (TileEntityMolder) world.getTileEntity(i, j, k);
- if (me != null && !world.isRemote)
- {
- if (me.hasJewelBase)
- {
- dropItem(me.getWorldObj(), (double)me.xCoord, (double)me.yCoord, (double)me.zCoord, me.jewelBase.copy());
- me.jewelBase = new ItemStack(Item.getItemById(0), 0, 0);
- me.hasJewelBase = false;
- }
- else if (me.hasMoltenMetal && me.cooling > 0)
- player.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.molder.metaliscooling") + " (" + ((ConfigHandler.ingotCoolingTime - me.cooling)*100/ConfigHandler.ingotCoolingTime) + "%)"));
- else if (me.mold.getItem() == ItemList.molds && !me.hasMoltenMetal)
- player.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.molder.moldisempty")));
- else if (me.mold.getItem() != ItemList.molds)
- player.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.molder.moldismissing")));
- me.isDirty = true;
- }
- }
-
- @Override
- public boolean shouldSideBeRendered(IBlockAccess iblockaccess, int i, int j, int k, int l)
- {
- return false;
- }
-
- @Override
- public boolean isOpaqueCube()
- {
- return false;
- }
-
- @Override
- public int getRenderType()
- {
- return -1;
- }
-
- public void registerBlockIcons(IIconRegister icon)
- {
- this.blockIcon = icon.registerIcon("jewelrycraft:molder");
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/block/BlockMoltenMetal.java b/src/main/java/darkknight/jewelrycraft/block/BlockMoltenMetal.java
deleted file mode 100644
index 4ba57de..0000000
--- a/src/main/java/darkknight/jewelrycraft/block/BlockMoltenMetal.java
+++ /dev/null
@@ -1,275 +0,0 @@
-package darkknight.jewelrycraft.block;
-
-import java.awt.image.BufferedImage;
-import java.io.IOException;
-import java.util.Random;
-
-import javax.imageio.ImageIO;
-
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.client.resources.IResourceManager;
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IIcon;
-import net.minecraft.util.ResourceLocation;
-import net.minecraft.world.IBlockAccess;
-import net.minecraft.world.World;
-import net.minecraftforge.fluids.BlockFluidClassic;
-import net.minecraftforge.fluids.Fluid;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import darkknight.jewelrycraft.JewelrycraftMod;
-import darkknight.jewelrycraft.util.JewelryNBT;
-import darkknight.jewelrycraft.util.JewelrycraftUtil;
-
-public class BlockMoltenMetal extends BlockFluidClassic {
-
- @SideOnly(Side.CLIENT)
- protected IIcon stillIcon;
- @SideOnly(Side.CLIENT)
- protected IIcon flowingIcon;
-
- public BlockMoltenMetal(Fluid fluid, Material material) {
- super(fluid, material);
- setBlockName("Jewelrycraft.moltenMetal");
- this.setQuantaPerBlock(100);
- setLightLevel(15f);
- }
-
- @Override
- public IIcon getIcon(int side, int meta) {
- return (side == 0 || side == 1)? stillIcon : flowingIcon;
- }
-
- @SideOnly(Side.CLIENT)
- public void registerBlockIcons(IIconRegister register) {
- stillIcon = register.registerIcon("jewelrycraft:moltenMetalStill");
- flowingIcon = register.registerIcon("jewelrycraft:moltenMetalFlow");
- }
-
- @Override
- public boolean canDisplace(IBlockAccess world, int x, int y, int z) {
- if (world.getBlock(x, y, z).getMaterial().isLiquid()) return false;
- return super.canDisplace(world, x, y, z);
- }
-
- @Override
- public boolean displaceIfPossible(World world, int x, int y, int z) {
- if (world.getBlock(x, y, z).getMaterial().isLiquid()) return false;
- return super.displaceIfPossible(world, x, y, z);
- }
-
- @Override
- protected boolean canFlowInto(IBlockAccess world, int x, int y, int z)
- {
- if (world.getBlock(x, y, z).isAir(world, x, y, z)) return true;
-
- Block block = world.getBlock(x, y, z);
- if (block == this)
- {
- return false;
- }
-
- if (displacements.containsKey(block))
- {
- return displacements.get(block);
- }
-
- Material material = block.getMaterial();
- if (material.blocksMovement() ||
- material == Material.water ||
- material == Material.lava ||
- material == Material.portal)
- {
- return false;
- }
-
- int density = getDensity(world, x, y, z);
- if (density == Integer.MAX_VALUE)
- {
- return true;
- }
-
- if (this.density > density)
- {
- return true;
- }
- else
- {
- return false;
- }
- }
-
- @SideOnly(Side.CLIENT)
- public int colorMultiplier(IBlockAccess world, int i, int j, int k)
- {
- try {
- return color(world, i, j, k, false, null);
- } catch (IOException e) {
- e.printStackTrace();
- }
- return 0;
- }
-
- @Override
- public void updateTick(World world, int x, int y, int z, Random rand)
- {
- int quantaRemaining = quantaPerBlock - world.getBlockMetadata(x, y, z);
- int expQuanta = -101;
-
- // check adjacent block levels if non-source
- if (quantaRemaining < quantaPerBlock)
- {
- int y2 = y - densityDir;
-
- if ((world.getBlock(x, y2, z ) == this && JewelrycraftMod.saveData.getInteger(coords(x, y2, z)) == JewelrycraftMod.saveData.getInteger(coords(x, y, z)))||
- (world.getBlock(x - 1, y2, z ) == this && JewelrycraftMod.saveData.getInteger(coords(x - 1, y2, z)) == JewelrycraftMod.saveData.getInteger(coords(x, y, z)))||
- (world.getBlock(x + 1, y2, z ) == this && JewelrycraftMod.saveData.getInteger(coords(x + 1, y2, z)) == JewelrycraftMod.saveData.getInteger(coords(x, y, z)))||
- (world.getBlock(x, y2, z - 1) == this && JewelrycraftMod.saveData.getInteger(coords(x, y2, z - 1)) == JewelrycraftMod.saveData.getInteger(coords(x, y, z)))||
- (world.getBlock(x, y2, z + 1) == this && JewelrycraftMod.saveData.getInteger(coords(x, y2, z + 1)) == JewelrycraftMod.saveData.getInteger(coords(x, y, z))))
- {
- expQuanta = quantaPerBlock - 1;
- }
- else
- {
- int maxQuanta = -100;
- maxQuanta = getLargerQuanta(world, x - 1, y, z, maxQuanta);
- maxQuanta = getLargerQuanta(world, x + 1, y, z, maxQuanta);
- maxQuanta = getLargerQuanta(world, x, y, z - 1, maxQuanta);
- maxQuanta = getLargerQuanta(world, x, y, z + 1, maxQuanta);
-
- expQuanta = maxQuanta - 1;
- }
-
- // decay calculation
- if (expQuanta != quantaRemaining)
- {
- quantaRemaining = expQuanta;
-
- if (expQuanta <= 0)
- {
- world.setBlock(x, y, z, Blocks.air);
- }
- else
- {
- world.setBlockMetadataWithNotify(x, y, z, quantaPerBlock - expQuanta, 3);
- world.scheduleBlockUpdate(x, y, z, this, tickRate);
- world.notifyBlocksOfNeighborChange(x, y, z, this);
- }
- }
- }
- // This is a "source" block, set meta to zero, and send a server only update
- else if (quantaRemaining >= quantaPerBlock)
- {
- world.setBlockMetadataWithNotify(x, y, z, 0, 2);
- }
-
- // Flow vertically if possible
- if (canDisplace(world, x, y + densityDir, z))
- {
- JewelrycraftMod.saveData.setInteger(coords(x, y + densityDir, z), JewelrycraftMod.saveData.getInteger(coords(x, y, z)));
- flowIntoBlock(world, x, y + densityDir, z, 1);
- return;
- }
-
- // Flow outward if possible
- int flowMeta = quantaPerBlock - quantaRemaining + 1;
- if (flowMeta >= quantaPerBlock)
- {
- return;
- }
-
- if (isSourceBlock(world, x, y, z) || !isFlowingVertically(world, x, y, z))
- {
- if (world.getBlock(x, y - densityDir, z) == this)
- {
- flowMeta = 1;
- }
- boolean flowTo[] = getOptimalFlowDirections(world, x, y, z);
-
- if (flowTo[0]){
- if(JewelrycraftMod.saveData.getTag(coords(x - 1, y, z)) == null || world.getBlock(x - 1, y, z).isAir(world, x - 1, y, z))
- JewelrycraftMod.saveData.setInteger(coords(x - 1, y, z), JewelrycraftMod.saveData.getInteger(coords(x, y, z)));
- flowIntoBlock(world, x - 1, y, z, flowMeta);
- }
- if (flowTo[1]){
- if(JewelrycraftMod.saveData.getTag(coords(x + 1, y, z)) == null || world.getBlock(x + 1, y, z).isAir(world, x + 1, y, z))
- JewelrycraftMod.saveData.setInteger(coords(x + 1, y, z), JewelrycraftMod.saveData.getInteger(coords(x, y, z)));
- flowIntoBlock(world, x + 1, y, z, flowMeta);
- }
- if (flowTo[2]){
- if(JewelrycraftMod.saveData.getTag(coords(x, y, z - 1)) == null || world.getBlock(x, y, z - 1).isAir(world, x, y, z - 1))
- JewelrycraftMod.saveData.setInteger(coords(x, y, z - 1), JewelrycraftMod.saveData.getInteger(coords(x, y, z)));
- flowIntoBlock(world, x, y, z - 1, flowMeta);
- }
- if (flowTo[3]){
- if(JewelrycraftMod.saveData.getTag(coords(x, y, z + 1)) == null || world.getBlock(x, y, z + 1).isAir(world, x, y, z + 1))
- JewelrycraftMod.saveData.setInteger(coords(x, y, z + 1), JewelrycraftMod.saveData.getInteger(coords(x, y, z)));
- flowIntoBlock(world, x, y, z + 1, flowMeta);
- }
- }
- }
-
- public static int color(IBlockAccess world, int i, int j, int k, boolean forcecolor, Item itemC) throws IOException
- {
- String domain = "", texture;
- IResourceManager rm = Minecraft.getMinecraft().getResourceManager();
- BufferedImage icon;
- ItemStack item = new ItemStack(BlockList.moltenMetal);
- if(JewelrycraftMod.saveData.getInteger(String.valueOf(i) + " " + String.valueOf(j) + " " + String.valueOf(k)) > 0)
- JewelryNBT.addMetal(item, new ItemStack(Item.getItemById(JewelrycraftMod.saveData.getInteger(coords(i, j, k)))));
- if(forcecolor) JewelryNBT.addMetal(item, new ItemStack(itemC));
- int x=0, y=0, ok = 0, red, green, blue;
- if (JewelryNBT.ingot(item) != null && JewelryNBT.ingot(item).getIconIndex() != null && JewelryNBT.ingotColor(item) == 16777215)
- {
- String ingotIconName = JewelryNBT.ingot(item).getIconIndex().getIconName();
-
- if (ingotIconName.substring(0, ingotIconName.indexOf(":") + 1) != "") domain = ingotIconName.substring(0, ingotIconName.indexOf(":") + 1).replace(":", " ").trim();
- else domain = "minecraft";
-
- texture = ingotIconName.substring(ingotIconName.lastIndexOf(":") + 1) + ".png";
- ResourceLocation ingot = null;
-
- if (JewelryNBT.ingot(item).getUnlocalizedName().contains("item")) ingot = new ResourceLocation(domain, "textures/items/" + texture);
- else ingot = new ResourceLocation(domain, "textures/blocks/" + texture);
-
- icon = ImageIO.read(rm.getResource(ingot).getInputStream());
- while(ok == 0)
- {
- red = (icon.getRGB(x, y) >> 16) & 0xFF;
- green = (icon.getRGB(x, y) >> 8) & 0xFF;
- blue = icon.getRGB(x, y) & 0xFF;
- if(!isColorPretty(red, green, blue))
- {
- if(x<icon.getTileWidth()-1) x++;
- if(x>=icon.getTileWidth()-1 && y<icon.getTileWidth()-1)
- {
- x=0;
- y++;
- }
- if(x == icon.getTileWidth()-1 && y==icon.getTileWidth()-1) ok=1;
- }
- else ok=1;
- }
- JewelryNBT.addIngotColor(item, icon.getRGB(x, y));
- }
- if(JewelryNBT.ingot(item) != null) return JewelryNBT.ingotColor(item);
- return 16777215;
- }
-
- public static boolean isColorPretty(int r, int g, int b)
- {
- if((r > 80 || g > 80 || b > 80) || (r > 80 && g > 80 && b > 80 && r < 230 && b < 230 && g < 230)) return true;
- else return false;
- }
-
- public static String coords(int x, int y, int z)
- {
- return String.valueOf(x) + " " + String.valueOf(y) + " " + String.valueOf(z);
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/block/BlockShadow.java b/src/main/java/darkknight/jewelrycraft/block/BlockShadow.java
deleted file mode 100644
index acce92f..0000000
--- a/src/main/java/darkknight/jewelrycraft/block/BlockShadow.java
+++ /dev/null
@@ -1,117 +0,0 @@
-package darkknight.jewelrycraft.block;
-
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import net.minecraft.block.Block;
-import net.minecraft.block.BlockContainer;
-import net.minecraft.block.material.Material;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.init.Blocks;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.AxisAlignedBB;
-import net.minecraft.util.Facing;
-import net.minecraft.util.IIcon;
-import net.minecraft.world.IBlockAccess;
-import net.minecraft.world.World;
-import net.minecraftforge.common.util.ForgeDirection;
-import darkknight.jewelrycraft.tileentity.TileEntityBlockShadow;
-
-public class BlockShadow extends BlockContainer
-{
- private IIcon[] iconArray;
- private static final String __OBFID = "CL_00000312";
-
- public BlockShadow()
- {
- super(Material.iron);
- this.setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 1.0F, 1.0F);
- }
-
- public int getRenderBlockPass()
- {
- return 1;
- }
-
- public boolean isBeaconBase(World worldObj, int x, int y, int z, int beaconX, int beaconY, int beaconZ)
- {
- return true;
- }
-
- public boolean isOpaqueCube()
- {
- return false;
- }
-
- public boolean renderAsNormalBlock()
- {
- return false;
- }
-
- public boolean isBlockSolidOnSide(World world, int x, int y, int z, ForgeDirection side)
- {
- return false;
- }
-
- public static boolean isNormalCube(int par0)
- {
- return true;
- }
-
- @Override
- public TileEntity createNewTileEntity(World world, int var2)
- {
- return new TileEntityBlockShadow();
- }
-
- public void registerBlockIcons(IIconRegister par1IconRegister)
- {
- this.iconArray = new IIcon[16];
-
- for (int i = 0; i < this.iconArray.length; ++i)
- {
- this.iconArray[i] = par1IconRegister.registerIcon(this.getTextureName() + (15 - i));
- }
- }
-
- public AxisAlignedBB getCollisionBoundingBoxFromPool(World world, int x, int y, int z)
- {
- if(world.getBlockMetadata(x, y, z) == 15) return null;
- return super.getCollisionBoundingBoxFromPool(world, x, y, z);
- }
-
- public void setBlockBoundsBasedOnState(IBlockAccess par1IBlockAccess, int par2, int par3, int par4)
- {
- this.setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 1.0F, 1.0F);
- }
-
- public boolean shouldSideBeRendered(IBlockAccess p_149646_1_, int p_149646_2_, int p_149646_3_, int p_149646_4_, int p_149646_5_)
- {
- Block block = p_149646_1_.getBlock(p_149646_2_, p_149646_3_, p_149646_4_);
-
- if (this == BlockList.shadowBlock)
- {
- if (block == this)
- {
- return false;
- }
- }
-
- return block == this ? false : super.shouldSideBeRendered(p_149646_1_, p_149646_2_, p_149646_3_, p_149646_4_, p_149646_5_);
- }
-
- public boolean hasComparatorInputOverride()
- {
- return true;
- }
-
- public int getComparatorInputOverride(World world, int x, int y, int z, int meta)
- {
- return world.getBlockMetadata(x, y, z);
- }
-
- @SideOnly(Side.CLIENT)
- public IIcon getIcon(int side, int meta)
- {
- return this.iconArray[meta];
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/block/BlockSmelter.java b/src/main/java/darkknight/jewelrycraft/block/BlockSmelter.java
deleted file mode 100644
index c88798b..0000000
--- a/src/main/java/darkknight/jewelrycraft/block/BlockSmelter.java
+++ /dev/null
@@ -1,189 +0,0 @@
-package darkknight.jewelrycraft.block;
-
-import java.util.Random;
-
-import net.minecraft.block.Block;
-import net.minecraft.block.BlockContainer;
-import net.minecraft.block.material.Material;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.ChatComponentText;
-import net.minecraft.util.MathHelper;
-import net.minecraft.util.StatCollector;
-import net.minecraft.world.IBlockAccess;
-import net.minecraft.world.World;
-import darkknight.jewelrycraft.config.ConfigHandler;
-import darkknight.jewelrycraft.tileentity.TileEntityMolder;
-import darkknight.jewelrycraft.tileentity.TileEntitySmelter;
-import darkknight.jewelrycraft.util.JewelrycraftUtil;
-
-public class BlockSmelter extends BlockContainer
-{
- Random rand = new Random();
-
- protected BlockSmelter(Material par2Material)
- {
- super(par2Material);
- }
-
- @Override
- public TileEntity createNewTileEntity(World world, int var2)
- {
- return new TileEntitySmelter();
- }
-
- @Override
- public boolean renderAsNormalBlock()
- {
- return false;
- }
-
- public void dropItem(World world, double x, double y, double z, ItemStack stack)
- {
- EntityItem entityitem = new EntityItem(world, x + 0.5D, y + 1.3D, z + 0.5D, stack);
- entityitem.motionX = 0;
- entityitem.motionZ = 0;
- entityitem.motionY = 0.11000000298023224D;
- world.spawnEntityInWorld(entityitem);
- }
-
- public void breakBlock(World world, int i, int j, int k, Block par5, int par6)
- {
- TileEntitySmelter te = (TileEntitySmelter) world.getTileEntity(i, j, k);
- if (te != null && te.hasMetal){
- dropItem(world, (double)te.xCoord, (double)te.yCoord, (double)te.zCoord, te.metal.copy());
- world.removeTileEntity(i, j, k);
- }
- super.breakBlock(world, i, j, k, par5, par6);
- }
-
- @Override
- public boolean onBlockActivated(World world, int i, int j, int k, EntityPlayer entityPlayer, int par6, float par7, float par8, float par9)
- {
- TileEntitySmelter te = (TileEntitySmelter) world.getTileEntity(i, j, k);
- ItemStack item = entityPlayer.inventory.getCurrentItem();
- if (te != null && !world.isRemote)
- {
- int index = -1;
- for(int a = 0; a < JewelrycraftUtil.jamcraftPlayers.size(); a++) if(entityPlayer.getDisplayName().equals(JewelrycraftUtil.jamcraftPlayers.get(a))) index = a;
- if (!te.hasMetal && !te.hasMoltenMetal && !te.pouring && item != null && (item.getUnlocalizedName().toLowerCase().contains("ingot") || item.getUnlocalizedName().toLowerCase().contains("alloy") || index != -1) && !item.getUnlocalizedName().toLowerCase().contains("mold"))
- {
- entityPlayer.addChatMessage(new ChatComponentText(StatCollector.translateToLocalFormatted("chatmessage.Jewelrycraft.smelter.nowsmeltingingot", item.getDisplayName())));
- te.metal = item.copy();
- te.metal.stackSize = 1;
- te.hasMetal = true;
- te.melting = ConfigHandler.ingotMeltingTime;
- if (!entityPlayer.capabilities.isCreativeMode) --item.stackSize;
- te.isDirty = true;
- }
- else if (te.hasMetal && !te.hasMoltenMetal && item != null && item.getDisplayName().contains("Ingot") && !item.getDisplayName().contains("Mold"))
- entityPlayer.addChatMessage(new ChatComponentText(StatCollector.translateToLocalFormatted("chatmessage.Jewelrycraft.smelter.alreadyhasingot", te.metal.getDisplayName())));
- else if (te.hasMoltenMetal)
- entityPlayer.addChatMessage(new ChatComponentText(StatCollector.translateToLocalFormatted("chatmessage.Jewelrycraft.smelter.hasmolteningot", te.moltenMetal.getDisplayName())));
- else if (item != null && !item.getUnlocalizedName().toLowerCase().contains("ingot") && item.getDisplayName().contains("Ingot"))
- entityPlayer.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.smelter.itemrenamedtoingot")));
- else if (item != null && (!item.getUnlocalizedName().toLowerCase().contains("ingot") || item.getUnlocalizedName().toLowerCase().contains("mold")))
- entityPlayer.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.smelter.itemneedstobeingot")));
-
- if (te.hasMetal && entityPlayer.isSneaking())
- {
- dropItem(world, (double)te.xCoord, (double)te.yCoord, (double)te.zCoord, te.metal.copy());
- te.hasMetal = false;
- te.melting = -1;
- world.markBlockForUpdate(i, j, k);
- world.setTileEntity(i, j, k, te);
- }
- if(te != null) world.setTileEntity(i, j, k, te);
- }
- return true;
- }
-
- @Override
- public void onBlockClicked(World world, int i, int j, int k, EntityPlayer player)
- {
- TileEntitySmelter te = (TileEntitySmelter) world.getTileEntity(i, j, k);
- TileEntityMolder me = null;
- if (world.getBlockMetadata(i, j, k) == 0 && world.getTileEntity(i, j, k - 1) != null && world.getTileEntity(i, j, k - 1) instanceof TileEntityMolder)
- me = (TileEntityMolder) world.getTileEntity(i, j, k - 1);
- else if (world.getBlockMetadata(i, j, k) == 1 && world.getTileEntity(i + 1, j, k) != null && world.getTileEntity(i + 1, j, k) instanceof TileEntityMolder)
- me = (TileEntityMolder) world.getTileEntity(i + 1, j, k);
- else if (world.getBlockMetadata(i, j, k) == 2 && world.getTileEntity(i, j, k + 1) != null && world.getTileEntity(i, j, k + 1) instanceof TileEntityMolder)
- me = (TileEntityMolder) world.getTileEntity(i, j, k + 1);
- else if (world.getBlockMetadata(i, j, k) == 3 && world.getTileEntity(i - 1, j, k) != null && world.getTileEntity(i - 1, j, k) instanceof TileEntityMolder)
- me = (TileEntityMolder) world.getTileEntity(i - 1, j, k);
-
- if (te != null && me != null && !world.isRemote)
- {
- if (te.hasMoltenMetal && isConnectedToMolder(world, i, j, k) && me != null && me.hasMold && !me.hasMoltenMetal && !me.hasJewelBase)
- {
- te.pouring = true;
- te.isDirty = true;
- world.markBlockForUpdate(i, j, k);
- world.setTileEntity(i, j, k, te);
- }
- else if (te.hasMetal && te.melting > 0)
- player.addChatMessage(new ChatComponentText(StatCollector.translateToLocalFormatted("chatmessage.Jewelrycraft.smelter.metalismelting", te.metal.getDisplayName()) + " (" + ((ConfigHandler.ingotMeltingTime - te.melting)*100/ConfigHandler.ingotMeltingTime) + "%)"));
- else if (te.hasMoltenMetal && !isConnectedToMolder(world, i, j, k))
- player.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.smelter.molderismissing")));
- else if (!me.hasMold && te.hasMoltenMetal)
- player.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.smelter.molderhasnomold")));
- else if (me.hasMoltenMetal && te.hasMoltenMetal)
- player.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.smelter.molderhasmoltenmetal")));
- else if (me.hasJewelBase && te.hasMoltenMetal)
- player.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.smelter.modlerhasitem")));
- else
- player.addChatMessage(new ChatComponentText(StatCollector.translateToLocal("chatmessage.Jewelrycraft.smelter.empty")));
- }
-
- }
-
- public boolean isConnectedToMolder(World world, int i, int j, int k)
- {
- int blockMeta = world.getBlockMetadata(i, j, k);
- if (blockMeta == 0 && world.getBlock(i, j, k - 1) instanceof BlockMolder)
- return true;
- else if (blockMeta == 1 && world.getBlock(i + 1, j, k) instanceof BlockMolder)
- return true;
- else if (blockMeta == 2 && world.getBlock(i, j, k + 1) instanceof BlockMolder)
- return true;
- else if (blockMeta == 3 && world.getBlock(i - 1, j, k) instanceof BlockMolder)
- return true;
- return false;
- }
-
- @Override
- public void onBlockPlacedBy(World world, int i, int j, int k, EntityLivingBase entityLiving, ItemStack par6ItemStack)
- {
- int rotation = MathHelper.floor_double(entityLiving.rotationYaw * 4.0F / 360.0F + 0.5D) & 3;
- world.setBlockMetadataWithNotify(i, j, k, rotation, 2);
- }
-
- @Override
- public boolean shouldSideBeRendered(IBlockAccess iblockaccess, int i, int j, int k, int l)
- {
- return false;
- }
-
- @Override
- public boolean isOpaqueCube()
- {
- return false;
- }
-
- @Override
- public int getRenderType()
- {
- return -1;
- }
-
- public void registerBlockIcons(IIconRegister icon)
- {
- this.blockIcon = icon.registerIcon("jewelrycraft:smelter");
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/client/ClientProxy.java b/src/main/java/darkknight/jewelrycraft/client/ClientProxy.java
deleted file mode 100644
index e086e94..0000000
--- a/src/main/java/darkknight/jewelrycraft/client/ClientProxy.java
+++ /dev/null
@@ -1,21 +0,0 @@
-package darkknight.jewelrycraft.client;
-
-import net.minecraft.util.ResourceLocation;
-import cpw.mods.fml.client.registry.ClientRegistry;
-import cpw.mods.fml.common.registry.VillagerRegistry;
-import darkknight.jewelrycraft.CommonProxy;
-import darkknight.jewelrycraft.renders.*;
-import darkknight.jewelrycraft.tileentity.*;
-
-public class ClientProxy extends CommonProxy
-{
- @Override
- public void registerRenderers()
- {
- ClientRegistry.bindTileEntitySpecialRenderer(TileEntitySmelter.class, new TileEntitySmelterRender());
- ClientRegistry.bindTileEntitySpecialRenderer(TileEntityMolder.class, new TileEntityMolderRender());
- ClientRegistry.bindTileEntitySpecialRenderer(TileEntityJewelrsCraftingTable.class, new TileEntityJewelrsCraftingTableRender());
- ClientRegistry.bindTileEntitySpecialRenderer(TileEntityDisplayer.class, new TileEntityDisplayerRender());
- VillagerRegistry.instance().registerVillagerSkin(3000, new ResourceLocation("jewelrycraft", "textures/entities/jeweler.png"));
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/client/GuiGuide.java b/src/main/java/darkknight/jewelrycraft/client/GuiGuide.java
deleted file mode 100644
index fbf02ee..0000000
--- a/src/main/java/darkknight/jewelrycraft/client/GuiGuide.java
+++ /dev/null
@@ -1,215 +0,0 @@
-package darkknight.jewelrycraft.client;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.gui.FontRenderer;
-import net.minecraft.client.gui.inventory.GuiContainer;
-import net.minecraft.client.renderer.entity.RenderManager;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.inventory.Container;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.ResourceLocation;
-import net.minecraft.world.World;
-
-import org.lwjgl.opengl.GL11;
-
-import darkknight.jewelrycraft.block.BlockList;
-import darkknight.jewelrycraft.container.GuiRectangle;
-import darkknight.jewelrycraft.container.GuiTab;
-import darkknight.jewelrycraft.container.GuiTabBlocks;
-import darkknight.jewelrycraft.container.GuiTabItems;
-import darkknight.jewelrycraft.container.GuiTabJewelsAndModifiers;
-import darkknight.jewelrycraft.container.GuiTabNecklaces;
-import darkknight.jewelrycraft.container.GuiTabRings;
-
-public class GuiGuide extends GuiContainer
-{
- public int page, rot, del;
- public boolean prevHover, nextHover;
- World world;
- private final GuiTab[] tabs;
- private GuiTab activeTab;
-
- public GuiGuide(Container container, World world)
- {
- super(container);
- page = 1;
- rot = 0;
- del = 0;
- this.world = world;
-
- tabs = new GuiTab[] {
- new GuiTabBlocks(0),
- new GuiTabItems(1),
- new GuiTabJewelsAndModifiers(2),
- new GuiTabRings(3),
- new GuiTabNecklaces(4)
- };
-
- activeTab = tabs[0];
- }
-
- @Override
- protected void drawGuiContainerBackgroundLayer(float f, int i, int j)
- {
- nextHover = false;
- prevHover = false;
- if(del == 0) rot++;
- del++;
- if(del >= 2) del = 0;
- Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation("jewelrycraft", "textures/gui/guidePage.png"));
- drawTexturedModalRect(guiLeft + 147/2 + 20, guiTop - 10, 0, 0, 145, 180);
- Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation("jewelrycraft", "textures/gui/guidePageFlip.png"));
- drawTexturedModalRect(guiLeft - 147/2 + 21, guiTop - 10, 0, 0, 145, 180);
-
- for (GuiRectangle tab : tabs) {
- int srcX = 24;
- int sizeX = 19;
-
- if (tab == activeTab) {
- srcX += 38;
- sizeX +=3;
- }else if(tab.inRect(this, i, j)) {
- srcX += 19;
- }
-
- tab.draw(this, srcX, 180, sizeX, 18);
- }
-
- if(i >= guiLeft + 195 + 20 && i <= guiLeft + 195 + 20 + 11 && j >= guiTop + 127 + 20 && j <= guiTop + 127 + 20 + 14 && page + 2 <= activeTab.getMaxPages())
- {
- drawTexturedModalRect(guiLeft + 195 + 20, guiTop + 127 + 20, 0, 180, 11, 14);
- nextHover = true;
- }
-
- if(i >= guiLeft + 20 - 61 && i <= guiLeft - 61 + 20 + 11 && j >= guiTop + 127 + 20 && j <= guiTop + 127 + 20 + 14 && page - 2 > 0)
- {
- drawTexturedModalRect(guiLeft - 61 + 20, guiTop + 127 + 20, 11, 180, 11, 14);
- prevHover = true;
- }
-
- activeTab.drawBackground(this, i, j, page);
- activeTab.drawBackground(this, i, j, page + 1);
-
- ArrayList<String> text = new ArrayList<String>();
- text.add(Integer.toString(page));
- this.drawHoveringText(text, guiLeft - 10 + 20 - text.get(0).length(), guiTop + 150 + 20, fontRendererObj);
- text.remove(Integer.toString(page));
- text.add(Integer.toString(page + 1));
- this.drawHoveringText(text, guiLeft - 10 + 20 + 147 - text.get(0).length(), guiTop + 150 + 20, fontRendererObj);
-
- for(int tab = 0; tab < tabs.length; tab++)
- renderItem(tabs[tab].getIcon(), guiLeft - 52, guiTop + 26 + tab*19, activeTab.getIcon());
-
- }
-
- protected void drawGuiContainerForegroundLayer(int x, int y)
- {
- activeTab.drawForeground(this, x, y, page);
- activeTab.drawForeground(this, x, y, page + 1);
-
- for (GuiTab tab : tabs) {
- tab.drawString(this, x, y, tab.getName());
- }
- }
-
- @Override
- protected void mouseClicked(int x, int y, int button)
- {
- if(nextHover && page+2 <= activeTab.getMaxPages()) page+=2;
- else if (prevHover && page > 1) page-=2;
-
- activeTab.mouseClick(this, x, y, button);
-
- for (GuiTab tab : tabs) {
- if (activeTab != tab) {
- if (tab.inRect(this, x, y)) {
- activeTab = tab;
- page = 1;
- break;
- }
- }
- }
- }
-
- public void renderItem(ItemStack item, float x, float y, ItemStack activeIcon)
- {
- GL11.glPushMatrix();
- GL11.glDisable(GL11.GL_LIGHTING);
- EntityItem entityitem = new EntityItem(world, 0.0D, 0.0D, 0.0D, item);
- entityitem.hoverStart = 0.0F;
- if(item.isItemEqual(new ItemStack(BlockList.jewelAltar)))
- {
- y-=4;
- }
- GL11.glTranslatef(x, y, 100);
-
- float scale = 30F;
- GL11.glScalef(-scale, scale, scale);
-
- if(activeIcon != null && item.isItemEqual(activeIcon)) GL11.glRotatef(rot, 0, 1, 0);
- if(item.isItemEqual(new ItemStack(BlockList.jewelAltar)))
- {
- GL11.glRotatef(160.0F, 1.0F, 0.0F, 0.0F);
- GL11.glRotatef(45.0F, 0.0F, 1.0F, 0.0F);
- }
- else GL11.glRotatef(180.0F, 0.0F, 0.0F, 1.0F);
-
- if(RenderManager.instance.options.fancyGraphics)
- RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- else
- {
- GL11.glRotatef(180F, 0F, 1F, 0F);
- RenderManager.instance.options.fancyGraphics = true;
- RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- RenderManager.instance.options.fancyGraphics = false;
- }
- GL11.glEnable(GL11.GL_LIGHTING);
- GL11.glPopMatrix();
-
- }
-
- public void renderItem(ItemStack item, float x, float y, float scale)
- {
- GL11.glPushMatrix();
- EntityItem entityitem = new EntityItem(world, 0.0D, 0.0D, 0.0D, item);
- entityitem.hoverStart = 0.0F;
- GL11.glTranslatef(x, y, 100);
- GL11.glScalef(-scale, scale, scale);
- GL11.glRotatef(160.0F, 1.0F, 0.0F, 0.0F);
- GL11.glRotatef(45.0F, 0.0F, 1.0F, 0.0F);
- GL11.glRotatef(rot, 0.0F, 1.0F, 0.0F);
- if(RenderManager.instance.options.fancyGraphics)
- RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- else
- {
- RenderManager.instance.options.fancyGraphics = true;
- RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- RenderManager.instance.options.fancyGraphics = false;
- }
- GL11.glPopMatrix();
- }
-
- public int getLeft()
- {
- return guiLeft;
- }
-
- public int getTop()
- {
- return guiTop;
- }
-
- public FontRenderer getFont()
- {
- return fontRendererObj;
- }
-
- @SuppressWarnings("rawtypes")
- public void drawHoverString(List lst, int x, int y)
- {
- drawHoveringText(lst, x, y, fontRendererObj);
- }
-} \ No newline at end of file
diff --git a/src/main/java/darkknight/jewelrycraft/client/GuiRingChest.java b/src/main/java/darkknight/jewelrycraft/client/GuiRingChest.java
deleted file mode 100644
index f711558..0000000
--- a/src/main/java/darkknight/jewelrycraft/client/GuiRingChest.java
+++ /dev/null
@@ -1,39 +0,0 @@
-package darkknight.jewelrycraft.client;
-
-import org.lwjgl.opengl.GL11;
-
-import darkknight.jewelrycraft.container.ContainerRingChest;
-
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.gui.inventory.GuiContainer;
-import net.minecraft.util.ResourceLocation;
-
-public class GuiRingChest extends GuiContainer
-{
- public ContainerRingChest container;
-
- public GuiRingChest(ContainerRingChest container)
- {
- super(container);
- this.container = container;
- xSize = 176;
- ySize = 166;
- }
-
- @Override
- public void drawGuiContainerBackgroundLayer(float f, int mouseX, int mouseY)
- {
- GL11.glColor3f(1, 1, 1);
-
- Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation("jewelrycraft", "textures/gui/chest_ring.png"));
-
- drawTexturedModalRect(guiLeft, guiTop, 0, 0, xSize, ySize);
- }
-
- @Override
- public void drawGuiContainerForegroundLayer(int mouseX, int mouseY)
- {
- fontRendererObj.drawString("Linked Chest", 8, 6, 0x404040);
- fontRendererObj.drawString("Inventory", 8, 72, 0x404040);
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/config/ConfigHandler.java b/src/main/java/darkknight/jewelrycraft/config/ConfigHandler.java
deleted file mode 100644
index 4bfd893..0000000
--- a/src/main/java/darkknight/jewelrycraft/config/ConfigHandler.java
+++ /dev/null
@@ -1,57 +0,0 @@
-package darkknight.jewelrycraft.config;
-
-import net.minecraftforge.common.config.Configuration;
-import cpw.mods.fml.common.event.FMLPreInitializationEvent;
-
-public class ConfigHandler
-{
- private static Configuration config;
- public static int ingotCoolingTime = 200;
- public static int ingotMeltingTime = 1500;
- public static int jewelryCraftingTime = 2000;
-
- private static boolean isInitialized = false;
- public static boolean generateVillageNetherstar = false;
- public static boolean canFurnacesGenerateIngots = true;
- public static int maxVillageJewelers = 1;
- public static int jewelerWeight = 30;
- public static int ingotChestMin = 1;
- public static int ingotChestMax = 4;
- public static int ingotChestMaxStack = 2;
- public static int jewelsChestMin = 2;
- public static int jewelsChestMax = 5;
- public static int furnacesIngotStackMin = 2;
- public static int furnacesIngotStackMax = 5;
-
- public static void preInit(FMLPreInitializationEvent e)
- {
- if (!isInitialized)
- {
- config = new Configuration(e.getSuggestedConfigurationFile());
-
- config.load();
-
- ingotCoolingTime = config.get("Timers", "Molder Ingot Cooling Time", ingotCoolingTime, "This sets the number of ticks you need to wait before the mold is cooled.").getInt();
- ingotMeltingTime = config.get("Timers", "Ingot Melting Time", ingotMeltingTime, "This sets the number of ticks you need to wait before an ingot is completely smelted.").getInt();
- jewelryCraftingTime = config.get("Timers", "Jewelry Crafting Time", jewelryCraftingTime, "This sets the number of ticks it takes for a jewel to be modified.").getInt();
-
- generateVillageNetherstar = config.get("Village Generation", "Netherstar Generation", generateVillageNetherstar, "If set to true Nether Stars will be able to generate in Jewelers chests.").getBoolean(generateVillageNetherstar);
- canFurnacesGenerateIngots = config.get("Village Generation", "Furnace Ingots Generation", canFurnacesGenerateIngots, "If set to true jewelers will generate ingots in furnaces.").getBoolean(canFurnacesGenerateIngots);
-
- maxVillageJewelers = config.get("Village Generation", "Maximum Jewelers", maxVillageJewelers, "Sets how many jewelers can be in a village.").getInt();
- jewelerWeight = config.get("Village Generation", "Jewelers Weight", jewelerWeight, "Chance of getting a jeweler in a village. The higher the value, the higher the chance.").getInt();
-
- ingotChestMin = config.get("Village Generation", "Ingot Chest Min", ingotChestMin, "Minimum number of ingots that can be found in a chest from the Jeweler. (It's the chest from the back part)").getInt();
- ingotChestMax = config.get("Village Generation", "Ingot Chest Max", ingotChestMax, "Maximum number of ingots that can be found in a chest from the Jeweler. (It's the chest from the back part)").getInt();
- ingotChestMaxStack = config.get("Village Generation", "Ingot Chest Max Stack", ingotChestMaxStack, "Maximum number of the stack the ingots can be. For example: if set to 2 and ingots have a chance of generating, you have a chance of getting a stack of max 2 ingots in a chest.").getInt();
- jewelsChestMin = config.get("Village Generation", "Jewelers Chest Min", jewelsChestMin, "Determines the minimum nuber of jewels/modifiers that can be generated in the front chests of a Jeweler.").getInt();
- jewelsChestMax = config.get("Village Generation", "Jewelers Chest Max", jewelsChestMax, "Determines the maximum nuber of jewels/modifiers that can be generated in the front chests of a Jeweler.").getInt();
- furnacesIngotStackMin = config.get("Village Generation", "Ingot Furnace Min", furnacesIngotStackMin, "Determines the minimum number of ingots that can generate in a furnace.").getInt();
- furnacesIngotStackMax = config.get("Village Generation", "Ingot Furnace Max", furnacesIngotStackMax, "Determines the maximum number of ingots that can generate in a furnace.").getInt();
-
- config.save();
-
- isInitialized = true;
- }
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/container/ContainerGuide.java b/src/main/java/darkknight/jewelrycraft/container/ContainerGuide.java
deleted file mode 100644
index ef05cc4..0000000
--- a/src/main/java/darkknight/jewelrycraft/container/ContainerGuide.java
+++ /dev/null
@@ -1,18 +0,0 @@
-package darkknight.jewelrycraft.container;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.inventory.Container;
-
-/**
- * User: joel / Date: 16.12.13 / Time: 22:36
- */
-public class ContainerGuide extends Container {
-
- public ContainerGuide() {
- }
-
- @Override
- public boolean canInteractWith(EntityPlayer entityplayer) {
- return true;
- }
-} \ No newline at end of file
diff --git a/src/main/java/darkknight/jewelrycraft/container/ContainerRingChest.java b/src/main/java/darkknight/jewelrycraft/container/ContainerRingChest.java
deleted file mode 100644
index 2728941..0000000
--- a/src/main/java/darkknight/jewelrycraft/container/ContainerRingChest.java
+++ /dev/null
@@ -1,71 +0,0 @@
-package darkknight.jewelrycraft.container;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.InventoryPlayer;
-import net.minecraft.inventory.Container;
-import net.minecraft.inventory.Slot;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntityChest;
-
-public class ContainerRingChest extends Container
-{
- public TileEntityChest theChest;
-
- public ContainerRingChest(InventoryPlayer inv, TileEntityChest chest)
- {
- theChest = chest;
-
- int x, y;
-
- for (x = 0; x < 9; x++)
- addSlotToContainer(new SlotRingChest(inv, x, 8 + (18 * x), 142, x == inv.currentItem));
- for (y = 0; y < 3; y++)
- for (x = 0; x < 9; x++)
- addSlotToContainer(new Slot(inv, x + 9 + (y * 9), 8 + (18 * x), 84 + (y * 18)));
-
- for (y = 0; y < 3; y++)
- for (x = 0; x < 9; x++)
- addSlotToContainer(new SlotRingChest(chest, 26 - (x + (y * 9)), 8 + (18 * (8 - x)), 17 + ((2 - y) * 18), false));
- }
- @Override
- public boolean canInteractWith(EntityPlayer player)
- {
- return true;
- }
-
- @Override
- public ItemStack transferStackInSlot(EntityPlayer par1EntityPlayer, int par2)
- {
- ItemStack itemstack = null;
- Slot slot = (Slot)this.inventorySlots.get(par2);
-
- if (slot != null && slot.getHasStack())
- {
- ItemStack itemstack1 = slot.getStack();
- itemstack = itemstack1.copy();
-
- if (par2 < 27)
- {
- if (!this.mergeItemStack(itemstack1, 27, this.inventorySlots.size(), true))
- {
- return null;
- }
- }
- else if (!this.mergeItemStack(itemstack1, 0, 27, false))
- {
- return null;
- }
-
- if (itemstack1.stackSize == 0)
- {
- slot.putStack((ItemStack)null);
- }
- else
- {
- slot.onSlotChanged();
- }
- }
-
- return itemstack;
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/container/GuiHandler.java b/src/main/java/darkknight/jewelrycraft/container/GuiHandler.java
deleted file mode 100644
index 3efe71c..0000000
--- a/src/main/java/darkknight/jewelrycraft/container/GuiHandler.java
+++ /dev/null
@@ -1,40 +0,0 @@
-package darkknight.jewelrycraft.container;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.tileentity.TileEntityChest;
-import net.minecraft.world.World;
-import cpw.mods.fml.common.network.IGuiHandler;
-import cpw.mods.fml.common.network.NetworkRegistry;
-import darkknight.jewelrycraft.JewelrycraftMod;
-import darkknight.jewelrycraft.client.GuiGuide;
-import darkknight.jewelrycraft.client.GuiRingChest;
-
-public class GuiHandler implements IGuiHandler
-{
- public GuiHandler()
- {
- NetworkRegistry.INSTANCE.registerGuiHandler(JewelrycraftMod.instance, this);
- }
-
- @Override
- public Object getServerGuiElement(int ID, EntityPlayer player, World world, int x, int y, int z)
- {
- switch(ID)
- {
- case 0: return new ContainerRingChest(player.inventory, (TileEntityChest) world.getTileEntity(x, y, z));
- case 1: return new ContainerGuide();
- default: return null;
- }
- }
-
- @Override
- public Object getClientGuiElement(int ID, EntityPlayer player, World world, int x, int y, int z)
- {
- switch(ID)
- {
- case 0: return new GuiRingChest((ContainerRingChest) getServerGuiElement(ID, player, world, x, y, z));
- case 1: return new GuiGuide((ContainerGuide) getServerGuiElement(ID, player, world, x, y, z), world);
- default: return null;
- }
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/container/GuiRectangle.java b/src/main/java/darkknight/jewelrycraft/container/GuiRectangle.java
deleted file mode 100644
index 76dee04..0000000
--- a/src/main/java/darkknight/jewelrycraft/container/GuiRectangle.java
+++ /dev/null
@@ -1,66 +0,0 @@
-package darkknight.jewelrycraft.container;
-
-import java.util.Arrays;
-
-import net.minecraft.item.ItemStack;
-
-import darkknight.jewelrycraft.client.GuiGuide;
-
-public class GuiRectangle
-{
-
- private int x;
- private int y;
- private int w;
- private int h;
-
- public GuiRectangle(int x, int y, int w, int h)
- {
- this.x = x;
- this.y = y;
- this.w = w;
- this.h = h;
- }
-
- public boolean inRect(GuiGuide gui, int mouseX, int mouseY)
- {
- mouseX -= gui.getLeft();
- mouseY -= gui.getTop();
-
- return x <= mouseX && mouseX <= x + w && y <= mouseY && mouseY <= y + h;
- }
-
- public void setX(int x)
- {
- this.x = x;
- }
-
- public void setY(int y)
- {
- this.y = y;
- }
-
-
- public void draw(GuiGuide gui, int srcX, int srcY)
- {
- gui.drawTexturedModalRect(gui.getLeft() + x, gui.getTop() + y, srcX, srcY, w, h);
- }
-
-
- public void draw(GuiGuide gui, int srcX, int srcY, int width, int height)
- {
- gui.drawTexturedModalRect(gui.getLeft() + x, gui.getTop() + y, srcX, srcY, width, height);
- }
-
- public void drawString(GuiGuide gui, int mouseX, int mouseY, String str)
- {
- if (inRect(gui, mouseX, mouseY)) {
- gui.drawHoverString(Arrays.asList(str.split("\n")), mouseX - gui.getLeft(), mouseY - gui.getTop());
- }
- }
-
- public ItemStack getIcon()
- {
- return null;
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/container/GuiTab.java b/src/main/java/darkknight/jewelrycraft/container/GuiTab.java
deleted file mode 100644
index c092ba6..0000000
--- a/src/main/java/darkknight/jewelrycraft/container/GuiTab.java
+++ /dev/null
@@ -1,37 +0,0 @@
-package darkknight.jewelrycraft.container;
-
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import darkknight.jewelrycraft.client.GuiGuide;
-
-@SideOnly(Side.CLIENT)
-public abstract class GuiTab extends GuiRectangle
-{
- int values, del;
- private String name;
-
- public GuiTab(String name, int id)
- {
- super(-62, 10 + 19*id, 19, 18);
- this.name = name;
- values = 0;
- del = 0;
- }
-
- public String getName()
- {
- return name;
- }
-
- public abstract void drawBackground(GuiGuide gui, int x, int y, int page);
- public abstract void drawForeground(GuiGuide gui, int x, int y, int page);
- public void mouseClick(GuiGuide gui, int x, int y, int button) {}
- public void mouseMoveClick(GuiGuide gui, int x, int y, int button, long timeSinceClicked) {}
- public void mouseReleased(GuiGuide gui, int x, int y, int button) {}
-
- public int getMaxPages()
- {
- return 1;
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/container/GuiTabBlocks.java b/src/main/java/darkknight/jewelrycraft/container/GuiTabBlocks.java
deleted file mode 100644
index 9627cf1..0000000
--- a/src/main/java/darkknight/jewelrycraft/container/GuiTabBlocks.java
+++ /dev/null
@@ -1,295 +0,0 @@
-package darkknight.jewelrycraft.container;
-
-import java.util.ArrayList;
-
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.EnumChatFormatting;
-import darkknight.jewelrycraft.block.BlockList;
-import darkknight.jewelrycraft.client.GuiGuide;
-import darkknight.jewelrycraft.item.ItemList;
-
-public class GuiTabBlocks extends GuiTab
-{
-
- public GuiTabBlocks(int id)
- {
- super("Blocks", id);
- }
-
- public ItemStack getIcon()
- {
- return new ItemStack(BlockList.jewelAltar);
- }
-
- @Override
- public void drawBackground(GuiGuide gui, int x, int y, int page)
- {
- ArrayList<String> text = new ArrayList<String>();
- ArrayList<ItemStack> items = new ArrayList<ItemStack>();
- int xPos = (page%2==0)?107:-35;
- switch(page)
- {
- case 1:
- text.add(" This ore is extremely");
- text.add("rare and can be found");
- text.add("only between Y level 5");
- text.add("and 8. It can only be");
- text.add("mined using a diamond");
- text.add("pickaxe.");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), new ItemStack(BlockList.shadowOre), text, 90f);
- break;
- case 2:
- text.add(" The Shadow Block is");
- text.add("crafted using 9 shadow");
- text.add("ingots. It has been");
- text.add("discovered that it");
- text.add("poseses abnormal");
- text.add("properties in the");
- text.add("shadow. The darker it");
- items.add(new ItemStack(BlockList.shadowBlock));
- for(int i = 1; i <= 9; i++) items.add(new ItemStack(ItemList.shadowIngot));
- Page.addCraftingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop(), false, text, items, x, y);
- break;
- case 3:
- text.add("is, the more");
- text.add("transparent it will be,");
- text.add("until it becomes");
- text.add("walkable through. If a");
- text.add("comparator is attached");
- text.add("to it, the output");
- text.add("strength will be equal");
- text.add("to the value of");
- text.add("darkness it is in.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 4:
- text.add(" The smelter is one of");
- text.add("the first blocks needed");
- text.add("to get started with");
- text.add("Jewelrycraft. Requiring");
- text.add("just some cobble and");
- text.add("a couple buckets, it's");
- text.add("the most important");
- items.add(new ItemStack(BlockList.smelter));
- items.add(new ItemStack(Blocks.cobblestone));
- items.add(new ItemStack(Items.bucket));
- items.add(new ItemStack(Blocks.cobblestone));
- items.add(new ItemStack(Blocks.cobblestone));
- items.add(null);
- items.add(new ItemStack(Blocks.cobblestone));
- items.add(new ItemStack(Blocks.cobblestone));
- items.add(new ItemStack(Items.lava_bucket));
- items.add(new ItemStack(Blocks.cobblestone));
- Page.addCraftingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop(), false, text, items, x, y);
- break;
- case 5:
- text.add("block as it can melt");
- text.add("ingots which can be");
- text.add("made into pieces of");
- text.add("jewellery, like rings");
- text.add("or necklaces. To use");
- text.add("the block all you need");
- text.add("to do is right click");
- text.add("on it with any ingot.");
- text.add("If left clicked while");
- text.add("smelting, a message");
- text.add("will appear saying the");
- text.add("percentage it is done.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 6:
- text.add("If left clicked when");
- text.add("it's done smelting,");
- text.add("a message will be");
- text.add("displayed, mentioning");
- text.add("the contents of the");
- text.add("block.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 7:
- text.add(" The molder is a key");
- text.add("piece in creating");
- text.add("jewellery. You need");
- text.add("to pour the molten");
- text.add("metal out of the");
- text.add("smelter somewhere.");
- text.add("That somewhere is the");
-
- items.add(new ItemStack(BlockList.molder));
- items.add(new ItemStack(Blocks.cobblestone));
- items.add(null);
- items.add(new ItemStack(Blocks.cobblestone));
- for(int i = 1; i <= 3; i++) items.add(new ItemStack(Blocks.cobblestone));
- Page.addCraftingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop(), false, text, items, x, y);
- break;
- case 8:
- text.add("molder. But before");
- text.add("pouring the molten");
- text.add("metal in it, you must");
- text.add("first add a mold.");
- text.add("You can do that by");
- text.add("simply right clicking");
- text.add("the block with the");
- text.add("mold of your choice.");
- text.add("If you want to get the");
- text.add("mold out, simply crouch");
- text.add("and right click it with");
- text.add("an empty hand.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 9:
- text.add(" Once you have a mold");
- text.add("inside, left click on");
- text.add("the smelter and wait");
- text.add("for the metal to cool");
- text.add("down. When it's done,");
- text.add("left click on the");
- text.add("molder to get the");
- text.add("jewellery. " + EnumChatFormatting.DARK_RED + "Be aware");
- text.add(EnumChatFormatting.DARK_RED + "that this block must be");
- text.add(EnumChatFormatting.DARK_RED + "placed directly in front");
- text.add(EnumChatFormatting.DARK_RED + "of the smelter,");
- text.add(EnumChatFormatting.DARK_RED + "otherwise it won't work!");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 10:
- text.add(" Your jewellery on");
- text.add("their own don't do");
- text.add("much. They need to be");
- text.add("modified a bit and the");
- text.add("only way to do that is");
- text.add("by using this block.");
- text.add("Simply right click the");
- if(del == 0) values++;
- del++;
- if(del >= 300) del = 0;
- if(values >= 4) values = 0;
- items.add(new ItemStack(BlockList.jewelCraftingTable));
- for(int i = 1; i <= 3; i++)items.add(new ItemStack(Blocks.planks, 1, values));
- items.add(new ItemStack(Blocks.cobblestone));
- items.add(null);
- items.add(new ItemStack(Blocks.cobblestone));
- items.add(new ItemStack(Blocks.cobblestone));
- items.add(null);
- items.add(new ItemStack(Blocks.cobblestone));
- Page.addCraftingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop(), false, text, items, x, y);
- break;
- case 11:
- text.add("block while holding the");
- text.add("jewellery to place it in.");
- text.add("After that just add in");
- text.add("a jewel or a modifier,");
- text.add("or even both, to the");
- text.add("block. To do that simply");
- text.add("right click with them on");
- text.add("the block. Once it's");
- text.add("done modifying, left");
- text.add("click on it to retrieve");
- text.add("the modified item. If");
- text.add("you wish to know how");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 12:
- text.add("much is left before the");
- text.add("transformation is done,");
- text.add("simply left click on the");
- text.add("table in the process.");
- text.add(" A list with all the");
- text.add("possible modifiers is");
- text.add("located in a separate");
- text.add("tab.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 13:
- text.add(" This block can store");
- text.add("any jewellery in it");
- text.add("and activate their");
- text.add("effects as it were a");
- text.add("player. However, it");
- text.add("does not work with");
- text.add("everything. You can");
- items.add(new ItemStack(BlockList.jewelAltar));
- items.add(new ItemStack(Blocks.end_stone));
- items.add(new ItemStack(Blocks.wool, 1, 5));
- items.add(new ItemStack(Blocks.end_stone));
- items.add(new ItemStack(Blocks.nether_brick));
- items.add(new ItemStack(Blocks.wool, 1, 5));
- items.add(new ItemStack(Blocks.nether_brick));
- items.add(new ItemStack(Blocks.nether_brick));
- items.add(new ItemStack(Blocks.nether_brick));
- items.add(new ItemStack(Blocks.nether_brick));
- Page.addCraftingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop(), false, text, items, x, y);
- break;
- case 14:
- text.add("find out which jewellery");
- text.add("works by looking in");
- text.add("their apropriate tab.");
- text.add(" Each item will have a");
- text.add("note where it is");
- text.add("mentioned their effect");
- text.add("when placed in this");
- text.add("block.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 15:
- text.add(" The Storage");
- text.add("Displayer, as the");
- text.add("name suggests, can");
- text.add("store a large amount");
- text.add("of a single item/block");
- text.add("placed in it. This will");
- text.add("display all possible");
- items.add(new ItemStack(BlockList.displayer));
- items.add(null);
- items.add(new ItemStack(Items.iron_ingot));
- items.add(null);
- items.add(new ItemStack(Items.iron_ingot));
- items.add(new ItemStack(Items.iron_ingot));
- items.add(new ItemStack(Items.iron_ingot));
- items.add(new ItemStack(Blocks.emerald_block));
- items.add(new ItemStack(Blocks.emerald_block));
- items.add(new ItemStack(Blocks.emerald_block));
- Page.addCraftingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop(), false, text, items, x, y);
- break;
- case 16:
- text.add("infromation about the");
- text.add("object in it, such as");
- text.add("the name, durability,");
- text.add("enchantments and many");
- text.add("more. Below the name");
- text.add("is shown the amount");
- text.add("stored. To store");
- text.add("something in it simply");
- text.add("right click with that");
- text.add("object on it and the");
- text.add("whole amount of items");
- text.add("or blocks will be");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 17:
- text.add("immediately stored");
- text.add("inside. To retrieve");
- text.add("a single item just");
- text.add("left click the block.");
- text.add("If you wish to get");
- text.add("a whole stack, just");
- text.add("crouch and left click.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- default:;
- }
- }
-
- public int getMaxPages()
- {
- return 17;
- }
-
- @Override
- public void drawForeground(GuiGuide gui, int x, int y, int page)
- {
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/container/GuiTabItems.java b/src/main/java/darkknight/jewelrycraft/container/GuiTabItems.java
deleted file mode 100644
index a4ea44e..0000000
--- a/src/main/java/darkknight/jewelrycraft/container/GuiTabItems.java
+++ /dev/null
@@ -1,278 +0,0 @@
-package darkknight.jewelrycraft.container;
-
-import java.awt.Desktop;
-import java.net.URL;
-import java.util.ArrayList;
-
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.EnumChatFormatting;
-import darkknight.jewelrycraft.block.BlockList;
-import darkknight.jewelrycraft.client.GuiGuide;
-import darkknight.jewelrycraft.item.ItemList;
-
-public class GuiTabItems extends GuiTab
-{
-
- public GuiTabItems(int id)
- {
- super("Items", id);
- }
-
- public ItemStack getIcon()
- {
- return new ItemStack(ItemList.thiefGloves);
- }
-
- @Override
- public void drawBackground(GuiGuide gui, int x, int y, int page)
- {
- ArrayList<String> text = new ArrayList<String>();
- ArrayList<ItemStack> items = new ArrayList<ItemStack>();
- int xPos = (page%2==0)?107:-35;
- switch(page)
- {
- case 1:
- text.add(" Shadow ingots are");
- text.add("obtained by smelting");
- text.add("shadow ore. They are");
- text.add("used in a few recipes");
- text.add("and an important key");
- text.add("for making some");
- text.add("jewellery work.");
- items.add(new ItemStack(BlockList.shadowOre));
- items.add(new ItemStack(ItemList.shadowIngot));
- Page.addSmeltingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text, items, x, y);
- break;
- case 2:
- text.add(" These gloves allow");
- text.add("you to steal the trades");
- text.add("the pesky Testificates");
- text.add("have to offer.");
- text.add(" To use these simply");
- text.add("open their gui at least");
- text.add("once, then crouch and");
- items.add(new ItemStack(ItemList.thiefGloves));
- items.add(new ItemStack(ItemList.shadowIngot));
- items.add(null);
- items.add(new ItemStack(ItemList.shadowIngot));
- items.add(new ItemStack(Blocks.wool, 1, 15));
- items.add(new ItemStack(ItemList.shadowIngot));
- items.add(new ItemStack(Blocks.wool, 1, 15));
- items.add(new ItemStack(Blocks.wool, 1, 15));
- items.add(new ItemStack(ItemList.shadowIngot));
- items.add(new ItemStack(Blocks.wool, 1, 15));
- Page.addCraftingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop(), false, text, items, x, y);
- break;
- case 3:
- text.add("right click on the them");
- text.add("to steal the trades.");
- text.add("A villager has 7 of the");
- text.add("same trade item. So, for");
- text.add("example, if he wants 2");
- text.add("emeralds in exchange");
- text.add("for 4 diamonds, you will");
- text.add("get 28 diamonds from");
- text.add("him, because 7*4=28.");
- text.add("However, if you have");
- text.add("traded with him before,");
- text.add("then he will have that");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 4:
- text.add("many times less of the");
- text.add("item. This has a maximum");
- text.add("of 10 uses before it");
- text.add("breaks.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 5:
- text.add(" In order to get the");
- text.add("ingot back from the");
- text.add("smelter you need a");
- text.add("mold for it. However,");
- text.add("this mold can't be used.");
- text.add("It is too soft. It needs");
- text.add("to be hardened in");
- text.add("order for it to be used.");
- items.add(new ItemStack(ItemList.clayMolds, 1, 0));
- items.add(new ItemStack(Items.clay_ball));
- items.add(new ItemStack(Items.clay_ball));
- Page.addCraftingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop(), true, text, items, x, y);
- break;
- case 6:
- text.add(" By smelting the clay_ball");
- text.add("mold you get a harder");
- text.add("version which can be");
- text.add("used to create ingots.");
- text.add("Simply right click with");
- text.add("this on a molder to");
- text.add("attach it and you're");
- text.add("ready to go.");
- items.add(new ItemStack(ItemList.clayMolds, 1, 0));
- items.add(new ItemStack(ItemList.molds, 1, 0));
- Page.addSmeltingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text, items, x, y);
- break;
- case 7:
- text.add(" In order to create a");
- text.add("ring you need a mold");
- text.add("for it. However, this");
- text.add("one can't be used. It is");
- text.add("too soft. It needs to be");
- text.add("hardened in order for");
- text.add("it to be used.");
- items.add(new ItemStack(ItemList.clayMolds, 1, 1));
- items.add(null);
- items.add(new ItemStack(Items.clay_ball));
- items.add(null);
- items.add(new ItemStack(Items.clay_ball));
- items.add(null);
- items.add(new ItemStack(Items.clay_ball));
- items.add(null);
- items.add(new ItemStack(Items.clay_ball));
- items.add(null);
- Page.addCraftingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop(), false, text, items, x, y);
- break;
- case 8:
- text.add(" By smelting the clay_ball");
- text.add("mold you get a harder");
- text.add("version which can be");
- text.add("used to create rings.");
- text.add("Simply right click with");
- text.add("this on a molder to");
- text.add("attach it and you're");
- text.add("ready to go.");
- items.add(new ItemStack(ItemList.clayMolds, 1, 1));
- items.add(new ItemStack(ItemList.molds, 1, 1));
- Page.addSmeltingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text, items, x, y);
- break;
- case 9:
- text.add(" In order to create a");
- text.add("necklace you need a");
- text.add("mold for it. However,");
- text.add("this one can't be used.");
- text.add("It is too soft. It needs");
- text.add("to be hardened in");
- text.add("order for it to be used.");
- items.add(new ItemStack(ItemList.clayMolds, 1, 2));
- items.add(new ItemStack(Items.clay_ball));
- items.add(null);
- items.add(new ItemStack(Items.clay_ball));
- items.add(new ItemStack(Items.clay_ball));
- items.add(null);
- items.add(new ItemStack(Items.clay_ball));
- items.add(null);
- items.add(new ItemStack(Items.clay_ball));
- items.add(null);
- Page.addCraftingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop(), false, text, items, x, y);
- break;
- case 10:
- text.add(" By smelting the clay_ball");
- text.add("mold you get a harder");
- text.add("version which can be");
- text.add("used to create");
- text.add("necklaces. Simply right");
- text.add("click with this on a");
- text.add("molder to attach it and");
- text.add("you're ready to go.");
- items.add(new ItemStack(ItemList.clayMolds, 1, 2));
- items.add(new ItemStack(ItemList.molds, 1, 2));
- Page.addSmeltingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text, items, x, y);
- break;
- case 11:
- text.add(" Crystals don't do");
- text.add("much. They can be dyed");
- text.add("in any color and used");
- text.add("as jewels to create a");
- text.add("nice jewellery.");
- items.add(new ItemStack(ItemList.crystal, 1, 15));
- items.add(null);
- items.add(new ItemStack(Blocks.glass));
- items.add(null);
- items.add(new ItemStack(Blocks.glass));
- items.add(null);
- items.add(new ItemStack(Blocks.glass));
- items.add(null);
- items.add(new ItemStack(Blocks.glass));
- items.add(null);
- Page.addCraftingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop(), false, text, items, x, y);
- break;
- case 12:
- if(del == 0) values++;
- del++;
- if(del >= 300) del = 0;
- if(values >= 15) values = 0;
- items.add(new ItemStack(ItemList.crystal, 1, values));
- items.add(new ItemStack(Items.dye, 1, values));
- items.add(new ItemStack(ItemList.crystal, 1, 15));
- Page.addCraftingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop(), true, text, items, x, y);
- items.removeAll(items);
- items.add(new ItemStack(ItemList.crystal, 1, 15));
- items.add(new ItemStack(Items.dye, 1, 15));
- items.add(new ItemStack(ItemList.crystal, 1, values));
- Page.addCraftingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop() + 60, true, text, items, x, y);
- break;
- case 13:
- if(del == 0) values++;
- del++;
- if(del >= 300) del = 0;
- if(values >= 3) values = 0;
- text.add(" It's this exact guide.");
- text.add("I don't even know why");
- text.add("you're reading this.");
- text.add("I added this recipe in");
- text.add("case you lose the");
- text.add("original. In case you");
- text.add("don't have it, I suggest");
- text.add("adding NEI so you can");
- items.add(new ItemStack(ItemList.guide));
- items.add(new ItemStack(ItemList.molds, 1, values));
- items.add(new ItemStack(Items.book));
- Page.addCraftingRecipeTextPage(gui, gui.getLeft() + xPos, gui.getTop(), true, text, items, x, y);
- break;
- case 14:
- String link = "HERE";
- if(x >= gui.getLeft() + 138 && x <= gui.getLeft() + 168 && y >= gui.getTop() + 98 && y <= gui.getTop() + 108) link = EnumChatFormatting.DARK_BLUE + "HERE" + EnumChatFormatting.BLACK;
- text.add("see all the recipes.");
- text.add("Since you are reading");
- text.add("this, how about making");
- text.add("a youtube video");
- text.add("spotlighting this mod.");
- text.add("I'd really appreciate it.");
- text.add("After that you can");
- text.add("share it in the main");
- text.add("thread " + link + ".");
- text.add(" This mod was made by");
- text.add("DarkKnight (or sor1n");
- text.add("depending from where");
- text.add("you got this)");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- default:;
- }
- }
-
- public int getMaxPages()
- {
- return 13;
- }
-
- public void mouseClick(GuiGuide gui, int x, int y, int button)
- {
- if(gui.page == 13 && x >= gui.getLeft() + 138 && x <= gui.getLeft() + 168 && y >= gui.getTop() + 98 && y <= gui.getTop() + 108)
- {
- try
- {
- Desktop.getDesktop().browse(new URL("http://www.minecraftforum.net/topic/2210959-164smp-ssp-jewelrycraft-version-12/").toURI());
- }
- catch (Exception e) {}
- }
- }
-
- @Override
- public void drawForeground(GuiGuide gui, int x, int y, int page)
- {
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/container/GuiTabJewelsAndModifiers.java b/src/main/java/darkknight/jewelrycraft/container/GuiTabJewelsAndModifiers.java
deleted file mode 100644
index 1085f7d..0000000
--- a/src/main/java/darkknight/jewelrycraft/container/GuiTabJewelsAndModifiers.java
+++ /dev/null
@@ -1,87 +0,0 @@
-package darkknight.jewelrycraft.container;
-
-import net.minecraft.init.Items;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.EnumChatFormatting;
-
-import org.lwjgl.opengl.GL11;
-
-import darkknight.jewelrycraft.client.GuiGuide;
-import darkknight.jewelrycraft.util.JewelrycraftUtil;
-
-public class GuiTabJewelsAndModifiers extends GuiTab
-{
- public GuiTabJewelsAndModifiers(int id)
- {
- super("Jewels and modifiers", id);
- }
-
- public ItemStack getIcon()
- {
- return new ItemStack(Items.emerald);
- }
-
- @Override
- public void drawBackground(GuiGuide gui, int x, int y, int page)
- {
- int xPos = (page%2==0)?107:-35;
- switch(page)
- {
- case 1:
- gui.getFont().drawString(EnumChatFormatting.DARK_BLUE + "\u00a7n" + "Jewels", gui.getLeft() + xPos + 40, gui.getTop(), 0);
- for(int i = 0; i <= 8; i++){
- gui.renderItem(JewelrycraftUtil.jewel.get(i), gui.getLeft() + xPos + 10, gui.getTop() + 22 + 16*i, 30f);
- gui.getFont().drawString(JewelrycraftUtil.jewel.get(i).getDisplayName(), gui.getLeft() + xPos + 20, gui.getTop() + 12 + 16*i, 0);
- }
- break;
- case 2:
- gui.getFont().drawString(EnumChatFormatting.DARK_BLUE + "\u00a7n" + "Jewels", gui.getLeft() + xPos + 40, gui.getTop(), 0);
- for(int i = 0; i <= 8; i++){
- gui.renderItem(JewelrycraftUtil.jewel.get(i+9), gui.getLeft() + xPos + 10, gui.getTop() + 22 + 16*i, 30f);
- gui.getFont().drawString(JewelrycraftUtil.jewel.get(i+9).getDisplayName(), gui.getLeft() + xPos + 20, gui.getTop() + 12 + 16*i, 0);
- }
- break;
- case 3:
- gui.getFont().drawString(EnumChatFormatting.DARK_BLUE + "\u00a7n" + "Jewels", gui.getLeft() + xPos + 40, gui.getTop(), 0);
- for(int i = 0; i <= 8; i++)
- if(i+18 < JewelrycraftUtil.jewel.size()){
- gui.renderItem(JewelrycraftUtil.jewel.get(i+18), gui.getLeft() + xPos + 10, gui.getTop() + 22 + 16*i, 30f);
- gui.getFont().drawString(JewelrycraftUtil.jewel.get(i+18).getDisplayName(), gui.getLeft() + xPos + 20, gui.getTop() + 12 + 16*i, 0);
- GL11.glDisable(GL11.GL_LIGHTING);
- }
- break;
- case 4:
- gui.getFont().drawString(EnumChatFormatting.DARK_BLUE + "\u00a7n" + "Modifiers", gui.getLeft() + xPos + 40, gui.getTop(), 0);
- for(int i = 0; i <= 8; i++){
- if(i < JewelrycraftUtil.modifiers.size())
- {
- gui.renderItem(JewelrycraftUtil.modifiers.get(i), gui.getLeft() + xPos + 10, gui.getTop() + 22 + 16*i, 30f);
- gui.getFont().drawString(JewelrycraftUtil.modifiers.get(i).getDisplayName(), gui.getLeft() + xPos + 20, gui.getTop() + 12 + 16*i, 0);
- }
- }
- break;
- case 5:
- gui.getFont().drawString(EnumChatFormatting.DARK_BLUE + "\u00a7n" + "Modifiers", gui.getLeft() + xPos + 40, gui.getTop(), 0);
- for(int i = 0; i <= 8; i++){
- if(i+9 < JewelrycraftUtil.modifiers.size()){
- gui.renderItem(JewelrycraftUtil.modifiers.get(i + 9), gui.getLeft() + xPos + 10, gui.getTop() + 22 + 16*i, 30f);
- gui.getFont().drawString(JewelrycraftUtil.modifiers.get(i + 9).getDisplayName(), gui.getLeft() + xPos + 20, gui.getTop() + 12 + 16*i, 0);
- GL11.glDisable(GL11.GL_LIGHTING);
- }
- }
- break;
- default:;
- }
- }
-
- public int getMaxPages()
- {
- return 5;
- }
-
- @Override
- public void drawForeground(GuiGuide gui, int x, int y, int page)
- {
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/container/GuiTabNecklaces.java b/src/main/java/darkknight/jewelrycraft/container/GuiTabNecklaces.java
deleted file mode 100644
index 4271928..0000000
--- a/src/main/java/darkknight/jewelrycraft/container/GuiTabNecklaces.java
+++ /dev/null
@@ -1,380 +0,0 @@
-package darkknight.jewelrycraft.container;
-
-import java.util.ArrayList;
-
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.EnumChatFormatting;
-import darkknight.jewelrycraft.client.GuiGuide;
-import darkknight.jewelrycraft.item.ItemList;
-import darkknight.jewelrycraft.util.JewelryNBT;
-import darkknight.jewelrycraft.util.JewelrycraftUtil;
-
-public class GuiTabNecklaces extends GuiTab
-{
- int jValues;
- public GuiTabNecklaces(int id)
- {
- super("Necklaces", id);
- jValues = 0;
- }
-
- public ItemStack getIcon()
- {
- ItemStack it = new ItemStack(ItemList.necklace);
- JewelryNBT.addMetal(it, new ItemStack(Items.iron_ingot));
- JewelryNBT.addJewel(it, new ItemStack(Blocks.redstone_block));
- return it;
- }
-
- @Override
- public void drawBackground(GuiGuide gui, int x, int y, int page)
- {
- ArrayList<String> text = new ArrayList<String>();
- ArrayList<ItemStack> jewels = new ArrayList<ItemStack>();
- ItemStack item = new ItemStack(ItemList.necklace);
- int xPos = (page%2==0)?107:-35;
- switch(page)
- {
- case 1:
- if(del == 0) values++;
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, new ItemStack(Items.ender_pearl));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "Ender Pearl");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "None");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" This ring teleports");
- text.add("you and anyone around ");
- text.add("in any location from the");
- text.add("same dimension. Just");
- text.add("right click once in a");
- text.add("location to se the ");
- text.add("position. Then right ");
- text.add("click any time you want");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 2:
- text.add("to teleport there.");
- text.add(EnumChatFormatting.DARK_RED + "\u00a7nAltar Effect");
- text.add(" This teleports anyone");
- text.add("or anything that steps");
- text.add("or goes near the altar");
- text.add("to the necklaces");
- text.add("coordonates, as long");
- text.add("as that is in the same");
- text.add("dimension.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 3:
- if(del == 0) values++;
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, new ItemStack(Items.ender_pearl));
- JewelryNBT.addModifier(item, new ItemStack(Items.bed));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "Ender Pearl");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Bed");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" Just like the other");
- text.add("necklace this teleports");
- text.add("you and anybody close");
- text.add("to you to the set");
- text.add("destination. The only");
- text.add("difference is that you");
- text.add("can travel between");
- text.add("dimensions with this.");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 4:
- text.add(EnumChatFormatting.DARK_RED + "\u00a7nAltar Effect");
- text.add(" This teleports anyone");
- text.add("or anything that step");
- text.add("on or around the altar");
- text.add("to the set location, with");
- text.add("the benefit of it being");
- text.add("capable of");
- text.add("inter-dimensional");
- text.add("travels.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 5:
- jewels.add(null);
- jewels.add(new ItemStack(Items.diamond));
- jewels.add(new ItemStack(Items.emerald));
- jewels.add(new ItemStack(Items.nether_star));
-
- if(del == 0) { values++; jValues++;}
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
- if(jValues > jewels.size() - 1) jValues = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, jewels.get(jValues));
- JewelryNBT.addModifier(item, new ItemStack(Items.blaze_powder));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "None, Diamond");
- text.add("Emerald or Nether Star");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Blaze Powder");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" This necklace gives");
- text.add("you and those around");
- text.add("you " + EnumChatFormatting.DARK_RED + "Fire Resistance");
- text.add("when activated and in");
- text.add("your inventory. To");
- text.add("deactivate it simply");
- text.add("right click with it.");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 6:
- text.add("Depending on the jewel");
- text.add("used, you and the");
- text.add("others get " + EnumChatFormatting.DARK_RED + "Fire");
- text.add(EnumChatFormatting.DARK_RED + "Resistance" + EnumChatFormatting.BLACK + " I if you");
- text.add("haven't got any jewel,");
- text.add("II for Diamond,");
- text.add("III for Emerald and");
- text.add("VIII for Nether Star.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 7:
- jewels.add(null);
- jewels.add(new ItemStack(Items.diamond));
- jewels.add(new ItemStack(Items.emerald));
- jewels.add(new ItemStack(Items.nether_star));
-
- if(del == 0) { values++; jValues++;}
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
- if(jValues > jewels.size() - 1) jValues = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, jewels.get(jValues));
- JewelryNBT.addModifier(item, new ItemStack(Items.sugar));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "None, Diamond");
- text.add("Emerald or Nether Star");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Sugar");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" This necklace gives");
- text.add("you and those around");
- text.add("you " + EnumChatFormatting.DARK_RED + "Speed" + EnumChatFormatting.BLACK + " when");
- text.add("activated and in your");
- text.add("inventory. To");
- text.add("deactivate it simply");
- text.add("right click with it.");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 8:
- text.add("Depending on the jewel");
- text.add("used, you and the");
- text.add("others get " + EnumChatFormatting.DARK_RED + "Speed" + EnumChatFormatting.BLACK + " I");
- text.add("if you haven't got any");
- text.add("jewel, II for Diamond,");
- text.add("III for Emerald and");
- text.add("VIII for Nether Star.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 9:
- jewels.add(null);
- jewels.add(new ItemStack(Items.diamond));
- jewels.add(new ItemStack(Items.emerald));
- jewels.add(new ItemStack(Items.nether_star));
-
- if(del == 0) { values++; jValues++;}
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
- if(jValues > jewels.size() - 1) jValues = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, jewels.get(jValues));
- JewelryNBT.addModifier(item, new ItemStack(Items.iron_pickaxe));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "None, Diamond");
- text.add("Emerald or Nether Star");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Iron Pickaxe");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" This necklace gives");
- text.add("you and those around");
- text.add("you " + EnumChatFormatting.DARK_RED + "Haste" + EnumChatFormatting.BLACK + " when");
- text.add("activated and in your");
- text.add("inventory. To");
- text.add("deactivate it simply");
- text.add("right click with it.");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 10:
- text.add("Depending on the jewel");
- text.add("used, you and the");
- text.add("others get " + EnumChatFormatting.DARK_RED + "Haste" + EnumChatFormatting.BLACK + " I");
- text.add("if you haven't got any");
- text.add("jewel, II for Diamond,");
- text.add("III for Emerald and");
- text.add("VIII for Nether Star.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 11:
- jewels.add(null);
- jewels.add(new ItemStack(Items.diamond));
- jewels.add(new ItemStack(Items.emerald));
- jewels.add(new ItemStack(Items.nether_star));
-
- if(del == 0) { values++; jValues++;}
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
- if(jValues > jewels.size() - 1) jValues = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, jewels.get(jValues));
- JewelryNBT.addModifier(item, new ItemStack(Items.feather));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "None, Diamond");
- text.add("Emerald or Nether Star");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Feather");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" This necklace gives");
- text.add("you and those around");
- text.add("you " + EnumChatFormatting.DARK_RED + "Jump Boost" + EnumChatFormatting.BLACK + " when");
- text.add("activated and in your");
- text.add("inventory. To");
- text.add("deactivate it simply");
- text.add("right click with it.");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 12:
- text.add("Depending on the jewel");
- text.add("used, you and the");
- text.add("others get " + EnumChatFormatting.DARK_RED + "Jump Boost");
- text.add("I if you haven't got any");
- text.add("jewel, II for Diamond,");
- text.add("III for Emerald and");
- text.add("VIII for Nether Star.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 13:
- jewels.add(null);
- jewels.add(new ItemStack(Items.diamond));
- jewels.add(new ItemStack(Items.emerald));
- jewels.add(new ItemStack(Items.nether_star));
-
- if(del == 0) { values++; jValues++;}
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
- if(jValues > jewels.size() - 1) jValues = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, jewels.get(jValues));
- JewelryNBT.addModifier(item, new ItemStack(Items.potionitem, 1, 8270));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "None, Diamond");
- text.add("Emerald or Nether Star");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "8min Potion of");
- text.add("Invisibility");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" This necklace gives");
- text.add("you and those around");
- text.add("you " + EnumChatFormatting.DARK_RED + "Invisibility" + EnumChatFormatting.BLACK + " when");
- text.add("activated and in your");
- text.add("inventory. To");
- text.add("deactivate it simply");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 14:
- text.add("right click with it.");
- text.add("Depending on the jewel");
- text.add("used, you and the");
- text.add("others get " + EnumChatFormatting.DARK_RED + "Invisibility" + EnumChatFormatting.BLACK + " I");
- text.add("if you haven't got any");
- text.add("jewel, II for Diamond,");
- text.add("III for Emerald and");
- text.add("VIII for Nether Star.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 15:
- jewels.add(null);
- jewels.add(new ItemStack(Items.diamond));
- jewels.add(new ItemStack(Items.emerald));
- jewels.add(new ItemStack(Items.nether_star));
-
- if(del == 0){values++; jValues++;}
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
- if(jValues > jewels.size() - 1) jValues = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, jewels.get(jValues));
- JewelryNBT.addModifier(item, new ItemStack(Items.dye, 1, 15));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "None, Diamond");
- text.add("Emerald or Nether Star");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Bone Meal");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" This hydrates the");
- text.add("farm blocks under you");
- text.add("in a defined area. If");
- text.add("you right click with this,");
- text.add("it will help plants in");
- text.add("that area grow faster.");
- text.add("The are it affects is");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 16:
- text.add("determined by the jewel");
- text.add("used. For none, the");
- text.add("area is a block, diamond");
- text.add("is 3x3, emerald 5x5 and");
- text.add("nether star 11x11.");
- text.add(EnumChatFormatting.DARK_RED + "\u00a7nAltar Effect");
- text.add(" In the altar, this");
- text.add("has the ability to");
- text.add("hydrate any tilted land");
- text.add("and speed up the");
- text.add("growth of plants in a");
- text.add("7x3x7 area.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 17:
- JewelryNBT.addMetal(item, new ItemStack(ItemList.shadowIngot));
- JewelryNBT.addJewel(item, new ItemStack(Items.nether_star));
- JewelryNBT.addModifier(item, new ItemStack(Items.diamond_pickaxe));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "Nether Star");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Diamond Pick");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Shadow Ingot");
- text.add(" This will break all");
- text.add("blocks in a 3x3x1 area.");
- text.add("Just right click on a");
- text.add("block and let the mining");
- text.add("begin.");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- default:;
- }
- }
-
- public int getMaxPages()
- {
- return 17;
- }
-
- @Override
- public void drawForeground(GuiGuide gui, int x, int y, int page)
- {
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/container/GuiTabRings.java b/src/main/java/darkknight/jewelrycraft/container/GuiTabRings.java
deleted file mode 100644
index 646a78b..0000000
--- a/src/main/java/darkknight/jewelrycraft/container/GuiTabRings.java
+++ /dev/null
@@ -1,587 +0,0 @@
-package darkknight.jewelrycraft.container;
-
-import java.util.ArrayList;
-
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.EnumChatFormatting;
-import darkknight.jewelrycraft.client.GuiGuide;
-import darkknight.jewelrycraft.item.ItemList;
-import darkknight.jewelrycraft.util.JewelryNBT;
-import darkknight.jewelrycraft.util.JewelrycraftUtil;
-
-public class GuiTabRings extends GuiTab
-{
- int jValues;
- public GuiTabRings(int id)
- {
- super("Rings", id);
- jValues = 0;
- }
-
- public ItemStack getIcon()
- {
- ItemStack it = new ItemStack(ItemList.ring);
- JewelryNBT.addMetal(it, new ItemStack(Items.gold_ingot));
- JewelryNBT.addJewel(it, new ItemStack(Items.ender_pearl));
- return it;
- }
-
- @Override
- public void drawBackground(GuiGuide gui, int x, int y, int page)
- {
- ArrayList<String> text = new ArrayList<String>();
- ArrayList<ItemStack> jewels = new ArrayList<ItemStack>();
- ItemStack item = new ItemStack(ItemList.ring);
- int xPos = (page%2==0)?107:-35;
- switch(page)
- {
- case 1:
- if(del == 0) values++;
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, new ItemStack(Items.ender_pearl));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "Ender Pearl");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "None");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" This ring allows you");
- text.add("to teleport in any");
- text.add("location from the same");
- text.add("dimension. Simply right");
- text.add("click once in a location");
- text.add("to se the position. Then");
- text.add("right click any time you");
- text.add("want to teleport there.");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 2:
- text.add(EnumChatFormatting.DARK_RED + "\u00a7nAltar Effect");
- text.add(" If this ring is placed");
- text.add("in the altar and if the");
- text.add("ring has coordonates");
- text.add("memorized, then anyone");
- text.add("who steps on the block");
- text.add("will get teleported in");
- text.add("that location, as long");
- text.add("as it is in the same");
- text.add("dimension. This works");
- text.add("for other entities as");
- text.add("well, not just players.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 3:
- if(del == 0) values++;
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, new ItemStack(Items.ender_pearl));
- JewelryNBT.addModifier(item, new ItemStack(Items.bed));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "Ender Pearl");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Bed");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" Just like the other");
- text.add("ring that had only an");
- text.add("ender pearl as a jewel,");
- text.add("by adding a bed as a");
- text.add("modifier to it you can");
- text.add("travel between");
- text.add("dimensions.");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 4:
- text.add(EnumChatFormatting.DARK_RED + "\u00a7nAltar Effect");
- text.add(" Just like the other");
- text.add("one, when in the altar");
- text.add("if somebody steps on");
- text.add("the block they get");
- text.add("teleported in that spot.");
- text.add("The only difference is");
- text.add("that you can teleport");
- text.add("between dimesnions with");
- text.add("this. It works for mobs");
- text.add("and other entities as");
- text.add("well.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 5:
- jewels.add(null);
- jewels.add(new ItemStack(Items.diamond));
- jewels.add(new ItemStack(Items.emerald));
- jewels.add(new ItemStack(Items.nether_star));
-
- if(del == 0) { values++; jValues++;}
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
- if(jValues > jewels.size() - 1) jValues = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, jewels.get(jValues));
- JewelryNBT.addModifier(item, new ItemStack(Items.blaze_powder));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "None, Diamond");
- text.add("Emerald or Nether Star");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Blaze Powder");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" This ring grants you");
- text.add(EnumChatFormatting.DARK_RED + "Fire Resistance" + EnumChatFormatting.BLACK + " when");
- text.add("activated and in your");
- text.add("inventory. To deactivate");
- text.add("it simply right click with");
- text.add("it. Depending on the");
- text.add("jewel you used, you");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 6:
- text.add("get " + EnumChatFormatting.DARK_RED + "Fire Resistance" + EnumChatFormatting.BLACK + " I");
- text.add("if you haven't got any");
- text.add("jewel, II for Diamond,");
- text.add("III for Emerald and");
- text.add("VIII for Nether Star.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 7:
- jewels.add(null);
- jewels.add(new ItemStack(Items.diamond));
- jewels.add(new ItemStack(Items.emerald));
- jewels.add(new ItemStack(Items.nether_star));
-
- if(del == 0) { values++; jValues++;}
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
- if(jValues > jewels.size() - 1) jValues = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, jewels.get(jValues));
- JewelryNBT.addModifier(item, new ItemStack(Items.sugar));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "None, Diamond");
- text.add("Emerald or Nether Star");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Sugar");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" This ring grants you");
- text.add(EnumChatFormatting.DARK_RED + "Speed" + EnumChatFormatting.BLACK + " when activated");
- text.add("and in your inventory.");
- text.add("To deactivate it simply");
- text.add("right click with it.");
- text.add("Depending on the");
- text.add("jewel you used, you");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 8:
- text.add("get " + EnumChatFormatting.DARK_RED + "Speed" + EnumChatFormatting.BLACK + " I if you");
- text.add("haven't got any jewel,");
- text.add("II for Diamond,");
- text.add("III for Emerald and");
- text.add("VIII for Nether Star.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 9:
- jewels.add(null);
- jewels.add(new ItemStack(Items.diamond));
- jewels.add(new ItemStack(Items.emerald));
- jewels.add(new ItemStack(Items.nether_star));
-
- if(del == 0) { values++; jValues++;}
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
- if(jValues > jewels.size() - 1) jValues = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, jewels.get(jValues));
- JewelryNBT.addModifier(item, new ItemStack(Items.iron_pickaxe));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "None, Diamond");
- text.add("Emerald or Nether Star");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Iron Pickaxe");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" This ring grants you");
- text.add(EnumChatFormatting.DARK_RED + "Haste" + EnumChatFormatting.BLACK + " when activated");
- text.add("and in your inventory.");
- text.add("To deactivate it simply");
- text.add("right click with it.");
- text.add("Depending on the");
- text.add("jewel you used, you");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 10:
- text.add("get " + EnumChatFormatting.DARK_RED + "Haste" + EnumChatFormatting.BLACK + " I if you");
- text.add("haven't got any jewel,");
- text.add("II for Diamond,");
- text.add("III for Emerald and");
- text.add("VIII for Nether Star.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 11:
- jewels.add(null);
- jewels.add(new ItemStack(Items.diamond));
- jewels.add(new ItemStack(Items.emerald));
- jewels.add(new ItemStack(Items.nether_star));
-
- if(del == 0) { values++; jValues++;}
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
- if(jValues > jewels.size() - 1) jValues = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, jewels.get(jValues));
- JewelryNBT.addModifier(item, new ItemStack(Items.feather));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "None, Diamond");
- text.add("Emerald or Nether Star");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Feather");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" This ring grants you");
- text.add(EnumChatFormatting.DARK_RED + "Jump Boost" + EnumChatFormatting.BLACK + " when");
- text.add("activated and in your");
- text.add("inventory, as well as");
- text.add("remove any fall damage.");
- text.add("To deactivate it simply");
- text.add("right click with it.");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 12:
- text.add("Depending on the jewel");
- text.add("you used, you get");
- text.add(EnumChatFormatting.DARK_RED + "Jump Boost" + EnumChatFormatting.BLACK + " I if you");
- text.add("haven't got any jewel,");
- text.add("II for Diamond,");
- text.add("III for Emerald and");
- text.add("VIII for Nether Star.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 13:
- jewels.add(null);
- jewels.add(new ItemStack(Items.diamond));
- jewels.add(new ItemStack(Items.emerald));
- jewels.add(new ItemStack(Items.nether_star));
-
- if(del == 0) { values++; jValues++;}
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
- if(jValues > jewels.size() - 1) jValues = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, jewels.get(jValues));
- JewelryNBT.addModifier(item, new ItemStack(Items.potionitem, 1, 8270));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "None, Diamond");
- text.add("Emerald or Nether Star");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "8min Potion of");
- text.add("Invisibility");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" This ring grants you");
- text.add(EnumChatFormatting.DARK_RED + "Invisibility" + EnumChatFormatting.BLACK + " when");
- text.add("activated and in your");
- text.add("inventory, as well as");
- text.add("remove any fall damage.");
- text.add("To deactivate it simply");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 14:
- text.add("right click with it.");
- text.add("Depending on the jewel");
- text.add("you used, you get");
- text.add(EnumChatFormatting.DARK_RED + "Invisibility" + EnumChatFormatting.BLACK + " I if you");
- text.add("haven't got any jewel,");
- text.add("II for Diamond,");
- text.add("III for Emerald and");
- text.add("VIII for Nether Star.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 15:
- if(del == 0) values++;
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, new ItemStack(Items.nether_star));
- JewelryNBT.addModifier(item, new ItemStack(Items.book));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "Nether Star");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Book");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" This has the power");
- text.add("to " + EnumChatFormatting.DARK_PURPLE + "Enchant" + EnumChatFormatting.BLACK + ", " + EnumChatFormatting.DARK_PURPLE + "Disenchant" + EnumChatFormatting.BLACK + "");
- text.add("or even" + EnumChatFormatting.DARK_PURPLE + " Transfer");
- text.add(EnumChatFormatting.DARK_PURPLE + "Enchantments" + EnumChatFormatting.BLACK + ". To");
- text.add("change its mode simply");
- text.add("right click it. However,");
- text.add("this ring only works");
- text.add("when it is being held.");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 16:
- text.add(EnumChatFormatting.DARK_PURPLE + "\u00a7nDisenchanting" + EnumChatFormatting.BLACK + "");
- text.add(" If the ring is held");
- text.add("and an enchanted item");
- text.add("is placed beside it in");
- text.add("the hotbar, the ring");
- text.add("will remove all the");
- text.add("enchantments from the");
- text.add("item and store them in");
- text.add("enchanted books, which");
- text.add("are placed in your");
- text.add("inventory. Be careful");
- text.add("however, because if");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 17:
- text.add("there is no room in");
- text.add("your inventory for the");
- text.add("books, the enchantments");
- text.add("will go in the void with");
- text.add("no way of recovering");
- text.add("them. Unfortunately,");
- text.add("disenchanting is not");
- text.add("free. It requires 2");
- text.add("levels of experience");
- text.add("per ench and some of");
- text.add("your blood. It will also");
- text.add("damage the item a bit.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 18:
- text.add(EnumChatFormatting.DARK_PURPLE + "\u00a7nEnchanting" + EnumChatFormatting.BLACK + "");
- text.add(" This mode allows you");
- text.add("to give a random");
- text.add("enchantment to an item");
- text.add("that can hold");
- text.add("enchantments in the");
- text.add("first place. However,");
- text.add("each enchanting comes");
- text.add("with a cost. The player");
- text.add("is required to have at");
- text.add("least 1 level of xp.");
- text.add("The higher the number");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 19:
- text.add("the better, as the level");
- text.add("of the enchantment will");
- text.add("be equal with the amount");
- text.add("of levels, but this value");
- text.add("can never go over 6.");
- text.add("This gives allows people");
- text.add("to get an enchantment");
- text.add("of a higher value than");
- text.add("normal (5 being the");
- text.add("limit normally).");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 20:
- text.add(EnumChatFormatting.DARK_PURPLE + "\u00a7nEnchantment Transfer" + EnumChatFormatting.BLACK + "");
- text.add(" This mode is very");
- text.add("special as it lets you");
- text.add("transfer enchantments");
- text.add("from an item or block to");
- text.add("another, not caring if");
- text.add("the item/block can");
- text.add("actually hold enchants.");
- text.add("Just place the ench");
- text.add("item on the left of the");
- text.add("ring and to the right of");
- text.add("the ring, the item you");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 21:
- text.add("want to transfer the");
- text.add("enchs to. The ring can");
- text.add("only transfer an ench");
- text.add("at a time, after each");
- text.add("transfer it requiring a");
- text.add("cooldown.");
- text.add(EnumChatFormatting.DARK_RED + " Again, this ring only");
- text.add(EnumChatFormatting.DARK_RED + "works when it is in the");
- text.add(EnumChatFormatting.DARK_RED + "players hotbar and");
- text.add(EnumChatFormatting.DARK_RED + "being held!");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 22:
- if(del == 0) values++;
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, new ItemStack(Items.ender_pearl));
- JewelryNBT.addModifier(item, new ItemStack(Blocks.chest));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "Ender Pearl");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Chest");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" This ring can link");
- text.add("to any chest and");
- text.add("access its inventory.");
- text.add("To link to a chest just");
- text.add("crouch and right click");
- text.add("on the one you want.");
- text.add("Then right click again");
- text.add("to open that inventory.");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 23:
- text.add("This only works if you");
- text.add("are in range to the");
- text.add("chest. You can go");
- text.add("about 128 blocks");
- text.add("before it stops");
- text.add("working. After that");
- text.add("a message will be");
- text.add("displayed saying the");
- text.add("amount of blocks you");
- text.add("need to be closer in");
- text.add("order for it to work");
- text.add("again.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 24:
- if(del == 0) values++;
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, new ItemStack(Blocks.obsidian));
- JewelryNBT.addModifier(item, new ItemStack(Items.ender_eye));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "Obsidian");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Eye of Ender");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" This ring is connected");
- text.add("to your ender chest.");
- text.add("Just right click it");
- text.add("anywhere to open the");
- text.add("ender chest gui.");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 25:
- if(del == 0) values++;
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, new ItemStack(Items.nether_star));
- JewelryNBT.addModifier(item, new ItemStack(Blocks.chest));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "Nether Star");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Chest");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" This ring can store");
- text.add("any entity in it. To do");
- text.add("that right click an");
- text.add("to store it in the ring");
- text.add("(crouch and right click");
- text.add("if right clicking the");
- text.add("entity opens a GUI,");
- text.add("such as villagers).");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 26:
- text.add("Right click again on the");
- text.add("ground to release the");
- text.add("entity in that spot.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 27:
- if(del == 0){values++; jValues++;}
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
- if(jValues > JewelrycraftUtil.jewel.size() - 1) jValues = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, JewelrycraftUtil.jewel.get(jValues));
- JewelryNBT.addModifier(item, new ItemStack(Items.dye, 1, 15));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "Any");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Bone Meal");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" While having it in");
- text.add("the inventory it will");
- text.add("hydrate any farmland");
- text.add("you step on. If you");
- text.add("right click with this");
- text.add("on a plant, it will");
- text.add("speed up the growth a");
- text.add("bit. Better keep right");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 28:
- text.add("clicking if you want to");
- text.add("see an actual effect.");
- text.add(EnumChatFormatting.DARK_RED + "\u00a7nAltar Effect");
- text.add(" In the altar, the ring");
- text.add("has the ability to");
- text.add("hydrate any tilted land");
- text.add("and speed up the");
- text.add("growth of plants in a");
- text.add("3x3x3 area.");
- Page.addTextPage(gui, gui.getLeft() + xPos, gui.getTop(), text);
- break;
- case 29:
- if(del == 0) values++;
- del++;
- if(del >= 300) del = 0;
- if(values > JewelrycraftUtil.metal.size() - 1) values = 0;
-
- JewelryNBT.addMetal(item, JewelrycraftUtil.metal.get(values));
- JewelryNBT.addJewel(item, new ItemStack(Items.ender_pearl));
- JewelryNBT.addModifier(item, new ItemStack(Items.diamond_pickaxe));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "Ender Pearl");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Diamond Pick");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Any");
- text.add(" You can right click");
- text.add("any block (or crouch");
- text.add("right click) to store");
- text.add("that block inside it.");
- text.add("Right click on the");
- text.add("ground to place it");
- text.add("there. It can also");
- text.add("create golems/withers.");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- case 30:
- JewelryNBT.addMetal(item, new ItemStack(ItemList.shadowIngot));
- JewelryNBT.addJewel(item, new ItemStack(Items.nether_star));
- JewelryNBT.addModifier(item, new ItemStack(Items.diamond_pickaxe));
-
- text.add(EnumChatFormatting.DARK_GREEN + "Jewel: " + EnumChatFormatting.BLACK + "Nether Star");
- text.add(EnumChatFormatting.DARK_GREEN + "Modifier: " + EnumChatFormatting.BLACK + "Diamond Pick");
- text.add(EnumChatFormatting.DARK_GREEN + "Ingot: " + EnumChatFormatting.BLACK + "Shadow Ingot");
- text.add(" Right clicking with");
- text.add("this on any block will");
- text.add("cause that block to");
- text.add("break instantly.");
- Page.addImageTextPage(gui, gui.getLeft() + xPos, gui.getTop(), item, text, 50f, 0, -10, false, 45, 0);
- break;
- default:;
- }
- }
-
- public int getMaxPages()
- {
- return 30;
- }
-
- @Override
- public void drawForeground(GuiGuide gui, int x, int y, int page)
- {
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/container/Page.java b/src/main/java/darkknight/jewelrycraft/container/Page.java
deleted file mode 100644
index da12663..0000000
--- a/src/main/java/darkknight/jewelrycraft/container/Page.java
+++ /dev/null
@@ -1,172 +0,0 @@
-package darkknight.jewelrycraft.container;
-
-import java.util.ArrayList;
-
-import org.lwjgl.opengl.GL11;
-
-import net.minecraft.client.Minecraft;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.ResourceLocation;
-import darkknight.jewelrycraft.client.GuiGuide;
-
-public class Page
-{
- public static void addCraftingRecipeTextPage(GuiGuide gui, int x, int y, boolean isSmall, ArrayList<String> text, ArrayList<ItemStack> items, int mouseX, int mouseY)
- {
- y+=5;
- gui.getFont().drawString(EnumChatFormatting.DARK_BLUE + "\u00a7n" + items.get(0).getDisplayName(), x + Math.abs(70 - gui.getFont().getStringWidth(items.get(0).getDisplayName())/2) - 10, y - 2, 0);
- GL11.glColor4f(1, 1, 1, 1);
- Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation("jewelrycraft", "textures/gui/guidePageFlip.png"));
- ArrayList<String> name = new ArrayList<String>();
- if(isSmall){
- gui.drawTexturedModalRect(x, y + 10, 145, 54, 111, 46);
- gui.renderItem(items.get(0), x + 89, y + 22 + 10, 30f);
-// gui.drawRect(x, y + 10, x + 111, y + 46, 325325);
- if(items.size() > 1 && items.get(1) != null){
- gui.renderItem(items.get(1), x + 8, y + 16 + 10, 30f);
- if(x - gui.getLeft() >= x + 8) gui.drawHoverString(text, x, y);
- name.add(items.get(1).getDisplayName());
- if(mouseX >= x && mouseX <= x + 16 && mouseY >= y + 10 && mouseY <= y + 26) gui.drawHoverString(name, x - 8, y + 10);
- name.removeAll(name);
- GL11.glDisable(GL11.GL_LIGHTING);
- }
- if(items.size() > 2 && items.get(2) != null){
- gui.renderItem(items.get(2), x + 30, y + 16 + 10, 30f);
- name.add(items.get(2).getDisplayName());
- if(mouseX >= x + 20 && mouseX <= x + 16 + 20 && mouseY >= y + 10 && mouseY <= y + 26) gui.drawHoverString(name, x + 15, y + 10);
- name.removeAll(name);
- GL11.glDisable(GL11.GL_LIGHTING);
- }
- if(items.size() > 3 && items.get(3) != null){
- gui.renderItem(items.get(3), x + 8, y + 40 + 10, 30f);
- name.add(items.get(3).getDisplayName());
- if(mouseX >= x && mouseX <= x + 16 && mouseY >= y + 36 && mouseY <= y + 36 + 16) gui.drawHoverString(name, x - 8, y + 35);
- name.removeAll(name);
- GL11.glDisable(GL11.GL_LIGHTING);
- }
- if(items.size() > 4 && items.get(4) != null){
- gui.renderItem(items.get(4), x + 30, y + 40 + 10, 30f);
- name.add(items.get(4).getDisplayName());
- if(mouseX >= x + 20 && mouseX <= x + 16 + 20 && mouseY >= y + 36 && mouseY <= y + 36 + 16) gui.drawHoverString(name, x + 15, y + 35);
- name.removeAll(name);
- GL11.glDisable(GL11.GL_LIGHTING);
- }
- for(int i = 0; i < text.size(); i++) gui.getFont().drawString(text.get(i), x, y + 55 + i*12, 0);
- }
- else{
- gui.drawTexturedModalRect(x, y + 10, 145, 0, 111, 54);
- gui.renderItem(items.get(0), x + 91, y + 28 + 10, 30f);
- if(items.size() > 1 && items.get(1) != null){
- gui.renderItem(items.get(1), x + 8, y + 20, 30f);
- name.add(items.get(1).getDisplayName());
- if(mouseX >= x && mouseX <= x + 16 && mouseY >= y + 10 && mouseY <= y + 26) gui.drawHoverString(name, x + 8, y + 10);
- name.removeAll(name);
- GL11.glDisable(GL11.GL_LIGHTING);
- }
- if(items.size() > 2 && items.get(2) != null){
- gui.renderItem(items.get(2), x + 28, y + 20, 30f);
- name.add(items.get(2).getDisplayName());
- if(mouseX >= x + 20 && mouseX <= x + 16 + 20 && mouseY >= y + 10 && mouseY <= y + 26) gui.drawHoverString(name, x + 28, y + 10);
- name.removeAll(name);
- GL11.glDisable(GL11.GL_LIGHTING);
- }
- if(items.size() > 3 && items.get(3) != null){
- gui.renderItem(items.get(3), x + 45, y + 20, 30f);
- name.add(items.get(3).getDisplayName());
- if(mouseX >= x + 40 && mouseX <= x + 16 + 40 && mouseY >= y + 10 && mouseY <= y + 26) gui.drawHoverString(name, x + 45, y + 10);
- name.removeAll(name);
- GL11.glDisable(GL11.GL_LIGHTING);
- }
- if(items.size() > 4 && items.get(4) != null){
- gui.renderItem(items.get(4), x + 8, y + 37, 30f);
- name.add(items.get(4).getDisplayName());
- if(mouseX >= x && mouseX <= x + 16 && mouseY >= y + 27 && mouseY <= y + 27 + 16) gui.drawHoverString(name, x + 8, y + 27);
- name.removeAll(name);
- GL11.glDisable(GL11.GL_LIGHTING);
- }
- if(items.size() > 5 && items.get(5) != null){
- gui.renderItem(items.get(5), x + 28, y + 37, 30f);
- name.add(items.get(5).getDisplayName());
- if(mouseX >= x + 20 && mouseX <= x + 16 + 20 && mouseY >= y + 27 && mouseY <= y + 27 + 16) gui.drawHoverString(name, x + 28, y + 27);
- name.removeAll(name);
- GL11.glDisable(GL11.GL_LIGHTING);
- }
- if(items.size() > 6 && items.get(6) != null){
- gui.renderItem(items.get(6), x + 45, y + 37, 30f);
- name.add(items.get(6).getDisplayName());
- if(mouseX >= x + 40 && mouseX <= x + 16 + 40 && mouseY >= y + 27 && mouseY <= y + 27 + 16) gui.drawHoverString(name, x + 45, y + 27);
- name.removeAll(name);
- GL11.glDisable(GL11.GL_LIGHTING);
- }
- if(items.size() > 7 && items.get(7) != null){
- gui.renderItem(items.get(7), x + 8, y + 57, 30f);
- name.add(items.get(7).getDisplayName());
- if(mouseX >= x && mouseX <= x + 16 && mouseY >= y + 47 && mouseY <= y + 47 + 16) gui.drawHoverString(name, x + 8, y + 47);
- name.removeAll(name);
- GL11.glDisable(GL11.GL_LIGHTING);
- }
- if(items.size() > 8 && items.get(8) != null){
- gui.renderItem(items.get(8), x + 28, y + 57, 30f);
- name.add(items.get(8).getDisplayName());
- if(mouseX >= x + 20 && mouseX <= x + 16 + 20 && mouseY >= y + 47 && mouseY <= y + 47 + 16) gui.drawHoverString(name, x + 28, y + 47);
- name.removeAll(name);
- GL11.glDisable(GL11.GL_LIGHTING);
- }
- if(items.size() > 9 && items.get(9) != null){
- gui.renderItem(items.get(9), x + 45, y + 57, 30f);
- name.add(items.get(9).getDisplayName());
- if(mouseX >= x + 40 && mouseX <= x + 16 + 40 && mouseY >= y + 47 && mouseY <= y + 47 + 16) gui.drawHoverString(name, x + 45, y + 47);
- name.removeAll(name);
- GL11.glDisable(GL11.GL_LIGHTING);
- }
- for(int i = 0; i < text.size(); i++) gui.getFont().drawString(text.get(i), x, y + 62 + i*12, 0);
- GL11.glColor4f(1, 1, 1, 1);
- }
- }
-
- public static void addSmeltingRecipeTextPage(GuiGuide gui, int x, int y, ArrayList<String> text, ArrayList<ItemStack> items, int mouseX, int mouseY)
- {
- ArrayList<String> name = new ArrayList<String>();
- gui.getFont().drawString(EnumChatFormatting.DARK_BLUE + "\u00a7n" + items.get(1).getDisplayName(), x + Math.abs(70 - gui.getFont().getStringWidth(items.get(0).getDisplayName())/2), y + 2, 0);
- GL11.glColor4f(1, 1, 1, 1);
- Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation("jewelrycraft", "textures/gui/guidePageFlip" + ".png"));
- gui.drawTexturedModalRect(x, y + 10, 145, 100, 111, 46);
-
- gui.renderItem(items.get(0), x + 13, y + 20 + 10, 50f);
- name.add(items.get(0).getDisplayName());
- if(mouseX >= x && mouseX <= x + 20 && mouseY >= y + 20 && mouseY <= y + 20 + 16) gui.drawHoverString(name, x, y + 20);
- name.removeAll(name);
- GL11.glDisable(GL11.GL_LIGHTING);
-
- gui.renderItem(items.get(1), x + 77, y + 28 + 10, 50f);
-
- for(int i = 0; i < text.size(); i++) gui.getFont().drawString(text.get(i), x, y + 60 + i*12, 0);
- GL11.glColor4f(1, 1, 1, 1);
- }
-
- public static void addImageTextPage(GuiGuide gui, int x, int y, ItemStack item, ArrayList<String> text, float size)
- {
- y+=5;
- gui.getFont().drawString(EnumChatFormatting.DARK_BLUE + "\u00a7n" + item.getDisplayName(), x + Math.abs(70 - gui.getFont().getStringWidth(item.getDisplayName())/2) - 10, y + 2, 0);
- GL11.glColor4f(1, 1, 1, 1);
- gui.renderItem(item, x + 13, y + 18, size);
- for(int i = 0; i < text.size(); i++) gui.getFont().drawString(text.get(i), x, y + 30 + i*12, 0);
- }
-
- public static void addImageTextPage(GuiGuide gui, int x, int y, ItemStack item, ArrayList<String> text, float size, int txtX, int txtY, boolean showName, int imgX, int imgY)
- {
- y+=5;
- if(showName) gui.getFont().drawString(EnumChatFormatting.DARK_BLUE + "\u00a7n" + item.getDisplayName(), x + Math.abs(70 - gui.getFont().getStringWidth(item.getDisplayName())/2) - 10, y + 2, 0);
- GL11.glColor4f(1, 1, 1, 1);
- gui.renderItem(item, x + 13 + imgX, y + 18 + imgY, size);
- for(int i = 0; i < text.size(); i++) gui.getFont().drawString(text.get(i), x + txtX, y + 30 + txtY + i*12, 0);
- }
-
- public static void addTextPage(GuiGuide gui, int x, int y, ArrayList<String> text)
- {
- y-=25;
- for(int i = 0; i < text.size(); i++) gui.getFont().drawString(text.get(i), x, y + 30 + i*12, 0);
- GL11.glColor4f(1, 1, 1, 1);
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/container/SlotRingChest.java b/src/main/java/darkknight/jewelrycraft/container/SlotRingChest.java
deleted file mode 100644
index 576dee7..0000000
--- a/src/main/java/darkknight/jewelrycraft/container/SlotRingChest.java
+++ /dev/null
@@ -1,39 +0,0 @@
-package darkknight.jewelrycraft.container;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.inventory.IInventory;
-import net.minecraft.inventory.Slot;
-import net.minecraft.item.ItemStack;
-
-public class SlotRingChest extends Slot
-{
- public boolean locked = false;
-
- public SlotRingChest(IInventory tile, int slotID, int x, int y, boolean locked)
- {
- super(tile, slotID, x, y);
- this.locked = locked;
- }
-
- @Override
- public boolean isItemValid(ItemStack stack)
- {
- return !locked;
- }
-
- @Override
- public ItemStack decrStackSize(int amount)
- {
- if (!locked)
- {
- return super.decrStackSize(amount);
- }
- return null;
- }
-
- @Override
- public boolean canTakeStack(EntityPlayer player)
- {
- return !locked;
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/events/BucketHandler.java b/src/main/java/darkknight/jewelrycraft/events/BucketHandler.java
deleted file mode 100644
index cf16847..0000000
--- a/src/main/java/darkknight/jewelrycraft/events/BucketHandler.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/**
- * Copyright (c) SpaceToad, 2011 http://www.mod-buildcraft.com
- *
- * BuildCraft is distributed under the terms of the Minecraft Mod Public License
- * 1.0, or MMPL. Please check the contents of the license located in
- * http://www.mod-buildcraft.com/MMPL-1.0.txt
- */
-package darkknight.jewelrycraft.events;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import net.minecraft.block.Block;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.MovingObjectPosition;
-import net.minecraft.world.World;
-import net.minecraftforge.event.entity.player.FillBucketEvent;
-import cpw.mods.fml.common.eventhandler.Event.Result;
-import cpw.mods.fml.common.eventhandler.SubscribeEvent;
-import darkknight.jewelrycraft.JewelrycraftMod;
-import darkknight.jewelrycraft.block.BlockMoltenMetal;
-import darkknight.jewelrycraft.util.JewelryNBT;
-
-public class BucketHandler {
-
- public static BucketHandler INSTANCE = new BucketHandler();
- public Map<Block, Item> buckets = new HashMap<Block, Item>();
-
- private BucketHandler() {
- }
-
- @SubscribeEvent
- public void onBucketFill(FillBucketEvent event) {
-
- ItemStack result = fillCustomBucket(event.world, event.target);
-
- if (result == null)
- return;
-
- event.result = result;
- event.setResult(Result.ALLOW);
- }
-
-
- private ItemStack fillCustomBucket(World world, MovingObjectPosition pos) {
-
- Block block = world.getBlock(pos.blockX, pos.blockY, pos.blockZ);
-
- Item bucket = buckets.get(block);
- if (bucket != null && world.getBlockMetadata(pos.blockX, pos.blockY, pos.blockZ) == 0) {
- world.setBlockToAir(pos.blockX, pos.blockY, pos.blockZ);
- ItemStack item = new ItemStack(bucket);
- JewelryNBT.addMetal(item, new ItemStack(Item.getItemById(JewelrycraftMod.saveData.getInteger(BlockMoltenMetal.coords(pos.blockX, pos.blockY, pos.blockZ)))));
- return item;
- } else
- return null;
-
- }
-} \ No newline at end of file
diff --git a/src/main/java/darkknight/jewelrycraft/events/EntityEventHandler.java b/src/main/java/darkknight/jewelrycraft/events/EntityEventHandler.java
deleted file mode 100644
index 42dc5a7..0000000
--- a/src/main/java/darkknight/jewelrycraft/events/EntityEventHandler.java
+++ /dev/null
@@ -1,100 +0,0 @@
-package darkknight.jewelrycraft.events;
-
-import java.io.EOFException;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileOutputStream;
-import java.io.IOException;
-
-import net.minecraft.client.Minecraft;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.CompressedStreamTools;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraftforge.event.entity.EntityJoinWorldEvent;
-import net.minecraftforge.event.world.WorldEvent;
-import cpw.mods.fml.common.FMLCommonHandler;
-import cpw.mods.fml.common.event.FMLPreInitializationEvent;
-import cpw.mods.fml.common.eventhandler.SubscribeEvent;
-import darkknight.jewelrycraft.JewelrycraftMod;
-import darkknight.jewelrycraft.item.ItemList;
-import darkknight.jewelrycraft.util.BlockUtils;
-import darkknight.jewelrycraft.util.PlayerUtils;
-
-/**
- * Code taken from OpenBlocks
- */
-
-public class EntityEventHandler
-{
- public static final String OPENBLOCKS_PERSIST_TAG = "Jewelrycraft";
- public static final String GIVEN_GUIDE_TAG = "givenGuive";
-
- @SubscribeEvent
- public void onEntityJoinWorld(EntityJoinWorldEvent event)
- {
- final Entity entity = event.entity;
-
- if (!event.world.isRemote && entity instanceof EntityPlayer)
- {
- EntityPlayer player = (EntityPlayer)entity;
- NBTTagCompound persistTag = PlayerUtils.getModPlayerPersistTag(player, "Jewelrycraft");
-
- boolean shouldGiveManual = ItemList.guide != null && !persistTag.getBoolean(GIVEN_GUIDE_TAG);
- if (shouldGiveManual)
- {
- ItemStack manual = new ItemStack(ItemList.guide);
- if (!player.inventory.addItemStackToInventory(manual))
- {
- BlockUtils.dropItemStackInWorld(player.worldObj, player.posX, player.posY, player.posZ, manual);
- }
- persistTag.setBoolean(GIVEN_GUIDE_TAG, true);
- }
- }
- }
-
- @SubscribeEvent
- public void onWorldLoad(WorldEvent.Load event)
- {
- if(!event.world.isRemote)
- {
- new File(JewelrycraftMod.dir + File.separator + "Jewelrycraft").mkdirs();
- JewelrycraftMod.liquidsConf = new File(JewelrycraftMod.dir + File.separator + "Jewelrycraft", "JLP" + event.world.getWorldInfo().getWorldName() + ".cfg");
- try {
- if(!JewelrycraftMod.liquidsConf.exists()) JewelrycraftMod.liquidsConf.createNewFile();
- } catch (IOException e) {
- e.printStackTrace();
- }
- }
-
- if(FMLCommonHandler.instance().getEffectiveSide().isServer())
- {
- try {
- if(JewelrycraftMod.liquidsConf.exists())
- JewelrycraftMod.saveData = CompressedStreamTools.readCompressed(new FileInputStream(JewelrycraftMod.liquidsConf));
- } catch (EOFException e) {
- e.printStackTrace();
- } catch (IOException e) {
- e.printStackTrace();
- }
- }
-
- }
-
- @SubscribeEvent
- public void onWorldSave(WorldEvent.Save event)
- {
- if(FMLCommonHandler.instance().getEffectiveSide().isServer())
- {
- try {
- if(JewelrycraftMod.liquidsConf.exists())
- CompressedStreamTools.writeCompressed(JewelrycraftMod.saveData, new FileOutputStream(JewelrycraftMod.liquidsConf));
- } catch (EOFException e) {
- e.printStackTrace();
- } catch (IOException e) {
- e.printStackTrace();
- }
- }
- }
-} \ No newline at end of file
diff --git a/src/main/java/darkknight/jewelrycraft/events/EventHandler.java b/src/main/java/darkknight/jewelrycraft/events/EventHandler.java
deleted file mode 100644
index 019deab..0000000
--- a/src/main/java/darkknight/jewelrycraft/events/EventHandler.java
+++ /dev/null
@@ -1,65 +0,0 @@
-package darkknight.jewelrycraft.events;
-
-import java.io.File;
-import java.io.FileOutputStream;
-import java.io.IOException;
-
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.CompressedStreamTools;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.world.WorldServer;
-import net.minecraftforge.event.entity.EntityJoinWorldEvent;
-import net.minecraftforge.event.world.WorldEvent;
-import darkknight.jewelrycraft.JewelrycraftMod;
-import darkknight.jewelrycraft.item.ItemList;
-import darkknight.jewelrycraft.util.BlockUtils;
-import darkknight.jewelrycraft.util.PlayerUtils;
-import cpw.mods.fml.common.FMLCommonHandler;
-import cpw.mods.fml.common.eventhandler.SubscribeEvent;
-
-/**
- * Code taken from OpenBlocks
- */
-public class EventHandler
-{
- public static final String OPENBLOCKS_PERSIST_TAG = "Jewelrycraft";
- public static final String GIVEN_GUIDE_TAG = "givenGuive";
-
- @SubscribeEvent
- public void onEntityJoinWorld(EntityJoinWorldEvent event)
- {
- final Entity entity = event.entity;
- /**
- * If the player hasn't been given a manual, we'll give him one! (or
- * throw it on the floor..)
- */
- if (!event.world.isRemote && entity instanceof EntityPlayer)
- {
- EntityPlayer player = (EntityPlayer)entity;
- NBTTagCompound persistTag = PlayerUtils.getModPlayerPersistTag(player, "Jewelrycraft");
-
- boolean shouldGiveManual = ItemList.guide != null && !persistTag.getBoolean(GIVEN_GUIDE_TAG);
- if (shouldGiveManual)
- {
- ItemStack manual = new ItemStack(ItemList.guide);
- if (!player.inventory.addItemStackToInventory(manual))
- {
- BlockUtils.dropItemStackInWorld(player.worldObj, player.posX, player.posY, player.posZ, manual);
- }
- persistTag.setBoolean(GIVEN_GUIDE_TAG, true);
- }
- }
- }
-
- @SubscribeEvent
- public void onWorldLoad(WorldEvent.Load event)
- {
- }
-
- @SubscribeEvent
- public void onWorldSave(WorldEvent.Save event)
- {
- }
-} \ No newline at end of file
diff --git a/src/main/java/darkknight/jewelrycraft/item/ItemClayMolds.java b/src/main/java/darkknight/jewelrycraft/item/ItemClayMolds.java
deleted file mode 100644
index 323a298..0000000
--- a/src/main/java/darkknight/jewelrycraft/item/ItemClayMolds.java
+++ /dev/null
@@ -1,72 +0,0 @@
-package darkknight.jewelrycraft.item;
-
-import java.util.List;
-
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.creativetab.CreativeTabs;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IIcon;
-import net.minecraft.util.MathHelper;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class ItemClayMolds extends Item
-{
- /** List of molds color names */
- public static final String[] moldsItemNames = new String[] { "clayIngot", "clayRing", "clayNecklace" };
- @SideOnly(Side.CLIENT)
- private IIcon[] moldsIcons;
-
- public ItemClayMolds()
- {
- super();
- this.setHasSubtypes(true);
- this.setMaxDamage(0);
- this.setMaxStackSize(1);
- }
-
- @SideOnly(Side.CLIENT)
- /**
- * Gets an icon index based on an item's damage value
- */
- public IIcon getIconFromDamage(int par1)
- {
- int j = MathHelper.clamp_int(par1, 0, moldsItemNames.length - 1);
- return this.moldsIcons[j];
- }
-
- /**
- * Returns the unlocalized name of this item. This version accepts an ItemStack so different stacks can have different names based on
- * their damage or NBT.
- */
- public String getUnlocalizedNameInefficiently(ItemStack par1ItemStack)
- {
- int i = MathHelper.clamp_int(par1ItemStack.getItemDamage(), 0, moldsItemNames.length - 1);
- return super.getUnlocalizedName() + "." + moldsItemNames[i];
- }
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- @SideOnly(Side.CLIENT)
- /**
- * returns a list of items with the same ID, but different meta (eg: molds returns 16 items)
- */
- public void getSubItems(Item par1, CreativeTabs par2CreativeTabs, List par3List)
- {
- for (int j = 0; j < moldsItemNames.length; ++j)
- {
- par3List.add(new ItemStack(par1, 1, j));
- }
- }
-
- @SideOnly(Side.CLIENT)
- public void registerIcons(IIconRegister par1IconRegister)
- {
- this.moldsIcons = new IIcon[moldsItemNames.length];
-
- for (int i = 0; i < moldsItemNames.length; ++i)
- {
- this.moldsIcons[i] = par1IconRegister.registerIcon("jewelrycraft:" + moldsItemNames[i] + this.getIconString());
- }
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/item/ItemCrystal.java b/src/main/java/darkknight/jewelrycraft/item/ItemCrystal.java
deleted file mode 100644
index 2009309..0000000
--- a/src/main/java/darkknight/jewelrycraft/item/ItemCrystal.java
+++ /dev/null
@@ -1,58 +0,0 @@
-package darkknight.jewelrycraft.item;
-
-import java.util.List;
-
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.creativetab.CreativeTabs;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IIcon;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class ItemCrystal extends Item
-{
- public IIcon overlay;
- public static final int[] dyeColors = new int[] {1973019, 11743532, 3887386, 5320730, 2437522, 8073150, 2651799, 11250603, 4408131, 14188952, 4312372, 14602026, 6719955, 12801229, 15435844, 15790320};
-
- public ItemCrystal()
- {
- super();
- this.setHasSubtypes(true);
- this.setMaxDamage(0);
- }
-
- public void registerIcons(IIconRegister iconRegister)
- {
- itemIcon = iconRegister.registerIcon("jewelrycraft:crystal");
- overlay = iconRegister.registerIcon("jewelrycraft:crystalOverlay");
- }
-
- @Override
- public boolean requiresMultipleRenderPasses()
- {
- return true;
- }
-
- @SideOnly(Side.CLIENT)
- public int getColorFromItemStack(ItemStack stack, int pass)
- {
- if(pass == 1 && this.getDamage(stack) != 16) return dyeColors[this.getDamage(stack)];
- return 16777215;
- }
-
- public IIcon getIcon(ItemStack stack, int pass)
- {
- return pass == 0 ? itemIcon : overlay;
- }
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- public void getSubItems(Item par1, CreativeTabs par2CreativeTabs, List par3List)
- {
- for (int j = 0; j < 16; ++j)
- {
- par3List.add(new ItemStack(par1, 1, j));
- }
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/item/ItemGuide.java b/src/main/java/darkknight/jewelrycraft/item/ItemGuide.java
deleted file mode 100644
index b4d300d..0000000
--- a/src/main/java/darkknight/jewelrycraft/item/ItemGuide.java
+++ /dev/null
@@ -1,26 +0,0 @@
-package darkknight.jewelrycraft.item;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.World;
-import darkknight.jewelrycraft.JewelrycraftMod;
-
-public class ItemGuide extends Item
-{
- public ItemGuide()
- {
- super();
- }
-
- @Override
- public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player)
- {
- if (world.isRemote)
- {
- player.openGui(JewelrycraftMod.instance, 1, player.worldObj, 0, 0, 0);
- }
-
- return stack;
- }
-} \ No newline at end of file
diff --git a/src/main/java/darkknight/jewelrycraft/item/ItemList.java b/src/main/java/darkknight/jewelrycraft/item/ItemList.java
deleted file mode 100644
index 1113a55..0000000
--- a/src/main/java/darkknight/jewelrycraft/item/ItemList.java
+++ /dev/null
@@ -1,73 +0,0 @@
-package darkknight.jewelrycraft.item;
-
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.fluids.FluidContainerRegistry;
-import net.minecraftforge.fluids.FluidRegistry;
-import net.minecraftforge.fluids.FluidStack;
-import cpw.mods.fml.common.event.FMLPreInitializationEvent;
-import cpw.mods.fml.common.registry.GameRegistry;
-import darkknight.jewelrycraft.JewelrycraftMod;
-import darkknight.jewelrycraft.block.BlockList;
-
-public class ItemList
-{
- public static Item thiefGloves;
- public static Item shadowIngot, ingot2, ingot3, ingot4, ingot5, ingot6, ingot7;
- public static Item molds;
- public static Item clayMolds;
- public static Item crystal;
- public static ItemRing ring;
- public static ItemNecklace necklace;
- public static Item guide;
- public static ItemMoltenMetalBucket bucket;
- public static ItemMoltenMetal metal;
-
- private static boolean isInitialized = false;
-
- public static void preInit(FMLPreInitializationEvent e)
- {
- if (!isInitialized)
- {
- thiefGloves = new ItemThiefGloves().setUnlocalizedName("Jewelrycraft.thiefGloves").setTextureName("jewelrycraft:thiefGloves").setCreativeTab(JewelrycraftMod.jewelrycraft);
- shadowIngot = new Item().setUnlocalizedName("Jewelrycraft.ingotShadow").setTextureName("jewelrycraft:ingotShadow").setCreativeTab(JewelrycraftMod.jewelrycraft);
- molds = new ItemMolds().setUnlocalizedName("Jewelrycraft.mold").setTextureName("Mold").setCreativeTab(JewelrycraftMod.jewelrycraft);
- clayMolds = new ItemClayMolds().setUnlocalizedName("Jewelrycraft.mold").setTextureName("Mold").setCreativeTab(JewelrycraftMod.jewelrycraft);
- ring = (ItemRing) new ItemRing().setUnlocalizedName("Jewelrycraft.ring").setTextureName("jewelrycraft:ring");
- crystal = new ItemCrystal().setUnlocalizedName("Jewelrycraft.crystal").setTextureName("jewelrycraft:crystal").setCreativeTab(JewelrycraftMod.jewelrycraft);
- necklace = (ItemNecklace) new ItemNecklace().setUnlocalizedName("Jewelrycraft.necklace").setTextureName("jewelrycraft:necklace");
- guide = new ItemGuide().setUnlocalizedName("Jewelrycraft.guide").setTextureName("jewelrycraft:guide").setCreativeTab(JewelrycraftMod.jewelrycraft);
- bucket = (ItemMoltenMetalBucket) new ItemMoltenMetalBucket().setUnlocalizedName("Jewelrycraft.bucket");
- metal = (ItemMoltenMetal) new ItemMoltenMetal().setUnlocalizedName("Jewelrycraft.bucket");
-
- // Test Ingots
- ingot2 = new Item().setUnlocalizedName("Jewelrycraft.ingot2").setTextureName("jewelrycraft:test/ingot2").setCreativeTab(JewelrycraftMod.jewelrycraft);
- ingot3 = new Item().setUnlocalizedName("Jewelrycraft.ingot3").setTextureName("jewelrycraft:ingot3").setCreativeTab(JewelrycraftMod.jewelrycraft);
- ingot4 = new Item().setUnlocalizedName("Jewelrycraft.ingot4").setTextureName("jewelrycraft:ingot4").setCreativeTab(JewelrycraftMod.jewelrycraft);
- ingot5 = new Item().setUnlocalizedName("Jewelrycraft.ingot5").setTextureName("jewelrycraft:test/ingot5").setCreativeTab(JewelrycraftMod.jewelrycraft);
- ingot6 = new Item().setUnlocalizedName("Jewelrycraft.ingot6").setTextureName("jewelrycraft:ingot6").setCreativeTab(JewelrycraftMod.jewelrycraft);
- ingot7 = new Item().setUnlocalizedName("Jewelrycraft.ingot7").setTextureName("jewelrycraft:ingot7").setCreativeTab(JewelrycraftMod.jewelrycraft);
-
- GameRegistry.registerItem(thiefGloves, "thiefGloves");
- GameRegistry.registerItem(shadowIngot, "shadowIngot");
- GameRegistry.registerItem(molds, "molds");
- GameRegistry.registerItem(clayMolds, "clayMolds");
- GameRegistry.registerItem(ring, "ring");
- GameRegistry.registerItem(necklace, "necklace");
- GameRegistry.registerItem(crystal, "crystal");
- GameRegistry.registerItem(guide, "guide");
- GameRegistry.registerItem(bucket, "moltenMetalBucket");
- GameRegistry.registerItem(metal, "moltenMetal");
-
- GameRegistry.registerItem(ingot2, "ingot2");
- GameRegistry.registerItem(ingot3, "ingot3");
- GameRegistry.registerItem(ingot4, "ingot4");
- GameRegistry.registerItem(ingot5, "ingot5");
- GameRegistry.registerItem(ingot6, "ingot6");
- GameRegistry.registerItem(ingot7, "ingot7");
-
- isInitialized = true;
- }
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/item/ItemMolds.java b/src/main/java/darkknight/jewelrycraft/item/ItemMolds.java
deleted file mode 100644
index 0ebb5d1..0000000
--- a/src/main/java/darkknight/jewelrycraft/item/ItemMolds.java
+++ /dev/null
@@ -1,72 +0,0 @@
-package darkknight.jewelrycraft.item;
-
-import java.util.List;
-
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.creativetab.CreativeTabs;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IIcon;
-import net.minecraft.util.MathHelper;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-public class ItemMolds extends Item
-{
- /** List of molds color names */
- public static final String[] moldsItemNames = new String[] { "ingot", "ring", "necklace" };
- @SideOnly(Side.CLIENT)
- private IIcon[] moldsIcons;
-
- public ItemMolds()
- {
- super();
- this.setHasSubtypes(true);
- this.setMaxDamage(0);
- this.setMaxStackSize(1);
- }
-
- @SideOnly(Side.CLIENT)
- /**
- * Gets an icon index based on an item's damage value
- */
- public IIcon getIconFromDamage(int par1)
- {
- int j = MathHelper.clamp_int(par1, 0, moldsItemNames.length - 1);
- return this.moldsIcons[j];
- }
-
- /**
- * Returns the unlocalized name of this item. This version accepts an ItemStack so different stacks can have different names based on
- * their damage or NBT.
- */
- public String getUnlocalizedName(ItemStack par1ItemStack)
- {
- int i = MathHelper.clamp_int(par1ItemStack.getItemDamage(), 0, moldsItemNames.length - 1);
- return super.getUnlocalizedName() + "." + moldsItemNames[i];
- }
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- @SideOnly(Side.CLIENT)
- /**
- * returns a list of items with the same ID, but different meta (eg: molds returns 16 items)
- */
- public void getSubItems(Item par1, CreativeTabs par2CreativeTabs, List par3List)
- {
- for (int j = 0; j < moldsItemNames.length; ++j)
- {
- par3List.add(new ItemStack(par1, 1, j));
- }
- }
-
- @SideOnly(Side.CLIENT)
- public void registerIcons(IIconRegister par1IconRegister)
- {
- this.moldsIcons = new IIcon[moldsItemNames.length];
-
- for (int i = 0; i < moldsItemNames.length; ++i)
- {
- this.moldsIcons[i] = par1IconRegister.registerIcon("jewelrycraft:" + moldsItemNames[i] + this.getIconString());
- }
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/item/ItemMoltenMetal.java b/src/main/java/darkknight/jewelrycraft/item/ItemMoltenMetal.java
deleted file mode 100644
index 81c1614..0000000
--- a/src/main/java/darkknight/jewelrycraft/item/ItemMoltenMetal.java
+++ /dev/null
@@ -1,128 +0,0 @@
-package darkknight.jewelrycraft.item;
-
-import java.awt.image.BufferedImage;
-import java.io.IOException;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-import java.util.Random;
-
-import javax.imageio.ImageIO;
-
-import net.minecraft.block.Block;
-import net.minecraft.block.BlockChest;
-import net.minecraft.block.BlockSkull;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.client.resources.IResourceManager;
-import net.minecraft.enchantment.Enchantment;
-import net.minecraft.enchantment.EnchantmentHelper;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.entity.monster.EntityIronGolem;
-import net.minecraft.entity.monster.EntitySnowman;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.inventory.InventoryEnderChest;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.potion.Potion;
-import net.minecraft.potion.PotionEffect;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.tileentity.TileEntityChest;
-import net.minecraft.tileentity.TileEntitySkull;
-import net.minecraft.util.ChatComponentText;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.IIcon;
-import net.minecraft.util.MathHelper;
-import net.minecraft.util.ResourceLocation;
-import net.minecraft.util.StatCollector;
-import net.minecraft.world.World;
-import cpw.mods.fml.common.network.internal.FMLNetworkHandler;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import darkknight.jewelrycraft.JewelrycraftMod;
-import darkknight.jewelrycraft.block.BlockList;
-import darkknight.jewelrycraft.util.JewelryNBT;
-
-public class ItemMoltenMetal extends Item
-{
- private int amplifier, cooldown = 0;
- int index = 0;
-
- public ItemMoltenMetal()
- {
- super();
- this.setMaxStackSize(1);
- }
-
- public void registerIcons(IIconRegister iconRegister)
- {
- itemIcon = iconRegister.registerIcon("jewelrycraft:moltenMetalStill");
- }
-
- @SideOnly(Side.CLIENT)
- public int getColorFromItemStack(ItemStack stack, int pass)
- {
- try
- {
- return color(stack, pass);
- }
- catch (IOException e)
- {
- e.printStackTrace();
- }
- return 16777215;
- }
-
- public static int color(ItemStack stack, int pass) throws IOException
- {
- String domain = "", texture;
- IResourceManager rm = Minecraft.getMinecraft().getResourceManager();
- BufferedImage icon;
- int x=0, y=0, ok = 0, red, green, blue;
- if (stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && JewelryNBT.ingot(stack) != null && JewelryNBT.ingot(stack) != new ItemStack(Item.getItemById(0), 0, 0) && JewelryNBT.ingot(stack).getIconIndex() != null && JewelryNBT.ingotColor(stack) == 16777215)
- {
- String ingotIconName = JewelryNBT.ingot(stack).getIconIndex().getIconName();
-
- if (ingotIconName.substring(0, ingotIconName.indexOf(":") + 1) != "") domain = ingotIconName.substring(0, ingotIconName.indexOf(":") + 1).replace(":", " ").trim();
- else domain = "minecraft";
-
- texture = ingotIconName.substring(ingotIconName.lastIndexOf(":") + 1) + ".png";
- ResourceLocation ingot = null;
-
- if (JewelryNBT.ingot(stack).getUnlocalizedName().contains("item")) ingot = new ResourceLocation(domain, "textures/items/" + texture);
- else ingot = new ResourceLocation(domain, "textures/blocks/" + texture);
-
- icon = ImageIO.read(rm.getResource(ingot).getInputStream());
- while(ok == 0)
- {
- red = (icon.getRGB(x, y) >> 16) & 0xFF;
- green = (icon.getRGB(x, y) >> 8) & 0xFF;
- blue = icon.getRGB(x, y) & 0xFF;
- if(!isColorPretty(red, green, blue))
- {
- if(x<icon.getTileWidth()-1) x++;
- if(x>=icon.getTileWidth()-1 && y<icon.getTileWidth()-1)
- {
- x=0;
- y++;
- }
- if(x == icon.getTileWidth()-1 && y==icon.getTileWidth()-1) ok=1;
- }
- else ok=1;
- }
- JewelryNBT.addIngotColor(stack, icon.getRGB(x, y));
- }
- if(JewelryNBT.ingot(stack) != null) return JewelryNBT.ingotColor(stack);
- return 16777215;
- }
-
- public static boolean isColorPretty(int r, int g, int b)
- {
- if((r > 80 || g > 80 || b > 80) || (r > 80 && g > 80 && b > 80 && r < 230 && b < 230 && g < 230)) return true;
- else return false;
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/item/ItemMoltenMetalBucket.java b/src/main/java/darkknight/jewelrycraft/item/ItemMoltenMetalBucket.java
deleted file mode 100644
index bd1ea72..0000000
--- a/src/main/java/darkknight/jewelrycraft/item/ItemMoltenMetalBucket.java
+++ /dev/null
@@ -1,309 +0,0 @@
-package darkknight.jewelrycraft.item;
-
-import java.awt.image.BufferedImage;
-import java.io.FileInputStream;
-import java.io.FileOutputStream;
-import java.io.IOException;
-
-import javax.imageio.ImageIO;
-
-import net.minecraft.block.material.Material;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.client.resources.IResourceManager;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.CompressedStreamTools;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.IIcon;
-import net.minecraft.util.MovingObjectPosition;
-import net.minecraft.util.ResourceLocation;
-import net.minecraft.util.StatCollector;
-import net.minecraft.world.World;
-import net.minecraft.world.storage.WorldInfo;
-import net.minecraftforge.common.MinecraftForge;
-import net.minecraftforge.event.entity.player.FillBucketEvent;
-import cpw.mods.fml.common.eventhandler.Event;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import darkknight.jewelrycraft.JewelrycraftMod;
-import darkknight.jewelrycraft.block.BlockList;
-import darkknight.jewelrycraft.block.BlockMoltenMetal;
-import darkknight.jewelrycraft.util.JewelryNBT;
-import darkknight.jewelrycraft.util.JewelrycraftUtil;
-
-public class ItemMoltenMetalBucket extends Item
-{
- public IIcon liquid;
- public ItemMoltenMetalBucket()
- {
- this.maxStackSize = 1;
- }
-
- /**
- * Called whenever this item is equipped and the right mouse button is pressed. Args: itemStack, world, entityPlayer
- */
- public ItemStack onItemRightClick(ItemStack stack, World par2World, EntityPlayer par3EntityPlayer)
- {
- boolean flag = BlockList.moltenMetal == Blocks.air;
- MovingObjectPosition movingobjectposition = this.getMovingObjectPositionFromPlayer(par2World, par3EntityPlayer, flag);
-
- if (movingobjectposition == null)
- {
- return stack;
- }
- else
- {
- FillBucketEvent event = new FillBucketEvent(par3EntityPlayer, stack, par2World, movingobjectposition);
- if (MinecraftForge.EVENT_BUS.post(event))
- {
- return stack;
- }
-
- if (event.getResult() == Event.Result.ALLOW)
- {
- if (par3EntityPlayer.capabilities.isCreativeMode)
- {
- return stack;
- }
-
- if (--stack.stackSize <= 0)
- {
- return event.result;
- }
-
- if (!par3EntityPlayer.inventory.addItemStackToInventory(event.result))
- {
- par3EntityPlayer.dropPlayerItemWithRandomChoice(event.result, false);
- }
-
- return stack;
- }
- if (movingobjectposition.typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK)
- {
- int i = movingobjectposition.blockX;
- int j = movingobjectposition.blockY;
- int k = movingobjectposition.blockZ;
-
- if (!par2World.canMineBlock(par3EntityPlayer, i, j, k))
- {
- return stack;
- }
-
- if (flag)
- {
- if (!par3EntityPlayer.canPlayerEdit(i, j, k, movingobjectposition.sideHit, stack))
- {
- return stack;
- }
-
- Material material = par2World.getBlock(i, j, k).getMaterial();
- int l = par2World.getBlockMetadata(i, j, k);
- par2World.setBlockToAir(i, j, k);
- return this.func_150910_a(stack, par3EntityPlayer, ItemList.bucket);
- }
- else
- {
- if (BlockList.moltenMetal == Blocks.air)
- {
- return new ItemStack(Items.bucket);
- }
-
- if (movingobjectposition.sideHit == 0)
- {
- --j;
- }
-
- if (movingobjectposition.sideHit == 1)
- {
- ++j;
- }
-
- if (movingobjectposition.sideHit == 2)
- {
- --k;
- }
-
- if (movingobjectposition.sideHit == 3)
- {
- ++k;
- }
-
- if (movingobjectposition.sideHit == 4)
- {
- --i;
- }
-
- if (movingobjectposition.sideHit == 5)
- {
- ++i;
- }
-
- if (!par3EntityPlayer.canPlayerEdit(i, j, k, movingobjectposition.sideHit, stack))
- {
- return stack;
- }
-
- try {
- if (this.tryPlaceContainedLiquid(par2World, i, j, k, stack) && !par3EntityPlayer.capabilities.isCreativeMode)
- {
- return new ItemStack(Items.bucket);
- }
- } catch (IOException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- }
- }
-
- return stack;
- }
- }
-
- private ItemStack func_150910_a(ItemStack p_150910_1_, EntityPlayer p_150910_2_, Item p_150910_3_)
- {
- if (p_150910_2_.capabilities.isCreativeMode)
- {
- return p_150910_1_;
- }
- else if (--p_150910_1_.stackSize <= 0)
- {
- return new ItemStack(p_150910_3_);
- }
- else
- {
- if (!p_150910_2_.inventory.addItemStackToInventory(new ItemStack(p_150910_3_)))
- {
- p_150910_2_.dropPlayerItemWithRandomChoice(new ItemStack(p_150910_3_, 1, 0), false);
- }
-
- return p_150910_1_;
- }
- }
-
- /**
- * Attempts to place the liquid contained inside the bucket.
- * @throws IOException
- */
- public boolean tryPlaceContainedLiquid(World par1World, int par2, int par3, int par4, ItemStack stack) throws IOException
- {
- if (BlockList.moltenMetal == Blocks.air)
- {
- return false;
- }
- else
- {
- Material material = par1World.getBlock(par2, par3, par4).getMaterial();
- boolean flag = !material.isSolid();
-
- if (!par1World.isAirBlock(par2, par3, par4) && !flag) return false;
- else
- {
- if (!par1World.isRemote && flag && !material.isLiquid()) par1World.func_147480_a(par2, par3, par4, true);
-
- JewelrycraftMod.saveData.setInteger(String.valueOf(par2) + " " + String.valueOf(par3) + " " + String.valueOf(par4), Item.getIdFromItem(JewelryNBT.ingot(stack).getItem()));
-
- par1World.setBlock(par2, par3, par4, BlockList.moltenMetal, 0, 3);
- return true;
- }
- }
- }
-
- public void registerIcons(IIconRegister iconRegister)
- {
- itemIcon = iconRegister.registerIcon("bucket_empty");
- liquid = iconRegister.registerIcon("jewelrycraft:bucketOverlay");
- }
-
- @SideOnly(Side.CLIENT)
- public int getColorFromItemStack(ItemStack stack, int pass)
- {
- try
- {
- return color(stack, pass);
- }
- catch (IOException e)
- {
- e.printStackTrace();
- }
- return 16777215;
- }
-
- @Override
- public boolean requiresMultipleRenderPasses()
- {
- return true;
- }
-
- public IIcon getIcon(ItemStack stack, int pass)
- {
- if(pass == 0) return itemIcon;
- if(pass == 1) return liquid;
- return itemIcon;
- }
-
- public static int color(ItemStack stack, int pass) throws IOException
- {
- String domain = "", texture;
- IResourceManager rm = Minecraft.getMinecraft().getResourceManager();
- BufferedImage icon;
- int x=0, y=0, ok = 0, red, green, blue;
- if (pass == 1 && JewelryNBT.ingot(stack) != null && JewelryNBT.ingot(stack).getIconIndex() != null && JewelryNBT.ingotColor(stack) == 16777215)
- {
- String ingotIconName = JewelryNBT.ingot(stack).getIconIndex().getIconName();
-
- if (ingotIconName.substring(0, ingotIconName.indexOf(":") + 1) != "") domain = ingotIconName.substring(0, ingotIconName.indexOf(":") + 1).replace(":", " ").trim();
- else domain = "minecraft";
-
- texture = ingotIconName.substring(ingotIconName.lastIndexOf(":") + 1) + ".png";
- ResourceLocation ingot = null;
-
- if (JewelryNBT.ingot(stack).getUnlocalizedName().contains("item")) ingot = new ResourceLocation(domain, "textures/items/" + texture);
- else ingot = new ResourceLocation(domain, "textures/blocks/" + texture);
-
- icon = ImageIO.read(rm.getResource(ingot).getInputStream());
- while(ok == 0)
- {
- red = (icon.getRGB(x, y) >> 16) & 0xFF;
- green = (icon.getRGB(x, y) >> 8) & 0xFF;
- blue = icon.getRGB(x, y) & 0xFF;
- if(!isColorPretty(red, green, blue))
- {
- if(x<icon.getTileWidth()-1) x++;
- if(x>=icon.getTileWidth()-1 && y<icon.getTileWidth()-1)
- {
- x=0;
- y++;
- }
- if(x == icon.getTileWidth()-1 && y==icon.getTileWidth()-1) ok=1;
- }
- else ok=1;
- }
- JewelryNBT.addIngotColor(stack, icon.getRGB(x, y));
- }
- if(JewelryNBT.ingot(stack) != null && pass == 1) return JewelryNBT.ingotColor(stack);
- return 16777215;
- }
-
- public static boolean isColorPretty(int r, int g, int b)
- {
- if((r > 80 || g > 80 || b > 80) || (r > 80 && g > 80 && b > 80 && r < 230 && b < 230 && g < 230)) return true;
- else return false;
- }
-
- public ItemStack getModifiedItemStack(ItemStack ingot)
- {
- ItemStack itemstack = new ItemStack(this);
- JewelryNBT.addMetal(itemstack, ingot);
- return itemstack;
- }
-
- public String getItemStackDisplayName(ItemStack stack)
- {
- if(JewelryNBT.ingot(stack) != null) return (StatCollector.translateToLocal(this.getUnlocalizedNameInefficiently(stack) + ".name")).trim() + " " + JewelryNBT.ingot(stack).getDisplayName().replace("Ingot", " ").trim() ;
- return ("" + StatCollector.translateToLocal(this.getUnlocalizedNameInefficiently(stack) + ".name")).trim() + " Metal";
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/item/ItemNecklace.java b/src/main/java/darkknight/jewelrycraft/item/ItemNecklace.java
deleted file mode 100644
index 96ef364..0000000
--- a/src/main/java/darkknight/jewelrycraft/item/ItemNecklace.java
+++ /dev/null
@@ -1,272 +0,0 @@
-package darkknight.jewelrycraft.item;
-
-import java.io.IOException;
-import java.util.List;
-
-import net.minecraft.block.Block;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.potion.Potion;
-import net.minecraft.potion.PotionEffect;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.AxisAlignedBB;
-import net.minecraft.util.ChatComponentText;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.IIcon;
-import net.minecraft.util.StatCollector;
-import net.minecraft.world.World;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import darkknight.jewelrycraft.util.JewelryNBT;
-
-public class ItemNecklace extends Item
-{
- public IIcon jewel;
- private double amplifier;
- int index = 0;
-
- public ItemNecklace()
- {
- super();
- this.setMaxStackSize(1);
- }
-
- public void registerIcons(IIconRegister iconRegister)
- {
- itemIcon = iconRegister.registerIcon("jewelrycraft:necklace");
- jewel = iconRegister.registerIcon("jewelrycraft:jewelNecklace");
- }
-
- @Override
- public boolean requiresMultipleRenderPasses()
- {
- return true;
- }
-
- @SideOnly(Side.CLIENT)
- public int getColorFromItemStack(ItemStack stack, int pass)
- {
- try
- {
- return ItemRing.color(stack, pass);
- }
- catch (IOException e)
- {
- e.printStackTrace();
- }
- return 16777215;
- }
-
- public IIcon getIcon(ItemStack stack, int pass)
- {
- if(pass == 0) return itemIcon;
- if(pass == 1 && JewelryNBT.jewel(stack) != null) return jewel;
- return itemIcon;
- }
-
- public String getItemStackDisplayName(ItemStack stack)
- {
- if(JewelryNBT.ingot(stack) != null) return JewelryNBT.ingot(stack).getDisplayName().replace("Ingot", " ").trim() + " " + ("" + StatCollector.translateToLocal(this.getUnlocalizedNameInefficiently(stack) + ".name")).trim();
- return ("" + StatCollector.translateToLocal(this.getUnlocalizedNameInefficiently(stack) + ".name")).trim();
- }
-
- @SuppressWarnings({ "rawtypes" })
- public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player)
- {
- if (!world.isRemote)
- {
- List entities = world.getEntitiesWithinAABB(EntityLivingBase.class, AxisAlignedBB.getBoundingBox(player.posX - 1.5D, player.posY, player.posZ - 1.5D, player.posX + 1.5D, player.posY + 2D, player.posZ + 1.5D));
- if (JewelryNBT.playerPosX(stack) != -1 && JewelryNBT.playerPosY(stack) != -1 && JewelryNBT.playerPosZ(stack) != -1)
- {
- double posX = JewelryNBT.playerPosX(stack), posY = JewelryNBT.playerPosY(stack), posZ = JewelryNBT.playerPosZ(stack);
- if (JewelryNBT.isJewelX(stack, new ItemStack(Items.ender_pearl)) && JewelryNBT.isModifierX(stack, new ItemStack(Items.bed)) && JewelryNBT.dimension(stack) != -2 && JewelryNBT.dimName(stack) != null)
- {
- int dimension = JewelryNBT.dimension(stack);
- for (int i = 1; i <= 20; i++) world.spawnParticle("largesmoke", player.posX - 0.5D + Math.random(), player.posY - 1.5D + Math.random(), player.posZ - 0.5D + Math.random(), 0.0D, 0.0D, 0.0D);
- if (!JewelryNBT.isDimensionX(stack, player.dimension)) player.travelToDimension(dimension);
- for (int i = 0; i < entities.size(); i++) ((EntityLivingBase)entities.get(i)).setPositionAndUpdate(posX, posY, posZ);
- for (int i = 1; i <= 300; i++) world.spawnParticle("portal", posX - 0.5D + Math.random(), posY + Math.random(), posZ - 0.5D + Math.random(), 0.0D, 0.0D, 0.0D);
- }
- else if(JewelryNBT.isDimensionX(stack, player.dimension))
- {
- for (int i = 1; i <= 20; i++) world.spawnParticle("largesmoke", player.posX - 0.5D + Math.random(), player.posY - 1.5D + Math.random(), player.posZ - 0.5D + Math.random(), 0.0D, 0.0D, 0.0D);
- for (int i = 0; i < entities.size(); i++) ((EntityLivingBase)entities.get(i)).setPositionAndUpdate(posX, posY, posZ);
- for (int i = 1; i <= 300; i++) world.spawnParticle("portal", posX - 0.5D + Math.random(), posY + Math.random(), posZ - 0.5D + Math.random(), 0.0D, 0.0D, 0.0D);
- }
- else player.addChatMessage(new ChatComponentText("You can't teleport to these coordonates! You need to be in the same dimension they were set!"));
- }
- else if(JewelryNBT.isJewelX(stack, new ItemStack(Items.ender_pearl)) && JewelryNBT.isModifierX(stack, new ItemStack(Items.bed)) && JewelryNBT.dimension(stack) == -2 && JewelryNBT.playerPosX(stack) == -1 && JewelryNBT.playerPosY(stack) == -1 && JewelryNBT.playerPosZ(stack) == -1){
- JewelryNBT.addCoordonatesAndDimension(stack, player.posX, player.posY, player.posZ, world.provider.dimensionId, world.provider.getDimensionName());
- JewelryNBT.addFakeEnchantment(stack);
- }
- else if (JewelryNBT.isJewelX(stack, new ItemStack(Items.ender_pearl)) && !JewelryNBT.hasTag(stack, "modifier") && JewelryNBT.playerPosX(stack) == -1 && JewelryNBT.playerPosY(stack) == -1 && JewelryNBT.playerPosZ(stack) == -1){
- JewelryNBT.addCoordonatesAndDimension(stack, player.posX, player.posY, player.posZ, world.provider.dimensionId, world.provider.getDimensionName());
- JewelryNBT.addFakeEnchantment(stack);
- }
-
- if(JewelryNBT.hasTag(stack, "mode"))
- {
- String mode = "";
- if(JewelryNBT.isModeX(stack, "Activated")) mode = "Deactivated";
- else if(JewelryNBT.isModeX(stack, "Deactivated")) mode = "Activated";
- if(mode != "")
- {
- player.addChatMessage(new ChatComponentText("The Necklace has been " + mode));
- JewelryNBT.addMode(stack, mode);
- }
- }
- }
- return stack;
- }
-
-// @Override
-// public boolean itemInteractionForEntity(ItemStack stack, EntityPlayer player, EntityLivingBase entity)
-// {
-// if (!player.worldObj.isRemote && entity instanceof EntityLivingBase && JewelryNBT.isJewelX(stack, new ItemStack(Item.netherStar)) && JewelryNBT.isModifierX(stack, new ItemStack(Block.chest)) && JewelryNBT.entity(stack, player) == null){
-// JewelryNBT.addEntity(stack, entity);
-// JewelryNBT.addEntityID(stack, entity);
-// entity.setDead();
-// JewelryNBT.addFakeEnchantment(stack);
-// }
-// return true;
-// }
-
- /**
- * allows items to add custom lines of information to the mouseover
- * description
- */
- public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean par4)
- {
- if (stack.hasTagCompound())
- {
- ItemStack ingot = JewelryNBT.ingot(stack);
- if (ingot != null) list.add("Ingot: " + EnumChatFormatting.YELLOW + ingot.getDisplayName());
-
- ItemStack jewel = JewelryNBT.jewel(stack);
- if (jewel != null) list.add("Jewel: " + EnumChatFormatting.BLUE + jewel.getDisplayName());
-
- ItemStack modifier = JewelryNBT.modifier(stack);
- if(modifier != null) list.add("Modifier: " + EnumChatFormatting.DARK_PURPLE + modifier.getDisplayName());
-
- double playerPosX = JewelryNBT.playerPosX(stack), playerPosY = JewelryNBT.playerPosY(stack), playerPosZ = JewelryNBT.playerPosZ(stack);
- if(playerPosX != -1 && playerPosY != -1 && playerPosZ != -1) list.add(EnumChatFormatting.YELLOW + "X: " + EnumChatFormatting.GRAY + (int) playerPosX + EnumChatFormatting.YELLOW + " Y: " + EnumChatFormatting.GRAY + (int) playerPosY + EnumChatFormatting.YELLOW + " Z: " + EnumChatFormatting.GRAY + (int) playerPosZ);
-
- int posX = JewelryNBT.blockCoordX(stack), posY = JewelryNBT.blockCoordY(stack), posZ = JewelryNBT.blockCoordZ(stack);
- if(posX != -1 && posY != -1 && posZ != -1) list.add(EnumChatFormatting.YELLOW + "X: " + EnumChatFormatting.GRAY + (int) posX + EnumChatFormatting.YELLOW + " Y: " + EnumChatFormatting.GRAY + (int) posY + EnumChatFormatting.YELLOW + " Z: " + EnumChatFormatting.GRAY + (int) posZ);
-
- String name = JewelryNBT.dimName(stack);
- if(name != null) list.add("Dimension: " + EnumChatFormatting.DARK_GREEN + name);
-
- EntityLivingBase entity = JewelryNBT.entity(stack, player);
- if (entity != null) list.add("Entity: " + EnumChatFormatting.GOLD + entity.getCommandSenderName());
-
- String modeN = JewelryNBT.modeName(stack);
- if(modeN != null) list.add("Mode: " + modeN);
-
- int block = JewelryNBT.blockID(stack);
- if(block != -1) list.add("Block: " + StatCollector.translateToLocalFormatted(Block.getBlockById(block).getUnlocalizedName()));
-
- int blockmeta = JewelryNBT.blockMetadata(stack);
- if(blockmeta != -1) list.add("Block Metadata: " + blockmeta);
-
- TileEntity tile = JewelryNBT.tileEntity(stack);
- if(tile != null) list.add(EnumChatFormatting.RED + "Contains a tile entity");
-
- int blockX = JewelryNBT.blockCoordX(stack);
- if(blockX != -1) list.add("Block Coords X: " + blockX);
-
- int blockY = JewelryNBT.blockCoordY(stack);
- if(blockY != -1) list.add("Block Coords Y: " + blockY);
-
- int blockZ = JewelryNBT.blockCoordZ(stack);
- if(blockZ != -1) list.add("Block Coords Z: " + blockZ);
-
- // int colorI = JewelryNBT.ingotColor(stack);
- // if(colorI != -1) list.add("Ingot Color: " + colorI);
- //
- // int colorJ = JewelryNBT.jewelColor(stack);
- // if(colorJ != -1) list.add("Jewel Color: " + colorJ);
- }
- }
-
- public boolean onItemUse(ItemStack stack, EntityPlayer player, World world, int i, int j, int k, int side, float par8, float par9, float par10)
- {
- amplifier = 0;
- if (JewelryNBT.isJewelX(stack, new ItemStack(Items.diamond))) amplifier = 1D;
- else if (JewelryNBT.isJewelX(stack, new ItemStack(Items.emerald))) amplifier = 2D;
- else if (JewelryNBT.isJewelX(stack, new ItemStack(Items.nether_star))) amplifier = 5D;
-
- if (!world.isRemote)
- {
- onItemRightClick(stack, world, player);
- if(JewelryNBT.isModifierX(stack, new ItemStack(Items.dye, 1, 15)))
- for(int x = (int) - amplifier; x <= amplifier; x++)
- for(int z = (int) - amplifier; z <= amplifier; z++)
- world.scheduleBlockUpdate(i + x, j, k + z, world.getBlock(i + x, j, k + z), 7 - (int)amplifier);
-
- for(int x = (int) - 1; x <= 1; x++)
- for(int z = (int) - 1; z <= 1; z++)
- if(JewelryNBT.isModifierX(stack, new ItemStack(Items.diamond_pickaxe)) && JewelryNBT.isJewelX(stack, new ItemStack(Items.nether_star)) && JewelryNBT.isIngotX(stack, new ItemStack(ItemList.shadowIngot)))
- if((side == 0 || side == 1) && j > 0 && world.getBlock(i, j + x, k + z) != Blocks.air && world.getBlock(i + x, j, k + z).getBlockHardness(world, i + x, j, k + z) > 0F) world.func_147480_a(i + x, j, k + z, true);
- else if((side == 2 || side == 3) && j + x > 0 && world.getBlock(i, j + x, k + z) != Blocks.air && world.getBlock(i + z, j + x, k).getBlockHardness(world, i + z, j + x, k) > 0F) world.func_147480_a(i + z, j + x, k, true);
- else if((side == 4 || side == 5) && j + x > 0 && world.getBlock(i, j + x, k + z) != Blocks.air && world.getBlock(i, j + x, k + z).getBlockHardness(world, i, j + x, k + z) > 0F) world.func_147480_a(i, j + x, k + z, true);
- }
- return true;
- }
-
- public void onUpdate(ItemStack stack, World world, Entity entity, int par4, boolean par5)
- {
- amplifier = 0D;
- if (!world.isRemote)
- {
- EntityPlayer entityplayer = (EntityPlayer) entity;
- int posX = (int)Math.floor(entityplayer.posX), posY = (int)Math.floor(entityplayer.posY), posZ = (int)Math.floor(entityplayer.posZ);
-
- if (JewelryNBT.isJewelX(stack, new ItemStack(Items.diamond))) amplifier = 1D;
- else if (JewelryNBT.isJewelX(stack, new ItemStack(Items.emerald))) amplifier = 2D;
- else if (JewelryNBT.isJewelX(stack, new ItemStack(Items.nether_star))) amplifier = 5D;
-
- if(JewelryNBT.isModifierX(stack, new ItemStack(Items.dye, 1, 15)) && world.getBlock(posX, posY - 1, posZ) == Blocks.farmland)
- for(int i = (int) - amplifier; i <= amplifier; i++)
- for(int j = (int) - amplifier; j <= amplifier; j++)
- world.setBlockMetadataWithNotify(posX + i, posY - 1, posZ + j, 1, 7);
-
- List entities = world.getEntitiesWithinAABB(EntityLivingBase.class, AxisAlignedBB.getBoundingBox(entityplayer.posX - amplifier, entityplayer.posY - amplifier, entityplayer.posZ - amplifier, entityplayer.posX + amplifier, entityplayer.posY + 2*amplifier, entityplayer.posZ + amplifier));
- if(JewelryNBT.isModeX(stack, "Activated"))
- {
- for(int i = 0; i < entities.size(); i++)
- {
- if (JewelryNBT.isModifierX(stack, new ItemStack(Items.blaze_powder))) ((EntityLivingBase) entities.get(i)).addPotionEffect(new PotionEffect(Potion.fireResistance.id, 4, 0, true));
- else if (JewelryNBT.isModifierX(stack, new ItemStack(Items.sugar))) ((EntityLivingBase) entities.get(i)).addPotionEffect(new PotionEffect(Potion.moveSpeed.id, 4, 0, true));
- else if (JewelryNBT.isModifierX(stack, new ItemStack(Items.iron_pickaxe)) && !JewelryNBT.isJewelX(stack, new ItemStack(Items.ender_pearl))) ((EntityLivingBase) entities.get(i)).addPotionEffect(new PotionEffect(Potion.digSpeed.id, 4, 0, true));
- else if (JewelryNBT.isModifierX(stack, new ItemStack(Items.feather)))
- {
- ((EntityLivingBase) entities.get(i)).addPotionEffect(new PotionEffect(Potion.jump.id, 4, 0, true));
- entityplayer.fallDistance = 0;
- }
- else if (JewelryNBT.isModifierX(stack, new ItemStack(Items.potionitem, 1, 8270))) ((EntityLivingBase) entities.get(i)).addPotionEffect(new PotionEffect(Potion.invisibility.id, 4, 0, true));
- }
- }
- }
- }
-
- public ItemStack getModifiedItemStack(ItemStack ingot, ItemStack modifier, ItemStack jewel)
- {
- ItemStack itemstack = new ItemStack(this);
- JewelryNBT.addMetal(itemstack, ingot);
- JewelryNBT.addModifier(itemstack, modifier);
- JewelryNBT.addJewel(itemstack, jewel);
- if(JewelryNBT.isModifierEffectType(itemstack) && !(JewelryNBT.isJewelX(itemstack, new ItemStack(Items.ender_pearl)) && JewelryNBT.isModifierX(itemstack, new ItemStack(Items.iron_pickaxe)))) JewelryNBT.addMode(itemstack, "Activated");
- if(JewelryNBT.isJewelX(itemstack, new ItemStack(Items.nether_star)) && JewelryNBT.isModifierX(itemstack, new ItemStack(Items.book)))
- JewelryNBT.addMode(itemstack, "Disenchant");
- return itemstack;
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/item/ItemRing.java b/src/main/java/darkknight/jewelrycraft/item/ItemRing.java
deleted file mode 100644
index 265730a..0000000
--- a/src/main/java/darkknight/jewelrycraft/item/ItemRing.java
+++ /dev/null
@@ -1,605 +0,0 @@
-package darkknight.jewelrycraft.item;
-
-import java.awt.image.BufferedImage;
-import java.io.IOException;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-import java.util.Random;
-
-import javax.imageio.ImageIO;
-
-import net.minecraft.block.Block;
-import net.minecraft.block.BlockChest;
-import net.minecraft.block.BlockSkull;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.client.resources.IResourceManager;
-import net.minecraft.enchantment.Enchantment;
-import net.minecraft.enchantment.EnchantmentHelper;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.entity.monster.EntityIronGolem;
-import net.minecraft.entity.monster.EntitySnowman;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.inventory.InventoryEnderChest;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.potion.Potion;
-import net.minecraft.potion.PotionEffect;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.tileentity.TileEntityChest;
-import net.minecraft.tileentity.TileEntitySkull;
-import net.minecraft.util.ChatComponentText;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.IIcon;
-import net.minecraft.util.MathHelper;
-import net.minecraft.util.ResourceLocation;
-import net.minecraft.util.StatCollector;
-import net.minecraft.world.World;
-import cpw.mods.fml.common.network.internal.FMLNetworkHandler;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import darkknight.jewelrycraft.JewelrycraftMod;
-import darkknight.jewelrycraft.block.BlockList;
-import darkknight.jewelrycraft.util.JewelryNBT;
-
-public class ItemRing extends Item
-{
- public IIcon jewel;
- private int amplifier, cooldown = 0;
- int index = 0;
-
- public ItemRing()
- {
- super();
- this.setMaxStackSize(1);
- }
-
- public void registerIcons(IIconRegister iconRegister)
- {
- itemIcon = iconRegister.registerIcon("jewelrycraft:ring");
- jewel = iconRegister.registerIcon("jewelrycraft:jewelRing");
- }
-
- @Override
- public boolean requiresMultipleRenderPasses()
- {
- return true;
- }
-
- @SideOnly(Side.CLIENT)
- public int getColorFromItemStack(ItemStack stack, int pass)
- {
- try
- {
- return color(stack, pass);
- }
- catch (IOException e)
- {
- e.printStackTrace();
- }
- return 16777215;
- }
-
- public IIcon getIcon(ItemStack stack, int pass)
- {
- if(pass == 0) return itemIcon;
- if(pass == 1 && JewelryNBT.jewel(stack) != null) return jewel;
- return itemIcon;
- }
-
- public static int color(ItemStack stack, int pass) throws IOException
- {
- String domain = "", texture;
- IResourceManager rm = Minecraft.getMinecraft().getResourceManager();
- BufferedImage icon;
- int x=0, y=0, ok = 0, red, green, blue;
- if (pass == 0 && JewelryNBT.ingot(stack) != null && JewelryNBT.ingot(stack).getIconIndex() != null && JewelryNBT.ingotColor(stack) == 16777215)
- {
- String ingotIconName = JewelryNBT.ingot(stack).getIconIndex().getIconName();
-
- if (ingotIconName.substring(0, ingotIconName.indexOf(":") + 1) != "") domain = ingotIconName.substring(0, ingotIconName.indexOf(":") + 1).replace(":", " ").trim();
- else domain = "minecraft";
-
- texture = ingotIconName.substring(ingotIconName.lastIndexOf(":") + 1) + ".png";
- ResourceLocation ingot = null;
-
- if (JewelryNBT.ingot(stack).getUnlocalizedName().contains("item")) ingot = new ResourceLocation(domain, "textures/items/" + texture);
- else ingot = new ResourceLocation(domain, "textures/blocks/" + texture);
-
- icon = ImageIO.read(rm.getResource(ingot).getInputStream());
- while(ok == 0)
- {
- red = (icon.getRGB(x, y) >> 16) & 0xFF;
- green = (icon.getRGB(x, y) >> 8) & 0xFF;
- blue = icon.getRGB(x, y) & 0xFF;
- if(!isColorPretty(red, green, blue))
- {
- if(x<icon.getTileWidth()-1) x++;
- if(x>=icon.getTileWidth()-1 && y<icon.getTileWidth()-1)
- {
- x=0;
- y++;
- }
- if(x == icon.getTileWidth()-1 && y==icon.getTileWidth()-1) ok=1;
- }
- else ok=1;
- }
- JewelryNBT.addIngotColor(stack, icon.getRGB(x, y));
- }
- else if (pass == 1 && JewelryNBT.jewel(stack) != null && JewelryNBT.jewel(stack).getIconIndex() != null && JewelryNBT.jewelColor(stack) == 16777215)
- {
- x = 0; y = 0; ok=0;
- String jewelIconName = JewelryNBT.jewel(stack).getIconIndex().getIconName();
-
- if (jewelIconName.substring(0, jewelIconName.indexOf(":") + 1) != "") domain = jewelIconName.substring(0, jewelIconName.indexOf(":") + 1).replace(":", " ").trim();
- else domain = "minecraft";
-
- texture = jewelIconName.substring(jewelIconName.lastIndexOf(":") + 1) + ".png";
- ResourceLocation jewelLoc = null;
-
- if (JewelryNBT.jewel(stack).getUnlocalizedName().contains("item")) jewelLoc = new ResourceLocation(domain, "textures/items/" + texture);
- else jewelLoc = new ResourceLocation(domain, "textures/blocks/" + texture);
-
- icon = ImageIO.read(rm.getResource(jewelLoc).getInputStream());
- while(ok == 0)
- {
- red = (icon.getRGB(x, y) >> 16) & 0xFF;
- green = (icon.getRGB(x, y) >> 8) & 0xFF;
- blue = icon.getRGB(x, y) & 0xFF;
- if(!isColorPretty(red, green, blue))
- {
- if(x<icon.getTileWidth()-1) x++;
- if(x>=icon.getTileWidth()-1 && y<icon.getTileWidth()-1)
- {
- x=0;
- y++;
- }
- if(x == icon.getTileWidth()-1 && y==icon.getTileWidth()-1) ok=1;
- }
- else ok=1;
- }
- if(JewelryNBT.jewel(stack).getItem().getColorFromItemStack(JewelryNBT.jewel(stack), 1) == 16777215) JewelryNBT.addJewelColor(stack, icon.getRGB(x, y));
- else JewelryNBT.addJewelColor(stack, JewelryNBT.jewel(stack).getItem().getColorFromItemStack(JewelryNBT.jewel(stack), 1));
- }
- if(pass == 0 && JewelryNBT.ingot(stack) != null) return JewelryNBT.ingotColor(stack);
- if(pass == 1 && JewelryNBT.jewel(stack) != null) return JewelryNBT.jewelColor(stack);
- else if(JewelryNBT.ingot(stack) != null) return JewelryNBT.ingotColor(stack);
- return 16777215;
- }
-
- public static boolean isColorPretty(int r, int g, int b)
- {
- if((r > 80 || g > 80 || b > 80) || (r > 80 && g > 80 && b > 80 && r < 230 && b < 230 && g < 230)) return true;
- else return false;
- }
-
- public String getItemStackDisplayName(ItemStack stack)
- {
- if (JewelryNBT.ingot(stack) != null && JewelryNBT.jewel(stack) != null && JewelryNBT.modifier(stack) == null && JewelryNBT.isJewelX(stack, new ItemStack(Items.diamond)) && JewelryNBT.isIngotX(stack, new ItemStack(Items.gold_ingot))) return "Wedding Ring";
- else if(JewelryNBT.ingot(stack) != null) return JewelryNBT.ingot(stack).getDisplayName().replace("Ingot", " ").trim() + " " + ("" + StatCollector.translateToLocal(this.getUnlocalizedNameInefficiently(stack) + ".name")).trim();
- return ("" + StatCollector.translateToLocal(this.getUnlocalizedNameInefficiently(stack) + ".name")).trim();
- }
-
- public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player)
- {
- if (!world.isRemote){
- if (JewelryNBT.playerPosX(stack) != -1 && JewelryNBT.playerPosY(stack) != -1 && JewelryNBT.playerPosZ(stack) != -1)
- {
- double posX = JewelryNBT.playerPosX(stack), posY = JewelryNBT.playerPosY(stack), posZ = JewelryNBT.playerPosZ(stack);
- if (JewelryNBT.isJewelX(stack, new ItemStack(Items.ender_pearl)) && JewelryNBT.isModifierX(stack, new ItemStack(Items.bed)) && JewelryNBT.dimension(stack) != -2 && JewelryNBT.dimName(stack) != null)
- {
- int dimension = JewelryNBT.dimension(stack);
- for (int i = 1; i <= 20; i++) world.spawnParticle("largesmoke", player.posX - 0.5D + Math.random(), player.posY - 1.5D + Math.random(), player.posZ - 0.5D + Math.random(), 0.0D, 0.0D, 0.0D);
- if (!JewelryNBT.isDimensionX(stack, player.dimension)) player.travelToDimension(dimension);
- player.setPositionAndUpdate(posX, posY, posZ);
- for (int i = 1; i <= 300; i++) world.spawnParticle("portal", posX - 0.5D + Math.random(), posY + Math.random(), posZ - 0.5D + Math.random(), 0.0D, 0.0D, 0.0D);
- }
- else if(JewelryNBT.isDimensionX(stack, player.dimension))
- {
- for (int i = 1; i <= 20; i++) world.spawnParticle("largesmoke", player.posX - 0.5D + Math.random(), player.posY - 1.5D + Math.random(), player.posZ - 0.5D + Math.random(), 0.0D, 0.0D, 0.0D);
- player.setPositionAndUpdate(posX, posY, posZ);
- for (int i = 1; i <= 300; i++) world.spawnParticle("portal", posX - 0.5D + Math.random(), posY + Math.random(), posZ - 0.5D + Math.random(), 0.0D, 0.0D, 0.0D);
- }
- else player.addChatMessage(new ChatComponentText("You can't teleport to these coordonates! You need to be in the same dimension they were set!"));
- }
- else if(JewelryNBT.isJewelX(stack, new ItemStack(Items.ender_pearl)) && JewelryNBT.isModifierX(stack, new ItemStack(Items.bed)) && JewelryNBT.dimension(stack) == -2 && JewelryNBT.playerPosX(stack) == -1 && JewelryNBT.playerPosY(stack) == -1 && JewelryNBT.playerPosZ(stack) == -1){
- JewelryNBT.addCoordonatesAndDimension(stack, player.posX, player.posY, player.posZ, world.provider.dimensionId, world.provider.getDimensionName());
- JewelryNBT.addFakeEnchantment(stack);
- }
- else if (JewelryNBT.isJewelX(stack, new ItemStack(Blocks.obsidian)) && JewelryNBT.isModifierX(stack, new ItemStack(Items.ender_eye)))
- {
- InventoryEnderChest inventoryenderchest = player.getInventoryEnderChest();
- player.displayGUIChest(inventoryenderchest);
- }
- else if (JewelryNBT.isJewelX(stack, new ItemStack(Items.ender_pearl)) && JewelryNBT.isModifierX(stack, new ItemStack(Blocks.chest))){
- int i = JewelryNBT.blockCoordX(stack), j = JewelryNBT.blockCoordY(stack), k = JewelryNBT.blockCoordZ(stack);
- if (player.getDistance(i + 0.5F, j + 0.5F, k + 0.5F) <= 128 && i != -1 && j != -1 && k != -1){
- Block block = world.getBlock(i, j, k);
- if (!block.isAir(world, i, j, k) && block instanceof BlockChest){
- TileEntity tile = world.getTileEntity(i, j, k);
- if (tile != null && tile instanceof TileEntityChest) FMLNetworkHandler.openGui(player, JewelrycraftMod.instance, 0, world, i, j, k);
- }
- }
- else if(i != -1 && j != -1 && k != -1) player.addChatMessage(new ChatComponentText("Chest out of range! You need to be " + ((int)player.getDistance(i + 0.5F, j + 0.5F, k + 0.5F) - 127) + " blocks closer."));
- else player.addChatMessage(new ChatComponentText("You need to link the ring with a chest first, before using it!"));
- }
- else if (JewelryNBT.isJewelX(stack, new ItemStack(Items.ender_pearl)) && !JewelryNBT.hasTag(stack, "modifier") && JewelryNBT.playerPosX(stack) == -1 && JewelryNBT.playerPosY(stack) == -1 && JewelryNBT.playerPosZ(stack) == -1){
- JewelryNBT.addCoordonatesAndDimension(stack, player.posX, player.posY, player.posZ, world.provider.dimensionId, world.provider.getDimensionName());
- JewelryNBT.addFakeEnchantment(stack);
- }
-
- if(JewelryNBT.hasTag(stack, "mode"))
- {
- String mode = "";
- if(JewelryNBT.isModeX(stack, "Disenchant")) mode = "Transfer";
- else if(JewelryNBT.isModeX(stack, "Transfer")) mode = "Enchant";
- else if(JewelryNBT.isModeX(stack, "Enchant")) mode = "Disenchant";
- if(mode != "")
- {
- player.addChatMessage(new ChatComponentText("Switched to " + mode + " mode"));
- JewelryNBT.addMode(stack, mode);
- }
- if(JewelryNBT.isModeX(stack, "Activated")) mode = "Deactivated";
- else if(JewelryNBT.isModeX(stack, "Deactivated")) mode = "Activated";
- if(mode != "" && mode != "Transfer" && mode != "Enchant" && mode != "Disenchant")
- {
- player.addChatMessage(new ChatComponentText("The Ring has been " + mode));
- JewelryNBT.addMode(stack, mode);
- }
- }
- }
- return stack;
- }
-
- @Override
- public boolean itemInteractionForEntity(ItemStack stack, EntityPlayer player, EntityLivingBase entity)
- {
- if (!player.worldObj.isRemote && entity instanceof EntityLivingBase && JewelryNBT.isJewelX(stack, new ItemStack(Items.nether_star)) && JewelryNBT.isModifierX(stack, new ItemStack(Blocks.chest)) && JewelryNBT.entity(stack, player) == null){
- JewelryNBT.addEntity(stack, entity);
- JewelryNBT.addEntityID(stack, entity);
- entity.setDead();
- JewelryNBT.addFakeEnchantment(stack);
- }
- return true;
- }
-
- /**
- * allows items to add custom lines of information to the mouseover
- * description
- */
- public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean par4)
- {
- if (stack.hasTagCompound() && stack.getDisplayName() != "Wedding Ring")
- {
- ItemStack ingot = JewelryNBT.ingot(stack);
- if (ingot != null) list.add("Ingot: " + EnumChatFormatting.YELLOW + ingot.getDisplayName());
-
- ItemStack jewel = JewelryNBT.jewel(stack);
- if (jewel != null) list.add("Jewel: " + EnumChatFormatting.BLUE + jewel.getDisplayName());
-
- ItemStack modifier = JewelryNBT.modifier(stack);
- if(modifier != null) list.add("Modifier: " + EnumChatFormatting.DARK_PURPLE + modifier.getDisplayName());
-
- double playerPosX = JewelryNBT.playerPosX(stack), playerPosY = JewelryNBT.playerPosY(stack), playerPosZ = JewelryNBT.playerPosZ(stack);
- if(playerPosX != -1 && playerPosY != -1 && playerPosZ != -1) list.add(EnumChatFormatting.YELLOW + "X: " + EnumChatFormatting.GRAY + (int) playerPosX + EnumChatFormatting.YELLOW + " Y: " + EnumChatFormatting.GRAY + (int) playerPosY + EnumChatFormatting.YELLOW + " Z: " + EnumChatFormatting.GRAY + (int) playerPosZ);
-
- int posX = JewelryNBT.blockCoordX(stack), posY = JewelryNBT.blockCoordY(stack), posZ = JewelryNBT.blockCoordZ(stack);
- if(posX != -1 && posY != -1 && posZ != -1) list.add(EnumChatFormatting.YELLOW + "X: " + EnumChatFormatting.GRAY + (int) posX + EnumChatFormatting.YELLOW + " Y: " + EnumChatFormatting.GRAY + (int) posY + EnumChatFormatting.YELLOW + " Z: " + EnumChatFormatting.GRAY + (int) posZ);
-
- String name = JewelryNBT.dimName(stack);
- if(name != null) list.add("Dimension: " + EnumChatFormatting.DARK_GREEN + name);
-
- EntityLivingBase entity = JewelryNBT.entity(stack, player);
- if (entity != null) list.add("Entity: " + EnumChatFormatting.GOLD + entity.getCommandSenderName());
-
- String modeN = JewelryNBT.modeName(stack);
- if(modeN != null) list.add("Mode: " + modeN);
-
- int block = JewelryNBT.blockID(stack);
- if(block != -1) list.add("Block: " + StatCollector.translateToLocalFormatted(Block.getBlockById(block).getUnlocalizedName()));
-
- int blockmeta = JewelryNBT.blockMetadata(stack);
- if(blockmeta != -1) list.add("Block Metadata: " + blockmeta);
-
- TileEntity tile = JewelryNBT.tileEntity(stack);
- if(tile != null) list.add(EnumChatFormatting.RED + "Contains a tile entity");
-
- int blockX = JewelryNBT.blockCoordX(stack);
- if(blockX != -1) list.add("Block Coords X: " + blockX);
-
- int blockY = JewelryNBT.blockCoordY(stack);
- if(blockY != -1) list.add("Block Coords Y: " + blockY);
-
- int blockZ = JewelryNBT.blockCoordZ(stack);
- if(blockZ != -1) list.add("Block Coords Z: " + blockZ);
-
- // int colorI = JewelryNBT.ingotColor(stack);
- // if(colorI != -1) list.add("Ingot Color: " + colorI);
- //
- // int colorJ = JewelryNBT.jewelColor(stack);
- // if(colorJ != -1) list.add("Jewel Color: " + colorJ);
- }
- }
-
- public boolean onItemUse(ItemStack stack, EntityPlayer player, World world, int i, int j, int k, int side, float par8, float par9, float par10)
- {
- amplifier = 0;
- if (JewelryNBT.isJewelX(stack, new ItemStack(Items.diamond))) amplifier = 1;
- else if (JewelryNBT.isJewelX(stack, new ItemStack(Items.emerald))) amplifier = 2;
- else if (JewelryNBT.isJewelX(stack, new ItemStack(Items.nether_star))) amplifier = 7;
-
- if (!world.isRemote)
- {
- EntityLivingBase entity = JewelryNBT.entity(stack, player);
- boolean used = false;
- if(entity != null && entity instanceof EntityLivingBase){
- entity.setLocationAndAngles(i + 0.5D, j + 1D, k + 0.5D, MathHelper.wrapAngleTo180_float(world.rand.nextFloat() * 360.0F), 0.0F);
- world.spawnEntityInWorld(entity);
- JewelryNBT.removeEntity(stack);
- }
- if (JewelryNBT.isJewelX(stack, new ItemStack(Items.ender_pearl)) && JewelryNBT.isModifierX(stack, new ItemStack(Blocks.chest)) && world.getBlock(i, j, k) == Blocks.chest) JewelryNBT.addBlockCoordonates(stack, i, j, k);
- onItemRightClick(stack, world, player);
- if(JewelryNBT.isModifierX(stack, new ItemStack(Items.dye, 1, 15))) world.scheduleBlockUpdate(i, j, k, world.getBlock(i, j, k), 7 - amplifier);
- if(JewelryNBT.isModifierX(stack, new ItemStack(Items.diamond_pickaxe)) && JewelryNBT.isJewelX(stack, new ItemStack(Items.ender_pearl)))
- {
- if(JewelryNBT.hasTag(stack, "blockID") && !used)
- {
- int shiftX = 0, shiftY = 0, shiftZ = 0;
- if(side == 0) shiftY = -1;
- else if(side == 1) shiftY = 1;
- else if(side == 2) shiftZ = -1;
- else if(side == 3) shiftZ = 1;
- else if(side == 4) shiftX = -1;
- else if(side == 5) shiftX = 1;
- world.setBlock(i + shiftX, j + shiftY, k + shiftZ, Block.getBlockById(JewelryNBT.blockID(stack)));
- world.setBlockMetadataWithNotify(i + shiftX, j + shiftY, k + shiftZ, JewelryNBT.blockMetadata(stack), 2);
- if(JewelryNBT.hasTag(stack, "tile")) world.setTileEntity(i + shiftX, j + shiftY, k + shiftZ, JewelryNBT.tileEntity(stack));
- if(JewelryNBT.tileEntity(stack) instanceof TileEntitySkull) ((BlockSkull)Blocks.skull).func_149965_a(world, i + shiftX, j + shiftY, k + shiftZ, (TileEntitySkull)JewelryNBT.tileEntity(stack));
- if(Block.getBlockById(JewelryNBT.blockID(stack)) == Blocks.pumpkin || Block.getBlockById(JewelryNBT.blockID(stack)) == Blocks.lit_pumpkin) createGolems(world, i + shiftX, j + shiftY, k + shiftZ);
- JewelryNBT.removeBlock(stack);
- used = true;
- }
-
- if(!JewelryNBT.hasTag(stack, "tile") && world.getTileEntity(i, j, k) != null && !used && world.getBlock(i, j, k).getBlockHardness(world, i, j, k) > 0F){
- JewelryNBT.addTileEntityBlock(stack, world, i, j, k);
- world.removeTileEntity(i, j, k);
- world.setBlock(i, j, k, Block.getBlockById(0));
- }
- else if(!JewelryNBT.hasTag(stack, "blockID") && !used && world.getBlock(i, j, k).getBlockHardness(world, i, j, k) > 0F){
- JewelryNBT.addBlock(stack, Block.getIdFromBlock(world.getBlock(i, j, k)), world.getBlockMetadata(i, j, k));
- JewelryNBT.addBlockCoordonates(stack, i, j, k);
- world.setBlock(i, j, k, Block.getBlockById(0));
- }
- }
- if(JewelryNBT.isModifierX(stack, new ItemStack(Items.diamond_pickaxe)) && JewelryNBT.isJewelX(stack, new ItemStack(Items.nether_star)) && JewelryNBT.isIngotX(stack, new ItemStack(ItemList.shadowIngot)) && j > 0 && world.getBlock(i, j, k).getBlockHardness(world, i, j, k) > 0F)
- world.func_147480_a(i, j, k, true);
- }
- return true;
- }
-
- public boolean canDisenchant(EntityPlayer player)
- {
- if(player.capabilities.isCreativeMode) return true;
- else if(player.experienceLevel >= 2) return true;
- return false;
- }
-
- public void dynamicLight(World world, EntityPlayer player)
- {
- world.setBlock((int)player.prevPosX, (int)player.prevPosY, (int)player.prevPosZ, Block.getBlockById(0));
- world.setBlock((int)player.posX, (int)player.posY, (int)player.posZ, BlockList.glow);
- }
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- @Override
- public void onUpdate(ItemStack stack, World world, Entity entity, int par4, boolean par5)
- {
- amplifier = 0;
- if(cooldown > 0) cooldown--;
- if (!world.isRemote){
- EntityPlayer entityplayer = (EntityPlayer) entity;
- int posX = (int)Math.floor(entityplayer.posX), posY = (int)Math.floor(entityplayer.posY), posZ = (int)Math.floor(entityplayer.posZ);
-
- if (JewelryNBT.isJewelX(stack, new ItemStack(Items.diamond))) amplifier = 1;
- else if (JewelryNBT.isJewelX(stack, new ItemStack(Items.emerald))) amplifier = 2;
- else if (JewelryNBT.isJewelX(stack, new ItemStack(Items.nether_star))) amplifier = 7;
-
- if(JewelryNBT.isModifierX(stack, new ItemStack(Items.dye, 1, 15)) && world.getBlock(posX, posY - 1, posZ) == Blocks.farmland)
- world.setBlockMetadataWithNotify(posX, posY - 1, posZ, 1, 7);
-
- if(JewelryNBT.isModeX(stack, "Activated"))
- {
- if (JewelryNBT.isModifierX(stack, new ItemStack(Items.blaze_powder)) && entityplayer != null)
- entityplayer.addPotionEffect(new PotionEffect(Potion.fireResistance.id, 4, amplifier, true));
- else if (JewelryNBT.isModifierX(stack, new ItemStack(Items.sugar)) && entityplayer != null)
- {
- entityplayer.addPotionEffect(new PotionEffect(Potion.moveSpeed.id, 4, amplifier, true));
- entityplayer.addExhaustion(0.05f*amplifier);
- }
- else if (JewelryNBT.isModifierX(stack, new ItemStack(Items.iron_pickaxe)) && entityplayer != null && !JewelryNBT.isJewelX(stack, new ItemStack(Items.ender_pearl)))
- entityplayer.addPotionEffect(new PotionEffect(Potion.digSpeed.id, 4, amplifier, true));
- else if (JewelryNBT.isModifierX(stack, new ItemStack(Items.feather)) && entityplayer != null)
- {
- entityplayer.addPotionEffect(new PotionEffect(Potion.jump.id, 4, amplifier, true));
- if(entityplayer.inventory.armorInventory[0] != null)
- {
- int damage = entityplayer.inventory.armorInventory[0].getMaxDamage() - entityplayer.inventory.armorInventory[0].getItemDamage();
- if(damage - entityplayer.fallDistance > 0){
- entityplayer.inventory.armorInventory[0].damageItem((int)entityplayer.fallDistance, entityplayer);
- entityplayer.fallDistance = 0;
- }
- else
- {
- --entityplayer.inventory.armorInventory[0].stackSize;
- entityplayer.fallDistance -= damage;
- }
- }
- }
- else if (JewelryNBT.isModifierX(stack, new ItemStack(Items.potionitem, 1, 8270)) && entityplayer != null) entityplayer.addPotionEffect(new PotionEffect(Potion.invisibility.id, 4, amplifier, true));
- }
- if(entityplayer.inventory.getCurrentItem() != null && JewelryNBT.isJewelX(stack, new ItemStack(Items.nether_star)) && JewelryNBT.isModifierX(stack, new ItemStack(Items.book)) && entityplayer.inventory.getCurrentItem().getItem() == stack.getItem())
- {
- ItemStack item = null;
- if(entityplayer.inventory.currentItem + 1 <= 8 && entityplayer.inventory.getStackInSlot(entityplayer.inventory.currentItem + 1) != null && entityplayer.inventory.getStackInSlot(entityplayer.inventory.currentItem + 1).isItemEnchanted()) item = entityplayer.inventory.getStackInSlot(entityplayer.inventory.currentItem + 1);
- if(entityplayer.inventory.currentItem - 1 >= 0 && entityplayer.inventory.getStackInSlot(entityplayer.inventory.currentItem - 1) != null && entityplayer.inventory.getStackInSlot(entityplayer.inventory.currentItem - 1).isItemEnchanted()) item = entityplayer.inventory.getStackInSlot(entityplayer.inventory.currentItem - 1);
- if(item != null && JewelryNBT.isModeX(stack, "Disenchant"))
- {
- ItemStack enchBook = new ItemStack(Items.enchanted_book);
- Map enchItem = EnchantmentHelper.getEnchantments(item);
- Map book = EnchantmentHelper.getEnchantments(enchBook);
- Iterator iterator = enchItem.keySet().iterator();
- int e;
-
- if (iterator.hasNext() && canDisenchant(entityplayer))
- {
- e = ((Integer)iterator.next()).intValue();
- book.put(Integer.valueOf(e), Integer.valueOf(((Integer)enchItem.get(Integer.valueOf(e))).intValue()));
- EnchantmentHelper.setEnchantments(book, enchBook);
- if(entityplayer.inventory.addItemStackToInventory(enchBook))
- {
- if(!entityplayer.capabilities.isCreativeMode)
- {
- entityplayer.addExperienceLevel(-2);
- entityplayer.heal(-1f);
- }
- enchItem.remove(Integer.valueOf(e));
- if(item.isItemStackDamageable() && (item.getMaxDamage() - item.getItemDamage())/3 > 0) item.damageItem((item.getMaxDamage() - item.getItemDamage())/3, entityplayer);
- EnchantmentHelper.setEnchantments(enchItem, item);
- }
- }
- }
- if(entityplayer.inventory.currentItem + 1 <= 8 && entityplayer.inventory.getStackInSlot(entityplayer.inventory.currentItem + 1) != null && entityplayer.inventory.currentItem - 1 >= 0 && entityplayer.inventory.getStackInSlot(entityplayer.inventory.currentItem - 1) != null && JewelryNBT.isModeX(stack, "Transfer"))
- {
- if(cooldown > 0) entityplayer.addChatMessage(new ChatComponentText("Ring is currently cooling down!"));
- ItemStack enchantedItem = null, enchantableItem = null;
- if(entityplayer.inventory.getStackInSlot(entityplayer.inventory.currentItem - 1).isItemEnchanted() && entityplayer.inventory.getStackInSlot(entityplayer.inventory.currentItem + 1) != null)
- {
- enchantedItem = entityplayer.inventory.getStackInSlot(entityplayer.inventory.currentItem - 1);
- enchantableItem = entityplayer.inventory.getStackInSlot(entityplayer.inventory.currentItem + 1);
-
- }
- if(enchantedItem != null && enchantableItem != null)
- {
- Map enchItem = EnchantmentHelper.getEnchantments(enchantedItem);
- Map resultItem = EnchantmentHelper.getEnchantments(enchantableItem);
- Iterator iterator = enchItem.keySet().iterator();
- int e;
-
- if (iterator.hasNext() && cooldown == 0)
- {
- e = ((Integer)iterator.next()).intValue();
- if(!EnchantmentHelper.getEnchantments(enchantableItem).containsKey(Integer.valueOf(e)))
- {
- resultItem.put(Integer.valueOf(e), Integer.valueOf(((Integer)enchItem.get(Integer.valueOf(e))).intValue()));
- EnchantmentHelper.setEnchantments(resultItem, enchantableItem);
- enchItem.remove(Integer.valueOf(e));
- EnchantmentHelper.setEnchantments(enchItem, enchantedItem);
- cooldown = 50000;
- }
- }
- }
- }
- if(entityplayer.inventory.currentItem + 1 <= 8 && entityplayer.inventory.getStackInSlot(entityplayer.inventory.currentItem + 1) != null) item = entityplayer.inventory.getStackInSlot(entityplayer.inventory.currentItem + 1);
- else if(entityplayer.inventory.currentItem - 1 >= 0 && entityplayer.inventory.getStackInSlot(entityplayer.inventory.currentItem - 1) != null) item = entityplayer.inventory.getStackInSlot(entityplayer.inventory.currentItem - 1);
- if(item != null && !item.isItemEnchanted() && item.isItemEnchantable() && entityplayer.experienceLevel > 0 && JewelryNBT.isModeX(stack, "Enchant"))
- {
- Map enchItem = EnchantmentHelper.getEnchantments(item);
- int level = entityplayer.experienceLevel;
- if(entityplayer.experienceLevel > 6) level = 6;
- if(!entityplayer.capabilities.isCreativeMode) entityplayer.addExperienceLevel(-level);
- enchItem.put(Enchantment.enchantmentsBookList[new Random().nextInt(Enchantment.enchantmentsBookList.length)].effectId, level);
- EnchantmentHelper.setEnchantments(enchItem, item);
- }
- }
- }
- }
-
- public ItemStack getModifiedItemStack(ItemStack ingot, ItemStack modifier, ItemStack jewel)
- {
- ItemStack itemstack = new ItemStack(this);
- JewelryNBT.addMetal(itemstack, ingot);
- JewelryNBT.addModifier(itemstack, modifier);
- JewelryNBT.addJewel(itemstack, jewel);
- if(JewelryNBT.isModifierEffectType(itemstack) && !(JewelryNBT.isJewelX(itemstack, new ItemStack(Items.ender_pearl)) && JewelryNBT.isModifierX(itemstack, new ItemStack(Items.iron_pickaxe)))) JewelryNBT.addMode(itemstack, "Activated");
- if(JewelryNBT.isJewelX(itemstack, new ItemStack(Items.nether_star)) && JewelryNBT.isModifierX(itemstack, new ItemStack(Items.book)))
- JewelryNBT.addMode(itemstack, "Disenchant");
- return itemstack;
- }
-
- public void createGolems(World world, int i, int j, int k)
- {
- if (world.getBlock(i, j - 1, k) == Blocks.snow && world.getBlock(i, j - 2, k) == Blocks.snow)
- {
- if (!world.isRemote)
- {
- world.setBlock(i, j, k, Block.getBlockById(0), 0, 2);
- world.setBlock(i, j - 1, k, Block.getBlockById(0), 0, 2);
- world.setBlock(i, j - 2, k, Block.getBlockById(0), 0, 2);
- EntitySnowman entitysnowman = new EntitySnowman(world);
- entitysnowman.setLocationAndAngles((double)i + 0.5D, (double)j - 1.95D, (double)k + 0.5D, 0.0F, 0.0F);
- world.spawnEntityInWorld(entitysnowman);
- world.notifyBlockChange(i, j, k, Block.getBlockById(0));
- world.notifyBlockChange(i, j - 1, k, Block.getBlockById(0));
- world.notifyBlockChange(i, j - 2, k, Block.getBlockById(0));
- }
-
- for (int l = 0; l < 120; ++l)
- {
- world.spawnParticle("snowshovel", (double)i + world.rand.nextDouble(), (double)(j - 2) + world.rand.nextDouble() * 2.5D, (double)k + world.rand.nextDouble(), 0.0D, 0.0D, 0.0D);
- }
- }
- else if (world.getBlock(i, j - 1, k) == Blocks.iron_block && world.getBlock(i, j - 2, k) == Blocks.iron_block)
- {
- boolean flag = world.getBlock(i - 1, j - 1, k) == Blocks.iron_block && world.getBlock(i + 1, j - 1, k) == Blocks.iron_block;
- boolean flag1 = world.getBlock(i, j - 1, k - 1) == Blocks.iron_block && world.getBlock(i, j - 1, k + 1) == Blocks.iron_block;
-
- if (flag || flag1)
- {
- world.setBlock(i, j, k, Block.getBlockById(0), 0, 2);
- world.setBlock(i, j - 1, k, Block.getBlockById(0), 0, 2);
- world.setBlock(i, j - 2, k, Block.getBlockById(0), 0, 2);
-
- if (flag)
- {
- world.setBlock(i - 1, j - 1, k, Block.getBlockById(0), 0, 2);
- world.setBlock(i + 1, j - 1, k, Block.getBlockById(0), 0, 2);
- }
- else
- {
- world.setBlock(i, j - 1, k - 1, Block.getBlockById(0), 0, 2);
- world.setBlock(i, j - 1, k + 1, Block.getBlockById(0), 0, 2);
- }
-
- EntityIronGolem entityirongolem = new EntityIronGolem(world);
- entityirongolem.setPlayerCreated(true);
- entityirongolem.setLocationAndAngles((double)i + 0.5D, (double)j - 1.95D, (double)k + 0.5D, 0.0F, 0.0F);
- world.spawnEntityInWorld(entityirongolem);
-
- for (int i1 = 0; i1 < 120; ++i1)
- {
- world.spawnParticle("snowballpoof", (double)i + world.rand.nextDouble(), (double)(j - 2) + world.rand.nextDouble() * 3.9D, (double)k + world.rand.nextDouble(), 0.0D, 0.0D, 0.0D);
- }
-
- world.notifyBlockChange(i, j, k, Block.getBlockById(0));
- world.notifyBlockChange(i, j - 1, k, Block.getBlockById(0));
- world.notifyBlockChange(i, j - 2, k, Block.getBlockById(0));
-
- if (flag)
- {
- world.notifyBlockChange(i - 1, j - 1, k, Block.getBlockById(0));
- world.notifyBlockChange(i + 1, j - 1, k, Block.getBlockById(0));
- }
- else
- {
- world.notifyBlockChange(i, j - 1, k - 1, Block.getBlockById(0));
- world.notifyBlockChange(i, j - 1, k + 1, Block.getBlockById(0));
- }
- }
- }
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/item/ItemThiefGloves.java b/src/main/java/darkknight/jewelrycraft/item/ItemThiefGloves.java
deleted file mode 100644
index f61085a..0000000
--- a/src/main/java/darkknight/jewelrycraft/item/ItemThiefGloves.java
+++ /dev/null
@@ -1,113 +0,0 @@
-package darkknight.jewelrycraft.item;
-
-import java.util.Iterator;
-import java.util.List;
-import java.util.Random;
-
-import net.minecraft.creativetab.CreativeTabs;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.passive.EntityVillager;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.ChatComponentText;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.village.MerchantRecipe;
-import net.minecraft.village.MerchantRecipeList;
-
-import org.lwjgl.input.Keyboard;
-
-import cpw.mods.fml.common.FMLCommonHandler;
-import cpw.mods.fml.relauncher.ReflectionHelper;
-import cpw.mods.fml.relauncher.Side;
-
-public class ItemThiefGloves extends Item
-{
- public Random rand;
-
- public ItemThiefGloves()
- {
- super();
- this.setCreativeTab(CreativeTabs.tabTools);
- this.setMaxStackSize(1);
- this.setMaxDamage(10);
- }
-
- @Override
- public boolean itemInteractionForEntity(ItemStack stack, EntityPlayer par2EntityPlayer, EntityLivingBase par3EntityLivingBase)
- {
- if (par3EntityLivingBase instanceof EntityVillager)
- {
- EntityVillager villager = (EntityVillager) par3EntityLivingBase;
- int wealth = (Integer) ReflectionHelper.getPrivateValue(EntityVillager.class, villager, "wealth", "field_70956_bz");
- MerchantRecipeList buyingList = (MerchantRecipeList) ReflectionHelper.getPrivateValue(EntityVillager.class, villager, "buyingList", "field_70963_i");
- if (buyingList != null)
- {
- Iterator<?> iterator = buyingList.iterator();
- while (iterator.hasNext())
- {
- MerchantRecipe recipe = (MerchantRecipe) iterator.next();
- int toolUses = (Integer) ReflectionHelper.getPrivateValue(MerchantRecipe.class, recipe, "toolUses", "field_77400_d");
- int quantity;
- if (recipe.getItemToSell().isStackable())
- quantity = recipe.getItemToSell().stackSize * (7 - toolUses);
- else
- quantity = 1;
- ItemStack s = new ItemStack(recipe.getItemToSell().getItem(), quantity, recipe.getItemToSell().getItemDamage());
- s.setTagCompound(recipe.getItemToSell().getTagCompound());
- if (par2EntityPlayer.inventory.addItemStackToInventory(s))
- ;
- else
- villager.entityDropItem(s, 0);
- par2EntityPlayer.addChatMessage(new ChatComponentText("Villager #" + villager.getProfession() + ": Hmmm... I seem to have lost my " + s.getDisplayName() + "!"));
- stack.damageItem(1, par2EntityPlayer);
- }
- buyingList.clear();
- ReflectionHelper.setPrivateValue(EntityVillager.class, villager, 300, "timeUntilReset", "field_70961_j");
- ReflectionHelper.setPrivateValue(EntityVillager.class, villager, true, "needsInitilization", "field_70959_by");
- }
-
- villager.dropItem(Items.emerald, wealth);
- ReflectionHelper.setPrivateValue(EntityVillager.class, villager, 0, "wealth", "field_70956_bz");
- return true;
- }
- else
- {
- return super.itemInteractionForEntity(stack, par2EntityPlayer, par3EntityLivingBase);
- }
- }
-
- @Override
- @SuppressWarnings("unchecked")
- public void addInformation(ItemStack stack, EntityPlayer player, @SuppressWarnings("rawtypes") List list, boolean par4)
- {
- if (!shouldAddAdditionalInfo())
- list.add(EnumChatFormatting.GRAY + additionalInfoInstructions());
- else
- {
- list.add(EnumChatFormatting.GRAY + "Right click with the gloves,");
- list.add(EnumChatFormatting.GRAY + "while sneaking, on a villager");
- list.add(EnumChatFormatting.GRAY + "to steal his stuff.");
- }
- }
-
- public static boolean shouldAddAdditionalInfo()
- {
- if (FMLCommonHandler.instance().getEffectiveSide() == Side.CLIENT)
- {
- if (Keyboard.isKeyDown(Keyboard.KEY_LSHIFT))
- {
- return true;
- }
- }
- return false;
- }
-
- public static String additionalInfoInstructions()
- {
- String message = "\247oPress \247b<SHIFT>\2477\247o for more information.";
- return message;
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/lib/Reference.java b/src/main/java/darkknight/jewelrycraft/lib/Reference.java
deleted file mode 100644
index ba22205..0000000
--- a/src/main/java/darkknight/jewelrycraft/lib/Reference.java
+++ /dev/null
@@ -1,9 +0,0 @@
-package darkknight.jewelrycraft.lib;
-
-public class Reference
-{
- public static final String MODID = "Jewelrycraft";
- public static final String MODNAME = "Jewelrycraft";
- public static final String VERSION = "1.4";
- public static final String PACKET_CHANNEL = "Jewelrycraft";
-}
diff --git a/src/main/java/darkknight/jewelrycraft/model/ModelDisplayer.java b/src/main/java/darkknight/jewelrycraft/model/ModelDisplayer.java
deleted file mode 100644
index 9764ca0..0000000
--- a/src/main/java/darkknight/jewelrycraft/model/ModelDisplayer.java
+++ /dev/null
@@ -1,241 +0,0 @@
-package darkknight.jewelrycraft.model;
-
-import org.lwjgl.opengl.GL11;
-
-import net.minecraft.client.model.ModelBase;
-import net.minecraft.client.model.ModelRenderer;
-import net.minecraft.entity.Entity;
-
-public class ModelDisplayer extends ModelBase
-{
- //fields
- ModelRenderer Base;
- ModelRenderer Ring11;
- ModelRenderer Ring12;
- ModelRenderer Ring13;
- ModelRenderer Ring14;
- ModelRenderer Ring31;
- ModelRenderer Ring21;
- ModelRenderer Ring32;
- ModelRenderer Ring22;
- ModelRenderer Ring33;
- ModelRenderer Ring23;
- ModelRenderer Ring34;
- ModelRenderer Ring24;
- ModelRenderer Ring25;
- ModelRenderer Ring26;
- ModelRenderer Ring27;
- ModelRenderer Ring28;
- ModelRenderer Ring35;
- ModelRenderer Ring36;
- ModelRenderer Ring37;
- ModelRenderer Ring38;
- ModelRenderer Ring39;
- ModelRenderer Ring310;
- ModelRenderer Ring311;
- ModelRenderer Ring312;
-
- public ModelDisplayer()
- {
- textureWidth = 64;
- textureHeight = 32;
-
- Base = new ModelRenderer(this, 0, 0);
- Base.addBox(0F, 0F, 0F, 16, 3, 16);
- Base.setRotationPoint(-8F, 21F, -8F);
- Base.setTextureSize(64, 32);
- Base.mirror = true;
- setRotation(Base, 0F, 0F, 0F);
- Ring11 = new ModelRenderer(this, 0, 26);
- Ring11.addBox(-2F, 0F, 2F, 4, 1, 1);
- Ring11.setRotationPoint(0F, 19F, 0F);
- Ring11.setTextureSize(64, 32);
- Ring11.mirror = true;
- setRotation(Ring11, 0F, 0F, 0F);
- Ring12 = new ModelRenderer(this, 0, 20);
- Ring12.addBox(-3F, 0F, -2F, 1, 1, 4);
- Ring12.setRotationPoint(0F, 19F, 0F);
- Ring12.setTextureSize(64, 32);
- Ring12.mirror = true;
- setRotation(Ring12, 0F, 0F, 0F);
- Ring13 = new ModelRenderer(this, 0, 20);
- Ring13.addBox(2F, 0F, -2F, 1, 1, 4);
- Ring13.setRotationPoint(0F, 19F, 0F);
- Ring13.setTextureSize(64, 32);
- Ring13.mirror = true;
- setRotation(Ring13, 0F, 0F, 0F);
- Ring14 = new ModelRenderer(this, 0, 26);
- Ring14.addBox(-2F, 0F, -3F, 4, 1, 1);
- Ring14.setRotationPoint(0F, 19F, 0F);
- Ring14.setTextureSize(64, 32);
- Ring14.mirror = true;
- setRotation(Ring14, 0F, 0F, 0F);
- Ring21 = new ModelRenderer(this, 0, 29);
- Ring21.addBox(-4F, 0F, 3F, 1, 1, 1);
- Ring21.setRotationPoint(0F, 19F, 0F);
- Ring21.setTextureSize(64, 32);
- Ring21.mirror = true;
- setRotation(Ring21, 0F, 0F, 0F);
- Ring22 = new ModelRenderer(this, 0, 29);
- Ring22.addBox(-4F, 0F, -4F, 1, 1, 1);
- Ring22.setRotationPoint(0F, 19F, 0F);
- Ring22.setTextureSize(64, 32);
- Ring22.mirror = true;
- setRotation(Ring22, 0F, 0F, 0F);
- Ring23 = new ModelRenderer(this, 0, 29);
- Ring23.addBox(3F, 0F, -4F, 1, 1, 1);
- Ring23.setRotationPoint(0F, 19F, 0F);
- Ring23.setTextureSize(64, 32);
- Ring23.mirror = true;
- setRotation(Ring23, 0F, 0F, 0F);
- Ring34 = new ModelRenderer(this, 26, 20);
- Ring34.addBox(6F, 0F, -4F, 1, 1, 8);
- Ring34.setRotationPoint(0F, 19F, 0F);
- Ring34.setTextureSize(64, 32);
- Ring34.mirror = true;
- setRotation(Ring34, 0F, 0F, 0F);
- Ring24 = new ModelRenderer(this, 0, 29);
- Ring24.addBox(3F, 0F, 3F, 1, 1, 1);
- Ring24.setRotationPoint(0F, 19F, 0F);
- Ring24.setTextureSize(64, 32);
- Ring24.mirror = true;
- setRotation(Ring24, 0F, 0F, 0F);
- Ring25 = new ModelRenderer(this, 11, 20);
- Ring25.addBox(4F, 0F, -3F, 1, 1, 6);
- Ring25.setRotationPoint(0F, 19F, 0F);
- Ring25.setTextureSize(64, 32);
- Ring25.mirror = true;
- setRotation(Ring25, 0F, 0F, 0F);
- Ring26 = new ModelRenderer(this, 11, 28);
- Ring26.addBox(-3F, 0F, -5F, 6, 1, 1);
- Ring26.setRotationPoint(0F, 19F, 0F);
- Ring26.setTextureSize(64, 32);
- Ring26.mirror = true;
- setRotation(Ring26, 0F, 0F, 0F);
- Ring27 = new ModelRenderer(this, 11, 20);
- Ring27.addBox(-5F, 0F, -3F, 1, 1, 6);
- Ring27.setRotationPoint(0F, 19F, 0F);
- Ring27.setTextureSize(64, 32);
- Ring27.mirror = true;
- setRotation(Ring27, 0F, 0F, 0F);
- Ring28 = new ModelRenderer(this, 11, 28);
- Ring28.addBox(-3F, 0F, 4F, 6, 1, 1);
- Ring28.setRotationPoint(0F, 19F, 0F);
- Ring28.setTextureSize(64, 32);
- Ring28.mirror = true;
- setRotation(Ring28, 0F, 0F, 0F);
- Ring31 = new ModelRenderer(this, 0, 29);
- Ring31.addBox(-6F, 0F, 4F, 1, 1, 1);
- Ring31.setRotationPoint(0F, 19F, 0F);
- Ring31.setTextureSize(64, 32);
- Ring31.mirror = true;
- setRotation(Ring31, 0F, 0F, 0F);
- Ring32 = new ModelRenderer(this, 26, 20);
- Ring32.addBox(-7F, 0F, -4F, 1, 1, 8);
- Ring32.setRotationPoint(0F, 19F, 0F);
- Ring32.setTextureSize(64, 32);
- Ring32.mirror = true;
- setRotation(Ring32, 0F, 0F, 0F);
- Ring33 = new ModelRenderer(this, 26, 30);
- Ring33.addBox(-4F, 0F, -7F, 8, 1, 1);
- Ring33.setRotationPoint(0F, 19F, 0F);
- Ring33.setTextureSize(64, 32);
- Ring33.mirror = true;
- setRotation(Ring33, 0F, 0F, 0F);
- Ring35 = new ModelRenderer(this, 26, 30);
- Ring35.addBox(-4F, 0F, 6F, 8, 1, 1);
- Ring35.setRotationPoint(0F, 19F, 0F);
- Ring35.setTextureSize(64, 32);
- Ring35.mirror = true;
- setRotation(Ring35, 0F, 0F, 0F);
- Ring36 = new ModelRenderer(this, 0, 29);
- Ring36.addBox(-5F, 0F, 5F, 1, 1, 1);
- Ring36.setRotationPoint(0F, 19F, 0F);
- Ring36.setTextureSize(64, 32);
- Ring36.mirror = true;
- setRotation(Ring36, 0F, 0F, 0F);
- Ring37 = new ModelRenderer(this, 0, 29);
- Ring37.addBox(5F, 0F, 4F, 1, 1, 1);
- Ring37.setRotationPoint(0F, 19F, 0F);
- Ring37.setTextureSize(64, 32);
- Ring37.mirror = true;
- setRotation(Ring37, 0F, 0F, 0F);
- Ring38 = new ModelRenderer(this, 0, 29);
- Ring38.addBox(4F, 0F, 5F, 1, 1, 1);
- Ring38.setRotationPoint(0F, 19F, 0F);
- Ring38.setTextureSize(64, 32);
- Ring38.mirror = true;
- setRotation(Ring38, 0F, 0F, 0F);
- Ring39 = new ModelRenderer(this, 0, 29);
- Ring39.addBox(4F, 0F, -6F, 1, 1, 1);
- Ring39.setRotationPoint(0F, 19F, 0F);
- Ring39.setTextureSize(64, 32);
- Ring39.mirror = true;
- setRotation(Ring39, 0F, 0F, 0F);
- Ring310 = new ModelRenderer(this, 0, 29);
- Ring310.addBox(5F, 0F, -5F, 1, 1, 1);
- Ring310.setRotationPoint(0F, 19F, 0F);
- Ring310.setTextureSize(64, 32);
- Ring310.mirror = true;
- setRotation(Ring310, 0F, 0F, 0F);
- Ring311 = new ModelRenderer(this, 0, 29);
- Ring311.addBox(-6F, 0F, -5F, 1, 1, 1);
- Ring311.setRotationPoint(0F, 19F, 0F);
- Ring311.setTextureSize(64, 32);
- Ring311.mirror = true;
- setRotation(Ring311, 0F, 0F, 0F);
- Ring312 = new ModelRenderer(this, 0, 29);
- Ring312.addBox(-5F, 0F, -6F, 1, 1, 1);
- Ring312.setRotationPoint(0F, 19F, 0F);
- Ring312.setTextureSize(64, 32);
- Ring312.mirror = true;
- setRotation(Ring312, 0F, 0F, 0F);
- }
-
- public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5)
- {
- GL11.glPushMatrix();
- Base.render(f5);
- GL11.glTranslatef(0.0F, 0F - f, 0.0F);
- Ring11.render(f5);
- Ring12.render(f5);
- Ring13.render(f5);
- Ring14.render(f5);
- GL11.glTranslatef(0.0F, 0F + f - f1, 0.0F);
- Ring21.render(f5);
- Ring22.render(f5);
- Ring23.render(f5);
- Ring24.render(f5);
- Ring25.render(f5);
- Ring26.render(f5);
- Ring27.render(f5);
- Ring28.render(f5);
- GL11.glTranslatef(0.0F, 0F + f1 - f2, 0.0F);
- Ring31.render(f5);
- Ring32.render(f5);
- Ring33.render(f5);
- Ring34.render(f5);
- Ring35.render(f5);
- Ring36.render(f5);
- Ring37.render(f5);
- Ring38.render(f5);
- Ring39.render(f5);
- Ring310.render(f5);
- Ring311.render(f5);
- Ring312.render(f5);
- GL11.glPopMatrix();
- }
-
- private void setRotation(ModelRenderer model, float x, float y, float z)
- {
- model.rotateAngleX = x;
- model.rotateAngleY = y;
- model.rotateAngleZ = z;
- }
-
- public void setRotationAngles(float f, float f1, float f2, float f3, float f4, float f5)
- {
- super.setRotationAngles(f, f1, f2, f3, f4, f5, null);
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/model/ModelJewlersCraftingBench.java b/src/main/java/darkknight/jewelrycraft/model/ModelJewlersCraftingBench.java
deleted file mode 100644
index 1cc3f72..0000000
--- a/src/main/java/darkknight/jewelrycraft/model/ModelJewlersCraftingBench.java
+++ /dev/null
@@ -1,140 +0,0 @@
-package darkknight.jewelrycraft.model;
-
-import net.minecraft.client.model.ModelBase;
-import net.minecraft.client.model.ModelRenderer;
-import net.minecraft.entity.Entity;
-
-public class ModelJewlersCraftingBench extends ModelBase
-{
- //fields
- ModelRenderer Leg1;
- ModelRenderer Leg2;
- ModelRenderer Leg3;
- ModelRenderer Leg4;
- ModelRenderer Top;
- ModelRenderer Support1;
- ModelRenderer Support2;
- ModelRenderer Support3;
- ModelRenderer Support4;
- ModelRenderer Support5;
- ModelRenderer Support6;
- ModelRenderer Support7;
- ModelRenderer Support8;
-
- public ModelJewlersCraftingBench()
- {
- textureWidth = 64;
- textureHeight = 32;
-
- Leg1 = new ModelRenderer(this, 0, 0);
- Leg1.addBox(0F, 0F, 0F, 2, 10, 2);
- Leg1.setRotationPoint(-6F, 14F, 4F);
- Leg1.setTextureSize(64, 32);
- Leg1.mirror = true;
- setRotation(Leg1, 0F, 0F, 0F);
- Leg2 = new ModelRenderer(this, 0, 0);
- Leg2.addBox(0F, 0F, 0F, 2, 10, 2);
- Leg2.setRotationPoint(-6F, 14F, -6F);
- Leg2.setTextureSize(64, 32);
- Leg2.mirror = true;
- setRotation(Leg2, 0F, 0F, 0F);
- Leg3 = new ModelRenderer(this, 0, 0);
- Leg3.addBox(0F, 0F, 0F, 2, 10, 2);
- Leg3.setRotationPoint(4F, 14F, -6F);
- Leg3.setTextureSize(64, 32);
- Leg3.mirror = true;
- setRotation(Leg3, 0F, 0F, 0F);
- Leg4 = new ModelRenderer(this, 0, 0);
- Leg4.addBox(0F, 0F, 0F, 2, 10, 2);
- Leg4.setRotationPoint(4F, 14F, 4F);
- Leg4.setTextureSize(64, 32);
- Leg4.mirror = true;
- setRotation(Leg4, 0F, 0F, 0F);
- Top = new ModelRenderer(this, 0, 13);
- Top.addBox(0F, 0F, 0F, 16, 1, 16);
- Top.setRotationPoint(-8F, 13F, -8F);
- Top.setTextureSize(64, 32);
- Top.mirror = true;
- setRotation(Top, 0F, 0F, 0F);
- Support1 = new ModelRenderer(this, 0, 0);
- Support1.addBox(0F, 0F, 0F, 3, 1, 1);
- Support1.setRotationPoint(3F, 12F, 5F);
- Support1.setTextureSize(64, 32);
- Support1.mirror = true;
- setRotation(Support1, 0F, 0F, 0F);
- Support2 = new ModelRenderer(this, 0, 0);
- Support2.addBox(0F, 0F, 0F, 1, 1, 3);
- Support2.setRotationPoint(2F, 12F, 2F);
- Support2.setTextureSize(64, 32);
- Support2.mirror = true;
- setRotation(Support2, 0F, 0F, 0F);
- Support3 = new ModelRenderer(this, 0, 0);
- Support3.addBox(0F, 0F, 0F, 1, 1, 3);
- Support3.setRotationPoint(6F, 12F, 2F);
- Support3.setTextureSize(64, 32);
- Support3.mirror = true;
- setRotation(Support3, 0F, 0F, 0F);
- Support4 = new ModelRenderer(this, 0, 0);
- Support4.addBox(0F, 0F, 0F, 3, 1, 1);
- Support4.setRotationPoint(3F, 12F, 1F);
- Support4.setTextureSize(64, 32);
- Support4.mirror = true;
- setRotation(Support4, 0F, 0F, 0F);
- Support5 = new ModelRenderer(this, 0, 0);
- Support5.addBox(0F, 0F, 0F, 1, 1, 3);
- Support5.setRotationPoint(-3F, 12F, 2F);
- Support5.setTextureSize(64, 32);
- Support5.mirror = true;
- setRotation(Support5, 0F, 0F, 0F);
- Support6 = new ModelRenderer(this, 0, 0);
- Support6.addBox(0F, 0F, 0F, 3, 1, 1);
- Support6.setRotationPoint(-6F, 12F, 5F);
- Support6.setTextureSize(64, 32);
- Support6.mirror = true;
- setRotation(Support6, 0F, 0F, 0F);
- Support7 = new ModelRenderer(this, 0, 0);
- Support7.addBox(0F, 0F, 0F, 1, 1, 3);
- Support7.setRotationPoint(-7F, 12F, 2F);
- Support7.setTextureSize(64, 32);
- Support7.mirror = true;
- setRotation(Support7, 0F, 0F, 0F);
- Support8 = new ModelRenderer(this, 0, 0);
- Support8.addBox(0F, 0F, 0F, 3, 1, 1);
- Support8.setRotationPoint(-6F, 12F, 1F);
- Support8.setTextureSize(64, 32);
- Support8.mirror = true;
- setRotation(Support8, 0F, 0F, 0F);
- }
-
- public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5)
- {
- super.render(entity, f, f1, f2, f3, f4, f5);
- setRotationAngles(f, f1, f2, f3, f4, f5);
- Leg1.render(f5);
- Leg2.render(f5);
- Leg3.render(f5);
- Leg4.render(f5);
- Top.render(f5);
- Support1.render(f5);
- Support2.render(f5);
- Support3.render(f5);
- Support4.render(f5);
- Support5.render(f5);
- Support6.render(f5);
- Support7.render(f5);
- Support8.render(f5);
- }
-
- private void setRotation(ModelRenderer model, float x, float y, float z)
- {
- model.rotateAngleX = x;
- model.rotateAngleY = y;
- model.rotateAngleZ = z;
- }
-
- public void setRotationAngles(float f, float f1, float f2, float f3, float f4, float f5)
- {
- super.setRotationAngles(f, f1, f2, f3, f4, f5, null);
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/model/ModelMolder.java b/src/main/java/darkknight/jewelrycraft/model/ModelMolder.java
deleted file mode 100644
index 374b218..0000000
--- a/src/main/java/darkknight/jewelrycraft/model/ModelMolder.java
+++ /dev/null
@@ -1,76 +0,0 @@
-package darkknight.jewelrycraft.model;
-
-import net.minecraft.client.model.ModelBase;
-import net.minecraft.client.model.ModelRenderer;
-import net.minecraft.entity.Entity;
-
-public class ModelMolder extends ModelBase
-{
- //fields
- ModelRenderer Base;
- ModelRenderer Side;
- ModelRenderer Side1;
- ModelRenderer Side2;
- ModelRenderer Side3;
-
- public ModelMolder()
- {
- textureWidth = 64;
- textureHeight = 32;
-
- Base = new ModelRenderer(this, 0, 0);
- Base.addBox(0F, 0F, 0F, 10, 1, 10);
- Base.setRotationPoint(-5F, 23F, -5F);
- Base.setTextureSize(64, 32);
- Base.mirror = true;
- setRotation(Base, 0F, 0F, 0F);
- Side = new ModelRenderer(this, 0, 13);
- Side.addBox(0F, 0F, 0F, 10, 2, 1);
- Side.setRotationPoint(-5F, 21F, 5F);
- Side.setTextureSize(64, 32);
- Side.mirror = true;
- setRotation(Side, 0F, 0F, 0F);
- Side1 = new ModelRenderer(this, 0, 13);
- Side1.addBox(0F, 0F, 0F, 10, 2, 1);
- Side1.setRotationPoint(-5F, 21F, -6F);
- Side1.setTextureSize(64, 32);
- Side1.mirror = true;
- setRotation(Side1, 0F, 0F, 0F);
- Side2 = new ModelRenderer(this, 41, 0);
- Side2.addBox(0F, 0F, 0F, 1, 2, 10);
- Side2.setRotationPoint(-6F, 21F, -5F);
- Side2.setTextureSize(64, 32);
- Side2.mirror = true;
- setRotation(Side2, 0F, 0F, 0F);
- Side3 = new ModelRenderer(this, 41, 0);
- Side3.addBox(0F, 0F, 0F, 1, 2, 10);
- Side3.setRotationPoint(5F, 21F, -5F);
- Side3.setTextureSize(64, 32);
- Side3.mirror = true;
- setRotation(Side3, 0F, 0F, 0F);
- }
-
- public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5)
- {
- super.render(entity, f, f1, f2, f3, f4, f5);
- setRotationAngles(f, f1, f2, f3, f4, f5);
- Base.render(f5);
- Side.render(f5);
- Side1.render(f5);
- Side2.render(f5);
- Side3.render(f5);
- }
-
- private void setRotation(ModelRenderer model, float x, float y, float z)
- {
- model.rotateAngleX = x;
- model.rotateAngleY = y;
- model.rotateAngleZ = z;
- }
-
- public void setRotationAngles(float f, float f1, float f2, float f3, float f4, float f5)
- {
- super.setRotationAngles(f, f1, f2, f3, f4, f5, null);
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/model/ModelSmelter.java b/src/main/java/darkknight/jewelrycraft/model/ModelSmelter.java
deleted file mode 100644
index afb3b09..0000000
--- a/src/main/java/darkknight/jewelrycraft/model/ModelSmelter.java
+++ /dev/null
@@ -1,276 +0,0 @@
-package darkknight.jewelrycraft.model;
-
-import net.minecraft.client.model.ModelBase;
-import net.minecraft.client.model.ModelRenderer;
-import net.minecraft.entity.Entity;
-
-public class ModelSmelter extends ModelBase
-{
- //fields
- ModelRenderer Support1;
- ModelRenderer Support2;
- ModelRenderer Hold1;
- ModelRenderer Hold2;
- ModelRenderer SmelterBase;
- ModelRenderer SmelterSide1;
- ModelRenderer SmelterSide2;
- ModelRenderer SmelterSide3;
- ModelRenderer SmelterSide4;
- ModelRenderer SmelterSide5;
- ModelRenderer SmelterSide6;
- ModelRenderer SmelterSide7;
- ModelRenderer SmelterSide8;
- ModelRenderer SmelterSide9;
- ModelRenderer SmelterSide10;
- ModelRenderer SmelterSide11;
- ModelRenderer SmelterSide12;
- ModelRenderer HeatSourceSide1;
- ModelRenderer HeatSourceSide2;
- ModelRenderer HeatSourceSide3;
- ModelRenderer HeatSourceSide4;
- ModelRenderer HeatSourceSide5;
- ModelRenderer HeatSourceBase;
- ModelRenderer HeatSourceSide6;
- ModelRenderer HeatSourceSide7;
- ModelRenderer HeatSourceSide8;
- ModelRenderer HeatSourceSide9;
- ModelRenderer HeatSourceSide10;
- ModelRenderer HeatSourceSide11;
- ModelRenderer HeatSourceSide12;
-
- public ModelSmelter()
- {
- textureWidth = 64;
- textureHeight = 32;
-
- Support1 = new ModelRenderer(this, 0, 0);
- Support1.addBox(0F, 0F, 0F, 2, 15, 3);
- Support1.setRotationPoint(6F, 9F, -1F);
- Support1.setTextureSize(64, 32);
- Support1.mirror = true;
- setRotation(Support1, 0F, 0F, 0F);
- Support2 = new ModelRenderer(this, 0, 0);
- Support2.addBox(0F, 0F, 0F, 2, 15, 3);
- Support2.setRotationPoint(-8F, 9F, -1F);
- Support2.setTextureSize(64, 32);
- Support2.mirror = true;
- setRotation(Support2, 0F, 0F, 0F);
- Hold1 = new ModelRenderer(this, 0, 0);
- Hold1.addBox(0F, 0F, 0F, 2, 1, 1);
- Hold1.setRotationPoint(4F, 11F, 0F);
- Hold1.setTextureSize(64, 32);
- Hold1.mirror = true;
- setRotation(Hold1, 0F, 0F, 0F);
- Hold2 = new ModelRenderer(this, 0, 0);
- Hold2.addBox(0F, 0F, 0F, 2, 1, 1);
- Hold2.setRotationPoint(-6F, 11F, 0F);
- Hold2.setTextureSize(64, 32);
- Hold2.mirror = true;
- setRotation(Hold2, 0F, 0F, 0F);
- SmelterBase = new ModelRenderer(this, 0, 0);
- SmelterBase.addBox(0F, 0F, 0F, 4, 1, 5);
- SmelterBase.setRotationPoint(-2F, 18F, -2F);
- SmelterBase.setTextureSize(64, 32);
- SmelterBase.mirror = true;
- setRotation(SmelterBase, 0F, 0F, 0F);
- SmelterSide1 = new ModelRenderer(this, 0, 0);
- SmelterSide1.addBox(0F, 0F, 0F, 4, 2, 1);
- SmelterSide1.setRotationPoint(-2F, 16F, -3F);
- SmelterSide1.setTextureSize(64, 32);
- SmelterSide1.mirror = true;
- setRotation(SmelterSide1, 0F, 0F, 0F);
- SmelterSide2 = new ModelRenderer(this, 0, 0);
- SmelterSide2.addBox(0F, 0F, 0F, 4, 2, 1);
- SmelterSide2.setRotationPoint(-2F, 16F, 3F);
- SmelterSide2.setTextureSize(64, 32);
- SmelterSide2.mirror = true;
- setRotation(SmelterSide2, 0F, 0F, 0F);
- SmelterSide3 = new ModelRenderer(this, 0, 0);
- SmelterSide3.addBox(0F, 0F, 0F, 1, 2, 5);
- SmelterSide3.setRotationPoint(2F, 16F, -2F);
- SmelterSide3.setTextureSize(64, 32);
- SmelterSide3.mirror = true;
- setRotation(SmelterSide3, 0F, 0F, 0F);
- SmelterSide4 = new ModelRenderer(this, 0, 0);
- SmelterSide4.addBox(0F, 0F, 0F, 1, 2, 5);
- SmelterSide4.setRotationPoint(-3F, 16F, -2F);
- SmelterSide4.setTextureSize(64, 32);
- SmelterSide4.mirror = true;
- setRotation(SmelterSide4, 0F, 0F, 0F);
- SmelterSide5 = new ModelRenderer(this, 0, 0);
- SmelterSide5.addBox(0F, 0F, 0F, 1, 7, 5);
- SmelterSide5.setRotationPoint(3F, 9F, -2F);
- SmelterSide5.setTextureSize(64, 32);
- SmelterSide5.mirror = true;
- setRotation(SmelterSide5, 0F, 0F, 0F);
- SmelterSide6 = new ModelRenderer(this, 0, 0);
- SmelterSide6.addBox(0F, 0F, 0F, 1, 7, 5);
- SmelterSide6.setRotationPoint(-4F, 9F, -2F);
- SmelterSide6.setTextureSize(64, 32);
- SmelterSide6.mirror = true;
- setRotation(SmelterSide6, 0F, 0F, 0F);
- SmelterSide7 = new ModelRenderer(this, 0, 0);
- SmelterSide7.addBox(0F, 0F, 0F, 1, 7, 1);
- SmelterSide7.setRotationPoint(2F, 9F, 3F);
- SmelterSide7.setTextureSize(64, 32);
- SmelterSide7.mirror = true;
- setRotation(SmelterSide7, 0F, 0F, 0F);
- SmelterSide8 = new ModelRenderer(this, 0, 0);
- SmelterSide8.addBox(0F, 0F, 0F, 1, 7, 1);
- SmelterSide8.setRotationPoint(-3F, 9F, 3F);
- SmelterSide8.setTextureSize(64, 32);
- SmelterSide8.mirror = true;
- setRotation(SmelterSide8, 0F, 0F, 0F);
- SmelterSide9 = new ModelRenderer(this, 0, 0);
- SmelterSide9.addBox(0F, 0F, 0F, 4, 7, 1);
- SmelterSide9.setRotationPoint(-2F, 9F, 4F);
- SmelterSide9.setTextureSize(64, 32);
- SmelterSide9.mirror = true;
- setRotation(SmelterSide9, 0F, 0F, 0F);
- SmelterSide10 = new ModelRenderer(this, 0, 0);
- SmelterSide10.addBox(0F, 0F, 0F, 4, 7, 1);
- SmelterSide10.setRotationPoint(-2F, 9F, -4F);
- SmelterSide10.setTextureSize(64, 32);
- SmelterSide10.mirror = true;
- setRotation(SmelterSide10, 0F, 0F, 0F);
- SmelterSide11 = new ModelRenderer(this, 0, 0);
- SmelterSide11.addBox(0F, 0F, 0F, 1, 7, 1);
- SmelterSide11.setRotationPoint(2F, 9F, -3F);
- SmelterSide11.setTextureSize(64, 32);
- SmelterSide11.mirror = true;
- setRotation(SmelterSide11, 0F, 0F, 0F);
- SmelterSide12 = new ModelRenderer(this, 0, 0);
- SmelterSide12.addBox(0F, 0F, 0F, 1, 7, 1);
- SmelterSide12.setRotationPoint(-3F, 9F, -3F);
- SmelterSide12.setTextureSize(64, 32);
- SmelterSide12.mirror = true;
- setRotation(SmelterSide12, 0F, 0F, 0F);
- HeatSourceSide1 = new ModelRenderer(this, 0, 0);
- HeatSourceSide1.addBox(0F, 0F, 0F, 8, 2, 1);
- HeatSourceSide1.setRotationPoint(-4F, 19F, 7F);
- HeatSourceSide1.setTextureSize(64, 32);
- HeatSourceSide1.mirror = true;
- setRotation(HeatSourceSide1, 0F, 0F, 0F);
- HeatSourceSide2 = new ModelRenderer(this, 0, 0);
- HeatSourceSide2.addBox(0F, 0F, 0F, 1, 2, 12);
- HeatSourceSide2.setRotationPoint(-6F, 19F, -6F);
- HeatSourceSide2.setTextureSize(64, 32);
- HeatSourceSide2.mirror = true;
- setRotation(HeatSourceSide2, 0F, 0F, 0F);
- HeatSourceSide3 = new ModelRenderer(this, 0, 0);
- HeatSourceSide3.addBox(0F, 0F, 0F, 1, 2, 12);
- HeatSourceSide3.setRotationPoint(5F, 19F, -6F);
- HeatSourceSide3.setTextureSize(64, 32);
- HeatSourceSide3.mirror = true;
- setRotation(HeatSourceSide3, 0F, 0F, 0F);
- HeatSourceSide4 = new ModelRenderer(this, 0, 0);
- HeatSourceSide4.addBox(0F, 0F, 0F, 1, 2, 12);
- HeatSourceSide4.setRotationPoint(4F, 21F, -6F);
- HeatSourceSide4.setTextureSize(64, 32);
- HeatSourceSide4.mirror = true;
- setRotation(HeatSourceSide4, 0F, 0F, 0F);
- HeatSourceSide5 = new ModelRenderer(this, 0, 0);
- HeatSourceSide5.addBox(0F, 0F, 0F, 1, 2, 12);
- HeatSourceSide5.setRotationPoint(-5F, 21F, -6F);
- HeatSourceSide5.setTextureSize(64, 32);
- HeatSourceSide5.mirror = true;
- setRotation(HeatSourceSide5, 0F, 0F, 0F);
- HeatSourceBase = new ModelRenderer(this, 0, 0);
- HeatSourceBase.addBox(0F, 0F, 0F, 8, 1, 12);
- HeatSourceBase.setRotationPoint(-4F, 23F, -6F);
- HeatSourceBase.setTextureSize(64, 32);
- HeatSourceBase.mirror = true;
- setRotation(HeatSourceBase, 0F, 0F, 0F);
- HeatSourceSide6 = new ModelRenderer(this, 0, 0);
- HeatSourceSide6.addBox(0F, 0F, 0F, 8, 2, 1);
- HeatSourceSide6.setRotationPoint(-4F, 21F, -7F);
- HeatSourceSide6.setTextureSize(64, 32);
- HeatSourceSide6.mirror = true;
- setRotation(HeatSourceSide6, 0F, 0F, 0F);
- HeatSourceSide7 = new ModelRenderer(this, 0, 0);
- HeatSourceSide7.addBox(0F, 0F, 0F, 8, 2, 1);
- HeatSourceSide7.setRotationPoint(-4F, 21F, 6F);
- HeatSourceSide7.setTextureSize(64, 32);
- HeatSourceSide7.mirror = true;
- setRotation(HeatSourceSide7, 0F, 0F, 0F);
- HeatSourceSide8 = new ModelRenderer(this, 0, 0);
- HeatSourceSide8.addBox(0F, 0F, 0F, 1, 2, 1);
- HeatSourceSide8.setRotationPoint(-5F, 19F, 6F);
- HeatSourceSide8.setTextureSize(64, 32);
- HeatSourceSide8.mirror = true;
- setRotation(HeatSourceSide8, 0F, 0F, 0F);
- HeatSourceSide9 = new ModelRenderer(this, 0, 0);
- HeatSourceSide9.addBox(0F, 0F, 0F, 1, 2, 1);
- HeatSourceSide9.setRotationPoint(4F, 19F, 6F);
- HeatSourceSide9.setTextureSize(64, 32);
- HeatSourceSide9.mirror = true;
- setRotation(HeatSourceSide9, 0F, 0F, 0F);
- HeatSourceSide10 = new ModelRenderer(this, 0, 0);
- HeatSourceSide10.addBox(0F, 0F, 0F, 1, 2, 1);
- HeatSourceSide10.setRotationPoint(4F, 19F, -7F);
- HeatSourceSide10.setTextureSize(64, 32);
- HeatSourceSide10.mirror = true;
- setRotation(HeatSourceSide10, 0F, 0F, 0F);
- HeatSourceSide11 = new ModelRenderer(this, 0, 0);
- HeatSourceSide11.addBox(0F, 0F, 0F, 1, 2, 1);
- HeatSourceSide11.setRotationPoint(-5F, 19F, -7F);
- HeatSourceSide11.setTextureSize(64, 32);
- HeatSourceSide11.mirror = true;
- setRotation(HeatSourceSide11, 0F, 0F, 0F);
- HeatSourceSide12 = new ModelRenderer(this, 0, 0);
- HeatSourceSide12.addBox(0F, 0F, 0F, 8, 2, 1);
- HeatSourceSide12.setRotationPoint(-4F, 19F, -8F);
- HeatSourceSide12.setTextureSize(64, 32);
- HeatSourceSide12.mirror = true;
- setRotation(HeatSourceSide12, 0F, 0F, 0F);
- }
-
- public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5)
- {
- super.render(entity, f, f1, f2, f3, f4, f5);
- setRotationAngles(f, f1, f2, f3, f4, f5);
- Support1.render(f5);
- Support2.render(f5);
- Hold1.render(f5);
- Hold2.render(f5);
- SmelterBase.render(f5);
- SmelterSide1.render(f5);
- SmelterSide2.render(f5);
- SmelterSide3.render(f5);
- SmelterSide4.render(f5);
- SmelterSide5.render(f5);
- SmelterSide6.render(f5);
- SmelterSide7.render(f5);
- SmelterSide8.render(f5);
- SmelterSide9.render(f5);
- SmelterSide10.render(f5);
- SmelterSide11.render(f5);
- SmelterSide12.render(f5);
- HeatSourceSide1.render(f5);
- HeatSourceSide2.render(f5);
- HeatSourceSide3.render(f5);
- HeatSourceSide4.render(f5);
- HeatSourceSide5.render(f5);
- HeatSourceBase.render(f5);
- HeatSourceSide6.render(f5);
- HeatSourceSide7.render(f5);
- HeatSourceSide8.render(f5);
- HeatSourceSide9.render(f5);
- HeatSourceSide10.render(f5);
- HeatSourceSide11.render(f5);
- HeatSourceSide12.render(f5);
- }
-
- private void setRotation(ModelRenderer model, float x, float y, float z)
- {
- model.rotateAngleX = x;
- model.rotateAngleY = y;
- model.rotateAngleZ = z;
- }
-
- public void setRotationAngles(float f, float f1, float f2, float f3, float f4, float f5)
- {
- super.setRotationAngles(f, f1, f2, f3, f4, f5, null);
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/recipes/CraftingRecipes.java b/src/main/java/darkknight/jewelrycraft/recipes/CraftingRecipes.java
deleted file mode 100644
index 366d8a8..0000000
--- a/src/main/java/darkknight/jewelrycraft/recipes/CraftingRecipes.java
+++ /dev/null
@@ -1,54 +0,0 @@
-package darkknight.jewelrycraft.recipes;
-
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.ItemStack;
-import net.minecraft.item.crafting.FurnaceRecipes;
-import net.minecraftforge.oredict.ShapedOreRecipe;
-import cpw.mods.fml.common.event.FMLPreInitializationEvent;
-import cpw.mods.fml.common.registry.GameRegistry;
-import darkknight.jewelrycraft.block.BlockList;
-import darkknight.jewelrycraft.item.ItemList;
-
-public class CraftingRecipes
-{
- private static boolean isInitialized = false;
-
- public static void preInit(FMLPreInitializationEvent e)
- {
- if (!isInitialized)
- {
- //Items
- GameRegistry.addRecipe(new ItemStack(ItemList.thiefGloves), "x x", "yxy", "yxy", 'x', ItemList.shadowIngot, 'y', new ItemStack(Blocks.wool, 1, 15));
- GameRegistry.addRecipe(new ItemStack(ItemList.clayMolds, 1, 0), "xx", 'x', Items.clay_ball);
- GameRegistry.addRecipe(new ItemStack(ItemList.clayMolds, 1, 1), " x ", "x x", " x ", 'x', Items.clay_ball);
- GameRegistry.addRecipe(new ItemStack(ItemList.clayMolds, 1, 2), "x x", "x x", " x ", 'x', Items.clay_ball);
- GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ItemList.crystal, 1, 15), " x ", "x x", " x ", 'x', Blocks.glass));
- for(int i=0; i < 15; i++)
- {
- GameRegistry.addShapelessRecipe(new ItemStack(ItemList.crystal, 1, i), new Object[]{new ItemStack(ItemList.crystal, 1, 15), new ItemStack(Items.dye, 1, i)});
- GameRegistry.addShapelessRecipe(new ItemStack(ItemList.crystal, 1, 15), new Object[]{new ItemStack(ItemList.crystal, 1, i), new ItemStack(Items.dye, 1, 15)});
- }
- GameRegistry.addShapelessRecipe(new ItemStack(ItemList.shadowIngot, 9), new Object[]{new ItemStack(BlockList.shadowBlock)});
- GameRegistry.addShapelessRecipe(new ItemStack(ItemList.guide), new Object[]{new ItemStack(Items.book), new ItemStack(ItemList.molds, 1, 0)});
- GameRegistry.addShapelessRecipe(new ItemStack(ItemList.guide), new Object[]{new ItemStack(Items.book), new ItemStack(ItemList.molds, 1, 1)});
- GameRegistry.addShapelessRecipe(new ItemStack(ItemList.guide), new Object[]{new ItemStack(Items.book), new ItemStack(ItemList.molds, 1, 2)});
-
- //Blocks
- GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(BlockList.molder), "x x", "xxx", 'x', Blocks.cobblestone));
- GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(BlockList.smelter), "xyx", "x x", "xzx", 'x', Blocks.cobblestone, 'y', Items.bucket, 'z', Items.lava_bucket));
- GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(BlockList.jewelCraftingTable), "xxx", "y y", "y y", 'x', Blocks.planks, 'y', Blocks.cobblestone));
- GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(BlockList.displayer, 2), " x ", "xxx", "yyy", 'x', Items.iron_ingot, 'y', Blocks.emerald_block));
- GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(BlockList.shadowBlock, 1), "xxx", "xxx", "xxx", 'x', ItemList.shadowIngot));
- GameRegistry.addRecipe(new ItemStack(BlockList.jewelAltar, 1), "sws", "bwb", "bbb", 's', Blocks.end_stone, 'w', new ItemStack(Blocks.wool, 1, 5), 'b', Blocks.nether_brick);
-
- //Smelting
- GameRegistry.addSmelting(BlockList.shadowOre, new ItemStack(ItemList.shadowIngot), 1.5f);
- GameRegistry.addSmelting(new ItemStack(ItemList.clayMolds, 1, 0), new ItemStack(ItemList.molds, 1, 0), 0.2F);
- GameRegistry.addSmelting(new ItemStack(ItemList.clayMolds, 1, 1), new ItemStack(ItemList.molds, 1, 1), 0.2F);
- GameRegistry.addSmelting(new ItemStack(ItemList.clayMolds, 1, 2), new ItemStack(ItemList.molds, 1, 2), 0.2F);
-
- isInitialized = true;
- }
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/renders/TileEntityDisplayerRender.java b/src/main/java/darkknight/jewelrycraft/renders/TileEntityDisplayerRender.java
deleted file mode 100644
index 8956eb4..0000000
--- a/src/main/java/darkknight/jewelrycraft/renders/TileEntityDisplayerRender.java
+++ /dev/null
@@ -1,235 +0,0 @@
-package darkknight.jewelrycraft.renders;
-
-import java.awt.Color;
-
-import net.minecraft.block.Block;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.gui.FontRenderer;
-import net.minecraft.client.renderer.OpenGlHelper;
-import net.minecraft.client.renderer.Tessellator;
-import net.minecraft.client.renderer.entity.RenderManager;
-import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemMap;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.ResourceLocation;
-import net.minecraft.world.World;
-
-import org.lwjgl.opengl.GL11;
-
-import darkknight.jewelrycraft.model.ModelDisplayer;
-import darkknight.jewelrycraft.tileentity.TileEntityDisplayer;
-
-public class TileEntityDisplayerRender extends TileEntitySpecialRenderer
-{
- ModelDisplayer displayer = new ModelDisplayer();
- String texture = "textures/tileentities/Displayer.png";
-
- @Override
- public void renderTileEntityAt(TileEntity te, double x, double y, double z, float scale)
- {
- GL11.glPushMatrix();
- GL11.glTranslatef((float) x + 0.5F, (float) y + 1.5F, (float) z + 0.5F);
- TileEntityDisplayer disp = (TileEntityDisplayer)te;
- int block = disp.getBlockMetadata();
-
- ResourceLocation blockTexture = new ResourceLocation("jewelrycraft", texture);
- Minecraft.getMinecraft().renderEngine.bindTexture(blockTexture);
-
- GL11.glPushMatrix();
- GL11.glRotatef(180F, 0.0F, 0.0F, 1.0F);
- displayer.render((Entity) null, disp.ringTranslation1, disp.ringTranslation2, disp.ringTranslation3, 0.0F, 0.0F, 0.0625F);
- if(disp != null && disp.hasObject && disp.object != null && disp.object != new ItemStack(Item.getItemById(0), 0, 0))
- {
- int ind = -3;
- GL11.glPushMatrix();
- renderLabel(disp.object.getDisplayName(), 0F, (-0.171F)*ind, 0F, block, disp, Color.YELLOW.getRGB());
- GL11.glPopMatrix();
- ind++;
- GL11.glPushMatrix();
- renderLabel(Integer.toString(disp.quantity), 0F, (-0.171F)*ind, 0F, block, disp, Color.GRAY.getRGB());
- GL11.glPopMatrix();
- ind++;
- EntityPlayer player = te.getWorldObj().getClosestPlayer(te.xCoord, te.yCoord, te.zCoord, 50D);
- if(disp.object.getItem() != Items.map && player != null && disp.object.getTooltip(player, true) != null)
- {
- for(int i = 1; i < disp.object.getTooltip(player, true).size(); i++)
- {
- if(disp.object.getTooltip(player, true).get(i).toString() != "")
- {
- GL11.glPushMatrix();
- renderLabel(disp.object.getTooltip(player, true).get(i).toString(), 0F, (-0.171F)*ind, 0F, block, disp, Color.GRAY.getRGB());
- GL11.glPopMatrix();
- ind++;
- }
- }
- }
- GL11.glPushMatrix();
- GL11.glDisable(GL11.GL_LIGHTING);
- EntityItem entityitem = new EntityItem(te.getWorldObj(), 0.0D, 0.0D, 0.0D, disp.object);
- entityitem.hoverStart = 0.0F;
- disp.object.stackSize = 1;
- GL11.glRotatef(180F, 1F, 0F, 0F);
- GL11.glTranslatef(0.0F, -0.6F + disp.ringTranslation1/5, 0F);
- GL11.glRotatef(disp.rotAngle, 0F, 1F, 0F);
- if(RenderManager.instance.options.fancyGraphics)
- RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- else
- {
- GL11.glRotatef(180F, 0F, 1F, 0F);
- RenderManager.instance.options.fancyGraphics = true;
- RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- RenderManager.instance.options.fancyGraphics = false;
- }
- GL11.glEnable(GL11.GL_LIGHTING);
- GL11.glPopMatrix();
- }
- GL11.glPopMatrix();
- GL11.glPopMatrix();
- }
-
- public void adjustLightFixture(World world, int i, int j, int k, Block block)
- {
- Tessellator tess = Tessellator.instance;
- float brightness = block.getLightOpacity(world, i, j, k);
- int skyLight = world.getLightBrightnessForSkyBlocks(i, j, k, 0);
- int modulousModifier = skyLight % 65536;
- int divModifier = skyLight / 65536;
- tess.setColorOpaque_F(brightness, brightness, brightness);
- OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, (float) modulousModifier, divModifier);
- }
-
- protected void renderLabel(String par2Str, double x, double y, double z, int metadata, TileEntity te, int color)
- {
- FontRenderer fontrenderer = RenderManager.instance.getFontRenderer();
- float var14 = 0.01266667F * 1.5F;
- float var17 = 0.015F;
- GL11.glRotatef(180F, 0F, 0F, 1F);
- if(metadata == 0) GL11.glRotatef(0F, 0F, 1F, 0F);
- else if(metadata == 1) GL11.glRotatef(270F, 0F, 1F, 0F);
- else if(metadata == 2) GL11.glRotatef(180F, 0F, 1F, 0F);
- else if(metadata == 3) GL11.glRotatef(90F, 0F, 1F, 0F);
- GL11.glTranslatef((float)x, (float)y, (float)z + 0.45F);
- GL11.glScalef(-0.015F, -var14, 0.015F);
- GL11.glPushMatrix();
- GL11.glDisable(GL11.GL_LIGHTING);
- GL11.glEnable(GL11.GL_BLEND);
- GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
- Tessellator tessellator = Tessellator.instance;
- GL11.glDisable(GL11.GL_TEXTURE_2D);
- int j = fontrenderer.getStringWidth(par2Str) / 2;
- tessellator.startDrawingQuads();
- tessellator.setColorRGBA_F(0.0F, 0.2F, 0.2F, 0.9F);
- tessellator.addVertex((double)(-33.333 - 0), -1D, 0.1D);
- tessellator.addVertex((double)(-33.333 - 0), 8D, 0.1D);
- tessellator.addVertex((double)(33.333 + 0), 8D, 0.1D);
- tessellator.addVertex((double)(33.333 + 0), -1D, 0.1D);
- tessellator.draw();
- if ((fontrenderer.getStringWidth(par2Str)/2) > 20) var17 = 0.9F / fontrenderer.getStringWidth(par2Str);
- else var17 = var14;
- int red = (color >> 16) & 0xFF;
- int green = (color >> 8) & 0xFF;
- int blue = color & 0xFF;
- GL11.glTranslatef((float)x + 1f, (float)y + 1f, (float)z);
- GL11.glPushMatrix();
- GL11.glEnable(GL11.GL_TEXTURE_2D);
- GL11.glScalef(var17*70F, 1F, 0F);
- fontrenderer.drawString(par2Str.replaceFirst("§0", "§r").replaceFirst("§1", "§r").replaceFirst("§2", "§r").replaceFirst("§3", "§r").replaceFirst("§4", "§r").replaceFirst("§5", "§r").replaceFirst("§6", "§r").replaceFirst("§7", "§r").replaceFirst("§8", "§r").replaceFirst("§9", "§r").replaceFirst("§a", "§r").replaceFirst("§b", "§r").replaceFirst("§c", "§r").replaceFirst("§d", "§r").replaceFirst("§e", "§r").replaceFirst("§f", "§r"), -j, 0, 65536 * (red/2) + 256 * (green/2) + blue/2);
- GL11.glPopMatrix();
- GL11.glTranslatef((float)x - 1f, (float)y - 1f, (float)z - 1F);
- GL11.glScalef(var17*70F, 1F, 0F);
- fontrenderer.drawString(par2Str, -j, 0, color);
- GL11.glEnable(GL11.GL_LIGHTING);
- GL11.glDisable(GL11.GL_BLEND);
- GL11.glPopMatrix();
- }
-
- public void replaceEnumEnchValues(String str, int color)
- {
- if(str.contains("§0"))
- {
- color = Color.BLACK.getRGB();
- str.replace("§0", "");
- }
- if(str.contains("§1"))
- {
- color = 85;
- str.replace("§1", "");
- }
- if(str.contains("§2"))
- {
- color = 17920;
- str.replace("§2", "");
- }
- if(str.contains("§3"))
- {
- color = 1336183;
- str.replace("§3", "");
- }
- if(str.contains("§4"))
- {
- color = 4587520;
- str.replace("§4", "");
- }
- if(str.contains("§5"))
- {
- color = 5701759;
- str.replace("§5", "");
- }
- if(str.contains("§6"))
- {
- color = 16762880;
- str.replace("§6", "");
- }
- if(str.contains("§7"))
- {
- color = Color.GRAY.getRGB();
- str.replace("§7", "");
- }
- if(str.contains("§8"))
- {
- color = Color.DARK_GRAY.getRGB();
- str.replace("§8", "");
- }
- if(str.contains("§9"))
- {
- color = Color.BLUE.getRGB();
- str.replace("§9", "");
- }
- if(str.contains("§a"))
- {
- color = Color.GREEN.getRGB();
- str.replace("§a", "");
- }
- if(str.contains("§b"))
- {
- color = Color.CYAN.getRGB();
- str.replace("§b", "");
- }
- if(str.contains("§c"))
- {
- color = Color.RED.getRGB();
- str.replace("§c", "");
- }
- if(str.contains("§d"))
- {
- color = 11665663;
- str.replace("§d", "");
- }
- if(str.contains("§e"))
- {
- color = Color.YELLOW.getRGB();
- str.replace("§e", "");
- }
- if(str.contains("§f"))
- {
- color = Color.WHITE.getRGB();
- str.replace("§f", "");
- }
- }
-} \ No newline at end of file
diff --git a/src/main/java/darkknight/jewelrycraft/renders/TileEntityJewelrsCraftingTableRender.java b/src/main/java/darkknight/jewelrycraft/renders/TileEntityJewelrsCraftingTableRender.java
deleted file mode 100644
index bfc2aac..0000000
--- a/src/main/java/darkknight/jewelrycraft/renders/TileEntityJewelrsCraftingTableRender.java
+++ /dev/null
@@ -1,165 +0,0 @@
-package darkknight.jewelrycraft.renders;
-
-import org.lwjgl.opengl.GL11;
-
-import darkknight.jewelrycraft.model.ModelJewlersCraftingBench;
-import darkknight.jewelrycraft.tileentity.TileEntityJewelrsCraftingTable;
-import net.minecraft.block.Block;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.renderer.OpenGlHelper;
-import net.minecraft.client.renderer.Tessellator;
-import net.minecraft.client.renderer.entity.RenderManager;
-import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.ResourceLocation;
-import net.minecraft.world.World;
-
-public class TileEntityJewelrsCraftingTableRender extends TileEntitySpecialRenderer
-{
- ModelJewlersCraftingBench modelTable = new ModelJewlersCraftingBench();
- String texture = "textures/tileentities/JewelrsCraftingBench.png";
-
- @Override
- public void renderTileEntityAt(TileEntity te, double x, double y, double z, float scale)
- {
- GL11.glPushMatrix();
- GL11.glTranslatef((float) x + 0.5F, (float) y + 1.5F, (float) z + 0.5F);
-
- ResourceLocation blockTexture = new ResourceLocation("jewelrycraft", texture);
- Minecraft.getMinecraft().renderEngine.bindTexture(blockTexture);
- int block = te.getBlockMetadata();
- TileEntityJewelrsCraftingTable jt = (TileEntityJewelrsCraftingTable)te;
-
- GL11.glPushMatrix();
- if (block == 0)
- GL11.glRotatef(180F, 0.0F, 0.0F, 1.0F);
- else if (block == 1){
- GL11.glRotatef(180F, 0.0F, 0.0F, 1.0F);
- GL11.glRotatef(90F, 0.0F, 1.0F, 0.0F);
- }
- else if (block == 2)
- GL11.glRotatef(180F, 1.0F, 0.0F, 0.0F);
- else if (block == 3)
- GL11.glRotatef(180F, 1.0F, 0.0F, 1.0F);
-
- modelTable.render((Entity) null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F);
- if (jt != null)
- {
- if (jt.hasJewelry && jt.jewelry.getIconIndex() != null && jt.jewelry.getIconIndex().getIconName() != "")
- {
- GL11.glPushMatrix();
- GL11.glDisable(GL11.GL_LIGHTING);
- EntityItem entityitem = new EntityItem(te.getWorldObj(), 0.0D, 0.0D, 0.0D, jt.jewelry);
- entityitem.getEntityItem().stackSize = 1;
- entityitem.hoverStart = 0.0F;
-
- GL11.glRotatef(180F, 1F, 0F, 0F);
- GL11.glScalef(0.5F, 0.5F, 0.5F);
- GL11.glTranslatef(0.0F, -1.6F, 0.6F);
- GL11.glRotatef(jt.angle, 0F, 1F, 0F);
- if(RenderManager.instance.options.fancyGraphics)
- RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- else
- {
- GL11.glRotatef(180F, 0F, 1F, 0F);
- RenderManager.instance.options.fancyGraphics = true;
- RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- RenderManager.instance.options.fancyGraphics = false;
- }
-
- GL11.glEnable(GL11.GL_LIGHTING);
- GL11.glPopMatrix();
- }
- if (jt.hasEndItem && jt.endItem.getIconIndex().getIconName() != "")
- {
- GL11.glPushMatrix();
- GL11.glDisable(GL11.GL_LIGHTING);
- EntityItem entityitem = new EntityItem(te.getWorldObj(), 0.0D, 0.0D, 0.0D, jt.endItem);
- entityitem.getEntityItem().stackSize = 1;
- entityitem.hoverStart = 0.0F;
-
- GL11.glRotatef(180F, 1F, 0F, 0F);
- GL11.glScalef(0.5F, 0.5F, 0.5F);
- GL11.glTranslatef(0.0F, -1.6F, 0.6F);
- GL11.glRotatef(jt.angle, 0F, 1F, 0F);
- if(RenderManager.instance.options.fancyGraphics)
- RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- else
- {
- GL11.glRotatef(180F, 0F, 1F, 0F);
- RenderManager.instance.options.fancyGraphics = true;
- RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- RenderManager.instance.options.fancyGraphics = false;
- }
-
- GL11.glEnable(GL11.GL_LIGHTING);
- GL11.glPopMatrix();
- }
- if (jt.hasModifier && jt.modifier.getIconIndex().getIconName() != "")
- {
- GL11.glPushMatrix();
- GL11.glDisable(GL11.GL_LIGHTING);
- EntityItem entityitem = new EntityItem(te.getWorldObj(), 0.0D, 0.0D, 0.0D, jt.modifier);
- entityitem.getEntityItem().stackSize = 1;
- entityitem.hoverStart = 0.0F;
-
- GL11.glRotatef(180F, 1F, 0F, 0F);
- GL11.glScalef(0.5F, 0.5F, 0.5F);
- GL11.glTranslatef(0.55F, -1.5F, -0.45F);
- GL11.glRotatef(jt.angle, 0F, 1F, 0F);
- if(RenderManager.instance.options.fancyGraphics)
- RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- else
- {
- GL11.glRotatef(180F, 0F, 1F, 0F);
- RenderManager.instance.options.fancyGraphics = true;
- RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- RenderManager.instance.options.fancyGraphics = false;
- }
- GL11.glEnable(GL11.GL_LIGHTING);
- GL11.glPopMatrix();
- }
- if (jt.hasJewel && jt.jewel.getIconIndex().getIconName() != "")
- {
- GL11.glPushMatrix();
- GL11.glDisable(GL11.GL_LIGHTING);
- EntityItem entityitem = new EntityItem(te.getWorldObj(), 0.0D, 0.0D, 0.0D, jt.jewel);
- entityitem.getEntityItem().stackSize = 1;
- entityitem.hoverStart = 0.0F;
-
- GL11.glRotatef(180F, 1F, 0F, 0F);
- GL11.glScalef(0.5F, 0.5F, 0.5F);
- GL11.glTranslatef(-0.55F, -1.5F, -0.45F);
- GL11.glRotatef(jt.angle, 0F, 1F, 0F);
- if(RenderManager.instance.options.fancyGraphics)
- RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- else
- {
- GL11.glRotatef(180F, 0F, 1F, 0F);
- RenderManager.instance.options.fancyGraphics = true;
- RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- RenderManager.instance.options.fancyGraphics = false;
- }
- GL11.glEnable(GL11.GL_LIGHTING);
- GL11.glPopMatrix();
- }
- }
-
- GL11.glPopMatrix();
- GL11.glPopMatrix();
- }
-
- public void adjustLightFixture(World world, int i, int j, int k, Block block)
- {
- Tessellator tess = Tessellator.instance;
- float brightness = block.getLightOpacity(world, i, j, k);
- int skyLight = world.getLightBrightnessForSkyBlocks(i, j, k, 0);
- int modulousModifier = skyLight % 65536;
- int divModifier = skyLight / 65536;
- tess.setColorOpaque_F(brightness, brightness, brightness);
- OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, (float) modulousModifier, divModifier);
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/renders/TileEntityMolderRender.java b/src/main/java/darkknight/jewelrycraft/renders/TileEntityMolderRender.java
deleted file mode 100644
index 1d31358..0000000
--- a/src/main/java/darkknight/jewelrycraft/renders/TileEntityMolderRender.java
+++ /dev/null
@@ -1,123 +0,0 @@
-package darkknight.jewelrycraft.renders;
-
-import org.lwjgl.opengl.GL11;
-
-import darkknight.jewelrycraft.item.ItemList;
-import darkknight.jewelrycraft.model.ModelMolder;
-import darkknight.jewelrycraft.tileentity.TileEntityMolder;
-import darkknight.jewelrycraft.util.JewelryNBT;
-
-import net.minecraft.block.Block;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.renderer.OpenGlHelper;
-import net.minecraft.client.renderer.Tessellator;
-import net.minecraft.client.renderer.entity.RenderItem;
-import net.minecraft.client.renderer.entity.RenderManager;
-import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.ResourceLocation;
-import net.minecraft.world.World;
-
-public class TileEntityMolderRender extends TileEntitySpecialRenderer
-{
- ModelMolder modelMolder = new ModelMolder();
- String texture = "textures/tileentities/Molder.png";
-
- @Override
- public void renderTileEntityAt(TileEntity te, double x, double y, double z, float scale)
- {
- GL11.glPushMatrix();
- GL11.glTranslatef((float) x + 0.5F, (float) y + 1.5F, (float) z + 0.5F);
- TileEntityMolder me = (TileEntityMolder) te;
-
- ResourceLocation blockTexture = new ResourceLocation("jewelrycraft", texture);
- Minecraft.getMinecraft().renderEngine.bindTexture(blockTexture);
- int block = me.getBlockMetadata();
-
- GL11.glPushMatrix();
- if (block == 0)
- GL11.glRotatef(180F, 0.0F, 0.0F, 1.0F);
- else if (block == 1){
- GL11.glRotatef(180F, 0.0F, 0.0F, 1.0F);
- GL11.glRotatef(90F, 0.0F, 1.0F, 0.0F);
- }
- else if (block == 2)
- GL11.glRotatef(180F, 1.0F, 0.0F, 0.0F);
- else if (block == 3)
- GL11.glRotatef(180F, 1.0F, 0.0F, 1.0F);
- modelMolder.render((Entity) null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F);
- if (me != null)
- {
- if (me.hasMold)
- {
- GL11.glPushMatrix();
- GL11.glDisable(GL11.GL_LIGHTING);
- EntityItem entityitem = new EntityItem(te.getWorldObj(), 0.0D, 0.0D, 0.0D, me.mold);
- entityitem.getEntityItem().stackSize = 1;
- entityitem.hoverStart = 0.0F;
- GL11.glTranslatef(0F, 1.312F, -0.25F);
- GL11.glScalef(1.25F, 1.0F, 1.25F);
- GL11.glRotatef(90F, 1F, 0F, 0f);
- RenderItem.renderInFrame = true;
- if(entityitem != null) RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- RenderItem.renderInFrame = false;
- GL11.glEnable(GL11.GL_LIGHTING);
- GL11.glPopMatrix();
- }
- if (me.hasJewelBase && me.jewelBase.getIconIndex() != null && me.jewelBase.getIconIndex().getIconName() != "")
- {
- GL11.glPushMatrix();
- GL11.glDisable(GL11.GL_LIGHTING);
- EntityItem entityitem = new EntityItem(te.getWorldObj(), 0.0D, 0.0D, 0.0D, me.jewelBase);
- entityitem.getEntityItem().stackSize = 1;
- entityitem.hoverStart = 0.0F;
- GL11.glTranslatef(0F, 1.312F, -0.25F);
- GL11.glScalef(1.25F, 1.0F, 1.25F);
- GL11.glRotatef(90F, 1F, 0F, 0f);
- RenderItem.renderInFrame = true;
- if(entityitem != null) RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- RenderItem.renderInFrame = false;
- GL11.glColor4f(1, 1F, 1F, 1.0F);
- GL11.glEnable(GL11.GL_LIGHTING);
- GL11.glPopMatrix();
- }
- if(me.hasMoltenMetal && me.moltenMetal != null && me.moltenMetal != new ItemStack(Item.getItemById(0), 0, 0))
- {
- GL11.glPushMatrix();
- GL11.glDisable(GL11.GL_LIGHTING);
- ItemStack metal = new ItemStack(ItemList.metal);
- JewelryNBT.addMetal(metal, new ItemStack(me.moltenMetal.getItem()));
- EntityItem moltenMetal = new EntityItem(te.getWorldObj(), 0.0D, 0.0D, 0.0D, metal);
- moltenMetal.getEntityItem().stackSize = 1;
- moltenMetal.hoverStart = 0.0F;
-
- GL11.glTranslatef(-0F, 1.43f - 0.115f*me.quantity, -0.3F);
- GL11.glScalef(1.2F, 1.0F, 1.45F);
- GL11.glRotatef(90F, 1F, 0F, 0f);
- RenderItem.renderInFrame = true;
- RenderManager.instance.renderEntityWithPosYaw(moltenMetal, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- RenderItem.renderInFrame = false;
- GL11.glEnable(GL11.GL_LIGHTING);
- GL11.glPopMatrix();
- }
- }
- GL11.glPopMatrix();
- GL11.glPopMatrix();
- }
-
- public void adjustLightFixture(World world, int i, int j, int k, Block block)
- {
- Tessellator tess = Tessellator.instance;
- float brightness = block.getLightOpacity(world, i, j, k);
- int skyLight = world.getLightBrightnessForSkyBlocks(i, j, k, 0);
- int modulousModifier = skyLight % 65536;
- int divModifier = skyLight / 65536;
- tess.setColorOpaque_F(brightness, brightness, brightness);
- OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, (float) modulousModifier, divModifier);
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/renders/TileEntitySmelterRender.java b/src/main/java/darkknight/jewelrycraft/renders/TileEntitySmelterRender.java
deleted file mode 100644
index d79c4b4..0000000
--- a/src/main/java/darkknight/jewelrycraft/renders/TileEntitySmelterRender.java
+++ /dev/null
@@ -1,181 +0,0 @@
-package darkknight.jewelrycraft.renders;
-
-import java.io.IOException;
-
-import net.minecraft.block.Block;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.renderer.OpenGlHelper;
-import net.minecraft.client.renderer.Tessellator;
-import net.minecraft.client.renderer.entity.RenderItem;
-import net.minecraft.client.renderer.entity.RenderManager;
-import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.IIcon;
-import net.minecraft.util.ResourceLocation;
-import net.minecraft.world.World;
-
-import org.lwjgl.opengl.GL11;
-
-import darkknight.jewelrycraft.block.BlockList;
-import darkknight.jewelrycraft.block.BlockMoltenMetal;
-import darkknight.jewelrycraft.item.ItemList;
-import darkknight.jewelrycraft.model.ModelSmelter;
-import darkknight.jewelrycraft.tileentity.TileEntitySmelter;
-import darkknight.jewelrycraft.util.JewelryNBT;
-
-public class TileEntitySmelterRender extends TileEntitySpecialRenderer
-{
- ModelSmelter modelSmelter = new ModelSmelter();
- String texture = "textures/tileentities/Smelter.png";
-
- public static final float p = 1 / 16, p3 = 3 * p, p13 = 13 * p, p15 = 15 * p;
-
- @Override
- public void renderTileEntityAt(TileEntity te, double x, double y, double z, float scale)
- {
- GL11.glPushMatrix();
- GL11.glTranslatef((float) x + 0.5F, (float) y + 1.5F, (float) z + 0.5F);
-
- ResourceLocation blockTexture = new ResourceLocation("jewelrycraft", texture);
- Minecraft.getMinecraft().renderEngine.bindTexture(blockTexture);
- TileEntitySmelter st = (TileEntitySmelter)te;
- int block = te.getBlockMetadata();
-
- GL11.glPushMatrix();
- if (block == 0)
- GL11.glRotatef(180F, 0.0F, 0.0F, 1.0F);
- else if (block == 1){
- GL11.glRotatef(180F, 0.0F, 0.0F, 1.0F);
- GL11.glRotatef(90F, 0.0F, 1.0F, 0.0F);
- }
- else if (block == 2)
- GL11.glRotatef(180F, 1.0F, 0.0F, 0.0F);
- else if (block == 3)
- GL11.glRotatef(180F, 1.0F, 0.0F, 1.0F);
-
- modelSmelter.render((Entity) null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F);
-
- GL11.glPushMatrix();
- GL11.glDisable(GL11.GL_LIGHTING);
- EntityItem entityitem = new EntityItem(te.getWorldObj(), 0.0D, 0.0D, 0.0D, new ItemStack(Blocks.lava));
- entityitem.getEntityItem().stackSize = 1;
- entityitem.hoverStart = 0.0F;
-
- GL11.glPushMatrix();
- GL11.glPopMatrix();
-
- Tessellator t = Tessellator.instance;
- float minU, minV, maxU, maxV;
- IIcon lava = Blocks.lava.getIcon(1, 0);
-
- t.setBrightness(15728864);
-
- int meta = te.getWorldObj().getBlockMetadata(te.xCoord, te.yCoord, te.zCoord);
-
- minU = lava.getMinU();
- minV = lava.getMinV();
- maxU = lava.getMaxU();
- maxV = lava.getMaxV();
- /*maxU = lava.getInterpolatedU(10);
- maxV = lava.getInterpolatedV(14);*/
-
-
-
- t.startDrawingQuads();
-
- t.addVertexWithUV(te.xCoord, te.yCoord + p15, te.zCoord, minU, minV);
- t.addVertexWithUV(te.xCoord, te.yCoord + p15, te.zCoord + 1, minU, maxV);
- t.addVertexWithUV(te.xCoord + 1, te.yCoord + p15, te.zCoord + 1, maxU, maxV);
- t.addVertexWithUV(te.xCoord + 1, te.yCoord + p15, te.zCoord, maxU, minV);
-
- t.draw();
-
-
- GL11.glTranslatef(-0F, 1.25F, -0.3F);
- GL11.glScalef(1.25F, 1.0F, 1.47F);
- GL11.glRotatef(90F, 1F, 0F, 0f);
- RenderItem.renderInFrame = true;
- RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- RenderItem.renderInFrame = false;
-
- GL11.glTranslatef(0F, 0.46F, 0.0F);
- GL11.glScalef(0.8F, 0.1F, 0F);
- RenderItem.renderInFrame = true;
- RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- RenderItem.renderInFrame = false;
-
- GL11.glTranslatef(0F, -5.6F, 0.0F);
- RenderItem.renderInFrame = true;
- RenderManager.instance.renderEntityWithPosYaw(entityitem, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- RenderItem.renderInFrame = false;
-
- GL11.glEnable(GL11.GL_LIGHTING);
- GL11.glPopMatrix();
- if (st != null)
- {
- if (st.hasMetal && st.metal != null && st.metal != new ItemStack(Item.getItemById(0), 0, 0) && st.metal.getIconIndex() != null && st.metal.getIconIndex().getIconName() != "")
- {
- GL11.glPushMatrix();
- GL11.glDisable(GL11.GL_LIGHTING);
- EntityItem metal = new EntityItem(te.getWorldObj(), 0.0D, 0.0D, 0.0D, st.metal);
- metal.getEntityItem().stackSize = 1;
- metal.hoverStart = 0.0F;
-
- GL11.glRotatef(-50F, 1F, 0F, 0F);
- GL11.glRotatef(-50F, 0F, 0F, 1F);
- GL11.glRotatef(180F, 1F, 0F, 0F);
- GL11.glScalef(0.5F, 0.5F, 0.5F);
- GL11.glTranslatef(-0.9F, -0.9F, -1.6F);
- if(RenderManager.instance.options.fancyGraphics) RenderManager.instance.renderEntityWithPosYaw(metal, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- else
- {
- RenderManager.instance.options.fancyGraphics = true;
- RenderManager.instance.renderEntityWithPosYaw(metal, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- RenderManager.instance.options.fancyGraphics = false;
- }
- GL11.glEnable(GL11.GL_LIGHTING);
- GL11.glPopMatrix();
- }
- if(st.hasMoltenMetal && st.moltenMetal != null && st.moltenMetal != new ItemStack(Item.getItemById(0), 0, 0))
- {
- GL11.glPushMatrix();
- GL11.glDisable(GL11.GL_LIGHTING);
- ItemStack metal = new ItemStack(ItemList.metal);
- JewelryNBT.addMetal(metal, new ItemStack(st.moltenMetal.getItem()));
- EntityItem moltenMetal = new EntityItem(te.getWorldObj(), 0.0D, 0.0D, 0.0D, metal);
- moltenMetal.getEntityItem().stackSize = 1;
- moltenMetal.hoverStart = 0.0F;
-
- GL11.glTranslatef(-0F, 1.1f -.5F*st.quantity, -0.3F);
- GL11.glScalef(1.25F, 1.0F, 1.47F);
- GL11.glRotatef(90F, 1F, 0F, 0f);
- RenderItem.renderInFrame = true;
- RenderManager.instance.renderEntityWithPosYaw(moltenMetal, 0.0D, 0.0D, 0.0D, 0.0F, 0.0F);
- RenderItem.renderInFrame = false;
- GL11.glEnable(GL11.GL_LIGHTING);
- GL11.glPopMatrix();
- }
- }
-
- GL11.glPopMatrix();
- GL11.glPopMatrix();
- }
-
- public void adjustLightFixture(World world, int i, int j, int k, Block block)
- {
- Tessellator tess = Tessellator.instance;
- float brightness = block.getLightOpacity(world, i, j, k);
- int skyLight = world.getLightBrightnessForSkyBlocks(i, j, k, 0);
- int modulousModifier = skyLight % 65536;
- int divModifier = skyLight / 65536;
- tess.setColorOpaque_F(brightness, brightness, brightness);
- OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, (float) modulousModifier, divModifier);
- }
-
-}
diff --git a/src/main/java/darkknight/jewelrycraft/tileentity/TileEntityAltar.java b/src/main/java/darkknight/jewelrycraft/tileentity/TileEntityAltar.java
deleted file mode 100644
index 62ef646..0000000
--- a/src/main/java/darkknight/jewelrycraft/tileentity/TileEntityAltar.java
+++ /dev/null
@@ -1,144 +0,0 @@
-package darkknight.jewelrycraft.tileentity;
-
-import java.util.List;
-
-import net.minecraft.block.Block;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.network.NetworkManager;
-import net.minecraft.network.Packet;
-import net.minecraft.network.play.server.S35PacketUpdateTileEntity;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.AxisAlignedBB;
-import darkknight.jewelrycraft.util.JewelryNBT;
-
-public class TileEntityAltar extends TileEntity
-{
- public ItemStack object;
- public boolean isDirty, hasObject;
- public String playerName;
-
- public TileEntityAltar()
- {
- this.hasObject = false;
- this.object = new ItemStack(Item.getItemById(0), 0, 0);
- this.isDirty = false;
- this.playerName = "";
- }
-
- @Override
- public void writeToNBT(NBTTagCompound nbt)
- {
- super.writeToNBT(nbt);
- NBTTagCompound tag = new NBTTagCompound();
- this.object.writeToNBT(tag);
- nbt.setTag("object", tag);
- nbt.setBoolean("hasObject", hasObject);
- nbt.setString("playerName", playerName);
- }
-
- @Override
- public void readFromNBT(NBTTagCompound nbt)
- {
- super.readFromNBT(nbt);
- this.object = new ItemStack(Item.getItemById(0), 0, 0);
- this.object.readFromNBT(nbt.getCompoundTag("object"));
- this.hasObject = nbt.getBoolean("hasObject");
- this.playerName = nbt.getString("playerName");
- }
-
- @SuppressWarnings("rawtypes")
- @Override
- public void updateEntity()
- {
- super.updateEntity();
-
- if(isDirty)
- {
- worldObj.markBlockForUpdate(xCoord, yCoord, zCoord);
- isDirty = false;
- }
- if(hasObject && playerName != "")
- {
- //int playerPosX = (int)player.posX, playerPosY = (int)player.posY, playerPosZ = (int)player.posZ;
- List entitiesR = worldObj.getEntitiesWithinAABB(EntityLivingBase.class, AxisAlignedBB.getBoundingBox(xCoord, yCoord + 1D, zCoord, xCoord + 0.5D, yCoord + 2D, zCoord + 0.5D));
- List entitiesN = worldObj.getEntitiesWithinAABB(EntityLivingBase.class, AxisAlignedBB.getBoundingBox(xCoord - 0.5D, yCoord + 1D, zCoord - 0.5D, xCoord + 1.5D, yCoord + 2D, zCoord + 1.5D));
- if(object.getUnlocalizedName().contains("ring"))
- {
- if (JewelryNBT.isJewelX(object, new ItemStack(Items.ender_pearl)) && JewelryNBT.dimension(object) != -2 && JewelryNBT.playerPosX(object) != -1 && JewelryNBT.playerPosY(object) != -1 && JewelryNBT.playerPosZ(object) != -1)
- {
- double posX = JewelryNBT.playerPosX(object), posY = JewelryNBT.playerPosY(object), posZ = JewelryNBT.playerPosZ(object);
- int dimension = JewelryNBT.dimension(object);
- for(int i = 0; i < entitiesR.size(); i++)
- {
- EntityLivingBase entity = (EntityLivingBase) entitiesR.get(i);
- if (!JewelryNBT.isDimensionX(object, entity.dimension) && JewelryNBT.isModifierX(object, new ItemStack(Items.bed))){
- entity.travelToDimension(dimension);
- entity.setPositionAndUpdate(posX, posY, posZ);
- }
- else if(JewelryNBT.isDimensionX(object, entity.dimension)) entity.setPositionAndUpdate(posX, posY, posZ);
- }
- }
- if (JewelryNBT.isModifierX(object, new ItemStack(Items.dye, 1, 15)))
- {
- for(int i=-1; i<=1; i++)
- for(int j=-1; j<=1; j++)
- for(int k=-1; k<=1; k++)
- {
- //if(worldObj.getBlockId(xCoord + i, yCoord + j, zCoord + k) == Block.dirt.blockID && (worldObj.getBlockId(xCoord + i, yCoord + j + 1, zCoord + k) == 0 || worldObj.getBlockId(xCoord + i, yCoord + j + 1, zCoord + k) == Block.crops.blockID) || worldObj.getBlockId(xCoord + i, yCoord + j + 1, zCoord + k) == Block.potato.blockID) worldObj.setBlock(xCoord + i, yCoord + j, zCoord + k, Block.tilledField.blockID);
- if(worldObj.getBlock(xCoord + i, yCoord + j, zCoord + k) == Blocks.farmland) worldObj.setBlockMetadataWithNotify(xCoord + i, yCoord + j, zCoord + k, 1, 7);
- if(worldObj.getBlock(xCoord + i, yCoord + j, zCoord + k) != Blocks.farmland) worldObj.scheduleBlockUpdate(xCoord + i, yCoord + j, zCoord + k, worldObj.getBlock(xCoord + i, yCoord + j, zCoord + k), 5);
- //JewelrycraftUtil.applyBonemeal(object, worldObj, xCoord + i, yCoord + j, zCoord + k, player);
- }
- }
- }
- else if(object.getUnlocalizedName().contains("necklace"))
- {
- if (JewelryNBT.isJewelX(object, new ItemStack(Items.ender_pearl)) && JewelryNBT.dimension(object) != -2 && JewelryNBT.playerPosX(object) != -1 && JewelryNBT.playerPosY(object) != -1 && JewelryNBT.playerPosZ(object) != -1)
- {
- double posX = JewelryNBT.playerPosX(object), posY = JewelryNBT.playerPosY(object), posZ = JewelryNBT.playerPosZ(object);
- int dimension = JewelryNBT.dimension(object);
- for(int i = 0; i < entitiesN.size(); i++)
- {
- EntityLivingBase entity = (EntityLivingBase) entitiesN.get(i);
- if (!JewelryNBT.isDimensionX(object, entity.dimension) && JewelryNBT.isModifierX(object, new ItemStack(Items.bed))){
- entity.travelToDimension(dimension);
- entity.setPositionAndUpdate(posX, posY, posZ);
- }
- else if(JewelryNBT.isDimensionX(object, entity.dimension)) entity.setPositionAndUpdate(posX, posY, posZ);
- }
- }
- if (JewelryNBT.isModifierX(object, new ItemStack(Items.dye, 1, 15)))
- {
- for(int i=-3; i<=3; i++)
- for(int j=-1; j<=1; j++)
- for(int k=-3; k<=3; k++)
- {
- //if(worldObj.getBlockId(xCoord + i, yCoord + j, zCoord + k) == Block.dirt.blockID && (worldObj.getBlockId(xCoord + i, yCoord + j + 1, zCoord + k) == 0 || worldObj.getBlockId(xCoord + i, yCoord + j + 1, zCoord + k) == Block.crops.blockID) || worldObj.getBlockId(xCoord + i, yCoord + j + 1, zCoord + k) == Block.potato.blockID) worldObj.setBlock(xCoord + i, yCoord + j, zCoord + k, Block.tilledField.blockID);
- if(worldObj.getBlock(xCoord + i, yCoord + j, zCoord + k) == Blocks.farmland) worldObj.setBlockMetadataWithNotify(xCoord + i, yCoord + j, zCoord + k, 1, 7);
- if(worldObj.getBlock(xCoord + i, yCoord + j, zCoord + k) != Blocks.farmland) worldObj.scheduleBlockUpdate(xCoord + i, yCoord + j, zCoord + k, worldObj.getBlock(xCoord + i, yCoord + j, zCoord + k), 5);
- //JewelrycraftUtil.applyBonemeal(object, worldObj, xCoord + i, yCoord + j, zCoord + k, player);
- }
- }
- }
- }
- }
-
- public Packet getDescriptionPacket()
- {
- NBTTagCompound nbttagcompound = new NBTTagCompound();
- this.writeToNBT(nbttagcompound);
- return new S35PacketUpdateTileEntity(this.xCoord, this.yCoord, this.zCoord, 1, nbttagcompound);
- }
-
- @Override
- public void onDataPacket (NetworkManager net, S35PacketUpdateTileEntity packet)
- {
- readFromNBT(packet.func_148857_g());
- worldObj.func_147479_m(xCoord, yCoord, zCoord);
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/tileentity/TileEntityBlockShadow.java b/src/main/java/darkknight/jewelrycraft/tileentity/TileEntityBlockShadow.java
deleted file mode 100644
index 186f78a..0000000
--- a/src/main/java/darkknight/jewelrycraft/tileentity/TileEntityBlockShadow.java
+++ /dev/null
@@ -1,74 +0,0 @@
-package darkknight.jewelrycraft.tileentity;
-
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.network.NetworkManager;
-import net.minecraft.network.Packet;
-import net.minecraft.network.play.server.S35PacketUpdateTileEntity;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.MathHelper;
-import net.minecraft.world.EnumSkyBlock;
-
-public class TileEntityBlockShadow extends TileEntity
-{
- public int metadata;
-
- public TileEntityBlockShadow()
- {
- this.metadata = -1;
- }
-
- @Override
- public void writeToNBT(NBTTagCompound nbt)
- {
- super.writeToNBT(nbt);
- nbt.setInteger("metadata", metadata);
- }
-
- @Override
- public void readFromNBT(NBTTagCompound nbt)
- {
- super.readFromNBT(nbt);
- this.metadata = nbt.getInteger("metadata");
- }
-
- @Override
- public void updateEntity()
- {
- super.updateEntity();
- int blockLight, realLight;
- int lightValue = worldObj.getSavedLightValue(EnumSkyBlock.Sky, xCoord, yCoord, zCoord) - worldObj.skylightSubtracted;
- float sunPosAngle = worldObj.getCelestialAngleRadians(1.0F);
-
- if (sunPosAngle < (float)Math.PI) sunPosAngle += (0.0F - sunPosAngle) * 0.2F;
- else sunPosAngle += (((float)Math.PI * 2F) - sunPosAngle) * 0.2F;
-
- lightValue = Math.round((float)lightValue * MathHelper.cos(sunPosAngle));
-
- if (lightValue < 0) lightValue = 0;
- if (lightValue > 15) lightValue = 15;
-
- blockLight = worldObj.getChunkFromBlockCoords(xCoord, zCoord).getSavedLightValue(EnumSkyBlock.Block, xCoord & 15, yCoord, zCoord & 15);
- realLight = worldObj.getChunkFromBlockCoords(xCoord, zCoord).getBlockLightValue(xCoord & 15, yCoord, zCoord & 15, 0);
-
- if((blockLight == 0 && worldObj.canBlockSeeTheSky(xCoord, yCoord, zCoord)) || (lightValue >= blockLight)) metadata = 15 - lightValue;
- else if(!worldObj.canBlockSeeTheSky(xCoord, yCoord, zCoord)) metadata = 15 - realLight;
- else if(lightValue < blockLight) metadata = 15 - blockLight;
-
- worldObj.setBlockMetadataWithNotify(xCoord, yCoord, zCoord, metadata, 2);
- worldObj.notifyBlocksOfNeighborChange(xCoord, yCoord, zCoord, worldObj.getBlock(xCoord, yCoord, zCoord));
- }
-
- public Packet getDescriptionPacket()
- {
- NBTTagCompound nbttagcompound = new NBTTagCompound();
- this.writeToNBT(nbttagcompound);
- return new S35PacketUpdateTileEntity(this.xCoord, this.yCoord, this.zCoord, 1, nbttagcompound);
- }
-
- @Override
- public void onDataPacket (NetworkManager net, S35PacketUpdateTileEntity packet)
- {
- readFromNBT(packet.func_148857_g());
- worldObj.func_147479_m(xCoord, yCoord, zCoord);
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/tileentity/TileEntityDisplayer.java b/src/main/java/darkknight/jewelrycraft/tileentity/TileEntityDisplayer.java
deleted file mode 100644
index 35def5c..0000000
--- a/src/main/java/darkknight/jewelrycraft/tileentity/TileEntityDisplayer.java
+++ /dev/null
@@ -1,108 +0,0 @@
-package darkknight.jewelrycraft.tileentity;
-
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.network.NetworkManager;
-import net.minecraft.network.Packet;
-import net.minecraft.network.play.server.S35PacketUpdateTileEntity;
-import net.minecraft.tileentity.TileEntity;
-
-public class TileEntityDisplayer extends TileEntity
-{
- public float ringTranslation1, ringTranslation2, ringTranslation3, rotAngle;
- public boolean isDescending1, isDescending2, isDescending3, isDirty, hasObject;
- public ItemStack object;
- public int quantity;
-
- public TileEntityDisplayer()
- {
- this.ringTranslation1 = 0;
- this.ringTranslation2 = 0;
- this.ringTranslation3 = 0;
- this.rotAngle = 0;
- this.quantity = 0;
- this.isDescending1 = false;
- this.isDescending2 = false;
- this.isDescending3 = false;
- this.isDirty = false;
- this.hasObject = false;
- this.object = new ItemStack(Item.getItemById(0), 0, 0);
- }
-
- @Override
- public void writeToNBT(NBTTagCompound nbt)
- {
- super.writeToNBT(nbt);
- nbt.setFloat("translation1", ringTranslation1);
- nbt.setFloat("translation2", ringTranslation2);
- nbt.setFloat("translation3", ringTranslation3);
- nbt.setFloat("angle", rotAngle);
- nbt.setInteger("quantity", quantity);
- nbt.setBoolean("descending1", isDescending1);
- nbt.setBoolean("descending2", isDescending2);
- nbt.setBoolean("descending3", isDescending3);
- nbt.setBoolean("hasObject", hasObject);
- NBTTagCompound tag = new NBTTagCompound();
- this.object.writeToNBT(tag);
- nbt.setTag("object", tag);
- }
-
- @Override
- public void readFromNBT(NBTTagCompound nbt)
- {
- super.readFromNBT(nbt);
- this.ringTranslation1 = nbt.getFloat("translation1");
- this.ringTranslation2 = nbt.getFloat("translation2");
- this.ringTranslation3 = nbt.getFloat("translation3");
- this.rotAngle = nbt.getFloat("angle");
- this.quantity = nbt.getInteger("quantity");
- this.isDescending1 = nbt.getBoolean("descending1");
- this.isDescending2 = nbt.getBoolean("descending2");
- this.isDescending3 = nbt.getBoolean("descending3");
- this.hasObject = nbt.getBoolean("hasObject");
- this.object = new ItemStack(Item.getItemById(0), 0, 0);
- this.object.readFromNBT(nbt.getCompoundTag("object"));
- }
-
- @Override
- public void updateEntity()
- {
- super.updateEntity();
- if(isDirty)
- {
- worldObj.markBlockForUpdate(xCoord, yCoord, zCoord);
- isDirty = false;
- }
- if(ringTranslation1 >= 0.6) isDescending1 = true;
- if(ringTranslation1 <= 0) isDescending1 = false;
- if(!isDescending1) ringTranslation1 += 0.05;
- if(isDescending1) ringTranslation1 -= 0.05;
-
- if(ringTranslation2 >= 0.6) isDescending2 = true;
- if(ringTranslation2 <= 0) isDescending2 = false;
- if(!isDescending2) ringTranslation2 += 0.04;
- if(isDescending2) ringTranslation2 -= 0.04;
-
- if(ringTranslation3 >= 0.6) isDescending3 = true;
- if(ringTranslation3 <= 0) isDescending3 = false;
- if(!isDescending3) ringTranslation3 += 0.03;
- if(isDescending3) ringTranslation3 -= 0.03;
- if(rotAngle < 360F) rotAngle += 6F;
- if(rotAngle>=360F) rotAngle = 0F;
- }
-
- public Packet getDescriptionPacket()
- {
- NBTTagCompound nbttagcompound = new NBTTagCompound();
- this.writeToNBT(nbttagcompound);
- return new S35PacketUpdateTileEntity(this.xCoord, this.yCoord, this.zCoord, 1, nbttagcompound);
- }
-
- @Override
- public void onDataPacket (NetworkManager net, S35PacketUpdateTileEntity packet)
- {
- readFromNBT(packet.func_148857_g());
- worldObj.func_147479_m(xCoord, yCoord, zCoord);
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/tileentity/TileEntityJewelrsCraftingTable.java b/src/main/java/darkknight/jewelrycraft/tileentity/TileEntityJewelrsCraftingTable.java
deleted file mode 100644
index 13b689d..0000000
--- a/src/main/java/darkknight/jewelrycraft/tileentity/TileEntityJewelrsCraftingTable.java
+++ /dev/null
@@ -1,141 +0,0 @@
-package darkknight.jewelrycraft.tileentity;
-
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.network.NetworkManager;
-import net.minecraft.network.Packet;
-import net.minecraft.network.play.server.S35PacketUpdateTileEntity;
-import net.minecraft.tileentity.TileEntity;
-import darkknight.jewelrycraft.config.ConfigHandler;
-import darkknight.jewelrycraft.util.JewelryNBT;
-
-public class TileEntityJewelrsCraftingTable extends TileEntity
-{
- public boolean hasJewelry, hasModifier, hasEndItem, isDirty, hasJewel;
- public ItemStack jewelry, modifier, endItem, jewel;
- public int timer, effect;
- public float angle;
-
- public TileEntityJewelrsCraftingTable()
- {
- this.jewelry = new ItemStack(Item.getItemById(0), 0, 0);
- this.modifier = new ItemStack(Item.getItemById(0), 0, 0);
- this.endItem = new ItemStack(Item.getItemById(0), 0, 0);
- this.jewel = new ItemStack(Item.getItemById(0), 0, 0);
- this.hasJewelry = false;
- this.hasModifier = false;
- this.hasEndItem = false;
- this.hasJewel = false;
- this.timer = 0;
- this.effect = 0;
- this.angle = 0;
- this.isDirty = false;
- }
-
- @Override
- public void writeToNBT(NBTTagCompound nbt)
- {
- super.writeToNBT(nbt);
- nbt.setBoolean("hasJewelry", hasJewelry);
- nbt.setBoolean("hasModifier", hasModifier);
- nbt.setBoolean("hasEndItem", hasEndItem);
- nbt.setBoolean("hasJewel", hasJewel);
- nbt.setInteger("timer", timer);
- nbt.setInteger("effect", effect);
- nbt.setFloat("angle", angle);
-
- NBTTagCompound tag = new NBTTagCompound();
- NBTTagCompound tag1 = new NBTTagCompound();
- NBTTagCompound tag2 = new NBTTagCompound();
- NBTTagCompound tag3 = new NBTTagCompound();
-
- this.jewelry.writeToNBT(tag);
- nbt.setTag("jewelry", tag);
- this.modifier.writeToNBT(tag1);
- nbt.setTag("modifier", tag1);
- this.endItem.writeToNBT(tag2);
- nbt.setTag("endItem", tag2);
- this.jewel.writeToNBT(tag3);
- nbt.setTag("jewel", tag3);
- }
-
- @Override
- public void readFromNBT(NBTTagCompound nbt)
- {
- super.readFromNBT(nbt);
- this.hasJewelry = nbt.getBoolean("hasJewelry");
- this.hasModifier = nbt.getBoolean("hasModifier");
- this.hasEndItem = nbt.getBoolean("hasEndItem");
- this.hasJewel = nbt.getBoolean("hasJewel");
-
- this.timer = nbt.getInteger("timer");
- this.effect = nbt.getInteger("effect");
- this.angle = nbt.getFloat("angle");
- this.jewelry = new ItemStack(Item.getItemById(0), 0, 0);
- this.jewelry.readFromNBT(nbt.getCompoundTag("jewelry"));
- this.modifier = new ItemStack(Item.getItemById(0), 0, 0);
- this.modifier.readFromNBT(nbt.getCompoundTag("modifier"));
- this.endItem = new ItemStack(Item.getItemById(0), 0, 0);
- this.endItem.readFromNBT(nbt.getCompoundTag("endItem"));
- this.jewel = new ItemStack(Item.getItemById(0), 0, 0);
- this.jewel.readFromNBT(nbt.getCompoundTag("jewel"));
- }
-
- @Override
- public void updateEntity()
- {
- super.updateEntity();
- if(isDirty){
- worldObj.markBlockForUpdate(xCoord, yCoord, zCoord);
- isDirty = false;
- }
- if(angle<360F)angle+=3F;
- else angle=0F;
- if (this.hasJewelry && (this.hasModifier || this.hasJewel) && !this.hasEndItem)
- {
- if (timer > 0)
- {
- timer--;
- for (int l = 0; l < ConfigHandler.jewelryCraftingTime/(timer + 2); ++l)
- {
- if(this.getBlockMetadata() == 0) this.worldObj.spawnParticle("witchMagic", xCoord + 0.5F, (double) yCoord + 0.8F, zCoord + 0.2F, 0.0D, 0.0D, 0.0D);
- if(this.getBlockMetadata() == 1) this.worldObj.spawnParticle("witchMagic", xCoord + 0.8F, (double) yCoord + 0.8F, zCoord + 0.5F, 0.0D, 0.0D, 0.0D);
- if(this.getBlockMetadata() == 2) this.worldObj.spawnParticle("witchMagic", xCoord + 0.5F, (double) yCoord + 0.8F, zCoord + 0.8F, 0.0D, 0.0D, 0.0D);
- if(this.getBlockMetadata() == 3) this.worldObj.spawnParticle("witchMagic", xCoord + 0.2F, (double) yCoord + 0.8F, zCoord + 0.5F, 0.0D, 0.0D, 0.0D);
- }
- }
- if (timer == 0)
- {
- this.hasEndItem = true;
- this.endItem = jewelry.copy();
- if (hasModifier && modifier != new ItemStack(Item.getItemById(0), 0, 0)) JewelryNBT.addModifier(endItem, modifier);
- if (hasJewel && jewel != new ItemStack(Item.getItemById(0), 0, 0)) JewelryNBT.addJewel(endItem, jewel);
- if (hasJewel && hasModifier && JewelryNBT.isJewelX(endItem, new ItemStack(Items.nether_star)) && JewelryNBT.isModifierX(endItem, new ItemStack(Items.book))) JewelryNBT.addMode(endItem, "Disenchant");
- if (hasModifier && JewelryNBT.isModifierEffectType(endItem)) JewelryNBT.addMode(endItem, "Activated");
- this.hasJewelry = false;
- this.jewelry = new ItemStack(Item.getItemById(0), 0, 0);
- this.hasModifier = false;
- this.modifier = new ItemStack(Item.getItemById(0), 0, 0);
- this.hasJewel = false;
- this.jewel = new ItemStack(Item.getItemById(0), 0, 0);
- timer = -1;
- }
- }
- }
-
- public Packet getDescriptionPacket()
- {
- NBTTagCompound nbttagcompound = new NBTTagCompound();
- this.writeToNBT(nbttagcompound);
- return new S35PacketUpdateTileEntity(this.xCoord, this.yCoord, this.zCoord, 1, nbttagcompound);
- }
-
- @Override
- public void onDataPacket (NetworkManager net, S35PacketUpdateTileEntity packet)
- {
- readFromNBT(packet.func_148857_g());
- worldObj.func_147479_m(xCoord, yCoord, zCoord);
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/tileentity/TileEntityMolder.java b/src/main/java/darkknight/jewelrycraft/tileentity/TileEntityMolder.java
deleted file mode 100644
index a1b0561..0000000
--- a/src/main/java/darkknight/jewelrycraft/tileentity/TileEntityMolder.java
+++ /dev/null
@@ -1,127 +0,0 @@
-package darkknight.jewelrycraft.tileentity;
-
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.network.NetworkManager;
-import net.minecraft.network.Packet;
-import net.minecraft.network.play.server.S35PacketUpdateTileEntity;
-import net.minecraft.tileentity.TileEntity;
-import darkknight.jewelrycraft.item.ItemList;
-import darkknight.jewelrycraft.util.JewelryNBT;
-
-public class TileEntityMolder extends TileEntity
-{
- public int cooling;
- public boolean hasMoltenMetal, hasJewelBase, hasMold, isDirty;
- public ItemStack mold, jewelBase, moltenMetal, ringMetal;
- public float quantity;
-
- public TileEntityMolder()
- {
- this.moltenMetal = new ItemStack(Item.getItemById(0), 0, 0);
- this.jewelBase = new ItemStack(Item.getItemById(0), 0, 0);
- this.mold = new ItemStack(Item.getItemById(0), 0, 0);
- this.ringMetal = new ItemStack(Item.getItemById(0), 0, 0);
- this.cooling = 0;
- this.quantity = 0f;
- this.hasJewelBase = false;
- this.hasMoltenMetal = false;
- this.hasMold = false;
- this.isDirty = false;
- }
-
- @Override
- public void writeToNBT(NBTTagCompound nbt)
- {
- super.writeToNBT(nbt);
- nbt.setInteger("cooling", cooling);
- nbt.setFloat("quantity", quantity);
- nbt.setBoolean("hasJewelBase", hasJewelBase);
- nbt.setBoolean("hasMoltenMetal", hasMoltenMetal);
- nbt.setBoolean("hasMold", hasMold);
- NBTTagCompound tag = new NBTTagCompound();
- NBTTagCompound tag1 = new NBTTagCompound();
- NBTTagCompound tag2 = new NBTTagCompound();
- NBTTagCompound tag3 = new NBTTagCompound();
- this.mold.writeToNBT(tag);
- nbt.setTag("mold", tag);
- this.jewelBase.writeToNBT(tag1);
- nbt.setTag("jewelBase", tag1);
- this.moltenMetal.writeToNBT(tag2);
- nbt.setTag("moltenMetal", tag2);
- this.ringMetal.writeToNBT(tag3);
- nbt.setTag("ringMetal", tag3);
- }
-
- @Override
- public void readFromNBT(NBTTagCompound nbt)
- {
- super.readFromNBT(nbt);
- this.cooling = nbt.getInteger("cooling");
- this.quantity = nbt.getFloat("quantity");
- this.hasJewelBase = nbt.getBoolean("hasJewelBase");
- this.hasMoltenMetal = nbt.getBoolean("hasMoltenMetal");
- this.hasMold = nbt.getBoolean("hasMold");
- this.mold = new ItemStack(Item.getItemById(0), 0, 0);
- this.mold.readFromNBT(nbt.getCompoundTag("mold"));
- this.jewelBase = new ItemStack(Item.getItemById(0), 0, 0);
- this.jewelBase.readFromNBT(nbt.getCompoundTag("jewelBase"));
- this.moltenMetal = new ItemStack(Item.getItemById(0), 0, 0);
- this.moltenMetal.readFromNBT(nbt.getCompoundTag("moltenMetal"));
- this.ringMetal = new ItemStack(Item.getItemById(0), 0, 0);
- this.ringMetal.readFromNBT(nbt.getCompoundTag("ringMetal"));
- }
-
- @Override
- public void updateEntity()
- {
- super.updateEntity();
- if(isDirty){
- worldObj.markBlockForUpdate(xCoord, yCoord, zCoord);
- isDirty = false;
- }
- if (moltenMetal.getItem() != Item.getItemById(0))
- {
-// if(worldObj.rand.nextInt(20) == 0) this.worldObj.playSoundEffect(xCoord, yCoord + 0.5F, zCoord, "random.fizz", 0.5F, 1F);
- for (int l = 0; l < 2; ++l)
- this.worldObj.spawnParticle("reddust", xCoord + Math.random(), (double) yCoord + 0.2F, zCoord + Math.random(), 0.0D, 1.0D, 1.0D);
- }
- if (this.hasMoltenMetal && !this.hasJewelBase)
- {
- ringMetal = moltenMetal;
- if (cooling > 0 && quantity > 0.9f) this.cooling--;
- if (cooling == 0)
- {
- this.hasMoltenMetal = false;
- if (mold.getItemDamage() == 0)
- this.jewelBase = moltenMetal;
- else if (mold.getItemDamage() == 1)
- this.jewelBase = new ItemStack(ItemList.ring);
- else
- this.jewelBase = new ItemStack(ItemList.necklace);
- if(mold.getItemDamage() != 0 && jewelBase != new ItemStack(Item.getItemById(0), 0, 0))
- JewelryNBT.addMetal(jewelBase, ringMetal);
- this.moltenMetal = new ItemStack(Item.getItemById(0), 0, 0);
- this.hasJewelBase = true;
- cooling = -1;
- quantity = 0f;
- isDirty = true;
- }
- }
- }
-
- public Packet getDescriptionPacket()
- {
- NBTTagCompound nbttagcompound = new NBTTagCompound();
- this.writeToNBT(nbttagcompound);
- return new S35PacketUpdateTileEntity(this.xCoord, this.yCoord, this.zCoord, 1, nbttagcompound);
- }
-
- @Override
- public void onDataPacket (NetworkManager net, S35PacketUpdateTileEntity packet)
- {
- readFromNBT(packet.func_148857_g());
- worldObj.func_147479_m(xCoord, yCoord, zCoord);
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/tileentity/TileEntitySmelter.java b/src/main/java/darkknight/jewelrycraft/tileentity/TileEntitySmelter.java
deleted file mode 100644
index 5f4be83..0000000
--- a/src/main/java/darkknight/jewelrycraft/tileentity/TileEntitySmelter.java
+++ /dev/null
@@ -1,159 +0,0 @@
-package darkknight.jewelrycraft.tileentity;
-
-import java.util.Random;
-
-import darkknight.jewelrycraft.config.ConfigHandler;
-
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.network.NetworkManager;
-import net.minecraft.network.Packet;
-import net.minecraft.network.play.server.S35PacketUpdateTileEntity;
-import net.minecraft.tileentity.TileEntity;
-
-public class TileEntitySmelter extends TileEntity
-{
- public int melting, flow, n = 0, p = 0;
- public boolean hasMetal, hasMoltenMetal, isDirty, pouring;
- public ItemStack metal, moltenMetal;
- public float quantity;
-
- public TileEntitySmelter()
- {
- this.melting = 0;
- this.pouring = false;
- this.flow = 0;
- this.quantity = 0f;
- this.hasMetal = false;
- this.hasMoltenMetal = false;
- this.metal = new ItemStack(Item.getItemById(0), 0, 0);
- this.moltenMetal = new ItemStack(Item.getItemById(0), 0, 0);
- this.isDirty = false;
- }
-
- @Override
- public void writeToNBT(NBTTagCompound nbt)
- {
- super.writeToNBT(nbt);
- nbt.setInteger("melting", melting);
- nbt.setFloat("quantity", quantity);
- nbt.setBoolean("hasMetal", hasMetal);
- nbt.setBoolean("hasMoltenMetal", hasMoltenMetal);
- nbt.setBoolean("pouring", pouring);
- NBTTagCompound tag = new NBTTagCompound();
- NBTTagCompound tag1 = new NBTTagCompound();
- this.metal.writeToNBT(tag);
- nbt.setTag("metal", tag);
- this.moltenMetal.writeToNBT(tag1);
- nbt.setTag("moltenMetal", tag1);
- }
-
- @Override
- public void readFromNBT(NBTTagCompound nbt)
- {
- super.readFromNBT(nbt);
- this.melting = nbt.getInteger("melting");
- this.quantity = nbt.getFloat("quantity");
- this.hasMetal = nbt.getBoolean("hasMetal");
- this.hasMoltenMetal = nbt.getBoolean("hasMoltenMetal");
- this.pouring = nbt.getBoolean("pouring");
- this.metal = new ItemStack(Item.getItemById(0), 0, 0);
- this.metal.readFromNBT(nbt.getCompoundTag("metal"));
- this.moltenMetal = new ItemStack(Item.getItemById(0), 0, 0);
- this.moltenMetal.readFromNBT(nbt.getCompoundTag("moltenMetal"));
- }
-
- @Override
- public void updateEntity()
- {
- super.updateEntity();
- Random rand = new Random();
- if(isDirty){
- worldObj.markBlockForUpdate(xCoord, yCoord, zCoord);
- isDirty = false;
- }
- if (p > 0)
- --p;
- else
- p = 5;
- if (n == 0 && p == 0)
- {
- flow += 16;
- if (flow >= 16 * 20)
- n = 1;
- }
- if (n == 1 && p == 0)
- {
- flow -= 16;
- if (flow <= 0)
- n = 0;
- }
- if (this.hasMetal)
- {
- for (int l = 0; l < 2; ++l)
- this.worldObj.spawnParticle("flame", xCoord + rand.nextFloat(), (double) yCoord + 0.3F, zCoord + rand.nextFloat(), 0.0D, 0.0D, 0.0D);
- }
- if (rand.nextInt(65) == 0)
- {
- double d5 = this.xCoord + rand.nextFloat();
- double d7 = this.yCoord;
- double d6 = this.zCoord + rand.nextFloat();
- this.worldObj.playSound(d5, d7, d6, "liquid.lavapop", 0.2F + rand.nextFloat() * 0.2F, 0.9F + rand.nextFloat() * 0.15F, false);
- }
- if (this.hasMetal)
- {
- if (melting > 0)
- this.melting--;
- if (melting == 0)
- {
- this.hasMetal = false;
- this.moltenMetal = metal;
- this.metal = new ItemStack(Item.getItemById(0), 0, 0);
- this.hasMoltenMetal = true;
- this.quantity = 1f;
- melting = -1;
- this.isDirty = true;
- }
- }
- TileEntityMolder me = null;
- if (worldObj.getBlockMetadata(xCoord, yCoord, zCoord) == 0 && worldObj.getTileEntity(xCoord, yCoord, zCoord - 1) != null && worldObj.getTileEntity(xCoord, yCoord, zCoord - 1) instanceof TileEntityMolder)
- me = (TileEntityMolder) worldObj.getTileEntity(xCoord, yCoord, zCoord - 1);
- else if (worldObj.getBlockMetadata(xCoord, yCoord, zCoord) == 1 && worldObj.getTileEntity(xCoord + 1, yCoord, zCoord) != null && worldObj.getTileEntity(xCoord + 1, yCoord, zCoord) instanceof TileEntityMolder)
- me = (TileEntityMolder) worldObj.getTileEntity(xCoord + 1, yCoord, zCoord);
- else if (worldObj.getBlockMetadata(xCoord, yCoord, zCoord) == 2 && worldObj.getTileEntity(xCoord, yCoord, zCoord + 1) != null && worldObj.getTileEntity(xCoord, yCoord, zCoord + 1) instanceof TileEntityMolder)
- me = (TileEntityMolder) worldObj.getTileEntity(xCoord, yCoord, zCoord + 1);
- else if (worldObj.getBlockMetadata(xCoord, yCoord, zCoord) == 3 && worldObj.getTileEntity(xCoord - 1, yCoord, zCoord) != null && worldObj.getTileEntity(xCoord - 1, yCoord, zCoord) instanceof TileEntityMolder)
- me = (TileEntityMolder) worldObj.getTileEntity(xCoord - 1, yCoord, zCoord);
- if(pouring){
- quantity -= 0.01f;
- me.quantity += 0.01f;
- if(!me.hasMoltenMetal)
- {
- me.moltenMetal = moltenMetal;
- me.hasMoltenMetal = true;
- }
- if(quantity < 0){
- quantity = 0f;
- hasMoltenMetal = false;
- moltenMetal = new ItemStack(Item.getItemById(0), 0, 0);
- pouring = false;
- me.cooling = ConfigHandler.ingotCoolingTime;
- }
- }
- }
-
- public Packet getDescriptionPacket()
- {
- NBTTagCompound nbttagcompound = new NBTTagCompound();
- this.writeToNBT(nbttagcompound);
- return new S35PacketUpdateTileEntity(this.xCoord, this.yCoord, this.zCoord, 1, nbttagcompound);
- }
-
- @Override
- public void onDataPacket (NetworkManager net, S35PacketUpdateTileEntity packet)
- {
- readFromNBT(packet.func_148857_g());
- worldObj.func_147479_m(xCoord, yCoord, zCoord);
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/util/BlockUtils.java b/src/main/java/darkknight/jewelrycraft/util/BlockUtils.java
deleted file mode 100644
index a5f7684..0000000
--- a/src/main/java/darkknight/jewelrycraft/util/BlockUtils.java
+++ /dev/null
@@ -1,122 +0,0 @@
-package darkknight.jewelrycraft.util;
-
-
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.inventory.IInventory;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.MathHelper;
-import net.minecraft.util.MovingObjectPosition;
-import net.minecraft.world.World;
-import net.minecraftforge.common.util.ForgeDirection;
-
-public class BlockUtils
-{
-
- public static final ForgeDirection DEFAULT_BLOCK_DIRECTION = ForgeDirection.WEST;
-
- public static ForgeDirection get2dOrientation(EntityLivingBase entity)
- {
- int l = MathHelper.floor_double(entity.rotationYaw * 4.0F / 360.0F + 0.5D) & 0x3;
- switch (l) {
- case 0:
- return ForgeDirection.SOUTH;
- case 1:
- return ForgeDirection.WEST;
- case 2:
- return ForgeDirection.NORTH;
- case 3:
- return ForgeDirection.EAST;
- }
- return ForgeDirection.SOUTH;
-
- }
-
- public static float getRotationFromDirection(ForgeDirection direction) {
- switch (direction) {
- case NORTH:
- return 0F;
- case SOUTH:
- return 180F;
- case WEST:
- return 90F;
- case EAST:
- return -90F;
- case DOWN:
- return -90f;
- case UP:
- return 90f;
- default:
- return 0f;
- }
- }
-
- public static ForgeDirection get3dOrientation(EntityLivingBase entity) {
- if (entity.rotationPitch > 45.5F) {
- return ForgeDirection.DOWN;
- } else if (entity.rotationPitch < -45.5F) { return ForgeDirection.UP; }
- return get2dOrientation(entity);
- }
-
- public static EntityItem dropItemStackInWorld(World worldObj, double x, double y, double z, ItemStack stack) {
- float f = 0.7F;
- float d0 = worldObj.rand.nextFloat() * f + (1.0F - f) * 0.5F;
- float d1 = worldObj.rand.nextFloat() * f + (1.0F - f) * 0.5F;
- float d2 = worldObj.rand.nextFloat() * f + (1.0F - f) * 0.5F;
- EntityItem entityitem = new EntityItem(worldObj, x + d0, y + d1, z + d2, stack);
- entityitem.delayBeforeCanPickup = 10;
- if (stack.hasTagCompound()) {
- entityitem.getEntityItem().setTagCompound((NBTTagCompound)stack.getTagCompound().copy());
- }
- worldObj.spawnEntityInWorld(entityitem);
- return entityitem;
- }
-
- public static EntityItem ejectItemInDirection(World world, double x, double y, double z, ForgeDirection direction, ItemStack stack) {
- EntityItem item = BlockUtils.dropItemStackInWorld(world, x, y, z, stack);
- item.motionX = direction.offsetX / 5F;
- item.motionY = direction.offsetY / 5F;
- item.motionZ = direction.offsetZ / 5F;
- return item;
- }
-
- public static void dropInventory(IInventory inventory, World world, double x, double y, double z) {
- if (inventory == null) { return; }
- for (int i = 0; i < inventory.getSizeInventory(); ++i) {
- ItemStack itemStack = inventory.getStackInSlot(i);
- if (itemStack != null) {
- dropItemStackInWorld(world, x, y, z, itemStack);
- }
- }
- }
-
- public static void dropInventory(IInventory inventory, World world, int x, int y, int z) {
- dropInventory(inventory, world, x + 0.5, y + 0.5, z + 0.5);
- }
-
- public static TileEntity getTileInDirection(TileEntity tile, ForgeDirection direction) {
- int targetX = tile.xCoord + direction.offsetX;
- int targetY = tile.yCoord + direction.offsetY;
- int targetZ = tile.zCoord + direction.offsetZ;
- return tile.getWorldObj().getTileEntity(targetX, targetY, targetZ);
- }
-
- public static int getFirstNonAirBlockFromTop(World world, int x, int z) {
- int y;
- for (y = world.getActualHeight(); world.isAirBlock(x, y - 1, z) && y > 0; y--) {}
- return y;
- }
-
- public static boolean isBlockHit(MovingObjectPosition mop, TileEntity tile) {
- if (tile == null) return false;
- return isBlockHit(mop, tile.xCoord, tile.yCoord, tile.zCoord);
- }
-
- public static boolean isBlockHit(MovingObjectPosition mop, int x, int y, int z) {
- if (mop == null) return false;
- return mop.blockX == x && mop.blockY == y && mop.blockZ == z;
- }
-
-} \ No newline at end of file
diff --git a/src/main/java/darkknight/jewelrycraft/util/JewelryNBT.java b/src/main/java/darkknight/jewelrycraft/util/JewelryNBT.java
deleted file mode 100644
index d76c84e..0000000
--- a/src/main/java/darkknight/jewelrycraft/util/JewelryNBT.java
+++ /dev/null
@@ -1,626 +0,0 @@
-package darkknight.jewelrycraft.util;
-
-import java.util.List;
-
-import net.minecraft.block.Block;
-import net.minecraft.entity.EntityList;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.nbt.NBTTagList;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.world.World;
-
-public class JewelryNBT
-{
- //TODO NBT Tag Adding
- /**
- *
- * @param item The item you want to add the NBT data on
- * @param metal The metal you want to add on the item
- */
- public static void addMetal(ItemStack item, ItemStack metal)
- {
- NBTTagCompound itemStackData;
- if (item.hasTagCompound())
- itemStackData = item.getTagCompound();
- else
- {
- itemStackData = new NBTTagCompound();
- item.setTagCompound(itemStackData);
- }
- NBTTagCompound ingotNBT = new NBTTagCompound();
- metal.writeToNBT(ingotNBT);
- itemStackData.setTag("ingot", ingotNBT);
- }
-
- /**
- *
- * @param item The item you want to add the NBT data on
- * @param jewel The jewel you want to add on the item
- */
- public static void addJewel(ItemStack item, ItemStack jewel)
- {
- if(jewel != null)
- {
- NBTTagCompound itemStackData;
- if (item.hasTagCompound())
- itemStackData = item.getTagCompound();
- else
- {
- itemStackData = new NBTTagCompound();
- item.setTagCompound(itemStackData);
- }
- NBTTagCompound jewelNBT = new NBTTagCompound();
- jewel.writeToNBT(jewelNBT);
- itemStackData.setTag("jewel", jewelNBT);
- }
- }
-
- /**
- *
- * @param item The item you want to add the NBT data on
- * @param modifier The modifier you want to add on the item
- */
- public static void addModifier(ItemStack item, ItemStack modifier)
- {
- if(modifier != null)
- {
- NBTTagCompound itemStackData;
- if (item.hasTagCompound())
- itemStackData = item.getTagCompound();
- else
- {
- itemStackData = new NBTTagCompound();
- item.setTagCompound(itemStackData);
- }
- NBTTagCompound modifierNBT = new NBTTagCompound();
- modifier.writeToNBT(modifierNBT);
- itemStackData.setTag("modifier", modifierNBT);
- }
- }
-
- public static void addEntity(ItemStack item, EntityLivingBase entity)
- {
- NBTTagCompound itemStackData;
- if (item.hasTagCompound())
- itemStackData = item.getTagCompound();
- else
- {
- itemStackData = new NBTTagCompound();
- item.setTagCompound(itemStackData);
- }
- NBTTagCompound entityNBT = new NBTTagCompound();
- entity.writeToNBT(entityNBT);
- itemStackData.setTag("entity", entityNBT);
- }
-
- public static void addEntityID(ItemStack item, EntityLivingBase entity)
- {
- NBTTagCompound itemStackData;
- if (item.hasTagCompound())
- itemStackData = item.getTagCompound();
- else
- {
- itemStackData = new NBTTagCompound();
- item.setTagCompound(itemStackData);
- }
- NBTTagCompound entityNBT = new NBTTagCompound();
- int id = EntityList.getEntityID(entity);
- entityNBT.setInteger("entityID", id);
- itemStackData.setTag("entityID", entityNBT);
- }
-
- public static void addCoordonates(ItemStack item, double x, double y, double z)
- {
- NBTTagCompound itemStackData;
- if (item.hasTagCompound())
- itemStackData = item.getTagCompound();
- else
- {
- itemStackData = new NBTTagCompound();
- item.setTagCompound(itemStackData);
- }
- NBTTagCompound coords = new NBTTagCompound();
- coords.setDouble("x", x);
- coords.setDouble("y", y);
- coords.setDouble("z", z);
- itemStackData.setTag("x", coords);
- itemStackData.setTag("y", coords);
- itemStackData.setTag("z", coords);
- }
-
- public static void addTileEntityBlock(ItemStack item, World world, int x, int y, int z)
- {
- NBTTagCompound itemStackData;
- if (item.hasTagCompound())
- itemStackData = item.getTagCompound();
- else
- {
- itemStackData = new NBTTagCompound();
- item.setTagCompound(itemStackData);
- }
- NBTTagCompound tileNBT = new NBTTagCompound();
- NBTTagCompound block = new NBTTagCompound();
- world.getTileEntity(x, y, z).writeToNBT(tileNBT);
- itemStackData.setTag("tile", tileNBT);
- block.setInteger("blockID", Block.getIdFromBlock(world.getBlock(x, y, z)));
- block.setInteger("metadata", world.getBlockMetadata(x, y, z));
- block.setInteger("blockX", x);
- block.setInteger("blockY", y);
- block.setInteger("blockZ", z);
- itemStackData.setTag("metadata", block);
- itemStackData.setTag("blockID", block);
- itemStackData.setTag("blockX", block);
- itemStackData.setTag("blockY", block);
- itemStackData.setTag("blockZ", block);
- }
-
- public static void addBlock(ItemStack item, int block, int metadata)
- {
- NBTTagCompound itemStackData;
- if (item.hasTagCompound())
- itemStackData = item.getTagCompound();
- else
- {
- itemStackData = new NBTTagCompound();
- item.setTagCompound(itemStackData);
- }
- NBTTagCompound blockNBT = new NBTTagCompound();
- blockNBT.setInteger("blockID", block);
- itemStackData.setTag("blockID", blockNBT);
- blockNBT.setInteger("metadata", metadata);
- itemStackData.setTag("metadata", blockNBT);
- }
-
- public static void addBlockCoordonates(ItemStack item, int x, int y, int z)
- {
- NBTTagCompound itemStackData;
- if (item.hasTagCompound())
- itemStackData = item.getTagCompound();
- else
- {
- itemStackData = new NBTTagCompound();
- item.setTagCompound(itemStackData);
- }
- NBTTagCompound coords = new NBTTagCompound();
- coords.setInteger("blockX", x);
- coords.setInteger("blockY", y);
- coords.setInteger("blockZ", z);
- itemStackData.setTag("blockX", coords);
- itemStackData.setTag("blockY", coords);
- itemStackData.setTag("blockZ", coords);
- }
-
- public static void addCoordonatesAndDimension(ItemStack item, double x, double y, double z, int dim, String name)
- {
- NBTTagCompound itemStackData;
- if (item.hasTagCompound())
- itemStackData = item.getTagCompound();
- else
- {
- itemStackData = new NBTTagCompound();
- item.setTagCompound(itemStackData);
- }
- NBTTagCompound coords = new NBTTagCompound();
- coords.setDouble("x", x);
- coords.setDouble("y", y);
- coords.setDouble("z", z);
- coords.setInteger("dimension", dim);
- coords.setString("dimName", name);
- itemStackData.setTag("x", coords);
- itemStackData.setTag("y", coords);
- itemStackData.setTag("z", coords);
- itemStackData.setTag("dimension", coords);
- itemStackData.setTag("dimName", coords);
- }
-
- public static void addMode(ItemStack item, String modeN)
- {
- NBTTagCompound itemStackData;
- if (item.hasTagCompound())
- itemStackData = item.getTagCompound();
- else
- {
- itemStackData = new NBTTagCompound();
- item.setTagCompound(itemStackData);
- }
- NBTTagCompound mode = new NBTTagCompound();
- mode.setString("mode", modeN);
- itemStackData.setTag("mode", mode);
- }
-
- public static void addFakeEnchantment(ItemStack item)
- {
- NBTTagCompound itemStackData;
- if (item.hasTagCompound())
- itemStackData = item.getTagCompound();
- else
- {
- itemStackData = new NBTTagCompound();
- item.setTagCompound(itemStackData);
- }
- itemStackData.setTag("ench", new NBTTagList());
- }
-
- public static void addIngotColor(ItemStack item, int color)
- {
- NBTTagCompound itemStackData;
- if (item.hasTagCompound())
- itemStackData = item.getTagCompound();
- else
- {
- itemStackData = new NBTTagCompound();
- item.setTagCompound(itemStackData);
- }
- NBTTagCompound colors = new NBTTagCompound();
- colors.setInteger("ingotColor", color);
- itemStackData.setTag("ingotColor", colors);
- }
-
- public static void addJewelColor(ItemStack item, int color)
- {
- NBTTagCompound itemStackData;
- if (item.hasTagCompound())
- itemStackData = item.getTagCompound();
- else
- {
- itemStackData = new NBTTagCompound();
- item.setTagCompound(itemStackData);
- }
- NBTTagCompound colors = new NBTTagCompound();
- colors.setInteger("jewelColor", color);
- itemStackData.setTag("jewelColor", colors);
- }
-
- @SuppressWarnings("rawtypes")
- public static void addEntities(ItemStack item, List list)
- {
- NBTTagCompound itemStackData;
- if (item.hasTagCompound())
- itemStackData = item.getTagCompound();
- else
- {
- itemStackData = new NBTTagCompound();
- item.setTagCompound(itemStackData);
- }
- NBTTagCompound entityNBT = new NBTTagCompound();
- for(int i=0; i < list.size(); i++) ((EntityLivingBase) list.get(i)).writeToNBT(entityNBT);
- itemStackData.setTag("entities", entityNBT);
- }
-
- //TODO NBT Tag Removing
- public static void removeNBT(ItemStack item, String tag)
- {
- NBTTagCompound itemStackData;
- if (item.hasTagCompound())
- itemStackData = item.getTagCompound();
- else
- {
- itemStackData = new NBTTagCompound();
- item.setTagCompound(itemStackData);
- }
- itemStackData.removeTag(tag);
- }
-
- public static void removeEntity(ItemStack item)
- {
- JewelryNBT.removeNBT(item, "entityID");
- JewelryNBT.removeNBT(item, "entity");
- JewelryNBT.removeNBT(item, "ench");
- }
-
- public static void removeBlock(ItemStack item)
- {
- JewelryNBT.removeNBT(item, "blockID");
- JewelryNBT.removeNBT(item, "metadata");
- JewelryNBT.removeNBT(item, "tile");
- JewelryNBT.removeNBT(item, "blockX");
- JewelryNBT.removeNBT(item, "blockY");
- JewelryNBT.removeNBT(item, "blockZ");
- }
-
- //TODO NTB Tag Checking
- public static boolean hasTag(ItemStack item, String tag)
- {
- NBTTagCompound itemStackData;
- if (item.hasTagCompound())
- itemStackData = item.getTagCompound();
- else
- {
- itemStackData = new NBTTagCompound();
- item.setTagCompound(itemStackData);
- }
- if(itemStackData.hasKey(tag)) return true;
- return false;
- }
-
- public static boolean isJewelX(ItemStack stack, ItemStack jewel)
- {
- if(jewel(stack) != null && jewel(stack).getItem() == jewel.getItem() && jewel(stack).getItemDamage() == jewel.getItemDamage()) return true;
- return false;
- }
-
- public static boolean isModifierX(ItemStack stack, ItemStack modifier)
- {
- if(modifier(stack) != null && modifier(stack).getItem() == modifier.getItem() && modifier(stack).getItemDamage() == modifier.getItemDamage()) return true;
- return false;
- }
-
- public static boolean isModifierEffectType(ItemStack stack)
- {
- if(modifier(stack) != null && (isModifierX(stack, new ItemStack(Items.blaze_powder)) || isModifierX(stack, new ItemStack(Items.sugar))
- || isModifierX(stack, new ItemStack(Items.iron_pickaxe)) || isModifierX(stack, new ItemStack(Items.feather))
- || isModifierX(stack, new ItemStack(Items.potionitem, 1, 8270)))) return true;
- return false;
- }
-
- public static boolean isIngotX(ItemStack stack, ItemStack ingot)
- {
- if(ingot(stack) != null && ingot(stack).getItem() == ingot.getItem() && ingot(stack).getItemDamage() == ingot.getItemDamage()) return true;
- return false;
- }
-
- public static boolean isModeX(ItemStack stack, String modeN)
- {
- if(modeName(stack) != null && modeName(stack).equals(modeN)) return true;
- return false;
- }
-
- public static boolean isEntityX(ItemStack stack, EntityPlayer player, EntityLivingBase entity)
- {
- if(entity != null && entity instanceof EntityLivingBase && entity(stack, player) != null && entity(stack, player).equals(entity)) return true;
- return false;
- }
-
- public static boolean isDimNameX(ItemStack stack, String dimName)
- {
- if(ingot(stack) != null && dimName(stack).equals(dimName)) return true;
- return false;
- }
-
- public static boolean isDimensionX(ItemStack stack, int dimension)
- {
- if(dimension(stack) != -2 && dimension(stack) == dimension) return true;
- return false;
- }
-
- //TODO Return components based on NBT
-
- public static ItemStack jewel(ItemStack stack)
- {
- if(stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.hasTagCompound() && stack.getTagCompound().hasKey("jewel"))
- {
- NBTTagCompound jewelNBT = (NBTTagCompound) stack.getTagCompound().getTag("jewel");
- ItemStack jewel = new ItemStack(Item.getItemById(0), 0, 0);
- jewel.readFromNBT(jewelNBT);
- return jewel;
- }
- return null;
- }
-
- public static ItemStack modifier(ItemStack stack)
- {
- if(stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.hasTagCompound() && stack.getTagCompound().hasKey("modifier"))
- {
- NBTTagCompound modifierNBT = (NBTTagCompound) stack.getTagCompound().getTag("modifier");
- ItemStack modifier = new ItemStack(Item.getItemById(0), 0, 0);
- modifier.readFromNBT(modifierNBT);
- return modifier;
- }
- return null;
- }
-
- public static ItemStack ingot(ItemStack stack)
- {
- if(stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.hasTagCompound() && stack.getTagCompound().hasKey("ingot"))
- {
- NBTTagCompound ingotNBT = (NBTTagCompound) stack.getTagCompound().getTag("ingot");
- ItemStack ingot = new ItemStack(Item.getItemById(0), 0, 0);
- ingot.readFromNBT(ingotNBT);
- return ingot;
- }
- return null;
- }
-
- public static EntityLivingBase entity(ItemStack stack, EntityPlayer player)
- {
- if (stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.getTagCompound().hasKey("entityID") && stack.getTagCompound().hasKey("entity"))
- {
- NBTTagCompound enID = (NBTTagCompound) stack.getTagCompound().getTag("entityID");
- NBTTagCompound en = (NBTTagCompound) stack.getTagCompound().getTag("entity");
- int entityID = 0;
- entityID = enID.getInteger("entityID");
- EntityLivingBase entity = (EntityLivingBase) EntityList.createEntityByID(entityID, player.worldObj);
- if(entity != null && entity instanceof EntityLivingBase)
- {
- entity.readFromNBT(en);
- return entity;
- }
- else return null;
- }
- return null;
- }
-
- public static TileEntity tileEntity(ItemStack stack)
- {
- if (stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.getTagCompound().hasKey("tile"))
- {
- NBTTagCompound tileNBT = (NBTTagCompound) stack.getTagCompound().getTag("tile");
- TileEntity tile = (TileEntity) TileEntity.createAndLoadEntity(tileNBT);
- if(tile != null && tile instanceof TileEntity)
- {
- tile.readFromNBT(tileNBT);
- return tile;
- }
- else return null;
- }
- return null;
- }
-
- public static String dimName(ItemStack stack)
- {
- if(stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.hasTagCompound() && stack.getTagCompound().hasKey("dimName"))
- {
- NBTTagCompound dim = (NBTTagCompound) stack.getTagCompound().getTag("dimName");
- String name = dim.getString("dimName");
- return name;
- }
- return null;
- }
-
- public static String modeName(ItemStack stack)
- {
- if(stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.hasTagCompound() && stack.getTagCompound().hasKey("mode"))
- {
- NBTTagCompound dim = (NBTTagCompound) stack.getTagCompound().getTag("mode");
- String name = dim.getString("mode");
- return name;
- }
- return null;
- }
-
- public static int dimension(ItemStack stack)
- {
- if(stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.hasTagCompound() && stack.getTagCompound().hasKey("dimension"))
- {
- NBTTagCompound dim = (NBTTagCompound) stack.getTagCompound().getTag("dimension");
- int dimension = dim.getInteger("dimension");
- return dimension;
- }
- return -2;
- }
-
- public static int blockCoordX(ItemStack stack)
- {
- if (stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.getTagCompound().hasKey("blockX"))
- {
- NBTTagCompound x = (NBTTagCompound) stack.getTagCompound().getTag("blockX");
- int posX = x.getInteger("blockX");
- return posX;
- }
- return -1;
- }
-
- public static int blockCoordY(ItemStack stack)
- {
- if (stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.getTagCompound().hasKey("blockY"))
- {
- NBTTagCompound y = (NBTTagCompound) stack.getTagCompound().getTag("blockY");
- int posY = y.getInteger("blockY");
- return posY;
- }
- return -1;
- }
-
- public static int blockCoordZ(ItemStack stack)
- {
- if (stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.getTagCompound().hasKey("blockZ"))
- {
- NBTTagCompound z = (NBTTagCompound) stack.getTagCompound().getTag("blockZ");
- int posZ = z.getInteger("blockZ");
- return posZ;
- }
- return -1;
- }
-
- public static int blockID(ItemStack stack)
- {
- if (stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.getTagCompound().hasKey("blockID"))
- {
- NBTTagCompound blockID = (NBTTagCompound) stack.getTagCompound().getTag("blockID");
- int blockId = blockID.getInteger("blockID");
- return blockId;
- }
- return -1;
- }
-
- public static int blockMetadata(ItemStack stack)
- {
- if (stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.getTagCompound().hasKey("metadata"))
- {
- NBTTagCompound metadataNBT = (NBTTagCompound) stack.getTagCompound().getTag("metadata");
- int metadata = metadataNBT.getInteger("metadata");
- return metadata;
- }
- return -1;
- }
-
- public static double playerPosX(ItemStack stack)
- {
- if (stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.getTagCompound().hasKey("x"))
- {
- NBTTagCompound x = (NBTTagCompound) stack.getTagCompound().getTag("x");
- double posX = x.getDouble("x");
- return posX;
- }
- return -1;
- }
-
- public static double playerPosY(ItemStack stack)
- {
- if (stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.getTagCompound().hasKey("y"))
- {
- NBTTagCompound y = (NBTTagCompound) stack.getTagCompound().getTag("y");
- double posY = y.getDouble("y");
- return posY;
- }
- return -1;
- }
-
- public static double playerPosZ(ItemStack stack)
- {
- if (stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.getTagCompound().hasKey("z"))
- {
- NBTTagCompound z = (NBTTagCompound) stack.getTagCompound().getTag("z");
- double posZ = z.getDouble("z");
- return posZ;
- }
- return -1;
- }
-
- public static int ingotColor(ItemStack stack)
- {
- if(stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.hasTagCompound() && stack.getTagCompound().hasKey("ingotColor"))
- {
- NBTTagCompound colors = (NBTTagCompound) stack.getTagCompound().getTag("ingotColor");
- int color = colors.getInteger("ingotColor");
- return color;
- }
- return 16777215;
- }
-
- public static int jewelColor(ItemStack stack)
- {
- if(stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.hasTagCompound() && stack.getTagCompound().hasKey("jewelColor"))
- {
- NBTTagCompound colors = (NBTTagCompound) stack.getTagCompound().getTag("jewelColor");
- int color = colors.getInteger("jewelColor");
- return color;
- }
- return 16777215;
- }
-
- @SuppressWarnings({ "rawtypes", "unchecked", "null" })
- public static List entities(ItemStack stack, EntityPlayer player)
- {
- if (stack != null && stack != new ItemStack(Item.getItemById(0), 0, 0) && stack.getTagCompound().hasKey("entities"))
- {
- NBTTagCompound enID = (NBTTagCompound) stack.getTagCompound().getTag("entitiesID");
- List list = null;
- int[] entityID;
- EntityLivingBase entity;
- entityID = enID.getIntArray("entitiesID");
- for(int i = 0; i < entityID.length; i++){
- entity = (EntityLivingBase) EntityList.createEntityByID(entityID[i], player.worldObj);
- list.add(entity);
- }
- return list;
- }
- return null;
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/util/JewelrycraftUtil.java b/src/main/java/darkknight/jewelrycraft/util/JewelrycraftUtil.java
deleted file mode 100644
index 7575c06..0000000
--- a/src/main/java/darkknight/jewelrycraft/util/JewelrycraftUtil.java
+++ /dev/null
@@ -1,137 +0,0 @@
-package darkknight.jewelrycraft.util;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Random;
-
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.oredict.OreDictionary;
-import darkknight.jewelrycraft.item.ItemList;
-
-public class JewelrycraftUtil
-{
- public static ArrayList<ItemStack> modifiers = new ArrayList<ItemStack>();
- public static ArrayList<ItemStack> jewel = new ArrayList<ItemStack>();
- public static ArrayList<ItemStack> jewelry = new ArrayList<ItemStack>();
- public static ArrayList<ItemStack> metal = new ArrayList<ItemStack>();
- public static ArrayList<String> jamcraftPlayers = new ArrayList<String>();
- public static Random rand = new Random();
-
- public static void addStuff()
- {
- //Modifiers
- modifiers.add(new ItemStack(Blocks.chest));
- modifiers.add(new ItemStack(Blocks.torch));
- modifiers.add(new ItemStack(Items.book));
- modifiers.add(new ItemStack(Items.dye, 1, 15));
- modifiers.add(new ItemStack(Items.bone));
- modifiers.add(new ItemStack(Items.sugar));
- modifiers.add(new ItemStack(Items.feather));
- modifiers.add(new ItemStack(Items.bed));
- modifiers.add(new ItemStack(Items.iron_pickaxe));
- modifiers.add(new ItemStack(Items.redstone));
- modifiers.add(new ItemStack(Items.diamond_pickaxe));
- modifiers.add(new ItemStack(Items.blaze_powder));
- modifiers.add(new ItemStack(Items.ender_eye));
- modifiers.add(new ItemStack(Items.potionitem, 1, 8270));
-
- //Jewels
- for(int i=0; i < 16; i++)
- jewel.add(new ItemStack(ItemList.crystal, 1, i));
- jewel.add(new ItemStack(Blocks.redstone_block));
- jewel.add(new ItemStack(Blocks.lapis_block));
- jewel.add(new ItemStack(Blocks.obsidian));
- jewel.add(new ItemStack(Items.diamond));
- jewel.add(new ItemStack(Items.emerald));
- jewel.add(new ItemStack(Items.ender_pearl));
- jewel.add(new ItemStack(Items.nether_star));
-
- //Jewelry
- jewelry.add(new ItemStack(ItemList.ring));
- jewelry.add(new ItemStack(ItemList.necklace));
- }
-
- public static void jamcrafters()
- {
- jamcraftPlayers.add("allout58");
- jamcraftPlayers.add("ChewBaker");
- jamcraftPlayers.add("domi1819");
- jamcraftPlayers.add("founderio");
- jamcraftPlayers.add("Ironhammer354");
- jamcraftPlayers.add("isomgirls6");
- jamcraftPlayers.add("jmjmjm439");
- jamcraftPlayers.add("Joban");
- jamcraftPlayers.add("KJ4IPS");
- jamcraftPlayers.add("Mitchellbrine");
- jamcraftPlayers.add("MrComputerGhost");
- jamcraftPlayers.add("MrKol999");
- jamcraftPlayers.add("Resinresin");
- jamcraftPlayers.add("sci4me");
- jamcraftPlayers.add("sor1n");
- jamcraftPlayers.add("theminecoder");
- jamcraftPlayers.add("YSPilot");
- jamcraftPlayers.add("direwolf20");
- }
-
- public static void addMetals()
- {
- int index = 0, index2 = 0;
- while(index < OreDictionary.getOreNames().length)
- {
- Iterator<ItemStack> i = OreDictionary.getOres(OreDictionary.getOreNames()[index]).iterator();
-
- while (i.hasNext())
- {
- ItemStack nextStack = i.next();
-
- if ((nextStack.getItem().getUnlocalizedName().toLowerCase().contains("ingot") || nextStack.getItem().getUnlocalizedName().toLowerCase().contains("alloy")) && !metal.contains(nextStack)) metal.add(nextStack);
- }
- index++;
- }
- if(!metal.contains(new ItemStack(Items.gold_ingot)))metal.add(new ItemStack(Items.gold_ingot));
- if(!metal.contains(new ItemStack(Items.iron_ingot)))metal.add(new ItemStack(Items.iron_ingot));
- }
-
- public static boolean isModifier(ItemStack item)
- {
- Iterator<ItemStack> i = modifiers.iterator();
-
- while (i.hasNext())
- {
- ItemStack temp = i.next();
- if (temp.getItem() == item.getItem() && temp.getItemDamage() == item.getItemDamage())
- return true;
- }
- return false;
- }
-
- public static boolean isJewel(ItemStack item)
- {
- Iterator<ItemStack> i = jewel.iterator();
-
- while (i.hasNext())
- {
- ItemStack temp = i.next();
- if (temp.getItem() == item.getItem() && temp.getItemDamage() == item.getItemDamage())
- return true;
- }
- return false;
- }
-
- public static boolean isJewelry(ItemStack item)
- {
- Iterator<ItemStack> i = jewelry.iterator();
-
- while (i.hasNext())
- {
- ItemStack temp = i.next();
- if (temp.getItem() == item.getItem() && temp.getItemDamage() == item.getItemDamage())
- return true;
- }
- return false;
- }
-}
diff --git a/src/main/java/darkknight/jewelrycraft/util/PlayerUtils.java b/src/main/java/darkknight/jewelrycraft/util/PlayerUtils.java
deleted file mode 100644
index aa6a12b..0000000
--- a/src/main/java/darkknight/jewelrycraft/util/PlayerUtils.java
+++ /dev/null
@@ -1,57 +0,0 @@
-package darkknight.jewelrycraft.util;
-
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.server.MinecraftServer;
-import net.minecraft.server.integrated.IntegratedServer;
-import cpw.mods.fml.common.FMLCommonHandler;
-
-/**
- * Code taken from OpenBlocks
- */
-public class PlayerUtils
-{
- public static boolean isPlayerOp(String username)
- {
- username = username.toLowerCase();
-
- MinecraftServer server = FMLCommonHandler.instance().getSidedDelegate().getServer();
-
- // SP and LAN
- if (server.isSinglePlayer()) {
- if (server instanceof IntegratedServer) return server.getServerOwner().equals(username);
- return server.getConfigurationManager().getOps().contains(username);
- }
-
- // SMP
- return server.getConfigurationManager().getOps().contains(username);
- }
-
- public static NBTTagCompound getModPlayerPersistTag(EntityPlayer player, String modName)
- {
-
- NBTTagCompound tag = player.getEntityData();
-
- NBTTagCompound persistTag = null;
- if (tag.hasKey(EntityPlayer.PERSISTED_NBT_TAG))
- {
- persistTag = tag.getCompoundTag(EntityPlayer.PERSISTED_NBT_TAG);
- } else
- {
- persistTag = new NBTTagCompound();
- tag.setTag(EntityPlayer.PERSISTED_NBT_TAG, persistTag);
- }
-
- NBTTagCompound modTag = null;
- if (persistTag.hasKey(modName))
- {
- modTag = persistTag.getCompoundTag(modName);
- } else
- {
- modTag = new NBTTagCompound();
- persistTag.setTag(modName, modTag);
- }
-
- return modTag;
- }
-} \ No newline at end of file
diff --git a/src/main/java/darkknight/jewelrycraft/worldGen/Generation.java b/src/main/java/darkknight/jewelrycraft/worldGen/Generation.java
deleted file mode 100644
index 90d2bb1..0000000
--- a/src/main/java/darkknight/jewelrycraft/worldGen/Generation.java
+++ /dev/null
@@ -1,48 +0,0 @@
-package darkknight.jewelrycraft.worldGen;
-
-import java.util.Random;
-
-import net.minecraft.init.Blocks;
-import net.minecraft.world.World;
-import net.minecraft.world.chunk.IChunkProvider;
-import cpw.mods.fml.common.IWorldGenerator;
-import darkknight.jewelrycraft.block.BlockList;
-
-public class Generation implements IWorldGenerator
-{
- @Override
- public void generate(Random random, int chunkX, int chunkZ, World world, IChunkProvider chunkGenerator, IChunkProvider chunkProvider)
- {
- switch (world.provider.dimensionId)
- {
- case -1:
- generateNether(world, random, chunkX << 4, chunkZ << 4);
- break;
- case 0:
- generateSurface(world, random, chunkX << 4, chunkZ << 4);
- break;
- case 1:
- generateEnd(world, random, chunkX << 4, chunkZ << 4);
- break;
- }
- }
-
- private void generateEnd(World world, Random random, int i, int j)
- {}
-
- private void generateSurface(World world, Random random, int i, int j)
- {
- for (int k = 0; k < 1; k++)
- {
- int x = i + random.nextInt(16);
- int y = 5 + random.nextInt(4);
- int z = j + random.nextInt(16);
- if(world.getBlock(x, y, z) == Blocks.stone) world.setBlock(x, y, z, BlockList.shadowOre);
- int randX = random.nextInt(2), randY = random.nextInt(1), randZ = random.nextInt(2);
- if(random.nextInt(3) == 0 && world.getBlock(x + randX, y + randY, z + randZ) == Blocks.stone) world.setBlock(x + randX, y + randY, z + randZ, BlockList.shadowOre);
- }
- }
-
- private void generateNether(World world, Random random, int i, int j)
- {}
-}
diff --git a/src/main/java/darkknight/jewelrycraft/worldGen/village/ComponentJewelry.java b/src/main/java/darkknight/jewelrycraft/worldGen/village/ComponentJewelry.java
deleted file mode 100644
index 32c9ec2..0000000
--- a/src/main/java/darkknight/jewelrycraft/worldGen/village/ComponentJewelry.java
+++ /dev/null
@@ -1,362 +0,0 @@
-package darkknight.jewelrycraft.worldGen.village;
-
-import java.util.List;
-import java.util.Random;
-
-import net.minecraft.block.Block;
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntityChest;
-import net.minecraft.tileentity.TileEntityFurnace;
-import net.minecraft.world.World;
-import net.minecraft.world.gen.structure.StructureBoundingBox;
-import net.minecraft.world.gen.structure.StructureComponent;
-import net.minecraft.world.gen.structure.StructureVillagePieces;
-import net.minecraft.world.gen.structure.StructureVillagePieces.Start;
-import darkknight.jewelrycraft.block.BlockList;
-import darkknight.jewelrycraft.config.ConfigHandler;
-import darkknight.jewelrycraft.item.ItemList;
-import darkknight.jewelrycraft.item.ItemMolds;
-import darkknight.jewelrycraft.tileentity.TileEntityDisplayer;
-import darkknight.jewelrycraft.tileentity.TileEntityMolder;
-import darkknight.jewelrycraft.tileentity.TileEntitySmelter;
-import darkknight.jewelrycraft.util.JewelryNBT;
-import darkknight.jewelrycraft.util.JewelrycraftUtil;
-
-public class ComponentJewelry extends StructureVillagePieces.House1
-{
- private int averageGroundLevel = -1;
-
- public ComponentJewelry()
- {
- }
-
- public ComponentJewelry(Start par1ComponentVillageStartPiece, int par2, Random par3Random, StructureBoundingBox par4StructureBoundingBox, int par5)
- {
- super();
- this.coordBaseMode = par5;
- this.boundingBox = par4StructureBoundingBox;
- }
-
- @SuppressWarnings("rawtypes")
- public static ComponentJewelry buildComponent (Start villagePiece, List pieces, Random random, int p1, int p2, int p3, int p4, int p5)
- {
- StructureBoundingBox structureboundingbox = StructureBoundingBox.getComponentToAddBoundingBox(p1, p2, p3, 0, 0, 0, 11, 5, 12, p4);
- return canVillageGoDeeper(structureboundingbox) && StructureComponent.findIntersecting(pieces, structureboundingbox) == null ? new ComponentJewelry(villagePiece, p5, random,
- structureboundingbox, p4) : null;
- }
-
- /**
- * second Part of Structure generating, this for example places Spiderwebs, Mob Spawners, it closes Mineshafts at
- * the end, it adds Fences...
- */
- public boolean addComponentParts (World world, Random random, StructureBoundingBox sbb)
- {
- if (this.averageGroundLevel < 0)
- {
- this.averageGroundLevel = this.getAverageGroundLevel(world, sbb);
-
- if (this.averageGroundLevel < 0)
- {
- return true;
- }
-
- this.boundingBox.offset(0, this.averageGroundLevel - this.boundingBox.maxY + 3, 0);
- }
-
- /**
- * arguments: (World worldObj, StructureBoundingBox structBB, int minX, int minY, int minZ, int maxX, int maxY, int
- * maxZ, int placeBlockId, int replaceBlockId, boolean alwaysreplace)
- */
- this.fillWithBlocks(world, sbb, 0, 0, 6, 10, 5, 11, Block.getBlockById(0), Block.getBlockById(0), false);
- this.fillWithBlocks(world, sbb, 2, 0, 0, 8, 5, 5, Block.getBlockById(0), Block.getBlockById(0), false);
- //Pillars
- this.fillWithBlocks(world, sbb, 2, 0, 0, 2, 3, 0, Blocks.log, Blocks.log, false);
- this.fillWithBlocks(world, sbb, 2, 0, 3, 2, 3, 3, Blocks.log, Blocks.log, false);
- this.fillWithBlocks(world, sbb, 8, 0, 0, 8, 3, 0, Blocks.log, Blocks.log, false);
- this.fillWithBlocks(world, sbb, 8, 0, 3, 8, 3, 3, Blocks.log, Blocks.log, false);
-
- //Walls
- this.fillWithBlocks(world, sbb, 2, 0, 1, 2, 3, 2, Blocks.planks, Blocks.planks, false);
- this.fillWithBlocks(world, sbb, 2, 0, 4, 2, 3, 5, Blocks.planks, Blocks.planks, false);
- this.fillWithBlocks(world, sbb, 8, 0, 1, 8, 3, 2, Blocks.planks, Blocks.planks, false);
- this.fillWithBlocks(world, sbb, 8, 0, 4, 8, 3, 5, Blocks.planks, Blocks.planks, false);
- this.fillWithBlocks(world, sbb, 3, 0, 0, 7, 3, 0, Blocks.planks, Blocks.planks, false);
-
- this.fillWithBlocks(world, sbb, 0, 0, 6, 10, 3, 6, Blocks.cobblestone, Blocks.cobblestone, false);
- this.fillWithBlocks(world, sbb, 0, 0, 11, 10, 3, 11, Blocks.cobblestone, Blocks.cobblestone, false);
- this.fillWithBlocks(world, sbb, 0, 0, 6, 0, 3, 11, Blocks.cobblestone, Blocks.cobblestone, false);
- this.fillWithBlocks(world, sbb, 10, 0, 6, 10, 3, 11, Blocks.cobblestone, Blocks.cobblestone, false);
-
- //Roof
- for(int i = 3; i <= 7; i++)
- for(int j = 1; j <= 5; j++)
- this.placeBlockAtCurrentPosition(world, Blocks.wooden_slab, 2, i, 4, j, sbb);
-
- for(int i = 3; i <= 7; i++)
- for(int j = 6; j <= 6; j++)
- this.placeBlockAtCurrentPosition(world, Blocks.stone_slab, 0, i, 4, j, sbb);
-
- for(int i = 1; i <= 9; i++)
- for(int j = 7; j <= 10; j++)
- this.placeBlockAtCurrentPosition(world, Blocks.stone_slab, 3, i, 4, j, sbb);
-
- for(int i = 2; i <= 8; i++)
- this.placeBlockAtCurrentPosition(world, Blocks.double_wooden_slab, 2, i, 4, 0, sbb);
-
- for(int i = 1; i <= 5; i++){
- this.placeBlockAtCurrentPosition(world, Blocks.double_wooden_slab, 2, 2, 4, i, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.double_wooden_slab, 2, 8, 4, i, sbb);
- }
-
- for(int i = 0; i <= 2; i++){
- this.placeBlockAtCurrentPosition(world, Blocks.double_stone_slab, 0, i, 4, 6, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.double_stone_slab, 0, i + 8, 4, 6, sbb);
- }
-
- for(int i = 7; i <= 11; i++){
- this.placeBlockAtCurrentPosition(world, Blocks.double_stone_slab, 0, 0, 4, i, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.double_stone_slab, 0, 10, 4, i, sbb);
- }
-
- for(int i = 0; i <= 10; i++)
- this.placeBlockAtCurrentPosition(world, Blocks.double_stone_slab, 0, i, 4, 11, sbb);
-
- //Base
- for(int i = 2; i <= 8; i++)
- for(int j = 0; j <= 5; j++)
- this.placeBlockAtCurrentPosition(world, Blocks.planks, 1, i, 0, j, sbb);
- this.fillWithBlocks(world, sbb, 0, 0, 6, 10, 0, 11, Blocks.stonebrick, Blocks.stonebrick, false);
-
- for(int i = 6; i <= 10; i++)
- this.placeBlockAtCurrentPosition(world, Blocks.double_stone_slab, 0, 5, 0, i, sbb);
-
- for(int i = 7; i <= 10; i++){
- this.placeBlockAtCurrentPosition(world, Blocks.stonebrick, 3, 1, 0, i, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.stonebrick, 3, 9, 0, i, sbb);
- }
-
- //Decorations
- this.placeDoorAtCurrentPosition(world, sbb, random, 6, 1, 0, this.getMetadataWithOffset(Blocks.wooden_door, 1));
- this.placeDoorAtCurrentPosition(world, sbb, random, 5, 1, 6, this.getMetadataWithOffset(Blocks.wooden_door, 1));
-
- this.placeBlockAtCurrentPosition(world, Blocks.glass_pane, 0, 3, 2, 0, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.glass_pane, 0, 4, 2, 0, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.glass_pane, 0, 2, 2, 1, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.glass_pane, 0, 2, 2, 2, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.glass_pane, 0, 2, 2, 4, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.glass_pane, 0, 2, 2, 5, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.glass_pane, 0, 8, 2, 1, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.glass_pane, 0, 8, 2, 2, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.glass_pane, 0, 8, 2, 4, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.glass_pane, 0, 8, 2, 5, sbb);
-
- this.placeBlockAtCurrentPosition(world, Blocks.torch, 0, 6, 3, 1, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.torch, 0, 3, 3, 3, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.torch, 0, 7, 3, 3, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.torch, 0, 5, 3, 5, sbb);
-
- this.placeBlockAtCurrentPosition(world, Blocks.torch, 0, 5, 3, 7, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.torch, 0, 5, 3, 10, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.torch, 0, 1, 3, 8, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.torch, 0, 1, 3, 9, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.torch, 0, 9, 3, 8, sbb);
- this.placeBlockAtCurrentPosition(world, Blocks.torch, 0, 9, 3, 9, sbb);
-
- int bgCarpetColor = random.nextInt(16);
-
- for(int i = 4; i <= 7; i++)
- for(int j = 1; j <= 5; j++)
- this.placeBlockAtCurrentPosition(world, Blocks.carpet, bgCarpetColor, i, 1, j, sbb);
-
- generateChest(world, 3, 1, 1, 0, random, sbb, ConfigHandler.jewelsChestMin, ConfigHandler.jewelsChestMax);
- generateDisplayer(world, 3, 1, 2, (coordBaseMode == 0 || coordBaseMode == 2)?1:2, random, sbb);
- placeBlockAtCurrentPosition(world, BlockList.jewelCraftingTable, (coordBaseMode == 0 || coordBaseMode == 2)?1:2, 3, 1, 3, sbb);
- generateDisplayer(world, 3, 1, 4, (coordBaseMode == 0 || coordBaseMode == 2)?1:2, random, sbb);
- generateChest(world, 3, 1, 5, 0, random, sbb, ConfigHandler.jewelsChestMin, ConfigHandler.jewelsChestMax);
-
- generateFurnace(world, 1, 1, 7, 0, random, sbb, ConfigHandler.furnacesIngotStackMin, ConfigHandler.furnacesIngotStackMax, ConfigHandler.canFurnacesGenerateIngots);
- generateFurnace(world, 1, 2, 7, 0, random, sbb, ConfigHandler.furnacesIngotStackMin, ConfigHandler.furnacesIngotStackMax, ConfigHandler.canFurnacesGenerateIngots);
- generateFurnace(world, 1, 3, 7, 0, random, sbb, ConfigHandler.furnacesIngotStackMin, ConfigHandler.furnacesIngotStackMax, ConfigHandler.canFurnacesGenerateIngots);
- generateFurnace(world, 1, 1, 10, 0, random, sbb, ConfigHandler.furnacesIngotStackMin, ConfigHandler.furnacesIngotStackMax, ConfigHandler.canFurnacesGenerateIngots);
- generateFurnace(world, 1, 2, 10, 0, random, sbb, ConfigHandler.furnacesIngotStackMin, ConfigHandler.furnacesIngotStackMax, ConfigHandler.canFurnacesGenerateIngots);
- generateFurnace(world, 1, 3, 10, 0, random, sbb, ConfigHandler.furnacesIngotStackMin, ConfigHandler.furnacesIngotStackMax, ConfigHandler.canFurnacesGenerateIngots);
-
- generateSmelter(world, 1, 1, 8, (coordBaseMode == 0 || coordBaseMode == 2)?1:2, random, sbb, random.nextBoolean());
- generateSmelter(world, 1, 1, 9, (coordBaseMode == 0 || coordBaseMode == 2)?1:2, random, sbb, random.nextBoolean());
-
- generateMolder(world, 2, 1, 8, (coordBaseMode == 0 || coordBaseMode == 2)?1:2, random, sbb, random.nextBoolean(), random.nextBoolean());
- generateMolder(world, 2, 1, 9, (coordBaseMode == 0 || coordBaseMode == 2)?1:2, random, sbb, random.nextBoolean(), random.nextBoolean());
-
- generateIngotChest(world, 9, 1, 7, 0, random, sbb, ConfigHandler.ingotChestMin, ConfigHandler.ingotChestMax, Blocks.chest, ConfigHandler.ingotChestMaxStack);
- generateIngotChest(world, 9, 1, 8, 0, random, sbb, ConfigHandler.ingotChestMin, ConfigHandler.ingotChestMax, Blocks.chest, ConfigHandler.ingotChestMaxStack);
- generateIngotChest(world, 9, 1, 9, 0, random, sbb, ConfigHandler.ingotChestMin, ConfigHandler.ingotChestMax, Blocks.trapped_chest, ConfigHandler.ingotChestMaxStack);
- generateIngotChest(world, 9, 1, 10, 0, random, sbb, ConfigHandler.ingotChestMin, ConfigHandler.ingotChestMax, Blocks.trapped_chest, ConfigHandler.ingotChestMaxStack);
-
-
- for (int l = 0; l < 6; ++l)
- {
- for (int i1 = 2; i1 < 9; ++i1)
- {
- this.clearCurrentPositionBlocksUpwards(world, i1, 9, l, sbb);
- this.func_151554_b(world, Blocks.cobblestone, 0, i1, -1, l, sbb);
- }
- }
-
- for (int l = 6; l < 12; ++l)
- {
- for (int i1 = 0; i1 < 11; ++i1)
- {
- this.clearCurrentPositionBlocksUpwards(world, i1, 9, l, sbb);
- this.func_151554_b(world, Blocks.cobblestone, 0, i1, -1, l, sbb);
- }
- }
-
- this.spawnVillagers(world, sbb, 3, 1, 3, 1);
-
- return true;
- }
-
- public void generateChest(World world, int i, int j, int k, int metadata, Random random, StructureBoundingBox sbb, int min, int max)
- {
- int i1 = this.getXWithOffset(i, k);
- int j1 = this.getYWithOffset(j);
- int k1 = this.getZWithOffset(i, k);
- int t = random.nextInt(max - min + 1) + min;
- this.placeBlockAtCurrentPosition(world, Blocks.chest, metadata, i, j, k, sbb);
- TileEntityChest chest = (TileEntityChest)world.getTileEntity(i1, j1, k1);
- while(chest != null && t > 0)
- {
- ItemStack jewels = JewelrycraftUtil.jewel.get(random.nextInt(JewelrycraftUtil.jewel.size()));
- chest.func_145976_a("Jeweler's Chest");
- if(random.nextBoolean()) chest.setInventorySlotContents(random.nextInt(chest.getSizeInventory()), JewelrycraftUtil.modifiers.get(random.nextInt(JewelrycraftUtil.modifiers.size())));
- else if(jewels.getItem() == Items.nether_star && ConfigHandler.generateVillageNetherstar) chest.setInventorySlotContents(random.nextInt(chest.getSizeInventory()), jewels);
- else if(random.nextBoolean() && jewels.getItem() != Items.nether_star) chest.setInventorySlotContents(random.nextInt(chest.getSizeInventory()), jewels);
- t--;
- }
- }
-
- public void generateIngotChest(World world, int i, int j, int k, int metadata, Random random, StructureBoundingBox sbb, int min, int max, Block chestB, int randomAmount)
- {
- int i1 = this.getXWithOffset(i, k);
- int j1 = this.getYWithOffset(j);
- int k1 = this.getZWithOffset(i, k);
- int t = random.nextInt(max - min + 1) + min;
- this.placeBlockAtCurrentPosition(world, chestB, metadata, i, j, k, sbb);
- TileEntityChest chest = (TileEntityChest)world.getTileEntity(i1, j1, k1);
- while(chest != null && t > 0)
- {
- chest.func_145976_a("Ingot Chest");
- if(random.nextBoolean()) chest.setInventorySlotContents(random.nextInt(chest.getSizeInventory()), new ItemStack(JewelrycraftUtil.metal.get(random.nextInt(JewelrycraftUtil.metal.size())).getItem(), 2 + random.nextInt(randomAmount)));
- t--;
- }
- }
-
- public void generateTrappedChest(World world, int i, int j, int k, int metadata, Random random, StructureBoundingBox sbb, int min, int max)
- {
- int i1 = this.getXWithOffset(i, k);
- int j1 = this.getYWithOffset(j);
- int k1 = this.getZWithOffset(i, k);
- int t = random.nextInt(max - min + 1) + min;
- this.placeBlockAtCurrentPosition(world, Blocks.trapped_chest, metadata, i, j, k, sbb);
- TileEntityChest chest = (TileEntityChest)world.getTileEntity(i1, j1, k1);
- while(chest != null && t > 0)
- {
- chest.func_145976_a("Jeweler's Chest");
- if(random.nextBoolean()) chest.setInventorySlotContents(random.nextInt(chest.getSizeInventory()), JewelrycraftUtil.modifiers.get(random.nextInt(JewelrycraftUtil.modifiers.size())));
- else chest.setInventorySlotContents(random.nextInt(chest.getSizeInventory()), JewelrycraftUtil.jewel.get(random.nextInt(JewelrycraftUtil.jewel.size())));
- t--;
- }
- }
-
- public void generateDisplayer(World world, int i, int j, int k, int metadata, Random random, StructureBoundingBox sbb)
- {
- int i1 = this.getXWithOffset(i, k);
- int j1 = this.getYWithOffset(j);
- int k1 = this.getZWithOffset(i, k);
- placeBlockAtCurrentPosition(world, BlockList.displayer, metadata, i, j, k, sbb);
- TileEntityDisplayer displayer = (TileEntityDisplayer)world.getTileEntity(i1, j1, k1);
- if(displayer != null)
- {
- ItemStack ring = new ItemStack(ItemList.ring);
- JewelryNBT.addMetal(ring, JewelrycraftUtil.metal.get(random.nextInt(JewelrycraftUtil.metal.size())));
- JewelryNBT.addModifier(ring, JewelrycraftUtil.modifiers.get(random.nextInt(JewelrycraftUtil.modifiers.size())));
- JewelryNBT.addJewel(ring, JewelrycraftUtil.jewel.get(random.nextInt(JewelrycraftUtil.jewel.size())));
- if(JewelryNBT.isModifierEffectType(ring)) JewelryNBT.addMode(ring, "Activated");
- if(JewelryNBT.isJewelX(ring, new ItemStack(Items.nether_star)) && JewelryNBT.isModifierX(ring, new ItemStack(Items.book)))
- JewelryNBT.addMode(ring, "Disenchant");
- displayer.object = ring;
- displayer.quantity = 1;
- displayer.hasObject = true;
- }
- }
-
- public void generateSmelter(World world, int i, int j, int k, int metadata, Random random, StructureBoundingBox sbb, boolean isEmpty)
- {
- int i1 = this.getXWithOffset(i, k);
- int j1 = this.getYWithOffset(j);
- int k1 = this.getZWithOffset(i, k);
- placeBlockAtCurrentPosition(world, BlockList.smelter, metadata, i, j, k, sbb);
- TileEntitySmelter smelter = (TileEntitySmelter)world.getTileEntity(i1, j1, k1);
- if(smelter != null && !isEmpty)
- {
- smelter.moltenMetal = JewelrycraftUtil.metal.get(random.nextInt(JewelrycraftUtil.metal.size()));
- smelter.hasMoltenMetal = true;
- smelter.quantity = 1f;
- }
- }
-
- public void generateMolder(World world, int i, int j, int k, int metadata, Random random, StructureBoundingBox sbb, boolean hasMold, boolean hasStuff)
- {
- int i1 = this.getXWithOffset(i, k);
- int j1 = this.getYWithOffset(j);
- int k1 = this.getZWithOffset(i, k);
- placeBlockAtCurrentPosition(world, BlockList.molder, metadata, i, j, k, sbb);
- TileEntityMolder molder = (TileEntityMolder)world.getTileEntity(i1, j1, k1);
- if(molder != null)
- {
- if(hasMold){
- int meta = random.nextInt(ItemMolds.moldsItemNames.length + 1);
- molder.mold = new ItemStack(ItemList.molds, 1, meta);
- molder.hasMold = true;
- if(hasStuff){
- ItemStack ring = new ItemStack(ItemList.ring);
- JewelryNBT.addMetal(ring, JewelrycraftUtil.metal.get(random.nextInt(JewelrycraftUtil.metal.size())));
- ItemStack necklace = new ItemStack(ItemList.necklace);
- JewelryNBT.addMetal(necklace, JewelrycraftUtil.metal.get(random.nextInt(JewelrycraftUtil.metal.size())));
- if(meta == 0) molder.jewelBase = JewelrycraftUtil.metal.get(random.nextInt(JewelrycraftUtil.metal.size()));
- else if(meta == 1) molder.jewelBase = ring;
- else molder.jewelBase = necklace;
- molder.hasJewelBase = true;
- }
- }
- }
- }
-
- public void generateFurnace(World world, int i, int j, int k, int metadata, Random random, StructureBoundingBox sbb, int min, int max, boolean hasMetal)
- {
- int i1 = this.getXWithOffset(i, k);
- int j1 = this.getYWithOffset(j);
- int k1 = this.getZWithOffset(i, k);
- placeBlockAtCurrentPosition(world, Blocks.furnace, metadata, i, j, k, sbb);
- TileEntityFurnace furnace = (TileEntityFurnace)world.getTileEntity(i1, j1, k1);
- if(furnace != null)
- {
- if(random.nextBoolean()) furnace.setInventorySlotContents(1, new ItemStack(Items.coal, 1 + random.nextInt(16)));
- if(hasMetal){
- ItemStack metal = JewelrycraftUtil.metal.get(random.nextInt(JewelrycraftUtil.metal.size()));
- furnace.setInventorySlotContents(2, new ItemStack(metal.getItem(), random.nextInt(max - min + 1) + min));
- }
- }
- }
-
- /**
- * Returns the villager type to spawn in this component, based on the number of villagers already spawned.
- */
- protected int getVillagerType (int par1)
- {
- return 3000;
- }
-} \ No newline at end of file
diff --git a/src/main/java/darkknight/jewelrycraft/worldGen/village/JCTrades.java b/src/main/java/darkknight/jewelrycraft/worldGen/village/JCTrades.java
deleted file mode 100644
index 8b5c79e..0000000
--- a/src/main/java/darkknight/jewelrycraft/worldGen/village/JCTrades.java
+++ /dev/null
@@ -1,151 +0,0 @@
-package darkknight.jewelrycraft.worldGen.village;
-
-import java.util.Random;
-
-import net.minecraft.entity.passive.EntityVillager;
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.ItemStack;
-import net.minecraft.village.MerchantRecipe;
-import net.minecraft.village.MerchantRecipeList;
-import cpw.mods.fml.common.registry.VillagerRegistry.IVillageTradeHandler;
-import darkknight.jewelrycraft.block.BlockList;
-import darkknight.jewelrycraft.item.ItemList;
-import darkknight.jewelrycraft.util.JewelryNBT;
-import darkknight.jewelrycraft.util.JewelrycraftUtil;
-
-public class JCTrades implements IVillageTradeHandler
-{
-
- public JCTrades()
- {
- super();
- }
-
- @Override
- public void manipulateTradesForVillager (EntityVillager villager, MerchantRecipeList recipeList, Random random)
- {
- if (villager.getProfession() == 3000)
- {
- ItemStack ingredient = null;
- ItemStack ingredient2 = null;
- ItemStack result;
-
- int type = random.nextInt(12);
- switch(type)
- {
- case 0:
- {
- result = JewelrycraftUtil.metal.get(random.nextInt(JewelrycraftUtil.metal.size()));
- result.stackSize = 5 + random.nextInt(8);
- ingredient = new ItemStack(Items.emerald, 2 + random.nextInt(2));
- if(random.nextBoolean()) ingredient2 = new ItemStack(Items.emerald, 2 + random.nextInt(2));
- break;
- }
- case 1:
- {
- result = new ItemStack(ItemList.molds, 5 + random.nextInt(7), random.nextInt(2));
- ingredient = new ItemStack(Items.emerald, 1 + random.nextInt(1));
- if(random.nextBoolean()) ingredient2 = new ItemStack(Items.emerald, 1 + random.nextInt(2));
- break;
- }
- case 2:
- {
- result = new ItemStack(ItemList.thiefGloves);
- ingredient = new ItemStack(Items.emerald, 16 + random.nextInt(8));
- if(random.nextBoolean()) ingredient2 = new ItemStack(Items.emerald, 8 + random.nextInt(4));
- break;
- }
- case 3:
- {
- result = new ItemStack(BlockList.displayer, 1 + random.nextInt(6));
- ingredient = new ItemStack(Items.emerald, 3 + random.nextInt(8));
- if(random.nextBoolean()) ingredient2 = new ItemStack(Items.emerald, 3 + random.nextInt(8));
- break;
- }
- case 4:
- {
- result = new ItemStack(BlockList.jewelCraftingTable);
- ingredient = new ItemStack(Items.emerald, 1 + random.nextInt(2));
- if(random.nextBoolean()) ingredient2 = new ItemStack(Items.emerald, 1 + random.nextInt(2));
- break;
- }
- case 5:
- {
- result = new ItemStack(BlockList.shadowOre, 1 + random.nextInt(16));
- ingredient = new ItemStack(Items.emerald, 3 + random.nextInt(4));
- if(random.nextBoolean()) ingredient2 = new ItemStack(Items.emerald, 3 + random.nextInt(4));
- break;
- }
- case 6:
- {
- result = new ItemStack(BlockList.molder, 5 + random.nextInt(5));
- ingredient = new ItemStack(Items.emerald, 1 + random.nextInt(1));
- if(random.nextBoolean()) ingredient2 = new ItemStack(Items.emerald, 1 + random.nextInt(1));
- break;
- }
- case 7:
- {
- result = new ItemStack(BlockList.smelter);
- ingredient = new ItemStack(Items.emerald, 1 + random.nextInt(2));
- if(random.nextBoolean()) ingredient2 = new ItemStack(Items.emerald, 1 + random.nextInt(2));
- break;
- }
- case 8:
- {
- int end = random.nextInt(JewelrycraftUtil.modifiers.size());
- result = JewelrycraftUtil.modifiers.get(end);
- if(JewelrycraftUtil.modifiers.size() - 1 - end >= 3)
- {
- result.stackSize = 1 + random.nextInt(JewelrycraftUtil.modifiers.size() - end);
- int value = end;
- if(value > 64) value = 64;
- ingredient = new ItemStack(Items.emerald, 3 + random.nextInt(value));
- if(random.nextBoolean()) ingredient2 = new ItemStack(Items.emerald, 4 + random.nextInt(value));
- }
- else
- {
- result.stackSize = 1 + random.nextInt(7);
- ingredient = new ItemStack(Items.emerald, result.stackSize/2 + 1 + random.nextInt(7));
- ingredient2 = new ItemStack(Items.emerald, result.stackSize/2 + 1 + random.nextInt(4));
- }
- if(result.getMaxStackSize()<=1) result.stackSize = 1;
- break;
- }
- case 9:
- {
- int end = random.nextInt(JewelrycraftUtil.jewel.size());
- result = JewelrycraftUtil.jewel.get(end);
- result.stackSize = 1 + random.nextInt(JewelrycraftUtil.jewel.size() - end);
- if(JewelrycraftUtil.jewel.size() - 1 - end >= 1)
- {
- int value = end;
- if(value > 64) value = 64;
- ingredient = new ItemStack(Items.emerald, 2 + random.nextInt(value));
- if(random.nextBoolean()) ingredient2 = new ItemStack(Items.emerald, 2 + random.nextInt(value));
- }
- else
- {
- ingredient = new ItemStack(Blocks.emerald_block, 16 + random.nextInt(32));
- ingredient2 = new ItemStack(Blocks.emerald_block, 8 + random.nextInt(48));
- }
- break;
- }
- default:
- {
- result = new ItemStack(ItemList.ring, 1, 0);
- JewelryNBT.addMetal(result, JewelrycraftUtil.metal.get(random.nextInt(JewelrycraftUtil.metal.size())));
- JewelryNBT.addModifier(result, JewelrycraftUtil.modifiers.get(random.nextInt(JewelrycraftUtil.modifiers.size())));
- JewelryNBT.addJewel(result, JewelrycraftUtil.jewel.get(random.nextInt(JewelrycraftUtil.jewel.size())));
- if(JewelryNBT.isModifierEffectType(result)) JewelryNBT.addMode(result, "Activated");
- if(JewelryNBT.isJewelX(result, new ItemStack(Items.nether_star)) && JewelryNBT.isModifierX(result, new ItemStack(Items.book)))
- JewelryNBT.addMode(result, "Disenchant");
- ingredient = new ItemStack(Items.emerald, 16 + random.nextInt(20));
- ingredient2 = new ItemStack(Blocks.emerald_block, 5 + random.nextInt(5));
- }
- }
-
- recipeList.addToListWithCheck(new MerchantRecipe(ingredient, ingredient2, result));
- }
- }
-} \ No newline at end of file
diff --git a/src/main/java/darkknight/jewelrycraft/worldGen/village/VillageJewelryHandler.java b/src/main/java/darkknight/jewelrycraft/worldGen/village/VillageJewelryHandler.java
deleted file mode 100644
index 3b3aa3f..0000000
--- a/src/main/java/darkknight/jewelrycraft/worldGen/village/VillageJewelryHandler.java
+++ /dev/null
@@ -1,33 +0,0 @@
-package darkknight.jewelrycraft.worldGen.village;
-
-import java.util.List;
-import java.util.Random;
-
-import net.minecraft.world.gen.structure.StructureVillagePieces.House1;
-import net.minecraft.world.gen.structure.StructureStart;
-import net.minecraft.world.gen.structure.MapGenStructureIO;
-import net.minecraft.world.gen.structure.StructureVillagePieces.PieceWeight;
-import net.minecraft.world.gen.structure.StructureVillagePieces.Start;
-import cpw.mods.fml.common.registry.VillagerRegistry.IVillageCreationHandler;
-import darkknight.jewelrycraft.config.ConfigHandler;
-
-public class VillageJewelryHandler implements IVillageCreationHandler
-{
- @Override
- public PieceWeight getVillagePieceWeight (Random random, int i)
- {
- return new PieceWeight(ComponentJewelry.class, ConfigHandler.jewelerWeight, ConfigHandler.maxVillageJewelers);
- }
-
- @Override
- public Class<?> getComponentClass ()
- {
- return ComponentJewelry.class;
- }
-
- @Override
- public Object buildComponent (PieceWeight villagePiece, Start startPiece, @SuppressWarnings("rawtypes") List pieces, Random random, int p1, int p2, int p3, int p4, int p5)
- {
- return ComponentJewelry.buildComponent(startPiece, pieces, random, p1, p2, p3, p4, p5);
- }
-} \ No newline at end of file
diff --git a/src/main/resources/assets/jewelrycraft/Changelog.txt b/src/main/resources/assets/jewelrycraft/Changelog.txt
deleted file mode 100644
index b1af1e8..0000000
--- a/src/main/resources/assets/jewelrycraft/Changelog.txt
+++ /dev/null
@@ -1,83 +0,0 @@
-- Added the Shadow Block
-- Added a enchanting/disenchanting/enchantments transfering ring made out of a Netherstar as jewel and book as modifier
-- Added a creative tab that generates all the possible ingot+jewel+modifier combinations
-- Fixed(?) bug with knightmetal ingots from Twilight Forest not being detected as ingots
-- Fixed weird empty spaces generated by Jewelries in villages
-- Added crystals
-- Reworked the coloring system, thus fixed some rings not having proper colors
-- Fixed(?) the entity holding ring storing entities that don't extend EntityLivingBase
-- Added generation of ingots in the Jewelry village house
-- Added 4 new possible jewels: Redstone, Redstone Block, Lapis and Lapis Block
-- Removed animation from the Shadow Ore
-- Made Shadow Ore more common
-- Balanced Villager trades
-- Fixed Displayer text rendering in front of everything
-- Added the Jewel Altar
-- Added a guide
-
-TODO
-- Make it so you can smelt ores in the smelter
-- Make a way so that the ingot affects the jewels somehow
-- Add a ring of Resistance
-- Think of a way to balance the rings
-- (MAYBE) Shadow Ring -> Shadow ingot ring, nether star, obsidian - makes you appear as hostile so mobs actually leave you alone
-- Elemental jewellery -> punch a creature with it in your hand to do different things, lightning, fling into the air, set on fire,
- encase in ice/fences/iron bars, turn into a sheep (like that spell from Warcraft 2, if anyone remembers that), blindness, extreme
- knockback, charm (turns on your enemies), tame - tames any tamable mob
-- Add Necklaces, bracelets and earrings; Necklaces could have an AOE effect;
-- Shadow armor and tools
-- Add an item that can store rings (maybe a keychain?)
-- Monks Ring -> ups your unarmed damage / block breaking speed / ability to break harder blocks with bare hands, made with a block of iron and a jewel.
-- Ring of Strength -> self explanatory
-- (MAYBE) Add a Shadow Merchant (a villager that trades only shadow related stuff and appears randomly at night)
-- Add a blast protection jewelry
-- Add a jewelery of the Arrow Catcher - each tier of protection gives you a certain % chance of catching arrows instead of being hit by them.
-- (MAYBE) Render the rings on the character
-- In the case of passive benefits, might it be possible to make it so, with fire resistance for example, it refreshes the buff as long as you're not in fire,
- but as soon as you are it gains a limited duration (better jewels for longer durations) that, when it expires there goes the buff and you can burn to death.
- Then you'd need to avoid being on fire for a cooldown period of a few seconds before it could refresh back to the passive state (this part reduced by better jewels)?
- Invisibility could turn off for a period when you punch a mob, that kind of thing.
-- Glowstone Block (Modifier): Places a torch-like blob of light in exchange for 1/2 a heart, higher-tier jewels increase the light emitted.
-- Ghast Tear (Modifier): Allows for a limited-duration flight buff, say starting at 3 seconds all the way to 60 when combined with a nether star. When the timer expires
- you have to land again to reset the usage.
-- Any Color Dye (Modifier): Right-click a sheep to dye it the chosen color. Posted Image
-- Beacon (Modifier): Portable beacon, with the tier based on the jewel added. Shift + Right-click to open the beacon GUI, which would work just like the vanilla one.
-- Water Bucket (Modifier): Right-click the air to start a storm.
-- Lava Bucket (Modifier): Passively adds fire aspect to your weapons and tools.
-- Sand (Modifier): Shift + right-click to advance the day 1 hour. Only usable once per day by default, better jewels increase this.
-- Glass (Jewel): Right-click while holding the ring to zoom in!
-- Lapis Piece (Modifier): Passively adds a slowing effect to your weapons. Better jewels improve this.
-- Lapis Block (Jewel): A jewel that looks pretty but doesn't do much else.
-- Bone (Jewel): Right-click to trade 1/2 a hunger for a bonemeal effect. Otherwise a white jewel with no benefit.
-- Carrot (Modifier): Right-click to trade 1/2 a heart for 1/2 a hunger. Better jewels increase these values. 4 hearts for a steaks-worth of food? XD
-- Diamond Block (Jewel): When on a gold ring it turns it into "Ostentatious Wedding Ring". Otherwise the same (or a little better than) diamond.
-- Golden Apple (Jewel): Ring becomes named "Discord". Right-clicking gives an entirely random buff, a debuff, launches you high into the air, teleports you to a
- random location, sets you on fire, spawns a pig or makes lightning strike. Pretty much anything can happen, and the more biased to negative results the better. :P
-- Enchanted Golden Apple (Jewel): As above, but more biased towards positive effects. Hail Discordia!
-- Name Tag (Jewel): Right-clicking a mob gives it a random name (bonus points if it's from a user-editable list!)
-- Add randomly generated "named" loot to dungeon chests! Ring of Displacement (lets you tele randomly like an enderman), Necklace of Second Chances
- (heals you for 50 when you drop to 3 or fewer hearts with a cooldown of ~1 minute), Trinket of the Gale (arrow/fireball immunity!), Goggles of the Merfolk
- (water breathing!). Endless possibilities! :D
-- Also! Trinkets and Belts!
-
-Trinkets would probably require a new mold, and should bring out the more passive side of items (like, say, instead of opening an enderchest, it automatically
-sucks items into your ender chest, or instead of teleporting you it prevents endermen from teleporting away from you [which could be done pretty easily with a
-fake screen overlay that's treated like the pumpkin one]).
-
-Belts... I'd personally see belts as a ring crafted with a piece of Leather as the "jewel" and could provide conditional buffs proportionate to some factor, like
-say increasing strength buff the lower your HP is. The idea being that the belt should assist you in a useful way, but only when its needed. I'd probably limit it
-to HP and Hunger as determining factors. Things like resistance, regeneration and strength could be applied at low HP, while things like jump boost, haste and speed
-could be applied at high hunger meter values. I wouldn't tie anything to having high/max HP or no hunger since those would be things that players normally try to
-avoid or always have.
-
-And as for goggles... A new mold for the base goggle template, and have it only accept "jewel"-typed items (as "lenses"). If you can't think of where to put a neat
-effect it should probably end up on goggles. Off the top of my head I can think of a few neat uses: Ore Radar (2x diamonds), Clear Vision (2x glass), Mob Spawnable
-Area Highlighting (2x ender pearl), Compass and Clock overlays (doy), Coordinate HUD (map and glass), Speedometer (glass and enderpearl), Altimiter (glass and emerald),
-Thermometer (diamond and glass)... Required Pickaxe Level HUD (no idea). XD
-
-Oooh! And last but not least: Cursed items! I'd probably start with an upgraded jewelry table requiring a regular one, a brewing stand, a piece of glass and a stick.
-You could initially use this upgraded stand to add additional effects, or merge two items into one. Should operate kind of like a furnace, but only accepts blaze powder
-and rods as fuel (about 1 rod or 2 powder = 1 process, the idea being using the blaze stuff like welding materials). But the other use would be cursing jewelry! Why?
-Because nothing says "I hate you so much." like a non-dequipable piece of jewelry that gives you blindness and slowness! Slimeballs could add a cursed sticky effect
-that prevents you dropping it without dying. Fermented spider eye, like with brewing potions, could corrupt the effects on the item. Flint and steel could randomly set
-you on fire. Eye of Ender could randomly tell the world your coordinates. \ No newline at end of file
diff --git a/src/main/resources/assets/jewelrycraft/lang/en_US.lang b/src/main/resources/assets/jewelrycraft/lang/en_US.lang
deleted file mode 100644
index 0b2e294..0000000
--- a/src/main/resources/assets/jewelrycraft/lang/en_US.lang
+++ /dev/null
@@ -1,56 +0,0 @@
-item.Jewelrycraft.thiefGloves.name=Thiefing Gloves
-item.Jewelrycraft.ingotShadow.name=Shadow Ingot
-item.Jewelrycraft.ingot2.name=Ingot 2
-item.Jewelrycraft.ingot3.name=Ingot 3
-item.Jewelrycraft.ingot4.name=Ingot 4
-item.Jewelrycraft.ingot5.name=Ingot 5
-item.Jewelrycraft.ingot6.name=Ingot 6
-item.Jewelrycraft.ingot7.name=Ingot 7
-item.Jewelrycraft.mold.ingot.name=Ingot Mold
-item.Jewelrycraft.mold.ring.name=Ring Mold
-item.Jewelrycraft.mold.necklace.name=Necklace Mold
-item.Jewelrycraft.mold.clayIngot.name=Clay Ingot Mold
-item.Jewelrycraft.mold.clayRing.name=Clay Ring Mold
-item.Jewelrycraft.mold.clayNecklace.name=Clay Necklace Mold
-item.Jewelrycraft.ring.name=Ring
-item.Jewelrycraft.necklace.name=Necklace
-item.Jewelrycraft.crystal.name=Crystal
-item.Jewelrycraft.guide.name=Jewelrycraft Guide
-item.Jewelrycraft.bucket.name=[WIP]Bucket of Molten
-tile.Jewelrycraft.oreShadow.name=Shadow Ore
-tile.Jewelrycraft.blockShadow.name=Shadow Block
-tile.Jewelrycraft.glow.name=Glow
-tile.Jewelrycraft.smelter.name=Smelter
-tile.Jewelrycraft.molder.name=Molder
-tile.Jewelrycraft.displayer.name=Storage Displayer
-tile.Jewelrycraft.jewelCraftingTable.name=Jeweler's Crafting Table
-tile.Jewelrycraft.altar.name=Jewel Altar
-tile.Jewelrycraft.moltenMetal.name=[WIP] Molten
-itemGroup.JewelryCraft=Jewelrycraft
-itemGroup.Rings=Jewelrycraft Rings
-itemGroup.Necklaces=Jewelrycraft Necklaces
-itemGroup.Liquids=Liquids
-chatmessage.Jewelrycraft.molder.addedmold=Added %s to molder.
-chatmessage.Jewelrycraft.molder.metaliscooling=Molten metal is cooling...
-chatmessage.Jewelrycraft.molder.moldisempty=Mold is currently empty.
-chatmessage.Jewelrycraft.molder.moldismissing=Molder does not contain a mold.
-chatmessage.Jewelrycraft.molder.hasmoltenmetal=You can't remove the mold. It contains molten metal!
-chatmessage.Jewelrycraft.smelter.alreadyhasingot=The Smelter already contains a %s
-chatmessage.Jewelrycraft.smelter.hasmolteningot=The Smelter contains a molten %s
-chatmessage.Jewelrycraft.smelter.itemneedstobeingot=The item needs to be an ingot!
-chatmessage.Jewelrycraft.smelter.itemrenamedtoingot=Nice try, but renaming it to an ingot doesn't make it an ingot :p You can't fool me player!
-chatmessage.Jewelrycraft.smelter.molderhasmoltenmetal=The Molder already has molten metal in it!
-chatmessage.Jewelrycraft.smelter.molderhasnomold=The Molder doesn't have a mold in it! You might as well pour this stuff on the ground, eh?
-chatmessage.Jewelrycraft.smelter.modlerhasitem=The Molder contains an item in it. Now you wouldn't want it to be destroyed, would you?
-chatmessage.Jewelrycraft.smelter.molderismissing=You need a Molder in front of this block in order to pour the molten metal!
-chatmessage.Jewelrycraft.smelter.nowsmeltingingot=Smelter is now smelting a %s.
-chatmessage.Jewelrycraft.smelter.metalismelting=%s is being melted.
-chatmessage.Jewelrycraft.smelter.empty=The Smelter is empty.
-chatmessage.Jewelrycraft.table.hasenditem=First take out the crafted jewel before inserting new stuff.
-chatmessage.Jewelrycraft.table.missingjewelryandmodifierorjewel=You need a jewelry piece and a modifier or a jewel.
-chatmessage.Jewelrycraft.table.missingjewelry=You're missing a piece of jewelry.
-chatmessage.Jewelrycraft.table.missingmodifierorjewel=You need a modifier or a jewel.
-chatmessage.Jewelrycraft.table.iscrafting=The %s is being modified.
-chatmessage.Jewelrycraft.table.jewelrymodifiedfull=This piece of jewelry is already modified at maxium. You can't modify it anymore!
-chatmessage.Jewelrycraft.table.jewelrycontainsmodifier=The piece of jewelry already contains a modifier.
-chatmessage.Jewelrycraft.table.jewelrycontainsjewel=The piece of jewelry already contains a jewel. \ No newline at end of file
diff --git a/src/main/resources/assets/jewelrycraft/pack.mcmeta b/src/main/resources/assets/jewelrycraft/pack.mcmeta
deleted file mode 100644
index 0b04ef8..0000000
--- a/src/main/resources/assets/jewelrycraft/pack.mcmeta
+++ /dev/null
@@ -1,6 +0,0 @@
-{
- "pack": {
- "pack_format": 1,
- "description": "Jewelrycraft"
- }
-} \ No newline at end of file
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/altar_bottom.png b/src/main/resources/assets/jewelrycraft/textures/blocks/altar_bottom.png
deleted file mode 100644
index 7ca4c6a..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/altar_bottom.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/altar_side.png b/src/main/resources/assets/jewelrycraft/textures/blocks/altar_side.png
deleted file mode 100644
index 3a69977..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/altar_side.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/altar_top.png b/src/main/resources/assets/jewelrycraft/textures/blocks/altar_top.png
deleted file mode 100644
index 39210c3..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/altar_top.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow0.png b/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow0.png
deleted file mode 100644
index 0b5323d..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow0.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow1.png b/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow1.png
deleted file mode 100644
index 16f9908..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow1.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow10.png b/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow10.png
deleted file mode 100644
index be70eb5..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow10.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow11.png b/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow11.png
deleted file mode 100644
index 1684d9a..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow11.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow12.png b/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow12.png
deleted file mode 100644
index ed4ea49..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow12.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow13.png b/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow13.png
deleted file mode 100644
index 9b2100a..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow13.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow14.png b/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow14.png
deleted file mode 100644
index ea00725..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow14.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow15.png b/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow15.png
deleted file mode 100644
index 2140624..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow15.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow2.png b/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow2.png
deleted file mode 100644
index f95b111..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow2.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow3.png b/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow3.png
deleted file mode 100644
index 0dd5633..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow3.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow4.png b/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow4.png
deleted file mode 100644
index a4e926c..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow4.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow5.png b/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow5.png
deleted file mode 100644
index 8461ac4..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow5.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow6.png b/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow6.png
deleted file mode 100644
index 352d3e4..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow6.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow7.png b/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow7.png
deleted file mode 100644
index 9aa0e03..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow7.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow8.png b/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow8.png
deleted file mode 100644
index ad21447..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow8.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow9.png b/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow9.png
deleted file mode 100644
index 01c0fa4..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/blockShadow9.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/displayer.png b/src/main/resources/assets/jewelrycraft/textures/blocks/displayer.png
deleted file mode 100644
index 155fa53..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/displayer.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/jewelrsCraftingTable.png b/src/main/resources/assets/jewelrycraft/textures/blocks/jewelrsCraftingTable.png
deleted file mode 100644
index e826bbe..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/jewelrsCraftingTable.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/molder.png b/src/main/resources/assets/jewelrycraft/textures/blocks/molder.png
deleted file mode 100644
index 5a08164..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/molder.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/moltenMetalFlow.png b/src/main/resources/assets/jewelrycraft/textures/blocks/moltenMetalFlow.png
deleted file mode 100644
index 8e9a452..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/moltenMetalFlow.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/moltenMetalFlow.png.mcmeta b/src/main/resources/assets/jewelrycraft/textures/blocks/moltenMetalFlow.png.mcmeta
deleted file mode 100644
index 8e55e43..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/moltenMetalFlow.png.mcmeta
+++ /dev/null
@@ -1,5 +0,0 @@
-{
- "animation": {
- "frametime": 3
- }
-}
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/moltenMetalStill.png b/src/main/resources/assets/jewelrycraft/textures/blocks/moltenMetalStill.png
deleted file mode 100644
index 1eff844..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/moltenMetalStill.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/moltenMetalStill.png.mcmeta b/src/main/resources/assets/jewelrycraft/textures/blocks/moltenMetalStill.png.mcmeta
deleted file mode 100644
index 7ceb363..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/moltenMetalStill.png.mcmeta
+++ /dev/null
@@ -1,45 +0,0 @@
-{
- "animation": {
- "frametime": 2,
- "frames": [
- 0,
- 1,
- 2,
- 3,
- 4,
- 5,
- 6,
- 7,
- 8,
- 9,
- 10,
- 11,
- 12,
- 13,
- 14,
- 15,
- 16,
- 17,
- 18,
- 19,
- 18,
- 17,
- 16,
- 15,
- 14,
- 13,
- 12,
- 11,
- 10,
- 9,
- 8,
- 7,
- 6,
- 5,
- 4,
- 3,
- 2,
- 1
- ]
- }
-} \ No newline at end of file
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/oreShadow.png b/src/main/resources/assets/jewelrycraft/textures/blocks/oreShadow.png
deleted file mode 100644
index ffc48dc..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/oreShadow.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/blocks/smelter.png b/src/main/resources/assets/jewelrycraft/textures/blocks/smelter.png
deleted file mode 100644
index 4da0c0a..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/blocks/smelter.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/entities/jeweler.png b/src/main/resources/assets/jewelrycraft/textures/entities/jeweler.png
deleted file mode 100644
index fbd01cb..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/entities/jeweler.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/gui/chest_ring.png b/src/main/resources/assets/jewelrycraft/textures/gui/chest_ring.png
deleted file mode 100644
index 66f00cc..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/gui/chest_ring.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/gui/guidePage.png b/src/main/resources/assets/jewelrycraft/textures/gui/guidePage.png
deleted file mode 100644
index c74dab2..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/gui/guidePage.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/gui/guidePageFlip.png b/src/main/resources/assets/jewelrycraft/textures/gui/guidePageFlip.png
deleted file mode 100644
index 0746861..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/gui/guidePageFlip.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/bucketOverlay.png b/src/main/resources/assets/jewelrycraft/textures/items/bucketOverlay.png
deleted file mode 100644
index fc2e2a9..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/bucketOverlay.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/clayIngotMold.png b/src/main/resources/assets/jewelrycraft/textures/items/clayIngotMold.png
deleted file mode 100644
index 0fecb22..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/clayIngotMold.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/clayNecklaceMold.png b/src/main/resources/assets/jewelrycraft/textures/items/clayNecklaceMold.png
deleted file mode 100644
index 455f094..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/clayNecklaceMold.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/clayRingMold.png b/src/main/resources/assets/jewelrycraft/textures/items/clayRingMold.png
deleted file mode 100644
index 49d2ab1..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/clayRingMold.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/crystal.png b/src/main/resources/assets/jewelrycraft/textures/items/crystal.png
deleted file mode 100644
index 563a41f..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/crystal.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/crystalOverlay.png b/src/main/resources/assets/jewelrycraft/textures/items/crystalOverlay.png
deleted file mode 100644
index d17e909..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/crystalOverlay.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/guide.png b/src/main/resources/assets/jewelrycraft/textures/items/guide.png
deleted file mode 100644
index 39c7f2c..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/guide.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/ingot3.png b/src/main/resources/assets/jewelrycraft/textures/items/ingot3.png
deleted file mode 100644
index 47c9cb8..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/ingot3.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/ingot4.png b/src/main/resources/assets/jewelrycraft/textures/items/ingot4.png
deleted file mode 100644
index 78894d0..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/ingot4.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/ingot6.png b/src/main/resources/assets/jewelrycraft/textures/items/ingot6.png
deleted file mode 100644
index e025782..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/ingot6.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/ingot7.png b/src/main/resources/assets/jewelrycraft/textures/items/ingot7.png
deleted file mode 100644
index b378e29..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/ingot7.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/ingotMold.png b/src/main/resources/assets/jewelrycraft/textures/items/ingotMold.png
deleted file mode 100644
index 0575de5..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/ingotMold.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/ingotShadow.png b/src/main/resources/assets/jewelrycraft/textures/items/ingotShadow.png
deleted file mode 100644
index e3b3aed..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/ingotShadow.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/jewelNecklace.png b/src/main/resources/assets/jewelrycraft/textures/items/jewelNecklace.png
deleted file mode 100644
index 41244d4..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/jewelNecklace.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/jewelRing.png b/src/main/resources/assets/jewelrycraft/textures/items/jewelRing.png
deleted file mode 100644
index 4875772..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/jewelRing.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/moltenMetalStill.png b/src/main/resources/assets/jewelrycraft/textures/items/moltenMetalStill.png
deleted file mode 100644
index 1eff844..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/moltenMetalStill.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/moltenMetalStill.png.mcmeta b/src/main/resources/assets/jewelrycraft/textures/items/moltenMetalStill.png.mcmeta
deleted file mode 100644
index 7ceb363..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/moltenMetalStill.png.mcmeta
+++ /dev/null
@@ -1,45 +0,0 @@
-{
- "animation": {
- "frametime": 2,
- "frames": [
- 0,
- 1,
- 2,
- 3,
- 4,
- 5,
- 6,
- 7,
- 8,
- 9,
- 10,
- 11,
- 12,
- 13,
- 14,
- 15,
- 16,
- 17,
- 18,
- 19,
- 18,
- 17,
- 16,
- 15,
- 14,
- 13,
- 12,
- 11,
- 10,
- 9,
- 8,
- 7,
- 6,
- 5,
- 4,
- 3,
- 2,
- 1
- ]
- }
-} \ No newline at end of file
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/necklace.png b/src/main/resources/assets/jewelrycraft/textures/items/necklace.png
deleted file mode 100644
index 054744d..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/necklace.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/necklaceMold.png b/src/main/resources/assets/jewelrycraft/textures/items/necklaceMold.png
deleted file mode 100644
index 0df4b65..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/necklaceMold.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/ring.png b/src/main/resources/assets/jewelrycraft/textures/items/ring.png
deleted file mode 100644
index ae59f5a..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/ring.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/ringMold.png b/src/main/resources/assets/jewelrycraft/textures/items/ringMold.png
deleted file mode 100644
index 7bab639..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/ringMold.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/test/ingot2.png b/src/main/resources/assets/jewelrycraft/textures/items/test/ingot2.png
deleted file mode 100644
index 8bd47da..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/test/ingot2.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/test/ingot5.png b/src/main/resources/assets/jewelrycraft/textures/items/test/ingot5.png
deleted file mode 100644
index 968b53d..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/test/ingot5.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/items/thiefGloves.png b/src/main/resources/assets/jewelrycraft/textures/items/thiefGloves.png
deleted file mode 100644
index b56e925..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/items/thiefGloves.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/tileentities/Displayer.png b/src/main/resources/assets/jewelrycraft/textures/tileentities/Displayer.png
deleted file mode 100644
index 200637b..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/tileentities/Displayer.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/tileentities/JewelrsCraftingBench.png b/src/main/resources/assets/jewelrycraft/textures/tileentities/JewelrsCraftingBench.png
deleted file mode 100644
index 1ee75d0..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/tileentities/JewelrsCraftingBench.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/tileentities/Molder.png b/src/main/resources/assets/jewelrycraft/textures/tileentities/Molder.png
deleted file mode 100644
index c5acc88..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/tileentities/Molder.png
+++ /dev/null
Binary files differ
diff --git a/src/main/resources/assets/jewelrycraft/textures/tileentities/Smelter.png b/src/main/resources/assets/jewelrycraft/textures/tileentities/Smelter.png
deleted file mode 100644
index 6ec3595..0000000
--- a/src/main/resources/assets/jewelrycraft/textures/tileentities/Smelter.png
+++ /dev/null
Binary files differ