Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Glorfindel22

Members
  • Joined

  • Last visited

Everything posted by Glorfindel22

  1. Well I hate to bump the thread but I really wanted to release this mod tonight.
  2. Okay, so I have completed updating my forge mod to 1.7.2 and it works in the testing environment exactly how I want it to; however, when I after I built it using gradle when I run it in Minecraft a window comes up for a second closes and I get the following error: Below is the code in my ItemGrassSeeds class: package net.richardsprojects.recipexpack.main; import cpw.mods.fml.common.registry.GameRegistry; import net.minecraft.item.Item; public class ItemGrassSeeds { public static void mainRegistry() { initializeItem(); registerItem(); } public static Item grassSeeds; public static void initializeItem() { grassSeeds = new Item().setUnlocalizedName("grassSeeds").setCreativeTab(RecipeExpansionPack.tabRecipeXPack).setTextureName("rep:grassSeeds"); } public static void registerItem() { GameRegistry.registerItem(grassSeeds, grassSeeds.getUnlocalizedName()); } }[/Code] I am both developing and running my Mod in forge build 10.12.0.1034. I do not understand how in the exact same build of Forge the mod runs fine in Eclipse but doesn't work in Minecraft. This is very fustrating because I was planning on releasing an update to my mod today. Any help would be greatly appreciated.
  3. Okay, that seemed to solve it, the event is now registered and seems prints out the "test" text to the log when I interact. However, the event code still doesn't work. In my event I am trying to detect if the player has a shovel (of any type in their hand). Under the old system I simply check using the item id but since that doesn't seem to work in 1.7 I am checking using the item name (downside won't work if the item is renamed on an anvil). The problem is it is not working at all it doesn't detect I have a shovel in my hand and print out test 2. Is there a better way to check the type of item a player has in their hand? Below is my code: @SubscribeEvent public void shovelHandler(PlayerInteractEvent event) { System.out.println("Testttttttttttttttttttttttttt!!!!!!!!!!!!!!!!!!!!!!!!!!"); ItemStack itemstack = event.entityPlayer.inventory.getCurrentItem(); //Check to see if the player right clicked if(event.action.equals(event.action.RIGHT_CLICK_BLOCK)) { //Check if player has nothing in their hand //if(event.entityPlayer.getCurrentArmor(0) != null) { if(itemstack.getDisplayName() == "Wooden Shovel" || itemstack.getDisplayName() == "Stone Shovel" || itemstack.getDisplayName() == "Iron Shovel" || itemstack.getDisplayName() == "Gold Shovel" || itemstack.getDisplayName() == "Diamond Shovel") { System.out.println("Test2"); //Change Grass to dirt if(event.entityPlayer.worldObj.getBlock(event.x, event.y, event.z) == Block.getBlockFromName("Grass")) { event.entityPlayer.worldObj.setBlock(event.x, event.y, event.z, Blocks.dirt, 3, 0); //Drop "Grass Seeds" in front of player event.entityPlayer.dropItem(ItemGrassSeeds.grassSeeds, 1); //Reduce the durability itemstack.damageItem(1, event.entityPlayer); } //} } } }
  4. I am working on updating my Minecraft mod, the Recipe Expansion Pack, to 1.7 and I can't figure out how to register events. I have a ModEvents class with the following code package net.richardsprojects.recipexpack.main; //Cut out the imports here for this post to save space so none of the issues come from the imports public class ModEvents { @SubscribeEvent public void shovelHandler(PlayerInteractEvent event) { System.out.println("Testttttttttttttttttttttttttt!!!!!!!!!!!!!!!!!!!!!!!!!!"); ItemStack itemstack = event.entityPlayer.inventory.getCurrentItem(); //Check to see if the player right clicked if(event.action.equals(event.action.RIGHT_CLICK_BLOCK)) { //Check if player has nothing in their hand //if(event.entityPlayer.getCurrentArmor(0) != null) { if(itemstack.getDisplayName() == "Wooden Shovel" || itemstack.getDisplayName() == "Stone Shovel" || itemstack.getDisplayName() == "Iron Shovel" || itemstack.getDisplayName() == "Gold Shovel" || itemstack.getDisplayName() == "Diamond Shovel") { //Change Grass to dirt if(event.entityPlayer.worldObj.getBlock(event.x, event.y, event.z) == Block.getBlockFromName("Grass")) { event.entityPlayer.worldObj.setBlock(event.x, event.y, event.z, Blocks.dirt, 3, 0); //Drop "Grass Seeds" in front of player event.entityPlayer.dropItem(ItemGrassSeeds.grassSeeds, 1); //Reduce the durability itemstack.damageItem(1, event.entityPlayer); } //} } } } } I used the SubscribeEvent annotation because I read that that was the new one. Below my PreInit event in my main class: @EventHandler public void preInit(FMLPreInitializationEvent event) { ItemGrassSeeds.mainRegistry(); FMLCommonHandler.instance().bus().register(new ModEvents()); } I do not get any errors just nothing happens when I right click with my shovel and no "Test" line appears in my console. This is making me believe that I am not registering the event right. Any help would be greatly appreciated!
  5. Like the title says I am trying to detect if the player has a certain item in their inventory, and if they do perform a few actions on it. I have been struggling to find a way to do that, at first I figured I would use the "haveItemStack" method, however while that would tell me they have it doesn't return the itemstack which I would need to perform the actions on. So now I have been thinking about doing a for loop that would look through every item in the inventory using the getStackInSlot method. But I can't seem to figure out what values i can be and how that number would relate to the rest of the inventory. Anyone know? Or better yet does anyone know of another easier way to do what I am trying to?
  6. With the new system of mod installation, as far as I understand you copy all the files into the minecraft jar file, so how does that work? Doesn't that you would have multiple files with the same name in the location if you installed multiple mods (i.e more than one mcmod.info) So either I am a missing something or something has changed. Also your post was very unhelpful, because in addition to that I have never made an mcmod.info file before, so I don't know what information I am supposed to place in it. Does anyone have a template?
  7. Thanks for the responses... I followed the tutorial on called "Releasing Mods" on the wiki and it seems to work. Although installing both forge and mods has definitely changed since 1.5.2. However, I was wondering under the new system where you place the files inside the jar folder instead of a mod folder, how does the mcmod.info work now? Where is it placed in your directory? Can you guys show me a template for me to follow for my mod?
  8. I have just finished the programming the basics for my mod and I am playing to do a Open Alpha (WIP) release. However, I can't figure out how to compile it into a jar file, have things since 1.5.2?
  9. Okay I am trying to add a spear to minecraft. I have finished the ItemSpear class and I am now stuck on the EntitySpear class. I have the entities working right. Basically when I pull the spear back (like a bow) it fires the spear entity and I want spear on impact to spawn a new spear item that is slightly damaged. However, when I try to spawn items in the world if I use the "damageItem" method I get a ticking entity error. So I commented that code out just for testing and now it spawns two spears on the ground instead of only one. Can anyone help me with this? All the code that is causing me trouble is in the "onImpact" method under the EntitySpear class. ItemSpear.java //Removed Package Name to save space (it is in the actual file) //Removed imports here to save space (they are in the actual file) public class ItemSpear extends Item { public static final String[] bowPullIconNameArray = new String[] {"-p_0", "-p_1", "-p_2"}; @SideOnly(Side.CLIENT) private Icon[] iconArray; public int durabilityValue; public ItemSpear(int par1, int durab) { super(par1); this.maxStackSize = 1; this.setMaxDamage(384); this.setCreativeTab(CreativeTabs.tabCombat); //Store Durability Value this.durabilityValue = durab; } public int getMaxItemUseDuration(ItemStack par1ItemStack) { return 72000; } public ItemStack onEaten(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer) { return par1ItemStack; } /** * Called whenever this item is equipped and the right mouse button is pressed. Args: itemStack, world, entityPlayer */ public ItemStack onItemRightClick(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer) { par3EntityPlayer.setItemInUse(par1ItemStack, this.getMaxItemUseDuration(par1ItemStack)); return par1ItemStack; } @SideOnly(Side.CLIENT) public void registerIcons(IconRegister par1IconRegister) { this.itemIcon = par1IconRegister.registerIcon("recipexpack:spear"); this.iconArray = new Icon[bowPullIconNameArray.length]; for (int i = 0; i < this.iconArray.length; ++i) { this.iconArray[i] = par1IconRegister.registerIcon("recipexpack:spear" + bowPullIconNameArray[i]); } } public Icon getItemIconForUseDuration(int par1) { return this.iconArray[par1]; } /** * returns the action that specifies what animation to play when the items is being used */ public EnumAction getItemUseAction(ItemStack par1ItemStack) { return EnumAction.bow; } public void onPlayerStoppedUsing(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer, int par4) { if (!par2World.isRemote) { EntitySpear spear = new EntitySpear(par2World, par3EntityPlayer); spear.setDurability(par1ItemStack.getItemDamage() - 1); par2World.spawnEntityInWorld(spear); } par2World.playSoundAtEntity(par3EntityPlayer, "random.bow", 2F, 1.6F / (itemRand.nextFloat() * 0.4F + 0.8F)); //Remove item from player's inventory } } EntitySpear.java //Removed Package Name to save space (it is in the actual file) //Removed imports here to save space (they are in the actual file) public class EntitySpear extends EntityThrowable { public int spearDurability; private boolean hasImpacted = false; public EntitySpear(World par1World) { super(par1World); } public EntitySpear(World par1World, EntityLivingBase par2EntityLivingBase) { super(par1World, par2EntityLivingBase); } public EntitySpear(World par1World, double par2, double par4, double par6) { super(par1World, par2, par4, par6); } /** * Sets the durability of the spear */ public void setDurability(int durab) { this.spearDurability = durab; } /** * Called when this EntityThrowable hits a block or entity. */ protected void onImpact(MovingObjectPosition par1MovingObjectPosition) { if (par1MovingObjectPosition.entityHit != null) { par1MovingObjectPosition.entityHit.attackEntityFrom(DamageSource.causeArrowDamage(new EntityArrow(worldObj), this.getThrower()), 20.0F); } for (int j = 0; j < 8; ++j) { //this.worldObj.spawnParticle("snowballpoof", this.posX, this.posY, this.posZ, 0.0D, 0.0D, 0.0D); } if (!this.worldObj.isRemote) { this.setDead(); } if(!hasImpacted) { //Spawn new damaged spear in world ItemStack newSpear = new ItemStack(RecipeExpansionPack.spearIron); //newSpear.damageItem(384 - (spearDurability - 1), this.getThrower()); Entity entity = new EntityItem(worldObj, par1MovingObjectPosition.blockX, par1MovingObjectPosition.blockY, par1MovingObjectPosition.blockZ, newSpear); worldObj.spawnEntityInWorld(entity); hasImpacted = true; } } }
  10. I am working on adding a feature in my mod that will let the player craft grass blocks. Basically the player will right click on a grass block with a shovel and the grass block will be turned into dirt, then the player will receive a grass seed. The grass seed can then be used in a recipe with dirt to craft a grass block. However, I am having an issue when checking if the player has a shovel in their hand, because I am using an itemstack of the item in the players hand, if the player right clicks with an empty hand it crashes. So I tried writing a statement that would check if a player has nothing in their hand and if they do kick them out of the if statement series, however it's not working. So my question is how do I properly perform this check? Below is my code. TIA @ForgeSubscribe public void onPlayerInteract(PlayerInteractEvent event) { ItemStack itemstack = event.entityPlayer.inventory.getCurrentItem(); //Check to see if the player right clicked if(event.action.equals(event.action.RIGHT_CLICK_BLOCK)) { //Check if player has nothing in their hand if(!(event.entityPlayer.inventory.currentItem == 0)) { if(itemstack.itemID == 269 || itemstack.itemID == 273 || itemstack.itemID == 256 || itemstack.itemID == 284 || itemstack.itemID == 277) { //Change Grass to dirt if(event.entityPlayer.worldObj.getBlockId(event.x, event.y, event.z) == 2) { event.entityPlayer.worldObj.setBlock(event.x, event.y, event.z, 3); //Drop "Grass Seeds" in front of player event.entityPlayer.dropPlayerItem(new ItemStack(myMod.grassSeed, 1, 0)); } } } } }
  11. I am creating a survival server that will use a custom client and launcher. The custom launcher verifies your minecraft account password and username so it is not cracked. I feel it wrong for people to try and steal minecraft. However, in addition to creating a mod for forge (which is working fine) I am also modding some of the main forge files to create this custom client. For testing purposes I modified some of the text at the main screen , when I run it in eclipse it works fine, however, I can't figure out how to get the modified forge code into a minecraft.jar. Where are fully compiled modified forge classes stored in the folders? Also since the client is based on forge what would I say? For now I have a short snippet of text at the bottom of the main screen that says "Client based on Forge version 7.8.1" Is that all I need?
  12. I have been working on adding compost to my mod I created the item for it and the recipes. My plan is for compost to be similar to bone meal but different. Rather than fully growing the wheat it will make the wheat have a better harvest. In order to accomplish this I created a new crop file that is a copy of the BlockCrops with a few minor changes. My issue is I don't know how to detect when a player right clicks the wheat with compost in their hand and then replace it with my version of the wheat. I figured I would use an event but I'm not sure which one or how the code would work. TIA. Here is my custom crops code and my compost item code. CropCompostedWheat.java package richard.RecipeExpansionPack; //Removed the imports to make it easier for you guys to read public class CropCompostedWheat extends BlockCrops { @SideOnly(Side.CLIENT) private Icon[] field_94363_a; protected CropCompostedWheat(int par1) { super(par1); this.setTickRandomly(true); float f = 0.5F; this.setBlockBounds(0.5F - f, 0.0F, 0.5F - f, 0.5F + f, 0.25F, 0.5F + f); this.setCreativeTab((CreativeTabs)null); this.setHardness(0.0F); this.setStepSound(soundGrassFootstep); this.disableStats(); } /** * Gets the growth rate for the crop. Setup to encourage rows by halving growth rate if there is diagonals, crops on * different sides that aren't opposing, and by adding growth for every crop next to this one (and for crop below * this one). Args: x, y, z */ @SideOnly(Side.CLIENT) /** * From the specified side and block metadata retrieves the blocks texture. Args: side, metadata */ public Icon getBlockTextureFromSideAndMetadata(int par1, int par2) { if (par2 < 0 || par2 > 7) { par2 = 7; } return this.field_94363_a[par2]; } /** * Returns the ID of the items to drop on destruction. */ @Override public int quantityDropped(Random par1Random) { return 3; } @SideOnly(Side.CLIENT) @Override public void func_94332_a(IconRegister par1IconRegister) { this.field_94363_a = new Icon[8]; for (int i = 0; i < this.field_94363_a.length; ++i) { this.field_94363_a[i] = par1IconRegister.func_94245_a("RecipeExpansionPack:cropsc_" + i); } } } ItemCompostComplete.java package richard.RecipeExpansionPack; //Again Removed Imports public class ItemCompostComplete extends Item { public ItemCompostComplete(int par1) { super(par1); } public void func_94581_a(IconRegister iconRegister) { iconIndex = iconRegister.func_94245_a("RecipeExpansionPack:woodbucket-c"); } } RecipeExpansionPack.java package richard.RecipeExpansionPack; //Removed Imports @Mod(modid="REP", name="RecipeExpansionPack", version="1.0.0") @NetworkMod(clientSideRequired=true, serverSideRequired=false) public class RecipeExpansionPack { // The instance of your mod that Forge uses. @Instance("RecipeExpansionPack") public static RecipeExpansionPack instance; //New Items public static Item bucketWoodEmpty = (new ItemWoodBucket(5000, 0)).setUnlocalizedName("woodbucket").setMaxStackSize(16); public static Item bucketWoodWater = (new ItemWoodBucket(5001, Block.waterMoving.blockID)).setUnlocalizedName("woodbucketWater").setContainerItem(bucketWoodEmpty); public static Item bucketWoodMilk = (new ItemWoodBucketMilk(5002)).setUnlocalizedName("woodbucketmilk").setContainerItem(bucketWoodEmpty); public static Item bucketCompostOne = new ItemCompostOne(5003).setUnlocalizedName("wcompostone"); public static Item bucketCompostTwo = new ItemCompostTwo(5004).setUnlocalizedName("wcomposttwo"); public static Item bucketCompostThree = new ItemCompostThree(5005).setUnlocalizedName("wcompostthree"); public static Item bucketCompostComplete = new ItemCompostComplete(5006).setUnlocalizedName("wcompostcomplete"); //New Blocks public static final Block CompostedWheatCrop = new CropCompostedWheat(503); // Says where the client and server 'proxy' code is loaded. @SidedProxy(clientSide="richard.RecipeExpansionPack.client.ClientProxy", serverSide="richard.RecipeExpansionPack.CommonProxy") public static CommonProxy proxy; @PreInit public void preInit(FMLPreInitializationEvent event) { // Stub Method } @Init public void load(FMLInitializationEvent event) { proxy.registerRenderers(); //Register new events MinecraftForge.EVENT_BUS.register(new ModEvents()); //Register New Blocks & Set names of Items GameRegistry.registerBlock(CompostedWheatCrop, "CompostedWheatCrop"); LanguageRegistry.addName(bucketWoodEmpty, "Wooden Bucket"); LanguageRegistry.addName(bucketWoodWater, "Water Bucket"); LanguageRegistry.addName(bucketWoodMilk, "Milk Bucket"); LanguageRegistry.addName(bucketCompostOne, "Compost - 1/4"); LanguageRegistry.addName(bucketCompostTwo, "Compost - 2/4"); LanguageRegistry.addName(bucketCompostThree, "Compost - 3/4"); LanguageRegistry.addName(bucketCompostComplete, "Compost"); //Recipe for Compost - 1 GameRegistry.addShapelessRecipe(new ItemStack(bucketCompostOne), new ItemStack(Item.seeds), new ItemStack(bucketWoodEmpty)); GameRegistry.addShapelessRecipe(new ItemStack(bucketCompostOne), new ItemStack(Block.sapling), new ItemStack(bucketWoodEmpty)); //Recipe for Compost - 2 GameRegistry.addShapelessRecipe(new ItemStack(bucketCompostTwo), new ItemStack(Item.seeds), new ItemStack(bucketCompostOne)); GameRegistry.addShapelessRecipe(new ItemStack(bucketCompostTwo), new ItemStack(Block.sapling), new ItemStack(bucketCompostOne)); //Recipe for Compost - 3 GameRegistry.addShapelessRecipe(new ItemStack(bucketCompostThree), new ItemStack(Item.seeds), new ItemStack(bucketCompostTwo)); GameRegistry.addShapelessRecipe(new ItemStack(bucketCompostThree), new ItemStack(Block.sapling), new ItemStack(bucketCompostTwo)); //Recipe for Compost - final GameRegistry.addShapelessRecipe(new ItemStack(bucketCompostComplete), new ItemStack(Item.seeds), new ItemStack(bucketCompostThree)); GameRegistry.addShapelessRecipe(new ItemStack(bucketCompostComplete), new ItemStack(Block.sapling), new ItemStack(bucketCompostThree)); } @PostInit public void postInit(FMLPostInitializationEvent event) { // Stub Method } }
  13. Hmm... Nice to know I am not the only one that has this issue. I am still looking for a solution though. It's not a huge deal though since the bucket can pick up and drop water fine but I kind of did want to implement the milk.
  14. I am working on adding a wooden bucket into my mod. My plan is for the wooden bucket to be able to pick up water and milk but not lava. I am nearly finished, my only problem is that the wooden bucket doesn't detect when I right click it with the cow. However, I have been playing around with the seperate item for Milk bucket which works perfectly. (I can drink & it becomes an empty wood bucket again). Below is my code. Mod base file package richard.RecipeExpansionPack; //Removed the imports just to keep it shorter for you guys @Mod(modid="REP", name="RecipeExpansionPack", version="1.0.0") @NetworkMod(clientSideRequired=true, serverSideRequired=false) public class RecipeExpansionPack { // The instance of your mod that Forge uses. @Instance("RecipeExpansionPack") public static RecipeExpansionPack instance; //New Items public static Item bucketWoodEmpty = (new ItemWoodBucket(5000, 0)).setUnlocalizedName("woodbucket").setMaxStackSize(16); public static Item bucketWoodWater = (new ItemWoodBucket(5001, Block.waterMoving.blockID)).setUnlocalizedName("woodbucketWater").setContainerItem(bucketWoodEmpty); public static Item bucketWoodMilk = (new ItemWoodBucketMilk(5002)).setUnlocalizedName("woodbucketmilk").setContainerItem(bucketWoodEmpty); // Says where the client and server 'proxy' code is loaded. @SidedProxy(clientSide="richard.RecipeExpansionPack.client.ClientProxy", serverSide="richard.RecipeExpansionPack.CommonProxy") public static CommonProxy proxy; @PreInit public void preInit(FMLPreInitializationEvent event) { // Stub Method } @Init public void load(FMLInitializationEvent event) { proxy.registerRenderers(); //Language Registry LanguageRegistry.addName(bucketWoodEmpty, "Wooden Bucket"); LanguageRegistry.addName(bucketWoodWater, "Water Bucket"); LanguageRegistry.addName(bucketWoodMilk, "Milk Bucket"); } @PostInit public void postInit(FMLPostInitializationEvent event) { // Stub Method } } ItemWoodBucket.java package richard.RecipeExpansionPack; //Again removed imports public class ItemWoodBucket extends ItemBucket { private int isFull; public ItemWoodBucket(int par1, int par2) { super(par1, par2); this.isFull = par2; // This is really important; That was what I've forgotten. } @Override public void func_94581_a(IconRegister iconRegister) { if(isFull == { iconIndex = iconRegister.func_94245_a("RecipeExpansionPack:woodbucket-w"); }else{ iconIndex = iconRegister.func_94245_a("RecipeExpansionPack:woodbucket-e"); } } @Override public ItemStack onItemRightClick(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer) { float f = 1.0F; double d0 = par3EntityPlayer.prevPosX + (par3EntityPlayer.posX - par3EntityPlayer.prevPosX) * (double)f; double d1 = par3EntityPlayer.prevPosY + (par3EntityPlayer.posY - par3EntityPlayer.prevPosY) * (double)f + 1.62D - (double)par3EntityPlayer.yOffset; double d2 = par3EntityPlayer.prevPosZ + (par3EntityPlayer.posZ - par3EntityPlayer.prevPosZ) * (double)f; boolean flag = this.isFull == 0; MovingObjectPosition movingobjectposition = this.getMovingObjectPositionFromPlayer(par2World, par3EntityPlayer, flag); if (movingobjectposition == null) { return par1ItemStack; } else { FillBucketEvent event = new FillBucketEvent(par3EntityPlayer, par1ItemStack, par2World, movingobjectposition); if (MinecraftForge.EVENT_BUS.post(event)) { return par1ItemStack; } if (event.getResult() == Event.Result.ALLOW) { if (par3EntityPlayer.capabilities.isCreativeMode) { return par1ItemStack; } if (--par1ItemStack.stackSize <= 0) { return event.result; } if (!par3EntityPlayer.inventory.addItemStackToInventory(event.result)) { par3EntityPlayer.dropPlayerItem(event.result); } return par1ItemStack; } if (movingobjectposition.typeOfHit == EnumMovingObjectType.TILE) { int i = movingobjectposition.blockX; int j = movingobjectposition.blockY; int k = movingobjectposition.blockZ; if (!par2World.canMineBlock(par3EntityPlayer, i, j, k)) { return par1ItemStack; } if (this.isFull == 0) { if (!par3EntityPlayer.canPlayerEdit(i, j, k, movingobjectposition.sideHit, par1ItemStack)) { return par1ItemStack; } if (par2World.getBlockMaterial(i, j, k) == Material.water && par2World.getBlockMetadata(i, j, k) == 0) { par2World.func_94571_i(i, j, k); if (par3EntityPlayer.capabilities.isCreativeMode) { return par1ItemStack; } if (--par1ItemStack.stackSize <= 0) { return new ItemStack(RecipeExpansionPack.bucketWoodWater); } if (!par3EntityPlayer.inventory.addItemStackToInventory(new ItemStack(RecipeExpansionPack.bucketWoodWater))) { par3EntityPlayer.dropPlayerItem(new ItemStack(RecipeExpansionPack.bucketWoodWater.itemID, 1, 0)); } return par1ItemStack; } } else { if (this.isFull < 0) { return new ItemStack(RecipeExpansionPack.bucketWoodEmpty); } if (movingobjectposition.sideHit == 0) { --j; } if (movingobjectposition.sideHit == 1) { ++j; } if (movingobjectposition.sideHit == 2) { --k; } if (movingobjectposition.sideHit == 3) { ++k; } if (movingobjectposition.sideHit == 4) { --i; } if (movingobjectposition.sideHit == 5) { ++i; } if (!par3EntityPlayer.canPlayerEdit(i, j, k, movingobjectposition.sideHit, par1ItemStack)) { return par1ItemStack; } if (this.tryPlaceContainedLiquid(par2World, d0, d1, d2, i, j, k) && !par3EntityPlayer.capabilities.isCreativeMode) { return new ItemStack(RecipeExpansionPack.bucketWoodEmpty); } } } else if (this.isFull == 0 && movingobjectposition.entityHit instanceof EntityCow) { return new ItemStack(RecipeExpansionPack.bucketWoodMilk); } return par1ItemStack; } } }

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.