mirror of
https://github.com/GTNewHorizons/Chisel.git
synced 2026-11-12 16:27:45 +00:00
Auto Chisel work
This commit is contained in:
1 parent
53b85531e2
commit
e64901c647
6 files changed
+101
-96
No files matched your search
@@ -54,21 +54,6 @@ public class BlockAutoChisel extends BlockContainer{
|
||||
player.openGui(Chisel.instance, 1, world, x, y, z);
|
||||
}
|
||||
|
||||
if(player.isSneaking() && tile!= null && tile instanceof TileEntityAutoChisel){
|
||||
TileEntityAutoChisel autoChisel = (TileEntityAutoChisel) tile;
|
||||
System.out.println(player.getHeldItem());
|
||||
if(player.getItemInUse() == new ItemStack(ModItems.upgrade, 1, 0)){
|
||||
//If they are using the speed upgrade
|
||||
world.setBlock(x, y, z, ModBlocks.autoChisel, 1, 3);
|
||||
} else if(player.getItemInUse() == new ItemStack(ModItems.upgrade, 1, 1)){
|
||||
//If they are using the automation upgrade
|
||||
world.setBlock(x, y, z, ModBlocks.autoChisel, 2, 3);
|
||||
} else if(player.getItemInUse() == new ItemStack(ModItems.upgrade, 1, 2)){
|
||||
//If they are using the stack upgrade
|
||||
world.setBlock(x, y, z, ModBlocks.autoChisel, 3, 3);
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -78,19 +63,6 @@ public class BlockAutoChisel extends BlockContainer{
|
||||
super.breakBlock(world, x, y, z, block, par6);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int damageDropped(int metadata){
|
||||
return metadata;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@Override
|
||||
public void getSubBlocks(Item item, CreativeTabs creativeTabs, List subItems){
|
||||
for(int x = 0; x < 4; x++){
|
||||
subItems.add(new ItemStack(this, 1, x));
|
||||
}
|
||||
}
|
||||
|
||||
private void dropItems(World world, int x, int y, int z) {
|
||||
Random random = new Random();
|
||||
TileEntity tileEntity = world.getTileEntity(x, y, z);
|
||||
|
||||
Reference in new issue
Block a user