Fix silk touch on Ender Chests.
This commit is contained in:
parent
18f3d41a5b
commit
895365d9b9
1 changed files with 7 additions and 7 deletions
|
@ -429,11 +429,11 @@
|
||||||
+ int count = quantityDropped(metadata, fortune, world.rand);
|
+ int count = quantityDropped(metadata, fortune, world.rand);
|
||||||
+ for(int i = 0; i < count; i++)
|
+ for(int i = 0; i < count; i++)
|
||||||
+ {
|
+ {
|
||||||
+ int id = idDropped(metadata, world.rand, 0);
|
+ int id = idDropped(metadata, world.rand, 0);
|
||||||
+ if (id > 0)
|
+ if (id > 0)
|
||||||
+ {
|
+ {
|
||||||
+ ret.add(new ItemStack(id, 1, damageDropped(metadata)));
|
+ ret.add(new ItemStack(id, 1, damageDropped(metadata)));
|
||||||
+ }
|
+ }
|
||||||
+ }
|
+ }
|
||||||
+ return ret;
|
+ return ret;
|
||||||
+ }
|
+ }
|
||||||
|
@ -451,9 +451,9 @@
|
||||||
+ */
|
+ */
|
||||||
+ public boolean canSilkHarvest(World world, EntityPlayer player, int x, int y, int z, int metadata)
|
+ public boolean canSilkHarvest(World world, EntityPlayer player, int x, int y, int z, int metadata)
|
||||||
+ {
|
+ {
|
||||||
+ if (this instanceof BlockGlass)
|
+ if (this instanceof BlockGlass || this instanceof BlockEnderChest)
|
||||||
+ {
|
+ {
|
||||||
+ return true;
|
+ return true;
|
||||||
+ }
|
+ }
|
||||||
+ return renderAsNormalBlock() && !hasTileEntity(metadata);
|
+ return renderAsNormalBlock() && !hasTileEntity(metadata);
|
||||||
+ }
|
+ }
|
||||||
|
|
Loading…
Reference in a new issue