From 46332e7bebfc371035fe38f74069e11ba2389099 Mon Sep 17 00:00:00 2001 From: Ellpeck Date: Sat, 20 Dec 2014 21:34:07 +0100 Subject: [PATCH] Started Booklet, looking good! --- .../ellpeck/gemification/Gemification.java | 8 +- .../blocks/BlockContainerBase.java | 47 ++++++ .../gemification/blocks/BlockCrucible.java | 57 ++++--- .../blocks/BlockCrucibleFire.java | 54 +++---- .../gemification/blocks/InitBlocks.java | 6 +- .../blocks/ItemBlockCrucible.java | 31 ---- .../blocks/ItemBlockCrucibleFire.java | 31 ---- .../gemification/blocks/ItemBlockOreGem.java | 43 ----- .../ellpeck/gemification/blocks/OreGem.java | 34 ++++ .../ellpeck/gemification/booklet/Chapter.java | 23 +++ .../gemification/booklet/ChapterList.java | 14 ++ .../booklet/ContainerInfoBook.java | 16 ++ .../gemification/booklet/GuiInfoBook.java | 149 ++++++++++++++++++ .../gemification/booklet/ItemInfoBook.java | 47 ++++++ .../crafting/CrucibleCraftingManager.java | 15 +- .../gemification/crafting/InitCrafting.java | 21 +++ .../gemification/inventory/GuiHandler.java | 7 + .../inventory/gui/GuiCrucibleFire.java | 4 - .../ellpeck/gemification/items/InitItems.java | 6 +- .../ellpeck/gemification/util/GemType.java | 4 +- .../java/ellpeck/gemification/util/Util.java | 38 ++--- .../gemification/textures/gui/guiInfoBook.png | Bin 0 -> 7646 bytes .../textures/items/itemInfoBook.png | Bin 0 -> 301 bytes 23 files changed, 448 insertions(+), 207 deletions(-) create mode 100644 src/main/java/ellpeck/gemification/blocks/BlockContainerBase.java delete mode 100644 src/main/java/ellpeck/gemification/blocks/ItemBlockCrucible.java delete mode 100644 src/main/java/ellpeck/gemification/blocks/ItemBlockCrucibleFire.java delete mode 100644 src/main/java/ellpeck/gemification/blocks/ItemBlockOreGem.java create mode 100644 src/main/java/ellpeck/gemification/booklet/Chapter.java create mode 100644 src/main/java/ellpeck/gemification/booklet/ChapterList.java create mode 100644 src/main/java/ellpeck/gemification/booklet/ContainerInfoBook.java create mode 100644 src/main/java/ellpeck/gemification/booklet/GuiInfoBook.java create mode 100644 src/main/java/ellpeck/gemification/booklet/ItemInfoBook.java create mode 100644 src/main/java/ellpeck/gemification/crafting/InitCrafting.java create mode 100644 src/main/resources/assets/gemification/textures/gui/guiInfoBook.png create mode 100644 src/main/resources/assets/gemification/textures/items/itemInfoBook.png diff --git a/src/main/java/ellpeck/gemification/Gemification.java b/src/main/java/ellpeck/gemification/Gemification.java index 4090b293a..7773c3b86 100644 --- a/src/main/java/ellpeck/gemification/Gemification.java +++ b/src/main/java/ellpeck/gemification/Gemification.java @@ -8,7 +8,8 @@ import cpw.mods.fml.common.event.FMLInitializationEvent; import cpw.mods.fml.common.event.FMLPostInitializationEvent; import cpw.mods.fml.common.event.FMLPreInitializationEvent; import ellpeck.gemification.blocks.InitBlocks; -import ellpeck.gemification.crafting.CrucibleCraftingManager; +import ellpeck.gemification.booklet.ChapterList; +import ellpeck.gemification.crafting.InitCrafting; import ellpeck.gemification.gen.OreGen; import ellpeck.gemification.inventory.GuiHandler; import ellpeck.gemification.items.InitItems; @@ -28,6 +29,7 @@ public class Gemification{ @SuppressWarnings("unused") @EventHandler() public void preInit(FMLPreInitializationEvent event){ + ChapterList.init(); InitBlocks.init(); InitItems.init(); proxy.preInit(); @@ -36,11 +38,11 @@ public class Gemification{ @SuppressWarnings("unused") @EventHandler() public void init(FMLInitializationEvent event){ - CrucibleCraftingManager.instance.initRecipes(); - proxy.init(); + InitCrafting.init(); GuiHandler.init(); OreGen.init(); TileEntityBase.init(); + proxy.init(); } @SuppressWarnings("unused") diff --git a/src/main/java/ellpeck/gemification/blocks/BlockContainerBase.java b/src/main/java/ellpeck/gemification/blocks/BlockContainerBase.java new file mode 100644 index 000000000..554ccaccc --- /dev/null +++ b/src/main/java/ellpeck/gemification/blocks/BlockContainerBase.java @@ -0,0 +1,47 @@ +package ellpeck.gemification.blocks; + +import ellpeck.gemification.tile.TileEntityInventoryBase; +import net.minecraft.block.Block; +import net.minecraft.block.BlockContainer; +import net.minecraft.block.material.Material; +import net.minecraft.entity.item.EntityItem; +import net.minecraft.item.ItemStack; +import net.minecraft.nbt.NBTTagCompound; +import net.minecraft.world.World; + +import java.util.Random; + +public abstract class BlockContainerBase extends BlockContainer{ + + public BlockContainerBase(Material mat) { + super(mat); + } + + public TileEntityInventoryBase dropInventory(World world, int x, int y, int z) { + TileEntityInventoryBase tileEntity = (TileEntityInventoryBase) world.getTileEntity(x, y, z); + for (int i = 0; i < tileEntity.getSizeInventory(); i++) { + ItemStack itemStack = tileEntity.getStackInSlot(i); + if (itemStack != null && itemStack.stackSize > 0) { + Random rand = new Random(); + float dX = rand.nextFloat() * 0.8F + 0.1F; + float dY = rand.nextFloat() * 0.8F + 0.1F; + float dZ = rand.nextFloat() * 0.8F + 0.1F; + EntityItem entityItem = new EntityItem(world, x + dX, y + dY, z + dZ, itemStack.copy()); + if (itemStack.hasTagCompound()) + entityItem.getEntityItem().setTagCompound((NBTTagCompound) itemStack.getTagCompound().copy()); + float factor = 0.05F; + entityItem.motionX = rand.nextGaussian() * factor; + entityItem.motionY = rand.nextGaussian() * factor + 0.2F; + entityItem.motionZ = rand.nextGaussian() * factor; + world.spawnEntityInWorld(entityItem); + itemStack.stackSize = 0; + } + } + return tileEntity; + } + + public void breakBlock(World world, int x, int y, int z, Block block, int meta){ + this.dropInventory(world, x, y, z); + super.breakBlock(world, x, y, z, block, meta); + } +} diff --git a/src/main/java/ellpeck/gemification/blocks/BlockCrucible.java b/src/main/java/ellpeck/gemification/blocks/BlockCrucible.java index 4fc22d4f9..fac176c5b 100644 --- a/src/main/java/ellpeck/gemification/blocks/BlockCrucible.java +++ b/src/main/java/ellpeck/gemification/blocks/BlockCrucible.java @@ -1,26 +1,28 @@ package ellpeck.gemification.blocks; import cpw.mods.fml.client.registry.RenderingRegistry; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; import ellpeck.gemification.Gemification; import ellpeck.gemification.creative.CreativeTab; import ellpeck.gemification.inventory.GuiHandler; import ellpeck.gemification.tile.TileEntityCrucible; +import ellpeck.gemification.tile.TileEntityInventoryBase; import ellpeck.gemification.util.Util; 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.init.Blocks; +import net.minecraft.item.ItemBlock; import net.minecraft.item.ItemStack; -import net.minecraft.nbt.NBTTagCompound; import net.minecraft.tileentity.TileEntity; +import net.minecraft.util.StatCollector; import net.minecraft.world.World; -import java.util.Random; +import java.util.List; -public class BlockCrucible extends BlockContainer{ +public class BlockCrucible extends BlockContainerBase{ protected BlockCrucible(){ super(Material.rock); @@ -56,31 +58,28 @@ public class BlockCrucible extends BlockContainer{ this.blockIcon = Blocks.hopper.getIcon(0, 0); } - public void breakBlock(World world, int x, int y, int z, Block block, int meta){ - this.dropInventory(world, x, y, z); - super.breakBlock(world, x, y, z, block, meta); - } - - public void dropInventory(World world, int x, int y, int z){ - TileEntityCrucible tileEntity = (TileEntityCrucible)world.getTileEntity(x, y, z); - for (int i = 0; i < tileEntity.getSizeInventory(); i++){ - ItemStack itemStack = tileEntity.getStackInSlot(i); - if (itemStack != null && itemStack.stackSize > 0){ - Random rand = new Random(); - float dX = rand.nextFloat() * 0.8F + 0.1F; - float dY = rand.nextFloat() * 0.8F + 0.1F; - float dZ = rand.nextFloat() * 0.8F + 0.1F; - EntityItem entityItem = new EntityItem(world, x + dX, y + dY, z + dZ, itemStack.copy()); - if (itemStack.hasTagCompound()) entityItem.getEntityItem().setTagCompound((NBTTagCompound) itemStack.getTagCompound().copy()); - float factor = 0.05F; - entityItem.motionX = rand.nextGaussian() * factor; - entityItem.motionY = rand.nextGaussian() * factor + 0.2F; - entityItem.motionZ = rand.nextGaussian() * factor; - world.spawnEntityInWorld(entityItem); - itemStack.stackSize = 0; - } - } + public TileEntityInventoryBase dropInventory(World world, int x, int y, int z){ + TileEntityCrucible tileEntity = (TileEntityCrucible)super.dropInventory(world, x, y, z); if(tileEntity.currentFluid != Util.fluidNone) world.setBlock(x, y, z, Blocks.flowing_water); + return tileEntity; } + public static class ItemBlockCrucible extends ItemBlock { + + public ItemBlockCrucible(Block block){ + super(block); + setHasSubtypes(false); + } + + public String getUnlocalizedName(ItemStack stack) { + return this.getUnlocalizedName(); + } + + @SuppressWarnings("unchecked") + @SideOnly(Side.CLIENT) + public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean isHeld) { + if(Util.isShiftPressed()) list.add(StatCollector.translateToLocal("tooltip." + this.getUnlocalizedName().substring(5) + ".desc")); + else list.add(Util.shiftForInfo()); + } + } } diff --git a/src/main/java/ellpeck/gemification/blocks/BlockCrucibleFire.java b/src/main/java/ellpeck/gemification/blocks/BlockCrucibleFire.java index 5d04073ec..96bcfac80 100644 --- a/src/main/java/ellpeck/gemification/blocks/BlockCrucibleFire.java +++ b/src/main/java/ellpeck/gemification/blocks/BlockCrucibleFire.java @@ -7,21 +7,22 @@ import ellpeck.gemification.Gemification; import ellpeck.gemification.creative.CreativeTab; import ellpeck.gemification.inventory.GuiHandler; import ellpeck.gemification.tile.TileEntityCrucibleFire; +import ellpeck.gemification.util.Util; 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.init.Blocks; +import net.minecraft.item.ItemBlock; import net.minecraft.item.ItemStack; -import net.minecraft.nbt.NBTTagCompound; import net.minecraft.tileentity.TileEntity; +import net.minecraft.util.StatCollector; import net.minecraft.world.World; +import java.util.List; import java.util.Random; -public class BlockCrucibleFire extends BlockContainer{ +public class BlockCrucibleFire extends BlockContainerBase{ protected BlockCrucibleFire(){ super(Material.rock); @@ -58,32 +59,6 @@ public class BlockCrucibleFire extends BlockContainer{ this.blockIcon = Blocks.hopper.getIcon(0, 0); } - public void breakBlock(World world, int x, int y, int z, Block block, int meta){ - this.dropInventory(world, x, y, z); - super.breakBlock(world, x, y, z, block, meta); - } - - public void dropInventory(World world, int x, int y, int z){ - TileEntityCrucibleFire tileEntity = (TileEntityCrucibleFire)world.getTileEntity(x, y, z); - for (int i = 0; i < tileEntity.getSizeInventory(); i++){ - ItemStack itemStack = tileEntity.getStackInSlot(i); - if (itemStack != null && itemStack.stackSize > 0){ - Random rand = new Random(); - float dX = rand.nextFloat() * 0.8F + 0.1F; - float dY = rand.nextFloat() * 0.8F + 0.1F; - float dZ = rand.nextFloat() * 0.8F + 0.1F; - EntityItem entityItem = new EntityItem(world, x + dX, y + dY, z + dZ, itemStack.copy()); - if(itemStack.hasTagCompound()) entityItem.getEntityItem().setTagCompound((NBTTagCompound)itemStack.getTagCompound().copy()); - float factor = 0.05F; - entityItem.motionX = rand.nextGaussian() * factor; - entityItem.motionY = rand.nextGaussian() * factor + 0.2F; - entityItem.motionZ = rand.nextGaussian() * factor; - world.spawnEntityInWorld(entityItem); - itemStack.stackSize = 0; - } - } - } - @SideOnly(Side.CLIENT) public void randomDisplayTick(World world, int x, int y, int z, Random rand){ if(((TileEntityCrucibleFire)world.getTileEntity(x, y, z)).isBurning()){ @@ -93,4 +68,23 @@ public class BlockCrucibleFire extends BlockContainer{ } } } + + public static class ItemBlockCrucibleFire extends ItemBlock { + + public ItemBlockCrucibleFire(Block block){ + super(block); + setHasSubtypes(false); + } + + public String getUnlocalizedName(ItemStack stack) { + return this.getUnlocalizedName(); + } + + @SuppressWarnings("unchecked") + @SideOnly(Side.CLIENT) + public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean isHeld) { + if(Util.isShiftPressed()) list.add(StatCollector.translateToLocal("tooltip." + this.getUnlocalizedName().substring(5) + ".desc")); + else list.add(Util.shiftForInfo()); + } + } } \ No newline at end of file diff --git a/src/main/java/ellpeck/gemification/blocks/InitBlocks.java b/src/main/java/ellpeck/gemification/blocks/InitBlocks.java index a299ff722..dc10de477 100644 --- a/src/main/java/ellpeck/gemification/blocks/InitBlocks.java +++ b/src/main/java/ellpeck/gemification/blocks/InitBlocks.java @@ -15,9 +15,9 @@ public class InitBlocks{ blockCrucible = new BlockCrucible(); blockCrucibleFire = new BlockCrucibleFire(); - GameRegistry.registerBlock(oreGem, ItemBlockOreGem.class, oreGem.getUnlocalizedName().substring(5)); - GameRegistry.registerBlock(blockCrucible, ItemBlockCrucible.class, blockCrucible.getUnlocalizedName().substring(5)); - GameRegistry.registerBlock(blockCrucibleFire, ItemBlockCrucibleFire.class, blockCrucibleFire.getUnlocalizedName().substring(5)); + GameRegistry.registerBlock(oreGem, OreGem.ItemBlockOreGem.class, oreGem.getUnlocalizedName().substring(5)); + GameRegistry.registerBlock(blockCrucible, BlockCrucible.ItemBlockCrucible.class, blockCrucible.getUnlocalizedName().substring(5)); + GameRegistry.registerBlock(blockCrucibleFire, BlockCrucibleFire.ItemBlockCrucibleFire.class, blockCrucibleFire.getUnlocalizedName().substring(5)); } diff --git a/src/main/java/ellpeck/gemification/blocks/ItemBlockCrucible.java b/src/main/java/ellpeck/gemification/blocks/ItemBlockCrucible.java deleted file mode 100644 index 888ed2da0..000000000 --- a/src/main/java/ellpeck/gemification/blocks/ItemBlockCrucible.java +++ /dev/null @@ -1,31 +0,0 @@ -package ellpeck.gemification.blocks; - -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; -import ellpeck.gemification.util.Util; -import net.minecraft.block.Block; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.item.ItemBlock; -import net.minecraft.item.ItemStack; -import net.minecraft.util.StatCollector; - -import java.util.List; - -public class ItemBlockCrucible extends ItemBlock { - - public ItemBlockCrucible(Block block){ - super(block); - setHasSubtypes(false); - } - - public String getUnlocalizedName(ItemStack stack) { - return this.getUnlocalizedName(); - } - - @SuppressWarnings("unchecked") - @SideOnly(Side.CLIENT) - public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean isHeld) { - if(Util.isShiftPressed()) list.add(StatCollector.translateToLocal("tooltip." + this.getUnlocalizedName().substring(5) + ".desc")); - else list.add(Util.shiftForInfo()); - } -} diff --git a/src/main/java/ellpeck/gemification/blocks/ItemBlockCrucibleFire.java b/src/main/java/ellpeck/gemification/blocks/ItemBlockCrucibleFire.java deleted file mode 100644 index 037afc698..000000000 --- a/src/main/java/ellpeck/gemification/blocks/ItemBlockCrucibleFire.java +++ /dev/null @@ -1,31 +0,0 @@ -package ellpeck.gemification.blocks; - -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; -import ellpeck.gemification.util.Util; -import net.minecraft.block.Block; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.item.ItemBlock; -import net.minecraft.item.ItemStack; -import net.minecraft.util.StatCollector; - -import java.util.List; - -public class ItemBlockCrucibleFire extends ItemBlock { - - public ItemBlockCrucibleFire(Block block){ - super(block); - setHasSubtypes(false); - } - - public String getUnlocalizedName(ItemStack stack) { - return this.getUnlocalizedName(); - } - - @SuppressWarnings("unchecked") - @SideOnly(Side.CLIENT) - public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean isHeld) { - if(Util.isShiftPressed()) list.add(StatCollector.translateToLocal("tooltip." + this.getUnlocalizedName().substring(5) + ".desc")); - else list.add(Util.shiftForInfo()); - } -} diff --git a/src/main/java/ellpeck/gemification/blocks/ItemBlockOreGem.java b/src/main/java/ellpeck/gemification/blocks/ItemBlockOreGem.java deleted file mode 100644 index 9176e2923..000000000 --- a/src/main/java/ellpeck/gemification/blocks/ItemBlockOreGem.java +++ /dev/null @@ -1,43 +0,0 @@ -package ellpeck.gemification.blocks; - -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; -import ellpeck.gemification.util.Util; -import net.minecraft.block.Block; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.item.ItemBlock; -import net.minecraft.item.ItemStack; -import net.minecraft.util.EnumChatFormatting; -import net.minecraft.util.StatCollector; - -import java.util.List; - -public class ItemBlockOreGem extends ItemBlock { - - public ItemBlockOreGem(Block block){ - super(block); - setHasSubtypes(true); - } - - public String getUnlocalizedName(ItemStack stack) { - return this.getUnlocalizedName() + Util.gemList.get(stack.getItemDamage()).name.substring(5); - } - - public int getMetadata(int i) { - return i; - } - - @SuppressWarnings("unchecked") - @SideOnly(Side.CLIENT) - public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean isHeld) { - if(Util.isShiftPressed()){ - for(int i = 0; i < Util.gemList.size(); i++){ - if(this.getDamage(stack) == i) list.add(StatCollector.translateToLocal("tooltip.gem" + Util.gemList.get(i).name.substring(5) + ".desc")); - } - list.add(EnumChatFormatting.BOLD + StatCollector.translateToLocal("tooltip.gemIsOre.desc")); - } - else{ - list.add(Util.shiftForInfo()); - } - } -} diff --git a/src/main/java/ellpeck/gemification/blocks/OreGem.java b/src/main/java/ellpeck/gemification/blocks/OreGem.java index c04377d68..f77a1f67a 100644 --- a/src/main/java/ellpeck/gemification/blocks/OreGem.java +++ b/src/main/java/ellpeck/gemification/blocks/OreGem.java @@ -9,9 +9,13 @@ import net.minecraft.block.Block; import net.minecraft.block.material.Material; import net.minecraft.client.renderer.texture.IIconRegister; import net.minecraft.creativetab.CreativeTabs; +import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.Item; +import net.minecraft.item.ItemBlock; import net.minecraft.item.ItemStack; +import net.minecraft.util.EnumChatFormatting; import net.minecraft.util.IIcon; +import net.minecraft.util.StatCollector; import java.util.List; import java.util.Random; @@ -60,4 +64,34 @@ public class OreGem extends Block{ textures[i] = iconReg.registerIcon(Util.MOD_ID + ":" + this.getUnlocalizedName().substring(5) + Util.gemList.get(i).name.substring(5)); } } + + public static class ItemBlockOreGem extends ItemBlock { + + public ItemBlockOreGem(Block block){ + super(block); + setHasSubtypes(true); + } + + public String getUnlocalizedName(ItemStack stack) { + return this.getUnlocalizedName() + Util.gemList.get(stack.getItemDamage()).name.substring(5); + } + + public int getMetadata(int i) { + return i; + } + + @SuppressWarnings("unchecked") + @SideOnly(Side.CLIENT) + public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean isHeld) { + if(Util.isShiftPressed()){ + for(int i = 0; i < Util.gemList.size(); i++){ + if(this.getDamage(stack) == i) list.add(StatCollector.translateToLocal("tooltip.gem" + Util.gemList.get(i).name.substring(5) + ".desc")); + } + list.add(EnumChatFormatting.BOLD + StatCollector.translateToLocal("tooltip.gemIsOre.desc")); + } + else{ + list.add(Util.shiftForInfo()); + } + } + } } diff --git a/src/main/java/ellpeck/gemification/booklet/Chapter.java b/src/main/java/ellpeck/gemification/booklet/Chapter.java new file mode 100644 index 000000000..bef076e90 --- /dev/null +++ b/src/main/java/ellpeck/gemification/booklet/Chapter.java @@ -0,0 +1,23 @@ +package ellpeck.gemification.booklet; + +import net.minecraft.util.StatCollector; + +public class Chapter{ + + public final int ID; + public final String name; + public final int pageAmount; + public final boolean hasCraftingRecipe; + public String[] pageTexts; + + public Chapter(int ID, String name, int pageAmount, boolean hasCraftingRecipe){ + this.ID = ID; + this.name = name; + this.pageAmount = pageAmount; + this.hasCraftingRecipe = hasCraftingRecipe; + this.pageTexts = new String[pageAmount]; + for(int i = 0; i < pageTexts.length; i++){ + this.pageTexts[i] = StatCollector.translateToLocal("infoBook." + this.name + ".page" + i + ".text"); + } + } +} diff --git a/src/main/java/ellpeck/gemification/booklet/ChapterList.java b/src/main/java/ellpeck/gemification/booklet/ChapterList.java new file mode 100644 index 000000000..f80368b96 --- /dev/null +++ b/src/main/java/ellpeck/gemification/booklet/ChapterList.java @@ -0,0 +1,14 @@ +package ellpeck.gemification.booklet; + +import java.util.ArrayList; + +public class ChapterList{ + + public static ArrayList chapterList = new ArrayList(); + + public static void init(){ + chapterList.add(new Chapter(0, "testChapterOne", 2, false)); + chapterList.add(new Chapter(1, "testChapterTwo", 3, false)); + chapterList.add(new Chapter(2, "testChapterThree", 2, false)); + } +} diff --git a/src/main/java/ellpeck/gemification/booklet/ContainerInfoBook.java b/src/main/java/ellpeck/gemification/booklet/ContainerInfoBook.java new file mode 100644 index 000000000..bb6208f32 --- /dev/null +++ b/src/main/java/ellpeck/gemification/booklet/ContainerInfoBook.java @@ -0,0 +1,16 @@ +package ellpeck.gemification.booklet; + +import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.inventory.Container; + +public class ContainerInfoBook extends Container { + + @SuppressWarnings("unused") + public ContainerInfoBook(EntityPlayer player){ + + } + + public boolean canInteractWith(EntityPlayer player){ + return true; + } +} diff --git a/src/main/java/ellpeck/gemification/booklet/GuiInfoBook.java b/src/main/java/ellpeck/gemification/booklet/GuiInfoBook.java new file mode 100644 index 000000000..31bf2f1f3 --- /dev/null +++ b/src/main/java/ellpeck/gemification/booklet/GuiInfoBook.java @@ -0,0 +1,149 @@ +package ellpeck.gemification.booklet; + +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; +import ellpeck.gemification.util.Util; +import net.minecraft.client.Minecraft; +import net.minecraft.client.gui.GuiButton; +import net.minecraft.client.gui.GuiScreen; +import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.util.ResourceLocation; +import net.minecraft.util.StatCollector; +import org.lwjgl.opengl.GL11; + +public class GuiInfoBook extends GuiScreen{ + + public static final ResourceLocation resLoc = new ResourceLocation(Util.MOD_ID, "textures/gui/guiInfoBook.png"); + + public final int xSize = 180; + public final int ySize = 180; + + public Chapter mainChapter = new Chapter(-1, "mainChapter", 0, false); + + public int currentPage = 0; + public Chapter currentChapter = mainChapter; + + public ChangePageButton nextPageButton; + public ChangePageButton prevPageButton; + public ChangePageButton mainPageButton; + + @SuppressWarnings("unused") + public GuiInfoBook(EntityPlayer player){ + + } + + @SuppressWarnings("all") + public void initGui(){ + this.buttonList.clear(); + + int xPos = (this.width-this.xSize)/2; + int yPos = (this.height-this.ySize)/2; + + this.addMainChapterButtons(); + this.nextPageButton = new ChangePageButton(-3, xPos+180, yPos+170); + this.prevPageButton = new ChangePageButton(-2, xPos-18, yPos+170); + this.mainPageButton = new ChangePageButton(-1, xPos, yPos-15); + this.buttonList.add(nextPageButton); + this.buttonList.add(prevPageButton); + this.buttonList.add(mainPageButton); + + this.updateButtons(); + } + + @SuppressWarnings("all") + public void addMainChapterButtons(){ + int xPos = (this.width-this.xSize)/2; + int yPos = (this.height-this.ySize)/2; + + int size = ChapterList.chapterList.size(); + for(int i = 0; i < size; i++){ + this.buttonList.add(new InvisiButton(i, xPos + 15, yPos + 15 + 11*i, 150, 10, StatCollector.translateToLocal("infoBook." + ChapterList.chapterList.get(i).name + ".title"))); + } + } + + public void updateButtons(){ + this.nextPageButton.visible = this.currentChapter.pageAmount > 0 && this.currentPage < this.currentChapter.pageAmount-1; + this.prevPageButton.visible = this.currentPage > 0; + this.mainPageButton.visible = this.currentChapter != this.mainChapter; + for(int i = 0; i < ChapterList.chapterList.size(); i++){ + ((GuiButton)this.buttonList.get(i)).visible = this.currentChapter == mainChapter; + } + + System.out.println(currentPage); + } + + @SuppressWarnings("static-access") + public void actionPerformed(GuiButton button){ + if(button == this.nextPageButton) this.currentPage++; + else if(button == this.prevPageButton) this.currentPage--; + else if(button == this.mainPageButton){ + this.currentPage = 0; + this.currentChapter = this.mainChapter; + } + else this.currentChapter = ChapterList.chapterList.get(button.id); + this.updateButtons(); + } + + public void drawScreen(int x, int y, float f){ + this.drawDefaultBackground(); + GL11.glColor4f(1F, 1F, 1F, 1F); + + int xPos = (this.width-this.xSize)/2; + int yPos = (this.height-this.ySize)/2; + + this.mc.getTextureManager().bindTexture(resLoc); + this.drawTexturedModalRect(xPos, yPos, 0, 0, this.xSize, this.ySize); + + super.drawScreen(x, y, f); + } + + @SideOnly(Side.CLIENT) + static class ChangePageButton extends GuiButton{ + /** + * Type of the button + * -3: Next Page + * -2: Previous Page + * -1: Back to main Page + */ + private final int buttonType; + + public ChangePageButton(int ID, int x, int y){ + super(ID, x, y, 18, ID == -1 ? 14 : 10, ""); + this.buttonType = ID; + } + + public void drawButton(Minecraft mc, int mouseX, int mouseY){ + if (this.visible){ + boolean isHoverOver = mouseX >= this.xPosition && mouseY >= this.yPosition && mouseX < this.xPosition + this.width && mouseY < this.yPosition + this.height; + GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); + mc.getTextureManager().bindTexture(GuiInfoBook.resLoc); + + int posX = 0; + int posY = 180; + if(this.buttonType == -2) posY += 10; + else if(this.buttonType == -1) posY += 20; + if(isHoverOver) posX += 18; + this.drawTexturedModalRect(this.xPosition, this.yPosition, posX, posY, 18, this.buttonType == -1 ? 14 : 10); + } + } + } + + @SideOnly(Side.CLIENT) + static class InvisiButton extends GuiButton{ + public InvisiButton(int ID, int x, int y, int width, int height, String text){ + super(ID, x, y, width, height, text); + } + + public void drawButton(Minecraft mc, int mouseX, int mouseY){ + if (this.visible){ + boolean isHoverOver = false; + if(mouseX >= this.xPosition && mouseY >= this.yPosition && mouseX < this.xPosition + this.width && mouseY < this.yPosition + this.height) isHoverOver = true; + mc.fontRenderer.drawString((isHoverOver ? ((char)167+"2" + (char)167+"n") : "") + this.displayString, this.xPosition, this.yPosition + (this.height - 8) / 2, 0); + } + } + } + + public boolean doesGuiPauseGame(){ + return false; + } +} diff --git a/src/main/java/ellpeck/gemification/booklet/ItemInfoBook.java b/src/main/java/ellpeck/gemification/booklet/ItemInfoBook.java new file mode 100644 index 000000000..27a2c0f68 --- /dev/null +++ b/src/main/java/ellpeck/gemification/booklet/ItemInfoBook.java @@ -0,0 +1,47 @@ +package ellpeck.gemification.booklet; + +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; +import ellpeck.gemification.Gemification; +import ellpeck.gemification.creative.CreativeTab; +import ellpeck.gemification.inventory.GuiHandler; +import ellpeck.gemification.util.Util; +import net.minecraft.client.renderer.texture.IIconRegister; +import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.item.Item; +import net.minecraft.item.ItemStack; +import net.minecraft.util.StatCollector; +import net.minecraft.world.World; + +import java.util.List; + +public class ItemInfoBook extends Item { + + public ItemInfoBook(){ + this.setCreativeTab(CreativeTab.instance); + this.setUnlocalizedName("itemInfoBook"); + } + + @SuppressWarnings("unchecked") + @SideOnly(Side.CLIENT) + public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean isHeld) { + if(Util.isShiftPressed()) list.add(StatCollector.translateToLocal("tooltip." + this.getUnlocalizedName().substring(5) + ".desc")); + else list.add(Util.shiftForInfo()); + } + + public String getUnlocalizedName(ItemStack stack){ + return this.getUnlocalizedName(); + } + + @SideOnly(Side.CLIENT) + public void registerIcons(IIconRegister iconReg){ + this.itemIcon = iconReg.registerIcon(Util.MOD_ID + ":" + this.getUnlocalizedName().substring(5)); + } + + public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player){ + if (!world.isRemote){ + player.openGui(Gemification.instance, GuiHandler.guiInfoBook, world, (int)player.posX, (int)player.posY, (int)player.posZ); + } + return stack; + } +} diff --git a/src/main/java/ellpeck/gemification/crafting/CrucibleCraftingManager.java b/src/main/java/ellpeck/gemification/crafting/CrucibleCraftingManager.java index 9163ad219..3f34d90e9 100644 --- a/src/main/java/ellpeck/gemification/crafting/CrucibleCraftingManager.java +++ b/src/main/java/ellpeck/gemification/crafting/CrucibleCraftingManager.java @@ -1,12 +1,10 @@ package ellpeck.gemification.crafting; import ellpeck.gemification.util.GemType; -import ellpeck.gemification.util.Util; 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.minecraftforge.oredict.OreDictionary; import java.util.ArrayList; import java.util.HashMap; @@ -16,11 +14,6 @@ public class CrucibleCraftingManager{ public static final CrucibleCraftingManager instance = new CrucibleCraftingManager(); public static ArrayList recipes = new ArrayList(); - @SuppressWarnings("all") - public void initRecipes(){ - this.addRecipe(new ItemStack(Blocks.acacia_stairs), Util.fluidChromeDiopside, 200, new Object[]{"ccc", "cgc", "ccc", 'c', Blocks.cobblestone, 'g', new ItemStack(Items.stick)}); - } - @SuppressWarnings("unchecked, static-access") public void addRecipe(ItemStack output, GemType fluidNeeded, int processTimeNeeded, Object ... recipe){ String s = ""; @@ -51,10 +44,10 @@ public class CrucibleCraftingManager{ ItemStack stack1 = null; if (recipe[i + 1] instanceof Item){ - stack1 = new ItemStack((Item)recipe[i + 1], 1, 32767); + stack1 = new ItemStack((Item)recipe[i + 1], 1, OreDictionary.WILDCARD_VALUE); } else if (recipe[i + 1] instanceof Block){ - stack1 = new ItemStack((Block)recipe[i + 1], 1, 32767); + stack1 = new ItemStack((Block)recipe[i + 1], 1, OreDictionary.WILDCARD_VALUE); } else if (recipe[i + 1] instanceof ItemStack){ stack1 = (ItemStack)recipe[i + 1]; @@ -102,7 +95,7 @@ public class CrucibleCraftingManager{ int k = 0; for (int j = 0; j < maxSlot - minSlot + 1; j++){ if (slots[minSlot + j] != null && inputs[j] != null && slots[minSlot + j].getItem() == inputs[j].getItem()){ - if(inputs[j].getItemDamage() == 32767 || inputs[j].getItemDamage() == slots[minSlot + j].getItemDamage()) { + if(inputs[j].getItemDamage() == OreDictionary.WILDCARD_VALUE || inputs[j].getItemDamage() == slots[minSlot + j].getItemDamage()) { k++; } } diff --git a/src/main/java/ellpeck/gemification/crafting/InitCrafting.java b/src/main/java/ellpeck/gemification/crafting/InitCrafting.java new file mode 100644 index 000000000..713b2e63a --- /dev/null +++ b/src/main/java/ellpeck/gemification/crafting/InitCrafting.java @@ -0,0 +1,21 @@ +package ellpeck.gemification.crafting; + +import cpw.mods.fml.common.registry.GameRegistry; +import ellpeck.gemification.blocks.InitBlocks; +import ellpeck.gemification.items.InitItems; +import ellpeck.gemification.util.Util; +import net.minecraft.init.Blocks; +import net.minecraft.init.Items; +import net.minecraft.item.ItemStack; +import net.minecraftforge.oredict.OreDictionary; + +public class InitCrafting { + + public static void init(){ + GameRegistry.addRecipe(new ItemStack(InitBlocks.blockCrucible), "i i", "gcg", "iii", 'i', Items.iron_ingot, 'g', new ItemStack(InitItems.itemGem, 1, OreDictionary.WILDCARD_VALUE), 'c', Items.cauldron); + GameRegistry.addRecipe(new ItemStack(InitBlocks.blockCrucibleFire), "ccc", "cac", "sss", 'c', Blocks.cobblestone, 'a', Items.cauldron, 's', Blocks.stone_slab); + + CrucibleCraftingManager.instance.addRecipe(new ItemStack(Blocks.acacia_stairs), Util.chromeDiopside, 200, "ccc", "cgc", "ccc", 'c', Blocks.cobblestone, 'g', Items.stick); + } + +} diff --git a/src/main/java/ellpeck/gemification/inventory/GuiHandler.java b/src/main/java/ellpeck/gemification/inventory/GuiHandler.java index 599ee2eb8..4f15e0b78 100644 --- a/src/main/java/ellpeck/gemification/inventory/GuiHandler.java +++ b/src/main/java/ellpeck/gemification/inventory/GuiHandler.java @@ -3,6 +3,8 @@ package ellpeck.gemification.inventory; import cpw.mods.fml.common.network.IGuiHandler; import cpw.mods.fml.common.network.NetworkRegistry; import ellpeck.gemification.Gemification; +import ellpeck.gemification.booklet.ContainerInfoBook; +import ellpeck.gemification.booklet.GuiInfoBook; import ellpeck.gemification.inventory.container.ContainerCrucible; import ellpeck.gemification.inventory.container.ContainerCrucibleFire; import ellpeck.gemification.inventory.gui.GuiCrucible; @@ -17,6 +19,7 @@ public class GuiHandler implements IGuiHandler { public static final int guiCrucible = 0; public static final int guiCrucibleFire = 1; + public static final int guiInfoBook = 2; public Object getServerGuiElement(int id, EntityPlayer entityPlayer, World world, int x, int y, int z) { TileEntityBase tile = (TileEntityBase)world.getTileEntity(x, y, z); @@ -25,6 +28,8 @@ public class GuiHandler implements IGuiHandler { return new ContainerCrucible(entityPlayer.inventory, (TileEntityCrucible)tile); case guiCrucibleFire: return new ContainerCrucibleFire(entityPlayer.inventory, (TileEntityCrucibleFire)tile); + case guiInfoBook: + return new ContainerInfoBook(entityPlayer); default: return null; @@ -38,6 +43,8 @@ public class GuiHandler implements IGuiHandler { return new GuiCrucible(entityPlayer.inventory, (TileEntityCrucible)tile); case guiCrucibleFire: return new GuiCrucibleFire(entityPlayer.inventory, (TileEntityCrucibleFire)tile); + case guiInfoBook: + return new GuiInfoBook(entityPlayer); default: return null; diff --git a/src/main/java/ellpeck/gemification/inventory/gui/GuiCrucibleFire.java b/src/main/java/ellpeck/gemification/inventory/gui/GuiCrucibleFire.java index 52aeaa8b6..b587fd29c 100644 --- a/src/main/java/ellpeck/gemification/inventory/gui/GuiCrucibleFire.java +++ b/src/main/java/ellpeck/gemification/inventory/gui/GuiCrucibleFire.java @@ -33,8 +33,4 @@ public class GuiCrucibleFire extends GuiContainer{ this.drawTexturedModalRect(guiLeft + 96, guiTop + 10 + 12 - i, 176, 12 - i, 14, i + 1); } } - - public void drawScreen(int par1, int par2, float par3){ - super.drawScreen(par1, par2, par3); - } } diff --git a/src/main/java/ellpeck/gemification/items/InitItems.java b/src/main/java/ellpeck/gemification/items/InitItems.java index 3b63e0617..09c1842e8 100644 --- a/src/main/java/ellpeck/gemification/items/InitItems.java +++ b/src/main/java/ellpeck/gemification/items/InitItems.java @@ -1,17 +1,21 @@ package ellpeck.gemification.items; -import net.minecraft.item.Item; import cpw.mods.fml.common.registry.GameRegistry; +import ellpeck.gemification.booklet.ItemInfoBook; +import net.minecraft.item.Item; public class InitItems { public static Item itemGem; + public static Item itemInfoBook; public static void init(){ itemGem = new ItemGem(); + itemInfoBook = new ItemInfoBook(); GameRegistry.registerItem(itemGem, itemGem.getUnlocalizedName().substring(5)); + GameRegistry.registerItem(itemInfoBook, itemInfoBook.getUnlocalizedName().substring(5)); } } diff --git a/src/main/java/ellpeck/gemification/util/GemType.java b/src/main/java/ellpeck/gemification/util/GemType.java index ddaed25cb..136765175 100644 --- a/src/main/java/ellpeck/gemification/util/GemType.java +++ b/src/main/java/ellpeck/gemification/util/GemType.java @@ -2,8 +2,8 @@ package ellpeck.gemification.util; public class GemType { - public int ID; - public String name; + public final int ID; + public final String name; public GemType(int ID, String name, boolean shouldAddToList){ this.ID = ID; diff --git a/src/main/java/ellpeck/gemification/util/Util.java b/src/main/java/ellpeck/gemification/util/Util.java index 4e593a4e3..592c004e6 100644 --- a/src/main/java/ellpeck/gemification/util/Util.java +++ b/src/main/java/ellpeck/gemification/util/Util.java @@ -1,12 +1,12 @@ package ellpeck.gemification.util; -import net.minecraft.util.EnumChatFormatting; import net.minecraft.util.StatCollector; import org.lwjgl.input.Keyboard; import java.util.ArrayList; -public class Util { +@SuppressWarnings("unused") +public class Util{ public static final String MOD_ID = "gemification"; public static final String NAME = "Gemification"; @@ -14,22 +14,22 @@ public class Util { public static ArrayList gemList = new ArrayList(); - public static final GemType fluidOnyx = new GemType(0, "Onyx", true); - public static final GemType fluidAlmandineGarnet = new GemType(1, "AlmandineGarnet", true); - public static final GemType fluidChromeDiopside = new GemType(2, "ChromeDiopside", true); - public static final GemType fluidJasper = new GemType(3, "Jasper", true); - public static final GemType fluidSodalite = new GemType(4, "Sodalite", true); - public static final GemType fluidIolite = new GemType(5, "Iolite", true); - public static final GemType fluidSmithsonite = new GemType(6, "Smithsonite", true); - public static final GemType fluidDanburite = new GemType(7, "Danburite", true); - public static final GemType fluidHematite = new GemType(8, "Hematite", true); - public static final GemType fluidLepidolite = new GemType(9, "Lepidolite", true); - public static final GemType fluidTourmaline = new GemType(10, "Tourmaline", true); - public static final GemType fluidSphene = new GemType(11, "Sphene", true); - public static final GemType fluidParaibaTourlamine = new GemType(12, "ParaibaTourlamine", true); - public static final GemType fluidRhodochrosite = new GemType(13, "Rhodochrosite", true); - public static final GemType fluidClinohumite = new GemType(14, "Clinohumite", true); - public static final GemType fluidGoshenite = new GemType(15, "Goshenite", true); + public static final GemType onyx = new GemType(0, "Onyx", true); + public static final GemType almandineGarnet = new GemType(1, "AlmandineGarnet", true); + public static final GemType chromeDiopside = new GemType(2, "ChromeDiopside", true); + public static final GemType jasper = new GemType(3, "Jasper", true); + public static final GemType sodalite = new GemType(4, "Sodalite", true); + public static final GemType iolite = new GemType(5, "Iolite", true); + public static final GemType smithsonite = new GemType(6, "Smithsonite", true); + public static final GemType danburite = new GemType(7, "Danburite", true); + public static final GemType hematite = new GemType(8, "Hematite", true); + public static final GemType lepidolite = new GemType(9, "Lepidolite", true); + public static final GemType tourmaline = new GemType(10, "Tourmaline", true); + public static final GemType sphene = new GemType(11, "Sphene", true); + public static final GemType paraibaTourlamine = new GemType(12, "ParaibaTourlamine", true); + public static final GemType rhodochrosite = new GemType(13, "Rhodochrosite", true); + public static final GemType clinohumite = new GemType(14, "Clinohumite", true); + public static final GemType goshenite = new GemType(15, "Goshenite", true); public static final GemType fluidWater = new GemType(16, "Water", false); public static final GemType fluidNone = new GemType(17, "None", false); @@ -38,6 +38,6 @@ public class Util { } public static String shiftForInfo() { - return ((char)167+"2" + EnumChatFormatting.ITALIC + StatCollector.translateToLocal("tooltip.shiftForInfo.desc")); + return (char)167+"2" + (char)167+"o" + StatCollector.translateToLocal("tooltip.shiftForInfo.desc"); } } diff --git a/src/main/resources/assets/gemification/textures/gui/guiInfoBook.png b/src/main/resources/assets/gemification/textures/gui/guiInfoBook.png new file mode 100644 index 0000000000000000000000000000000000000000..8cdb81568fae289d8f93e80308cc72d8dc7d7027 GIT binary patch literal 7646 zcmeHs`9D-&{Qtdo7Bglr))`9-*+OP4g%pzrDW)V;7|Bvel2+jkS(8wSgh`vCh?2^3 zZ8bus)hA5_jS+nb)M&OQ<$!fQj#i? z002liJK66708rcn0USzP9VzwNEw0ePn|EvmfG3v;LVpYZpaACf-46doDFVPIEZG{P zVk-gc#sT~ADhvq~I|)^LoSGd@%>k!ok5}J{*Km~7aKdXiNos5p3jqixP+bVr?F7vo zL@igMwwu&yCQ+LyrL#*~XP1nghm77Hv5@pVNo%}h4ZP(I_R1Oh$Q%18t@Tx)`H|PM z6pUGlG!~h5K#>-pL=PaF1W-%^R7?*ln;uj#4N^7>RxuA$F+ZqkE^Y*=t_xIK7o@f> zM0H(=n#Cb?izDh5hczsZXjmQ9*bqwH5TF?*)?|1d|_^CO<7r{m)(p1;dbobKq*X5a> z<(b~)*}kROe&KANaISxGW_WpSV0rGlaBe_2HzfS?UHE52I6o|$7waFw`Jc;wMuqdE ze;3C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001 diff --git a/src/main/resources/assets/gemification/textures/items/itemInfoBook.png b/src/main/resources/assets/gemification/textures/items/itemInfoBook.png new file mode 100644 index 0000000000000000000000000000000000000000..4784fed1b5ba45c4d5d068012ac039b60d0ab8be GIT binary patch literal 301 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`jKx9jP7LeL$-D$|SkfJR9T^xl z_H+M9WCij$3p^r=85sBugD~Uq{1qucL5ULAh?3y^w370~qEv>0#LT=By}Z;C1rt33 zJ>#Bd(*uBN=6Sj}hFJJ-?Z3_2V!*?4cyW_<16PJp_(9W2YC*2MSk01pQ+4!yCM*>_ zk#bCN&%8oT>FT~)P8t7rFR6919^V?6YQ=Q-j_!3Np$M&