From 83c9127ba173729606577fc2fd0565c0425e5629 Mon Sep 17 00:00:00 2001 From: mDiyo Date: Sun, 8 Sep 2013 19:23:22 -0700 Subject: [PATCH] Add Jerky, fix Drying Rack --- resources/assets/tinker/lang/en_US.xml | 7 + .../items/{ => food}/apple_diamond.png | Bin .../textures/items/{ => food}/edibleslime.png | Bin .../tinker/textures/items/food/jerky_beef.png | Bin 0 -> 543 bytes .../textures/items/food/jerky_chicken.png | Bin 0 -> 598 bytes .../tinker/textures/items/food/jerky_fish.png | Bin 0 -> 416 bytes .../textures/items/food/jerky_monster.png | Bin 0 -> 449 bytes .../textures/items/food/jerky_mutton.png | Bin 0 -> 483 bytes .../tinker/textures/items/food/jerky_pork.png | Bin 0 -> 499 bytes .../textures/items/food/mutton_cooked.png | Bin 0 -> 435 bytes .../tinker/textures/items/food/mutton_raw.png | Bin 0 -> 356 bytes src/tconstruct/TConstruct.java | 2 +- src/tconstruct/blocks/DryingRack.java | 14 +- src/tconstruct/client/TProxyClient.java | 25 +- .../client/entity/projectile/ArrowRender.java | 387 +----------------- src/tconstruct/common/TContent.java | 16 +- src/tconstruct/entity/BlueSlime.java | 2 +- src/tconstruct/entity/GolemBase.java | 2 +- src/tconstruct/entity/SlimeClone.java | 2 +- .../entity/projectile/ArrowEntity.java | 5 +- src/tconstruct/items/DiamondApple.java | 2 +- src/tconstruct/items/Jerky.java | 41 ++ src/tconstruct/items/StrangeFood.java | 2 +- src/tconstruct/util/PHConstruct.java | 2 + test/XinStick.java | 9 +- 25 files changed, 96 insertions(+), 422 deletions(-) rename resources/assets/tinker/textures/items/{ => food}/apple_diamond.png (100%) rename resources/assets/tinker/textures/items/{ => food}/edibleslime.png (100%) create mode 100644 resources/assets/tinker/textures/items/food/jerky_beef.png create mode 100644 resources/assets/tinker/textures/items/food/jerky_chicken.png create mode 100644 resources/assets/tinker/textures/items/food/jerky_fish.png create mode 100644 resources/assets/tinker/textures/items/food/jerky_monster.png create mode 100644 resources/assets/tinker/textures/items/food/jerky_mutton.png create mode 100644 resources/assets/tinker/textures/items/food/jerky_pork.png create mode 100644 resources/assets/tinker/textures/items/food/mutton_cooked.png create mode 100644 resources/assets/tinker/textures/items/food/mutton_raw.png create mode 100644 src/tconstruct/items/Jerky.java diff --git a/resources/assets/tinker/lang/en_US.xml b/resources/assets/tinker/lang/en_US.xml index 3caa5ad7c93..6527afc21a9 100644 --- a/resources/assets/tinker/lang/en_US.xml +++ b/resources/assets/tinker/lang/en_US.xml @@ -185,6 +185,13 @@ Alumite Nugget Steel Nugget + Beef Jerky + Bacon Jerky + Chicken Jerky + Mutton Jerky + Fish Jerky + Monster Jerky + Essence Crystal Smeltery Controller diff --git a/resources/assets/tinker/textures/items/apple_diamond.png b/resources/assets/tinker/textures/items/food/apple_diamond.png similarity index 100% rename from resources/assets/tinker/textures/items/apple_diamond.png rename to resources/assets/tinker/textures/items/food/apple_diamond.png diff --git a/resources/assets/tinker/textures/items/edibleslime.png b/resources/assets/tinker/textures/items/food/edibleslime.png similarity index 100% rename from resources/assets/tinker/textures/items/edibleslime.png rename to resources/assets/tinker/textures/items/food/edibleslime.png diff --git a/resources/assets/tinker/textures/items/food/jerky_beef.png b/resources/assets/tinker/textures/items/food/jerky_beef.png new file mode 100644 index 0000000000000000000000000000000000000000..1b2a71fceae5e6d25429da7948cf78d4579b7adb GIT binary patch literal 543 zcmV+)0^t3LP)N2bPDNB8 zb~7$DE-^7j^FlWO00EmxL_t(IPrXvxOTu6j-_&W_bn`NIQI}1(G))mD=|-l3y`)Bp zr6gU1d<^>k@z8{9ADowubAGpT80Np9<7Z*{7}$OWTXQ=!=+NMW8b+4e0^lgf zp(^^23k7hgMRC3fz=`CCTZJ8FeyjxNO(TqMDvrUfh72iLE598TP!YYj(!*#{4fj+u zRGDPUxK2jV{RUu{Kx!oQOqJlW_0kGjdI&dW1aJ8i9xNTVX?3AsrT-G|CB_K))NpU9 znAjR-xdbLz8Z_0#|Hv{3M1$r1ZGkNYJj5DBivn^R8@jw;{wVI^ooc$D#EYH4m;myt z)^|wk<*+q>lbAi$z52{Lvqj&nGO{q=}#uP?i7y002ovPDHLkV1mRc;miO4 literal 0 HcmV?d00001 diff --git a/resources/assets/tinker/textures/items/food/jerky_chicken.png b/resources/assets/tinker/textures/items/food/jerky_chicken.png new file mode 100644 index 0000000000000000000000000000000000000000..90ff30d18adc626d4001757639df290cb7588602 GIT binary patch literal 598 zcmV-c0;&CpP)N2bPDNB8 zb~7$DE-^7j^FlWO00GiTL_t(IPrZ`uOH*MO#tD9IQM?`dTh3x zy|q?rFcJg{BZy!`B`B4y+KWU5{k8V%83ZMpL%;OE^X<8Q*Zo}AJvH^ek1ov;o}VFZ zw{U6iq0m^gvKMh*4p4F3!dzJ(BwK&I($@t*BPrdOJV9QyQ(ct^OP15Z9r<)8y2fEH zOs}kyaZC_5HHDz~XWg&zAfWQr*q|A3vK@5s&hXRu3z#0sz*KD%Jqoq;WuEFD0a19S zuky8#t3FO zRQ3%Y-)eDAs=Bx-2DL0-$_ef|W-;WOqvO|B=4g0i_F^u&W|)&wgl-{BUx)_PH0`99 zf--l0ZB4htBhMncL6z3VZQ-8adrdeCz_7NwGRF1a3La|?c7*tKQe!{sgu5L?{crL;_-V87>V|*5sRYWsFbnQYrf6rl|?p&bdTcWcSA#FQb)kPpz khmSJ$8FEWw7UdkmZxip*K!Iv2-2eap07*qoM6N<$g2d|z-T(jq literal 0 HcmV?d00001 diff --git a/resources/assets/tinker/textures/items/food/jerky_fish.png b/resources/assets/tinker/textures/items/food/jerky_fish.png new file mode 100644 index 0000000000000000000000000000000000000000..3aba2b531d884b6f8e49b939a1770c5291a443a3 GIT binary patch literal 416 zcmV;R0bl-!P)N2bPDNB8 zb~7$DE-^7j^FlWO00A6HL_t(IPpy;9PQx$|g!4F+2-M)D367jN!TmE(i9;270Hi`W zpdNVt%dl%H(6ltIpq5sVBG0!oyK)em;w+2_jwvl9RCo@)+d4Zx_PBCs>H+1I#Ge4e zC`Q=pVUbsu>--1O<-jEgqO%aG5MT$(8;j3d2i+IlfaIc&N=DFRx7GzXzm+lN&+$Qk zl7QbawjHpDYeF3p%4}n~E7}~wCSayAJR9pf)u!Nyqs|Q;RMGDG8{n~|i`Uu%*a3H5 zPo3|+8cz-bSi}JT%`&Wp7E5dKKI#y&6OJ&BXkg-!au4uAqF1V?vclUTaRazl$^%C6 zz&l{uYj?Nb_Vx^BWSOTv&$S;Ouc@`Ft~b+cp%EP|JjFx&H{%PcJD`L>e3{(<0000< KMNUMnLSTZ-D6A&{ literal 0 HcmV?d00001 diff --git a/resources/assets/tinker/textures/items/food/jerky_monster.png b/resources/assets/tinker/textures/items/food/jerky_monster.png new file mode 100644 index 0000000000000000000000000000000000000000..00f3217a4eeb3312955899aec572cef343749e37 GIT binary patch literal 449 zcmV;y0Y3hTP)Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D02*{fSaefwW^{L9 za%BKeVQFr3E>1;MAa*k@H7+qRNAp5A0003nNklL18wAgmF3K8nTt2d<{gceNk+fU~W7Nkue;>o}e!sfmC&6{mB{>|e!&WUcigqkKk z-3|l#75qiVqcfvuc^QhhtKDjYeW!NI711fbEsM6fq2j^Npsj?YlmG`;J)b6hpKcfx zLVRakj~=s-z80ohoWzRy?0(J#0fae=RyLB(8>{JaUSR++!g=BuU*{36@3kPKHVaL~ z9pkfjnTCYXj__lxI2a`}ryLl%!wj8)4RJ9uG>W})1Ef6QLkNMq4-B2R){yN5Vo=&0 zI50qPpujlK<{98gxZibW?9;ba!ELWdKlNX>N2bPDNB8 zb~7$DE-^7j^FlWO00Cb~L_t(IPrXywPQp+S?cUpB+2SKe6l@7dKqEqe54OYx*Qg|Y zGx7g_;&`T*5Jj5$Vw0O8bj~t!ZZ++{pN^@aWoS5J{j+w5Kq0vFZM6BjG{Ko|U|{Pw zb_`tk4lc?NOxP@^YiSsJ7G@P2ao{4Ys$%tpGSR2noB#o>YA&W!6x-Ja4&p6=zB9s* zR>htGld8*V;U;j9H9g$d6qfvNuY=Ii32^d;JE}g{RSuN8{IdR#lPI+G?+es><_0|D zf`nj72crCO=;NJd-SF^Q_wY!9li%VyrF!IYQ6!jfgoNOAL*a$$Zv&((!MCAoL4N1a>5ZtTP+RRu!m@)wA Z`2={SmCWP}UUC2c002ovPDHLkV1j;I%NhUx literal 0 HcmV?d00001 diff --git a/resources/assets/tinker/textures/items/food/jerky_pork.png b/resources/assets/tinker/textures/items/food/jerky_pork.png new file mode 100644 index 0000000000000000000000000000000000000000..3317e22f7a9155534cf5d9025c8ae70f4c741ce5 GIT binary patch literal 499 zcmVN2bPDNB8 zb~7$DE-^7j^FlWO00D1FL_t(IPrXuEO9D|C)gs7UXB@{RvBeZ~OG`48q?I-zdXTX7 zL4ril7L0!V={qBc;g&BA9PZ`LoaH-rOs4;ScKmkaG#j|i?444rC<^g0p`oD9AaE3R zp%id{0?$Iei+iUFkVGUE3(7$Uu2(&HP3!o`2axyK#>cO&tH^q-xL9`MG~z}*>BB+T zY3v#OJ=Yg74|PCCet0hA+n9<<$cZa)?rsIq%KFjB^b(AmpDs0-jUN*2O+T7KU;>_V zB{Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D02*{fSaefwW^{L9 za%BKeVQFr3E>1;MAa*k@H7+qRNAp5A0003ZNkl7#W~UP2@i^Cdt9%_Lh*l_hS>i)EiteGAnYc_jnfcjkm(@J z{rWOM+lBrwbyojB-&+2EC(wXNhO&4KV21e>X46y?`Ts>K!vFh?r2a2=Q2IaBR0g*< zK$@oj6|`xJ{V!1!`M=m!0jziiPz+>9EzkwCEFjLu8V(=>rWs3vZ36kXUtjwFEHha! zf0?Vs|4I$f|HZ1p*!>T-9T?K>K-;T<3PCo30uU4qAj4*uBm9ojc93%y*(iVm3giWl zrkOwtvKizBoKAq|KvkDLT^vI!{F4(TBpb|*H^T*?se-o-)y>8Sm;$h7E zwl$Q3lc}2io679co)}o5zfyrLpayDZ{hylJw@i3?>Xqe#T~7mWdyj%M-$J zxxtBfFN0A+eHf1%bAq4iH|r}e<<+sl}_MpFl#b7lymH5$&6?RKW5Ee7UfJapP3UH8jnn4empPXPqWAY upu?CFSJZQ6yYUH5a6B<%MTq-4C5Gl04cR+|4I6;oWAJqKb6Mw<&;$Suet=Q{ literal 0 HcmV?d00001 diff --git a/src/tconstruct/TConstruct.java b/src/tconstruct/TConstruct.java index 180c311eef2..d84385eda91 100644 --- a/src/tconstruct/TConstruct.java +++ b/src/tconstruct/TConstruct.java @@ -40,7 +40,7 @@ * @dependencies: IC2 API, MFR API */ -@Mod(modid = "TConstruct", name = "TConstruct", version = "1.6.2_1.4.5d1", dependencies = "required-after:Forge@[7.7.1.687,)") +@Mod(modid = "TConstruct", name = "TConstruct", version = "1.6.2_1.4.5d4", dependencies = "required-after:Forge@[7.7.1.687,)") @NetworkMod(serverSideRequired = false, clientSideRequired = true, channels = { "TConstruct" }, packetHandler = tconstruct.util.network.TPacketHandler.class) public class TConstruct { diff --git a/src/tconstruct/blocks/DryingRack.java b/src/tconstruct/blocks/DryingRack.java index 51baa980d3d..4d07b25ddc3 100644 --- a/src/tconstruct/blocks/DryingRack.java +++ b/src/tconstruct/blocks/DryingRack.java @@ -27,25 +27,15 @@ public class DryingRack extends InventoryBlock public DryingRack(int id) { - super(id, Material.rock); + super(id, Material.wood); this.setCreativeTab(TConstructRegistry.blockTab); - setHardness(12); + setHardness(2.0f); setStepSound(soundMetalFootstep); } @Override public TileEntity createTileEntity (World world, int metadata) { - /*switch (metadata) - { - case 0: - case 1: - return new FaucetLogic(); - case 2: - return new CastingBasinLogic(); - default: - return null; - }*/ return new DryingRackLogic(); } diff --git a/src/tconstruct/client/TProxyClient.java b/src/tconstruct/client/TProxyClient.java index 2d3880b5da9..00b3f253d33 100644 --- a/src/tconstruct/client/TProxyClient.java +++ b/src/tconstruct/client/TProxyClient.java @@ -356,11 +356,11 @@ public void registerRenderer () RenderingRegistry.registerEntityRenderingHandler(SlimeClone.class, new SlimeCloneRender(new CloneHeadModel(0), new CloneHeadModel(1f), 0.25F)); RenderingRegistry.registerEntityRenderingHandler(CartEntity.class, new CartRender()); - RenderingRegistry.registerEntityRenderingHandler(DaggerEntity.class, new DaggerRenderCustom()); RenderingRegistry.registerEntityRenderingHandler(Crystal.class, new CrystalRender()); RenderingRegistry.registerEntityRenderingHandler(MiniGardy.class, new MiniGardyRender()); RenderingRegistry.registerEntityRenderingHandler(Automaton.class, new CrystalGuardianRender()); RenderingRegistry.registerEntityRenderingHandler(LaunchedPotion.class, new LaunchedItemRender(Item.potion, 16384)); + RenderingRegistry.registerEntityRenderingHandler(DaggerEntity.class, new DaggerRenderCustom()); RenderingRegistry.registerEntityRenderingHandler(ArrowEntity.class, new ArrowRenderCustom()); // RenderingRegistry.registerEntityRenderingHandler(net.minecraft.entity.player.EntityPlayer.class, // new PlayerArmorRender()); // <-- Works, woo! @@ -369,29 +369,8 @@ public void registerRenderer () VillagerRegistry.instance().registerVillagerSkin(78943, new ResourceLocation("tinker", "textures/mob/villagertools.png")); ToolCoreRenderer renderer = new ToolCoreRenderer(); - /*MinecraftForgeClient.registerItemRenderer(TContent.arrow.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.battleaxe.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.battlesign.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.broadsword.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.chisel.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.cleaver.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.cutlass.itemID, renderer);*/ - MinecraftForgeClient.registerItemRenderer(TContent.dagger.itemID, renderer); - /*MinecraftForgeClient.registerItemRenderer(TContent.excavator.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.cutlass.itemID, renderer); + MinecraftForgeClient.registerItemRenderer(TContent.arrow.itemID, renderer); MinecraftForgeClient.registerItemRenderer(TContent.dagger.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.excavator.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.frypan.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.hammer.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.hatchet.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.longsword.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.lumberaxe.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.mattock.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.pickaxe.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.rapier.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.scythe.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.shortbow.itemID, renderer); - MinecraftForgeClient.registerItemRenderer(TContent.shovel.itemID, renderer);*/ addRenderMappings(); addToolButtons(); diff --git a/src/tconstruct/client/entity/projectile/ArrowRender.java b/src/tconstruct/client/entity/projectile/ArrowRender.java index 78595815baf..ec530c40bd1 100644 --- a/src/tconstruct/client/entity/projectile/ArrowRender.java +++ b/src/tconstruct/client/entity/projectile/ArrowRender.java @@ -50,7 +50,7 @@ public ArrowRender() /** * Renders the item */ - public void doRenderItem (ArrowEntity par1ArrowEntity, double par2, double par4, double par6, float par8, float par9) + public void doRenderItem(ArrowEntity par1ArrowEntity, double par2, double par4, double par6, float par8, float par9) { this.func_110777_b(par1ArrowEntity); this.random.setSeed(187L); @@ -61,7 +61,7 @@ public void doRenderItem (ArrowEntity par1ArrowEntity, double par2, double par4, GL11.glPushMatrix(); float f2 = shouldBob() ? MathHelper.sin(((float) 0 + par9) / 10.0F + 0) * 0.1F + 0.1F : 0F; float f3 = (((float) 0 + par9) / 20.0F + 0) * (180F / (float) Math.PI); - byte b0 = getMiniBlockCount(itemstack); + byte b0 = 1; GL11.glTranslatef((float) par2, (float) par4 + f2, (float) par6); GL11.glEnable(GL12.GL_RESCALE_NORMAL); @@ -80,13 +80,6 @@ public void doRenderItem (ArrowEntity par1ArrowEntity, double par2, double par4, { GL11.glRotatef(f3, 0.0F, 1.0F, 0.0F); - if (renderInFrame) - { - GL11.glScalef(1.25F, 1.25F, 1.25F); - GL11.glTranslatef(0.0F, 0.05F, 0.0F); - GL11.glRotatef(-90.0F, 0.0F, 1.0F, 0.0F); - } - float f7 = 0.25F; int j = block.getRenderType(); @@ -120,15 +113,7 @@ public void doRenderItem (ArrowEntity par1ArrowEntity, double par2, double par4, if (itemstack.getItemSpriteNumber() == 1 && itemstack.getItem().requiresMultipleRenderPasses()) { - if (renderInFrame) - { - GL11.glScalef(0.5128205F, 0.5128205F, 0.5128205F); - GL11.glTranslatef(0.0F, -0.05F, 0.0F); - } - else - { - GL11.glScalef(0.5F, 0.5F, 0.5F); - } + GL11.glScalef(0.5F, 0.5F, 0.5F); for (int k = 0; k < itemstack.getItem().getRenderPasses(itemstack.getItemDamage()); ++k) { @@ -153,15 +138,7 @@ public void doRenderItem (ArrowEntity par1ArrowEntity, double par2, double par4, } else { - if (renderInFrame) - { - GL11.glScalef(0.5128205F, 0.5128205F, 0.5128205F); - GL11.glTranslatef(0.0F, -0.05F, 0.0F); - } - else - { - GL11.glScalef(0.5F, 0.5F, 0.5F); - } + GL11.glScalef(0.5F, 0.5F, 0.5F); Icon icon1 = itemstack.getIconIndex(); @@ -186,7 +163,7 @@ public void doRenderItem (ArrowEntity par1ArrowEntity, double par2, double par4, } } - protected ResourceLocation func_110796_a (ArrowEntity par1ArrowEntity) + protected ResourceLocation func_110796_a(ArrowEntity par1ArrowEntity) { return this.renderManager.renderEngine.func_130087_a(par1ArrowEntity.getEntityItem().getItemSpriteNumber()); } @@ -194,12 +171,12 @@ protected ResourceLocation func_110796_a (ArrowEntity par1ArrowEntity) /** * Renders a dropped item */ - private void renderDroppedItem (ArrowEntity par1ArrowEntity, Icon par2Icon, int par3, float par4, float par5, float par6, float par7) + private void renderDroppedItem(ArrowEntity par1ArrowEntity, Icon par2Icon, int par3, float par4, float par5, float par6, float par7) { renderDroppedItem(par1ArrowEntity, par2Icon, par3, par4, par5, par6, par7, 0); } - private void renderDroppedItem (ArrowEntity arrow, Icon par2Icon, int par3, float par4, float par5, float par6, float par7, int pass) + private void renderDroppedItem(ArrowEntity arrow, Icon par2Icon, int par3, float par4, float par5, float par6, float par7, int pass) { Tessellator tessellator = Tessellator.instance; @@ -221,20 +198,13 @@ private void renderDroppedItem (ArrowEntity arrow, Icon par2Icon, int par3, floa GL11.glPushMatrix(); - if (renderInFrame) - { - GL11.glRotatef(180.0F, 0.0F, 1.0F, 0.0F); - } - else - { - GL11.glRotatef((((float) 0 + par4) / 20.0F + 0) * (180F / (float) Math.PI), 0.0F, 1.0F, 0.0F); - } + GL11.glRotatef((((float) 0 + par4) / 20.0F + 0) * (180F / (float) Math.PI), 0.0F, 1.0F, 0.0F); float f12 = 0.0625F; f11 = 0.021875F; ItemStack itemstack = arrow.getEntityItem(); int j = itemstack.stackSize; - byte b0 = getMiniItemCount(itemstack); + byte b0 = 1; GL11.glTranslatef(-f9, -f10, -((f12 + f11) * (float) b0 / 2.0F)); @@ -266,307 +236,12 @@ private void renderDroppedItem (ArrowEntity arrow, Icon par2Icon, int par3, floa GL11.glColor4f(par5, par6, par7, 1.0F); ItemRenderer.renderItemIn2D(tessellator, f5, f6, f4, f7, ((Icon) par2Icon).getOriginX(), ((Icon) par2Icon).getOriginY(), f12); - - if (itemstack.hasEffect(pass)) - { - GL11.glDepthFunc(GL11.GL_EQUAL); - GL11.glDisable(GL11.GL_LIGHTING); - this.renderManager.renderEngine.func_110577_a(field_110798_h); - GL11.glEnable(GL11.GL_BLEND); - GL11.glBlendFunc(GL11.GL_SRC_COLOR, GL11.GL_ONE); - float f13 = 0.76F; - GL11.glColor4f(0.5F * f13, 0.25F * f13, 0.8F * f13, 1.0F); - GL11.glMatrixMode(GL11.GL_TEXTURE); - GL11.glPushMatrix(); - float f14 = 0.125F; - GL11.glScalef(f14, f14, f14); - float f15 = (float) (Minecraft.getSystemTime() % 3000L) / 3000.0F * 8.0F; - GL11.glTranslatef(f15, 0.0F, 0.0F); - GL11.glRotatef(-50.0F, 0.0F, 0.0F, 1.0F); - ItemRenderer.renderItemIn2D(tessellator, 0.0F, 0.0F, 1.0F, 1.0F, 255, 255, f12); - GL11.glPopMatrix(); - GL11.glPushMatrix(); - GL11.glScalef(f14, f14, f14); - f15 = (float) (Minecraft.getSystemTime() % 4873L) / 4873.0F * 8.0F; - GL11.glTranslatef(-f15, 0.0F, 0.0F); - GL11.glRotatef(10.0F, 0.0F, 0.0F, 1.0F); - ItemRenderer.renderItemIn2D(tessellator, 0.0F, 0.0F, 1.0F, 1.0F, 255, 255, f12); - GL11.glPopMatrix(); - GL11.glMatrixMode(GL11.GL_MODELVIEW); - GL11.glDisable(GL11.GL_BLEND); - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glDepthFunc(GL11.GL_LEQUAL); - } } GL11.glPopMatrix(); } - /** - * Renders the item's icon or block into the UI at the specified position. - */ - public void renderItemIntoGUI (FontRenderer par1FontRenderer, TextureManager par2TextureManager, ItemStack par3ItemStack, int par4, int par5) - { - renderItemIntoGUI(par1FontRenderer, par2TextureManager, par3ItemStack, par4, par5, false); - } - - public void renderItemIntoGUI (FontRenderer par1FontRenderer, TextureManager par2TextureManager, ItemStack par3ItemStack, int par4, int par5, boolean renderEffect) - { - int k = par3ItemStack.itemID; - int l = par3ItemStack.getItemDamage(); - Object object = par3ItemStack.getIconIndex(); - float f; - int i1; - float f1; - float f2; - - Block block = (k < Block.blocksList.length ? Block.blocksList[k] : null); - if (par3ItemStack.getItemSpriteNumber() == 0 && block != null && RenderBlocks.renderItemIn3d(Block.blocksList[k].getRenderType())) - { - par2TextureManager.func_110577_a(TextureMap.field_110575_b); - GL11.glPushMatrix(); - GL11.glTranslatef((float) (par4 - 2), (float) (par5 + 3), -3.0F + this.zLevel); - GL11.glScalef(10.0F, 10.0F, 10.0F); - GL11.glTranslatef(1.0F, 0.5F, 1.0F); - GL11.glScalef(1.0F, 1.0F, -1.0F); - GL11.glRotatef(210.0F, 1.0F, 0.0F, 0.0F); - GL11.glRotatef(45.0F, 0.0F, 1.0F, 0.0F); - i1 = Item.itemsList[k].getColorFromItemStack(par3ItemStack, 0); - f = (float) (i1 >> 16 & 255) / 255.0F; - f1 = (float) (i1 >> 8 & 255) / 255.0F; - f2 = (float) (i1 & 255) / 255.0F; - - if (this.renderWithColor) - { - GL11.glColor4f(f, f1, f2, 1.0F); - } - - GL11.glRotatef(-90.0F, 0.0F, 1.0F, 0.0F); - this.itemRenderBlocks.useInventoryTint = this.renderWithColor; - this.itemRenderBlocks.renderBlockAsItem(block, l, 1.0F); - this.itemRenderBlocks.useInventoryTint = true; - GL11.glPopMatrix(); - } - else if (Item.itemsList[k].requiresMultipleRenderPasses()) - { - GL11.glDisable(GL11.GL_LIGHTING); - - for (int j1 = 0; j1 < Item.itemsList[k].getRenderPasses(l); ++j1) - { - par2TextureManager.func_110577_a(par3ItemStack.getItemSpriteNumber() == 0 ? TextureMap.field_110575_b : TextureMap.field_110576_c); - Icon icon = Item.itemsList[k].getIcon(par3ItemStack, j1); - int k1 = Item.itemsList[k].getColorFromItemStack(par3ItemStack, j1); - f1 = (float) (k1 >> 16 & 255) / 255.0F; - f2 = (float) (k1 >> 8 & 255) / 255.0F; - float f3 = (float) (k1 & 255) / 255.0F; - - if (this.renderWithColor) - { - GL11.glColor4f(f1, f2, f3, 1.0F); - } - - this.renderIcon(par4, par5, icon, 16, 16); - - if (par3ItemStack.hasEffect(j1)) - { - renderEffect(par2TextureManager, par4, par5); - } - } - - GL11.glEnable(GL11.GL_LIGHTING); - } - else - { - GL11.glDisable(GL11.GL_LIGHTING); - ResourceLocation resourcelocation = par2TextureManager.func_130087_a(par3ItemStack.getItemSpriteNumber()); - par2TextureManager.func_110577_a(resourcelocation); - - if (object == null) - { - object = ((TextureMap) Minecraft.getMinecraft().func_110434_K().func_110581_b(resourcelocation)).func_110572_b("missingno"); - } - - i1 = Item.itemsList[k].getColorFromItemStack(par3ItemStack, 0); - f = (float) (i1 >> 16 & 255) / 255.0F; - f1 = (float) (i1 >> 8 & 255) / 255.0F; - f2 = (float) (i1 & 255) / 255.0F; - - if (this.renderWithColor) - { - GL11.glColor4f(f, f1, f2, 1.0F); - } - - this.renderIcon(par4, par5, (Icon) object, 16, 16); - GL11.glEnable(GL11.GL_LIGHTING); - - if (par3ItemStack.hasEffect(0)) - { - renderEffect(par2TextureManager, par4, par5); - } - } - - GL11.glEnable(GL11.GL_CULL_FACE); - } - - private void renderEffect (TextureManager manager, int x, int y) - { - GL11.glDepthFunc(GL11.GL_GREATER); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glDepthMask(false); - manager.func_110577_a(field_110798_h); - this.zLevel -= 50.0F; - GL11.glEnable(GL11.GL_BLEND); - GL11.glBlendFunc(GL11.GL_DST_COLOR, GL11.GL_DST_COLOR); - GL11.glColor4f(0.5F, 0.25F, 0.8F, 1.0F); - this.renderGlint(x * 431278612 + y * 32178161, x - 2, y - 2, 20, 20); - GL11.glDisable(GL11.GL_BLEND); - GL11.glDepthMask(true); - this.zLevel += 50.0F; - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glDepthFunc(GL11.GL_LEQUAL); - } - - /** - * Render the item's icon or block into the GUI, including the glint effect. - */ - public void renderItemAndEffectIntoGUI (FontRenderer par1FontRenderer, TextureManager par2TextureManager, ItemStack par3ItemStack, int par4, int par5) - { - if (par3ItemStack != null) - { - if (!ForgeHooksClient.renderInventoryItem(renderBlocks, par2TextureManager, par3ItemStack, renderWithColor, zLevel, (float) par4, (float) par5)) - { - this.renderItemIntoGUI(par1FontRenderer, par2TextureManager, par3ItemStack, par4, par5, true); - } - - /* Modders must handle this themselves if they use custom renderers! - if (par3ItemStack.hasEffect()) - { - GL11.glDepthFunc(GL11.GL_GREATER); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glDepthMask(false); - par2TextureManager.func_110577_a(field_110798_h); - this.zLevel -= 50.0F; - GL11.glEnable(GL11.GL_BLEND); - GL11.glBlendFunc(GL11.GL_DST_COLOR, GL11.GL_DST_COLOR); - GL11.glColor4f(0.5F, 0.25F, 0.8F, 1.0F); - this.renderGlint(par4 * 431278612 + par5 * 32178161, par4 - 2, par5 - 2, 20, 20); - GL11.glDisable(GL11.GL_BLEND); - GL11.glDepthMask(true); - this.zLevel += 50.0F; - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glDepthFunc(GL11.GL_LEQUAL); - } - */ - } - } - - private void renderGlint (int par1, int par2, int par3, int par4, int par5) - { - for (int j1 = 0; j1 < 2; ++j1) - { - if (j1 == 0) - { - GL11.glBlendFunc(GL11.GL_SRC_COLOR, GL11.GL_ONE); - } - - if (j1 == 1) - { - GL11.glBlendFunc(GL11.GL_SRC_COLOR, GL11.GL_ONE); - } - - float f = 0.00390625F; - float f1 = 0.00390625F; - float f2 = (float) (Minecraft.getSystemTime() % (long) (3000 + j1 * 1873)) / (3000.0F + (float) (j1 * 1873)) * 256.0F; - float f3 = 0.0F; - Tessellator tessellator = Tessellator.instance; - float f4 = 4.0F; - - if (j1 == 1) - { - f4 = -1.0F; - } - - tessellator.startDrawingQuads(); - tessellator.addVertexWithUV((double) (par2 + 0), (double) (par3 + par5), (double) this.zLevel, (double) ((f2 + (float) par5 * f4) * f), (double) ((f3 + (float) par5) * f1)); - tessellator.addVertexWithUV((double) (par2 + par4), (double) (par3 + par5), (double) this.zLevel, (double) ((f2 + (float) par4 + (float) par5 * f4) * f), - (double) ((f3 + (float) par5) * f1)); - tessellator.addVertexWithUV((double) (par2 + par4), (double) (par3 + 0), (double) this.zLevel, (double) ((f2 + (float) par4) * f), (double) ((f3 + 0.0F) * f1)); - tessellator.addVertexWithUV((double) (par2 + 0), (double) (par3 + 0), (double) this.zLevel, (double) ((f2 + 0.0F) * f), (double) ((f3 + 0.0F) * f1)); - tessellator.draw(); - } - } - - /** - * Renders the item's overlay information. Examples being stack count or damage on top of the item's image at the - * specified position. - */ - public void renderItemOverlayIntoGUI (FontRenderer par1FontRenderer, TextureManager par2TextureManager, ItemStack par3ItemStack, int par4, int par5) - { - this.renderItemOverlayIntoGUI(par1FontRenderer, par2TextureManager, par3ItemStack, par4, par5, (String) null); - } - - public void renderItemOverlayIntoGUI (FontRenderer par1FontRenderer, TextureManager par2TextureManager, ItemStack par3ItemStack, int par4, int par5, String par6Str) - { - if (par3ItemStack != null) - { - if (par3ItemStack.stackSize > 1 || par6Str != null) - { - String s1 = par6Str == null ? String.valueOf(par3ItemStack.stackSize) : par6Str; - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glDisable(GL11.GL_DEPTH_TEST); - par1FontRenderer.drawStringWithShadow(s1, par4 + 19 - 2 - par1FontRenderer.getStringWidth(s1), par5 + 6 + 3, 16777215); - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glEnable(GL11.GL_DEPTH_TEST); - } - - if (par3ItemStack.isItemDamaged()) - { - int k = (int) Math.round(13.0D - (double) par3ItemStack.getItemDamageForDisplay() * 13.0D / (double) par3ItemStack.getMaxDamage()); - int l = (int) Math.round(255.0D - (double) par3ItemStack.getItemDamageForDisplay() * 255.0D / (double) par3ItemStack.getMaxDamage()); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glDisable(GL11.GL_DEPTH_TEST); - GL11.glDisable(GL11.GL_TEXTURE_2D); - Tessellator tessellator = Tessellator.instance; - int i1 = 255 - l << 16 | l << 8; - int j1 = (255 - l) / 4 << 16 | 16128; - this.renderQuad(tessellator, par4 + 2, par5 + 13, 13, 2, 0); - this.renderQuad(tessellator, par4 + 2, par5 + 13, 12, 1, j1); - this.renderQuad(tessellator, par4 + 2, par5 + 13, k, 1, i1); - GL11.glEnable(GL11.GL_TEXTURE_2D); - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glEnable(GL11.GL_DEPTH_TEST); - GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); - } - } - } - - /** - * Adds a quad to the tesselator at the specified position with the set width and height and color. Args: - * tessellator, x, y, width, height, color - */ - private void renderQuad (Tessellator par1Tessellator, int par2, int par3, int par4, int par5, int par6) - { - par1Tessellator.startDrawingQuads(); - par1Tessellator.setColorOpaque_I(par6); - par1Tessellator.addVertex((double) (par2 + 0), (double) (par3 + 0), 0.0D); - par1Tessellator.addVertex((double) (par2 + 0), (double) (par3 + par5), 0.0D); - par1Tessellator.addVertex((double) (par2 + par4), (double) (par3 + par5), 0.0D); - par1Tessellator.addVertex((double) (par2 + par4), (double) (par3 + 0), 0.0D); - par1Tessellator.draw(); - } - - public void renderIcon (int par1, int par2, Icon par3Icon, int par4, int par5) - { - Tessellator tessellator = Tessellator.instance; - tessellator.startDrawingQuads(); - tessellator.addVertexWithUV((double) (par1 + 0), (double) (par2 + par5), (double) this.zLevel, (double) par3Icon.getMinU(), (double) par3Icon.getMaxV()); - tessellator.addVertexWithUV((double) (par1 + par4), (double) (par2 + par5), (double) this.zLevel, (double) par3Icon.getMaxU(), (double) par3Icon.getMaxV()); - tessellator.addVertexWithUV((double) (par1 + par4), (double) (par2 + 0), (double) this.zLevel, (double) par3Icon.getMaxU(), (double) par3Icon.getMinV()); - tessellator.addVertexWithUV((double) (par1 + 0), (double) (par2 + 0), (double) this.zLevel, (double) par3Icon.getMinU(), (double) par3Icon.getMinV()); - tessellator.draw(); - } - - protected ResourceLocation func_110775_a (Entity par1Entity) + protected ResourceLocation func_110775_a(Entity par1Entity) { return this.func_110796_a((ArrowEntity) par1Entity); } @@ -577,7 +252,7 @@ protected ResourceLocation func_110775_a (Entity par1Entity) * (Render 1) - ret = 2; - if (stack.stackSize > 5) - ret = 3; - if (stack.stackSize > 20) - ret = 4; - if (stack.stackSize > 40) - ret = 5; - return ret; - } - - /** - * Allows for a subclass to override how many rendered items appear in a - * "mini item 3d stack" - * @param stack - * @return - */ - public byte getMiniItemCount (ItemStack stack) + public boolean shouldBob() { - byte ret = 1; - if (stack.stackSize > 1) - ret = 2; - if (stack.stackSize > 15) - ret = 3; - if (stack.stackSize > 31) - ret = 4; - return ret; + return false; } } diff --git a/src/tconstruct/common/TContent.java b/src/tconstruct/common/TContent.java index f0f81e341a6..c26e468c840 100644 --- a/src/tconstruct/common/TContent.java +++ b/src/tconstruct/common/TContent.java @@ -109,6 +109,7 @@ import tconstruct.items.FilledBucket; import tconstruct.items.Fletching; import tconstruct.items.GoldenHead; +import tconstruct.items.Jerky; import tconstruct.items.Manual; import tconstruct.items.MaterialItem; import tconstruct.items.MetalPattern; @@ -226,6 +227,7 @@ public class TContent implements IFuelHandler public static Item strangeFood; public static Item diamondApple; + public static Item jerky; //public static Item stonePattern; //public static Item netherPattern; @@ -1027,6 +1029,8 @@ void registerItems() diamondApple = new DiamondApple(PHConstruct.diamondApple).setUnlocalizedName("tconstruct.apple.diamond"); strangeFood = new StrangeFood(PHConstruct.slimefood).setUnlocalizedName("tconstruct.strangefood"); oreBerries = new OreBerries(PHConstruct.oreChunks).setUnlocalizedName("oreberry"); + + jerky = new Jerky(PHConstruct.jerky, Loader.isModLoaded("HungerOverhaul")).setUnlocalizedName("tconstruct.jerky"); //Wearables //heavyHelmet = new TArmorBase(PHConstruct.heavyHelmet, 0).setUnlocalizedName("tconstruct.HeavyHelmet"); @@ -1784,7 +1788,7 @@ void addCraftingRecipes() GameRegistry.addRecipe(new ItemStack(knapsack, 1, 0), "###", "rmr", "###", '#', new ItemStack(Item.leather), 'r', new ItemStack(toughRod, 1, 2), 'm', new ItemStack(materials, 1, 14)); //Armor - //GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(dryingRack, 1, 0), "bbb", 'b', "slabWood")); + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(dryingRack, 1, 0), "bbb", 'b', "slabWood")); //Landmine GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(landmine, 1, 0), "mcm", "rpr", 'm', "plankWood", 'c', new ItemStack(blankPattern, 1, 1), 'r', Item.redstone, 'p', @@ -1820,7 +1824,14 @@ void addCraftingRecipes() tableCasting.addCastingRecipe(new ItemStack(Item.appleGold, 1, 1), new FluidStack(moltenGoldFluid, TConstruct.ingotLiquidValue * 8 * 9), new ItemStack(Item.appleRed), true, 50); //Drying rack - DryingRackRecipes.addDryingRecipe(Item.rottenFlesh, 20 * 60 * 5, Item.leather); + DryingRackRecipes.addDryingRecipe(Item.beefRaw, 20 * 60 * 5, new ItemStack(jerky, 1, 0)); + DryingRackRecipes.addDryingRecipe(Item.chickenRaw, 20 * 60 * 5, new ItemStack(jerky, 1, 1)); + DryingRackRecipes.addDryingRecipe(Item.porkRaw, 20 * 60 * 5, new ItemStack(jerky, 1, 2)); + //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(jerky, 1, 5), 20 * 60 * 10, Item.leather); //Slabs for (int i = 0; i < 7; i++) @@ -1972,6 +1983,7 @@ public void oreRegistry() OreDictionary.registerOre("blockAlumite", new ItemStack(metalBlock, 1, 8)); OreDictionary.registerOre("blockSteel", new ItemStack(metalBlock, 1, 9)); + OreDictionary.registerOre("nuggetIron", new ItemStack(materials, 1, 19)); OreDictionary.registerOre("nuggetCopper", new ItemStack(materials, 1, 20)); OreDictionary.registerOre("nuggetTin", new ItemStack(materials, 1, 21)); OreDictionary.registerOre("nuggetNaturalAluminum", new ItemStack(materials, 1, 22)); diff --git a/src/tconstruct/entity/BlueSlime.java b/src/tconstruct/entity/BlueSlime.java index 6d213ebc5cd..30a0951d3c5 100644 --- a/src/tconstruct/entity/BlueSlime.java +++ b/src/tconstruct/entity/BlueSlime.java @@ -171,7 +171,7 @@ public double getMountedYOffset () return this.height * 0.3; } - protected void jump () + public void jump () { this.motionY = 0.05 * getSlimeSize() + 0.37; diff --git a/src/tconstruct/entity/GolemBase.java b/src/tconstruct/entity/GolemBase.java index 416b51cc4c8..aad426b27b8 100644 --- a/src/tconstruct/entity/GolemBase.java +++ b/src/tconstruct/entity/GolemBase.java @@ -110,7 +110,7 @@ protected boolean isAIEnabled () return true; } - protected void updateWanderPath () + public void updateWanderPath () { if (!paused) super.updateWanderPath(); diff --git a/src/tconstruct/entity/SlimeClone.java b/src/tconstruct/entity/SlimeClone.java index 4ffe0b7212f..0158391b606 100644 --- a/src/tconstruct/entity/SlimeClone.java +++ b/src/tconstruct/entity/SlimeClone.java @@ -98,7 +98,7 @@ protected String getJumpSound () return "mob.slime." + (this.getSlimeSize() > 1 ? "big" : "small"); } - protected void jump () + public void jump () { this.motionY = 0.05 * getSlimeSize() + 0.37; diff --git a/src/tconstruct/entity/projectile/ArrowEntity.java b/src/tconstruct/entity/projectile/ArrowEntity.java index c3f3c0aecbc..ebc783e1144 100644 --- a/src/tconstruct/entity/projectile/ArrowEntity.java +++ b/src/tconstruct/entity/projectile/ArrowEntity.java @@ -109,6 +109,8 @@ public void onUpdate () if (this.inGround) { + if (!worldObj.isRemote) + { int j = this.worldObj.getBlockId(this.xTile, this.yTile, this.zTile); int k = this.worldObj.getBlockMetadata(this.xTile, this.yTile, this.zTile); @@ -130,6 +132,7 @@ public void onUpdate () this.ticksInGround = 0; this.ticksInAir = 0; } + } } else { @@ -327,7 +330,7 @@ else if (movingobjectposition.entityHit instanceof EntityLivingBase) this.posZ -= this.motionZ / (double) speed * 0.05000000074505806D; this.playSound("random.bowhit", 1.0F, 1.2F / (this.rand.nextFloat() * 0.2F + 0.9F)); this.inGround = true; - this.arrowShake = 7; + this.arrowShake = 0; this.setIsCritical(false); if (this.inTile != 0) diff --git a/src/tconstruct/items/DiamondApple.java b/src/tconstruct/items/DiamondApple.java index 5539f083cda..7f88dc95c27 100644 --- a/src/tconstruct/items/DiamondApple.java +++ b/src/tconstruct/items/DiamondApple.java @@ -14,7 +14,7 @@ public class DiamondApple extends ItemFood { public Icon[] icons; - public String[] textureNames = new String[] { "apple_diamond" }; + public String[] textureNames = new String[] { "food/apple_diamond" }; public String[] itemNames = new String[] { "apple.diamond" }; public DiamondApple(int id) diff --git a/src/tconstruct/items/Jerky.java b/src/tconstruct/items/Jerky.java new file mode 100644 index 00000000000..95670d9eecb --- /dev/null +++ b/src/tconstruct/items/Jerky.java @@ -0,0 +1,41 @@ +package tconstruct.items; + +import net.minecraft.client.renderer.texture.IconRegister; +import net.minecraft.item.ItemStack; +import net.minecraft.util.Icon; +import net.minecraft.util.MathHelper; +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[] { 0.8f, 0.6f, 0.8f, 0.6f, 0.6f, 0.4f }; + public static int[] overhaulHunger = new int[] { 1, 1, 1, 1, 1, 1 }; + + public Jerky(int id, boolean hungerOverhaul) + { + super(id, hungerOverhaul ? overhaulHunger : hunger, saturation, itemNames, textureNames); + } + + @SideOnly(Side.CLIENT) + @Override + public void registerIcons(IconRegister iconRegister) + { + this.icons = new Icon[iconNames.length]; + + for (int i = 0; i < this.icons.length; ++i) + { + this.icons[i] = iconRegister.registerIcon("tinker:food/jerky_" + iconNames[i]); + } + } + + + public String getUnlocalizedName (ItemStack stack) + { + int arr = MathHelper.clamp_int(stack.getItemDamage(), 0, unlocalizedNames.length); + return "item.tconstruct." + unlocalizedNames[arr]; + } +} diff --git a/src/tconstruct/items/StrangeFood.java b/src/tconstruct/items/StrangeFood.java index e19080f0634..53d9d49ffdf 100644 --- a/src/tconstruct/items/StrangeFood.java +++ b/src/tconstruct/items/StrangeFood.java @@ -11,7 +11,7 @@ public class StrangeFood extends SpecialFood { public StrangeFood(int id) { - super(id, new int[] { 2 }, new float[] { 1f }, new String[] { "edibleslime" }, new String[] { "edibleslime" }); + super(id, new int[] { 2 }, new float[] { 1f }, new String[] { "edibleslime" }, new String[] { "food/edibleslime" }); } @Override diff --git a/src/tconstruct/util/PHConstruct.java b/src/tconstruct/util/PHConstruct.java index 5469b40b8ea..6cda863073f 100644 --- a/src/tconstruct/util/PHConstruct.java +++ b/src/tconstruct/util/PHConstruct.java @@ -255,6 +255,7 @@ public static void initProps (File location) knapsack = config.getItem("Equipables", "Knapsack", 14112).getInt(14112); goldHead = config.getItem("Patterns and Misc", "Golden Head", 14113).getInt(14113); essenceCrystal = config.getItem("Patterns and Misc", "Essence Crystal", 14114).getInt(14114); + jerky = config.getItem("Patterns and Misc", "Jerky", 14115).getInt(14115); boolean ic2 = true; boolean xycraft = true; @@ -481,6 +482,7 @@ public static void initProps (File location) //Food public static int diamondApple; public static int slimefood; + public static int jerky; //Tools public static int pickaxe; diff --git a/test/XinStick.java b/test/XinStick.java index d8540c77856..8f4abf77b18 100644 --- a/test/XinStick.java +++ b/test/XinStick.java @@ -8,7 +8,7 @@ import net.minecraft.item.ItemStack; import net.minecraft.util.Icon; import net.minecraft.world.World; -import tconstruct.entity.MiniGardy; +import bastion.entity.WoodMinecartEntity; /* * mDiyo's development testing item @@ -31,12 +31,9 @@ public Icon getIconFromDamage (int par1) @Override public ItemStack onItemRightClick (ItemStack stack, World world, EntityPlayer player) { - //if (!world.isRemote) - //MinecraftServer.getServer().getConfigurationManager().transferPlayerToDimension((EntityPlayerMP) player, -7); - //player.travelToDimension(-7); //clearInventoryExeptHotbar(player); - MiniGardy entity = new MiniGardy(world); - entity.setOwner(player); + WoodMinecartEntity entity = new WoodMinecartEntity(world); + //entity.setOwner(player); //entity.setCustomNameTag("Cutie"); spawnEntity(player.posX, player.posY + 1, player.posZ, entity, world, player); /*EntityChicken chicken = new EntityChicken(world);