-
[1.7.10] Config boolean and recipes
G' day, Im trying to make a config file, where if "dirt recipes" is on, allow the user to craft grass and if off, disable the recipe. It does not seem to be working though... This is inside the main class
-
[1.7.10] Place Bucket event?
Hello, Im trying to find an event which is called when the player places a bucket of water or lava. I have found a FillBucketEvent but cant find one for placing the bucket. Is there another event out there that is called when a player places a bucket of water or lava? Cheers
-
[1.7.10] need some help with BlockBreakEvent and harvesting blocks
I have found something that works but still not fully correct. int boxWidth = 3; double par1 = boxWidth / 2; for(int i = 0; i < boxWidth; i++) { for(int j = 0; j < boxWidth; j++) { for(int k = 0; k < boxWidth; k++) { Item heldItem = player.getHeldItem().getItem(); //if(player.getHeldItem().getItem().canHarvestBlock()) //System.out.println(heldItem.canHarvestBlock(target, player.getHeldItem())); int x1 = (int)(x - par1 + i); int y1 = (int)(y - par1 + j); int z1 = (int)(z - par1 + k); Block target = world.getBlock(x1, y1, z1); int targetMeta = world.getBlockMetadata(x1, y1, z1); if(ForgeHooks.canToolHarvestBlock(target, targetMeta, player.getHeldItem())) { target.harvestBlock(world, player, x1, y1, z1, targetMeta); world.setBlockToAir(x1, y1, z1); } } } } this seems to work fine only that for some reason dirt doesnt get destroyed???
-
[1.7.10] need some help with BlockBreakEvent and harvesting blocks
Hmm, i cant find any of those methods? Are they new in 1.8? cause im still on 1.7...
-
[1.7.10] need some help with BlockBreakEvent and harvesting blocks
G' day Ive made an upgrade for the pickaxe where when you break a block, all surrounding blocks get broken too in a 3x3 area. This works but there is a problem. B S S B S S S S S B = bedrock S = stone Lets say I break the center block, all 9 blocks will break even though im using and iron pickaxe which cant break bedrock. What I need to happen is so that when I break the center block, it will only break the stone (or whatever other block an iron pick can break) butnot the bedrock. This is inside BlockBreakEvent int boxWidth = 3; double par1 = boxWidth / 2; for(int i = 0; i < boxWidth; i++) { for(int j = 0; j < boxWidth; j++) { for(int k = 0; k < boxWidth; k++) { Item heldItem = player.getHeldItem().getItem(); //if(player.getHeldItem().getItem().canHarvestBlock()) //System.out.println(heldItem.canHarvestBlock(target, player.getHeldItem())); int x1 = (int)(x - par1 + i); int y1 = (int)(y - par1 + j); int z1 = (int)(z - par1 + k); Block target = world.getBlock(x1, y1, z1); int targetMeta = world.getBlockMetadata(x1, y1, z1); if(heldItem.canHarvestBlock(target, player.getHeldItem())) { target.harvestBlock(world, player, x1, y1, z1, targetMeta); world.setBlockToAir(x1, y1, z1); } } } } That code still makes the bedrock break, however I have also tried the following which somewhat works: int boxWidth = 3; double par1 = boxWidth / 2; for(int i = 0; i < boxWidth; i++) { for(int j = 0; j < boxWidth; j++) { for(int k = 0; k < boxWidth; k++) { Item heldItem = player.getHeldItem().getItem(); //if(player.getHeldItem().getItem().canHarvestBlock()) //System.out.println(heldItem.canHarvestBlock(target, player.getHeldItem())); int x1 = (int)(x - par1 + i); int y1 = (int)(y - par1 + j); int z1 = (int)(z - par1 + k); Block target = world.getBlock(x1, y1, z1); int targetMeta = world.getBlockMetadata(x1, y1, z1); if(world.getBlock((x1, y1, z1) != Blocks.bedrock) { target.harvestBlock(world, player, x1, y1, z1, targetMeta); world.setBlockToAir(x1, y1, z1); } } } } This code DOES work. The pick does not break the bedrock but still breaks the stone. Only problem is that blocks like Obsidian which an iron pick cant mine can still get broken this way. What looking for is something that checks if the block at the coords at x y z can be broken with the held item, and if so break it, otherwise dont. Thnx
-
Changing moon texture in custom dimension
Thank you so much guys! Got it working now
-
Changing moon texture in custom dimension
Is there a way i can change the texture of the moon in my custom dimension? Looked through the world provider but couldn't find anything... Cheers
-
[SOLVED][1.7.10] setupDecompWorkspace - no build script
I fixed it! Did some research on the "SocketException" and had to run 'netsh winsoc reset'. Now everything is working
-
[SOLVED][1.7.10] setupDecompWorkspace - no build script
Still not working, everytime i run it, it seems to never make any files in C:\Users\john\.gradle\caches\2.0\scripts\build_2n89d7nu8105mn84crl2s6oc0q\ProjectScript\buildscript\ which causes it to fail. Also when i try to launch Minecraft.exe, i get the same message when launching: Downloading: https://s3.amazonaws.com/Minecraft.Download/launcher/launcher.pack.lzma (try x/10) Exception: java.net.SocketException: Unrecognized Windows Sockets error: 87: create is it something to do with java?
-
[SOLVED][1.7.10] setupDecompWorkspace - no build script
So im trying to setup forge 1.7.10 and when i run setupDecompWorkspace i get this error: Now, ive gone and looked in C:\Users\john\.gradle\caches\2.0\scripts\build_2n89d7nu8105mn84crl2s6oc0q\ProjectScript\buildscript\ and it is empty! How can i get the files needed in this folder? Thnx
-
[1.7.10] Variables in EntityLivingBase are not public
hmm i installed new web security before and it wanted me to delete some files scattered in the cpu, so its probably that. Ill try making a new workspace and see if it works update: yep its that, it failed to setupDecompWorkspace, gotta redownload forge
-
[1.7.10] Variables in EntityLivingBase are not public
Ive found another way of doing what i want, so dont worry bout those variables, but ive run into a crash report that i cant even firgure out whats wrong, can u help? It happens as soon as i click on the world
-
[1.7.10] Variables in EntityLivingBase are not public
The variables i need are isJumping and jumpTicks, is there a way i can somehow access these protected variables? Thnx
-
[1.7.10] How to make potion NOT appear in player inventory when active
Ok, ill try it out
-
[1.7.10] How to make potion NOT appear in player inventory when active
Damn, but i may be able to do an alternative way. Do u know if there is a method like isJumping() in the entity class which says if an entity is jumping or off the ground?
IPS spam blocked by CleanTalk.