diff --git a/resources/assets/tinker/lang/en_US.lang b/resources/assets/tinker/lang/en_US.lang index 562bbf64cee..aeddf5a2efb 100644 --- a/resources/assets/tinker/lang/en_US.lang +++ b/resources/assets/tinker/lang/en_US.lang @@ -28,6 +28,7 @@ CraftedSoil.ConsecratedSoil.name=Consecrated Soil tile.CastingChannel.name=Casting Channel tile.slime.channel.name=Slime Channel tile.slime.pad.name=Bounce Pad +tile.blood.channel.name=Blood Channel MetalOre.NetherSlag.name=Netherack Slag MetalOre.Cobalt.name=Cobalt Ore @@ -268,6 +269,8 @@ item.tconstruct.jerky.chicken.name=Chicken Jerky item.tconstruct.jerky.sheep.name=Mutton Jerky item.tconstruct.jerky.fish.name=Fish Jerky item.tconstruct.jerky.zombie.name=Monster Jerky +item.tconstruct.jerky.blueslime.name=Gelatinous Slime Drop +item.tconstruct.jerky.blood.name=Coagulated Blood Drop Smeltery.Controller.name=Smeltery Controller Smeltery.Drain.name=Smeltery Drain @@ -480,6 +483,7 @@ LiquidMetal.Ender.name=Liquified Ender item.food.apple.diamond.name=Jeweled Apple item.tconstruct.strangefood.edibleslime.name=Gelatinous Slime +item.tconstruct.strangefood.edibleblood.name=Coagulated Blood item.tconstruct.canister.empty.name=Empty Canister item.tconstruct.canister.miniheart.red.name=Miniature Red Heart item.tconstruct.canister.heart.name=Heart Canister @@ -603,6 +607,10 @@ achievement.tconstruct.dualConvenience.desc=Kill a mob with a frying pan, and th knapsack.tooltip=A Knapsack to hold your things. strangefood1.tooltip=It smells terrible, but if you strangefood2.tooltip=have nothing else to eat... +strangefood3.tooltip=It seems edible, but somehow +strangefood4.tooltip=it's just not appealing. +strangefood5.tooltip=Stretchy food! +strangefood6.tooltip=One vampiric appetizer hambone1.tooltip=Hambone! hambone2.tooltip=Usable for Beacon bases metalblock.tooltip=Usable for Beacon bases diff --git a/resources/assets/tinker/textures/items/food/edibleblood.png b/resources/assets/tinker/textures/items/food/edibleblood.png new file mode 100644 index 00000000000..4809b05b628 Binary files /dev/null and b/resources/assets/tinker/textures/items/food/edibleblood.png differ diff --git a/resources/assets/tinker/textures/items/food/edibleslime.png b/resources/assets/tinker/textures/items/food/edibleslime.png index cfb81f32c25..1fa828261b6 100644 Binary files a/resources/assets/tinker/textures/items/food/edibleslime.png and b/resources/assets/tinker/textures/items/food/edibleslime.png differ diff --git a/resources/assets/tinker/textures/items/food/jerky_blood.png b/resources/assets/tinker/textures/items/food/jerky_blood.png new file mode 100644 index 00000000000..60f71259262 Binary files /dev/null and b/resources/assets/tinker/textures/items/food/jerky_blood.png differ diff --git a/resources/assets/tinker/textures/items/food/jerky_blueslime.png b/resources/assets/tinker/textures/items/food/jerky_blueslime.png new file mode 100644 index 00000000000..5f3d12b405b Binary files /dev/null and b/resources/assets/tinker/textures/items/food/jerky_blueslime.png differ diff --git a/src/tconstruct/blocks/ConveyorBase.java b/src/tconstruct/blocks/ConveyorBase.java index a376c26bc66..2a51e709715 100644 --- a/src/tconstruct/blocks/ConveyorBase.java +++ b/src/tconstruct/blocks/ConveyorBase.java @@ -19,11 +19,13 @@ public class ConveyorBase extends Block { - public ConveyorBase(int ID, Material material) + String textureName; + public ConveyorBase(int ID, Material material, String name) { super(ID, material); this.setCreativeTab(TConstructRegistry.blockTab); setBlockBounds(0f, 0f, 0f, 1f, 0.5f, 1f); + textureName = name; } public boolean isBlockReplaceable (World world, int x, int y, int z) @@ -134,7 +136,7 @@ public int getRenderType () @Override public void registerIcons (IconRegister iconRegister) { - String[] textureNames = new String[] { "greencurrent", "greencurrent_flow" }; + String[] textureNames = new String[] { textureName, textureName+"_flow" }; this.icons = new Icon[textureNames.length]; for (int i = 0; i < this.icons.length; ++i) diff --git a/src/tconstruct/common/TContent.java b/src/tconstruct/common/TContent.java index d4d549e9515..823edeb113d 100644 --- a/src/tconstruct/common/TContent.java +++ b/src/tconstruct/common/TContent.java @@ -252,6 +252,7 @@ public class TContent implements IFuelHandler public static Block slimeChannel; public static Block slimePad; + public static Block bloodChannel; //Glue public static Fluid glueFluid; @@ -758,11 +759,15 @@ void registerBlocks () slimeSapling = (SlimeSapling) new SlimeSapling(PHConstruct.slimeSapling).setStepSound(slimeStep).setUnlocalizedName("slime.sapling"); GameRegistry.registerBlock(slimeSapling, SlimeSaplingItemBlock.class, "slime.sapling"); - slimeChannel = new ConveyorBase(PHConstruct.slimeChannel, Material.water).setStepSound(slimeStep).setUnlocalizedName("slime.channel"); + slimeChannel = new ConveyorBase(PHConstruct.slimeChannel, Material.water, "greencurrent").setHardness(0.3f).setStepSound(slimeStep).setUnlocalizedName("slime.channel"); GameRegistry.registerBlock(slimeChannel, "slime.channel"); TConstructRegistry.drawbridgeState[slimeChannel.blockID] = 1; - slimePad = new SlimePad(PHConstruct.slimePad, Material.cloth).setStepSound(slimeStep).setUnlocalizedName("slime.pad"); + bloodChannel = new ConveyorBase(PHConstruct.bloodChannel, Material.water, "liquid_cow").setHardness(0.3f).setStepSound(slimeStep).setUnlocalizedName("blood.channel"); + GameRegistry.registerBlock(bloodChannel, "blood.channel"); + TConstructRegistry.drawbridgeState[slimeChannel.blockID] = 1; + + slimePad = new SlimePad(PHConstruct.slimePad, Material.cloth).setStepSound(slimeStep).setHardness(0.3f).setUnlocalizedName("slime.pad"); GameRegistry.registerBlock(slimePad, "slime.pad"); TConstructRegistry.drawbridgeState[slimePad.blockID] = 1; @@ -1450,7 +1455,10 @@ private void addRecipesForCraftingTable () GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(slimeExplosive, 1, 0), "slimeball", Block.tnt)); GameRegistry.addShapelessRecipe(new ItemStack(slimeChannel, 1, 0), new ItemStack(slimeGel, 1, Short.MAX_VALUE), new ItemStack(Item.redstone)); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(slimePad, 1, 0), slimeChannel, "slimeBall")); + GameRegistry.addShapelessRecipe(new ItemStack(bloodChannel, 1, 0), new ItemStack(strangeFood, 1, 1), new ItemStack(strangeFood, 1, 1), new ItemStack(strangeFood, 1, 1), new ItemStack( + strangeFood, 1, 1), new ItemStack(Item.redstone)); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(slimeChannel, 1, 0), "slimeball", "slimeball", "slimeball", "slimeball", new ItemStack(Item.redstone))); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(slimePad, 1, 0), slimeChannel, "slimeball")); } private void addRecipesForFurnace () @@ -1629,6 +1637,7 @@ private void addRecipesForTableCasting () //Misc tableCasting.addCastingRecipe(new ItemStack(Item.emerald), new FluidStack(moltenEmeraldFluid, 640), gemcast, 80); tableCasting.addCastingRecipe(new ItemStack(materials, 1, 36), new FluidStack(glueFluid, TConstruct.ingotLiquidValue), null, 50); + tableCasting.addCastingRecipe(new ItemStack(strangeFood, 1, 1), new FluidStack(bloodFluid, 160), null, 50); //Buckets ItemStack bucket = new ItemStack(Item.bucketEmpty); @@ -1890,6 +1899,8 @@ private void addRecipesForDryingRack () //DryingRackRecipes.addDryingRecipe(Item.muttonRaw, 20 * 60 * 5, new ItemStack(jerky, 1, 3)); DryingRackRecipes.addDryingRecipe(Item.fishRaw, 20 * 60 * 5, new ItemStack(jerky, 1, 4)); DryingRackRecipes.addDryingRecipe(Item.rottenFlesh, 20 * 60 * 5, new ItemStack(jerky, 1, 5)); + DryingRackRecipes.addDryingRecipe(new ItemStack(strangeFood, 1, 0), 20 * 60 * 5, new ItemStack(jerky, 1, 6)); + DryingRackRecipes.addDryingRecipe(new ItemStack(strangeFood, 1, 1), 20 * 60 * 5, new ItemStack(jerky, 1, 7)); //DryingRackRecipes.addDryingRecipe(new ItemStack(jerky, 1, 5), 20 * 60 * 10, Item.leather); } @@ -2093,6 +2104,7 @@ public void oreRegistry () //Vanilla stuff OreDictionary.registerOre("slimeball", new ItemStack(Item.slimeBall)); OreDictionary.registerOre("slimeball", new ItemStack(strangeFood, 1, 0)); + OreDictionary.registerOre("slimeball", new ItemStack(strangeFood, 1, 1)); OreDictionary.registerOre("slimeball", new ItemStack(materials, 1, 36)); OreDictionary.registerOre("glass", new ItemStack(clearGlass)); OreDictionary.registerOre("glass", new ItemStack(Block.glass)); @@ -2274,7 +2286,7 @@ public void modIntegration () Block heatSand = GameRegistry.findBlock("Natura", "heatsand"); if (taintedSoil != null && heatSand != null) GameRegistry.addShapelessRecipe(new ItemStack(craftedSoil, 2, 6), Item.netherStalkSeeds, taintedSoil, heatSand); - + /*TE3 Flux*/ ItemStack batHardened = GameRegistry.findItemStack("ThermalExpansion", "capacitorHardened", 1); if (batHardened != null) diff --git a/src/tconstruct/items/Jerky.java b/src/tconstruct/items/Jerky.java index 52df94662c7..eda0c911f38 100644 --- a/src/tconstruct/items/Jerky.java +++ b/src/tconstruct/items/Jerky.java @@ -1,19 +1,26 @@ package tconstruct.items; +import java.util.List; + import net.minecraft.client.renderer.texture.IconRegister; +import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemStack; +import net.minecraft.potion.Potion; +import net.minecraft.potion.PotionEffect; import net.minecraft.util.Icon; import net.minecraft.util.MathHelper; +import net.minecraft.util.StatCollector; +import net.minecraft.world.World; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; public class Jerky extends SpecialFood { - public static String[] textureNames = new String[] { "beef", "chicken", "pork", "mutton", "fish", "monster" }; - public static String[] itemNames = new String[] { "jerky.beef", "jerky.chicken", "jerky.pig", "jerky.sheep", "jerky.fish", "jerky.zombie" }; - public static int[] hunger = new int[] { 8, 6, 8, 6, 5, 4 }; - public static float[] saturation = new float[] { 1.0f, 0.8f, 1.0f, 0.8f, 0.8f, 0.4f }; - public static int[] overhaulHunger = new int[] { 1, 1, 1, 1, 1, 1 }; + public static String[] textureNames = new String[] { "beef", "chicken", "pork", "mutton", "fish", "monster", "blueslime", "blood" }; + public static String[] itemNames = new String[] { "jerky.beef", "jerky.chicken", "jerky.pig", "jerky.sheep", "jerky.fish", "jerky.zombie", "jerky.blueslime", "jerky.blood" }; + public static int[] hunger = new int[] { 8, 6, 8, 6, 5, 4, 6, 4 }; + public static float[] saturation = new float[] { 1.0f, 0.8f, 1.0f, 0.8f, 0.8f, 0.4f, 1.0f, 0.25f }; + public static int[] overhaulHunger = new int[] { 1, 1, 1, 1, 1, 1, 1, 1 }; public Jerky(int id, boolean hungerOverhaul) { @@ -38,4 +45,33 @@ public String getUnlocalizedName (ItemStack stack) int arr = MathHelper.clamp_int(stack.getItemDamage(), 0, unlocalizedNames.length); return "item.tconstruct." + unlocalizedNames[arr]; } + + @Override + protected void onFoodEaten (ItemStack stack, World world, EntityPlayer player) + { + if (stack.getItemDamage() == 7) + { + int duration = 20 * 30; + PotionEffect potion = player.getActivePotionEffect(Potion.regeneration); + if (potion != null) + duration = potion.duration; + player.addPotionEffect(new PotionEffect(Potion.field_76434_w.id, duration + 20 * 30, 0)); + } + } + + @Override + @SideOnly(Side.CLIENT) + public void addInformation (ItemStack stack, EntityPlayer player, List list, boolean par4) + { + int type = stack.getItemDamage(); + switch (type) + { + case 6: + list.add("\u00a7b" + StatCollector.translateToLocal("strangefood5.tooltip")); + break; + case 7: + list.add("\u00a74" + StatCollector.translateToLocal("strangefood6.tooltip")); + break; + } + } } diff --git a/src/tconstruct/items/StrangeFood.java b/src/tconstruct/items/StrangeFood.java index 7bead988c3f..18142aafd35 100644 --- a/src/tconstruct/items/StrangeFood.java +++ b/src/tconstruct/items/StrangeFood.java @@ -2,7 +2,10 @@ import java.util.List; +import net.minecraft.potion.Potion; +import net.minecraft.potion.PotionEffect; import net.minecraft.util.StatCollector; +import net.minecraft.world.World; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemStack; import cpw.mods.fml.relauncher.Side; @@ -12,14 +15,31 @@ public class StrangeFood extends SpecialFood { public StrangeFood(int id) { - super(id, new int[] { 2 }, new float[] { 1f }, new String[] { "edibleslime" }, new String[] { "food/edibleslime" }); + super(id, new int[] { 2, 2 }, new float[] { 1f, 1f }, new String[] { "edibleslime", "edibleblood" }, new String[] { "food/edibleslime", "food/edibleblood" }); + } + + @Override + protected void onFoodEaten (ItemStack stack, World world, EntityPlayer player) + { + if (stack.getItemDamage() == 1) + player.addPotionEffect(new PotionEffect(Potion.field_76434_w.id, 20*15, 0)); } @Override @SideOnly(Side.CLIENT) public void addInformation (ItemStack stack, EntityPlayer player, List list, boolean par4) { - list.add("\u00a7b\u00a7o"+StatCollector.translateToLocal("strangefood1.tooltip")); - list.add("\u00a7b\u00a7o"+StatCollector.translateToLocal("strangefood2.tooltip")); + int type = stack.getItemDamage(); + switch (type) + { + case 0: + list.add("\u00a7b\u00a7o" + StatCollector.translateToLocal("strangefood1.tooltip")); + list.add("\u00a7b\u00a7o" + StatCollector.translateToLocal("strangefood2.tooltip")); + break; + case 1: + list.add("\u00a74\u00a7o" + StatCollector.translateToLocal("strangefood3.tooltip")); + list.add("\u00a74\u00a7o" + StatCollector.translateToLocal("strangefood4.tooltip")); + break; + } } } diff --git a/src/tconstruct/util/config/PHConstruct.java b/src/tconstruct/util/config/PHConstruct.java index 59cf1e0a3df..9140c01c92b 100644 --- a/src/tconstruct/util/config/PHConstruct.java +++ b/src/tconstruct/util/config/PHConstruct.java @@ -103,10 +103,11 @@ public static void initProps (File location) barricadeBirch = config.getBlock("Birch Barricade", 1483).getInt(1483); barricadeJungle = config.getBlock("Jungle Barricade", 1487).getInt(1487); - lavaTankNether = config.getBlock("Nether Lava Tank", 3187).getInt(3187); - smelteryNether = config.getBlock("Nether Smeltery", 3188).getInt(3188); - searedTableNether = config.getBlock("Nether Seared Block", 3189).getInt(3189); - + lavaTankNether = config.getBlock("Nether Lava Tank", 3186).getInt(3186); + smelteryNether = config.getBlock("Nether Smeltery", 3187).getInt(3187); + searedTableNether = config.getBlock("Nether Seared Block", 3188).getInt(3188); + + bloodChannel = config.getBlock("Blood Channel", 3189).getInt(3189); slimeChannel = config.getBlock("Slime Channel", 3190).getInt(3190); slimePad = config.getBlock("Slime Pad", 3191).getInt(3191); @@ -492,6 +493,7 @@ public static void initProps (File location) public static int slimeChannel; public static int slimePad; + public static int bloodChannel; // Glue public static int glueFluidBlock;