Facebook
From Flying Goose, 2 Years ago, written in Plain Text.
Embed
Download Paste or View Raw
Hits: 54
  1. package com.saon.PotteryMod.blocks;
  2.  
  3. import net.minecraft.block.AbstractBlock;
  4. import net.minecraft.block.Block;
  5. import net.minecraft.block.SoundType;
  6. import net.minecraft.block.material.Material;
  7. import net.minecraft.block.material.MaterialColor;
  8. import net.minecraft.util.math.shapes.IBooleanFunction;
  9. import net.minecraft.util.math.shapes.VoxelShape;
  10. import net.minecraft.util.math.shapes.VoxelShapes;
  11. import net.minecraftforge.common.ToolType;
  12.  
  13. import java.util.stream.Stream;
  14.  
  15. public class PotterWheel extends Block {
  16.  
  17.     private static final VoxelShape SHAPE_N = Stream.of(
  18.             Block.makeCuboidShape(6, 1, 6, 10, 4, 10),
  19.             Block.makeCuboidShape(5, 1, 7, 6, 4, 9),
  20.             Block.makeCuboidShape(7, 1, 5, 9, 4, 6),
  21.             Block.makeCuboidShape(10, 1, 7, 11, 4, 9),
  22.             Block.makeCuboidShape(7, 1, 10, 9, 4, 11),
  23.             Block.makeCuboidShape(0, 1, 6, 1, 3, 10),
  24.             Block.makeCuboidShape(6, 1, 0, 10, 3, 1),
  25.             Block.makeCuboidShape(6, 1, 15, 10, 3, 16),
  26.             Block.makeCuboidShape(15, 1, 6, 16, 3, 10),
  27.             Block.makeCuboidShape(1, 1, 4, 2, 3, 6),
  28.             Block.makeCuboidShape(4, 1, 1, 6, 3, 2),
  29.             Block.makeCuboidShape(3, 1, 2, 4, 3, 3),
  30.             Block.makeCuboidShape(2, 1, 3, 3, 3, 4),
  31.             Block.makeCuboidShape(1, 1, 10, 2, 3, 12),
  32.             Block.makeCuboidShape(2, 1, 12, 3, 3, 13),
  33.             Block.makeCuboidShape(4, 1, 14, 6, 3, 15),
  34.             Block.makeCuboidShape(3, 1, 13, 4, 3, 14),
  35.             Block.makeCuboidShape(10, 1, 1, 12, 3, 2),
  36.             Block.makeCuboidShape(12, 1, 2, 13, 3, 3),
  37.             Block.makeCuboidShape(13, 1, 3, 14, 3, 4),
  38.             Block.makeCuboidShape(14, 1, 4, 15, 3, 6),
  39.             Block.makeCuboidShape(14, 1, 10, 15, 3, 12),
  40.             Block.makeCuboidShape(10, 1, 14, 12, 3, 15),
  41.             Block.makeCuboidShape(13, 1, 12, 14, 3, 13),
  42.             Block.makeCuboidShape(12, 1, 13, 13, 3, 14),
  43.             Block.makeCuboidShape(13, 1, 5, 14, 2, 6),
  44.             Block.makeCuboidShape(11, 1, 6, 13, 2, 7),
  45.             Block.makeCuboidShape(13, 1, 10, 14, 2, 11),
  46.             Block.makeCuboidShape(11, 1, 9, 13, 2, 10),
  47.             Block.makeCuboidShape(2, 1, 10, 3, 2, 11),
  48.             Block.makeCuboidShape(10, 1, 2, 11, 2, 3),
  49.             Block.makeCuboidShape(5, 1, 2, 6, 2, 3),
  50.             Block.makeCuboidShape(6, 1, 3, 7, 2, 5),
  51.             Block.makeCuboidShape(9, 1, 3, 10, 2, 5),
  52.             Block.makeCuboidShape(2, 1, 5, 3, 2, 6),
  53.             Block.makeCuboidShape(3, 1, 6, 5, 2, 7),
  54.             Block.makeCuboidShape(10, 1, 13, 11, 2, 14),
  55.             Block.makeCuboidShape(5, 1, 13, 6, 2, 14),
  56.             Block.makeCuboidShape(9, 1, 11, 10, 2, 13),
  57.             Block.makeCuboidShape(6, 1, 11, 7, 2, 13),
  58.             Block.makeCuboidShape(3, 1, 9, 5, 2, 10),
  59.             Block.makeCuboidShape(6, 4.199999999999999, 15, 10, 5.199999999999999, 16),
  60.             Block.makeCuboidShape(15, 4.199999999999999, 6, 16, 5.199999999999999, 10),
  61.             Block.makeCuboidShape(10, 4.199999999999999, 14, 12, 5.199999999999999, 15),
  62.             Block.makeCuboidShape(14, 4.199999999999999, 10, 15, 5.199999999999999, 12),
  63.             Block.makeCuboidShape(12, 4.199999999999999, 13, 13, 5.199999999999999, 14),
  64.             Block.makeCuboidShape(13, 4.199999999999999, 12, 14, 5.199999999999999, 13),
  65.             Block.makeCuboidShape(4, 4.199999999999999, 14, 6, 5.199999999999999, 15),
  66.             Block.makeCuboidShape(14, 4.199999999999999, 4, 15, 5.199999999999999, 6),
  67.             Block.makeCuboidShape(13, 4.199999999999999, 3, 14, 5.199999999999999, 4),
  68.             Block.makeCuboidShape(3, 4.199999999999999, 13, 4, 5.199999999999999, 14),
  69.             Block.makeCuboidShape(2, 4.199999999999999, 12, 3, 5.199999999999999, 13),
  70.             Block.makeCuboidShape(1, 4.199999999999999, 10, 2, 5.199999999999999, 12),
  71.             Block.makeCuboidShape(12, 4.199999999999999, 2, 13, 5.199999999999999, 3),
  72.             Block.makeCuboidShape(10, 4.199999999999999, 1, 12, 5.199999999999999, 2),
  73.             Block.makeCuboidShape(6, 4.199999999999999, 0, 10, 5.199999999999999, 1),
  74.             Block.makeCuboidShape(0, 4.199999999999999, 6, 1, 5.199999999999999, 10),
  75.             Block.makeCuboidShape(4, 4.199999999999999, 1, 6, 5.199999999999999, 2),
  76.             Block.makeCuboidShape(1, 4.199999999999999, 4, 2, 5.199999999999999, 6),
  77.             Block.makeCuboidShape(2, 4.199999999999999, 3, 3, 5.199999999999999, 4),
  78.             Block.makeCuboidShape(3, 4.199999999999999, 2, 4, 5.199999999999999, 3),
  79.             Block.makeCuboidShape(2, 4.2, 10, 3, 5.2, 11),
  80.             Block.makeCuboidShape(3, 4.199999999999999, 9, 5, 5.199999999999999, 10),
  81.             Block.makeCuboidShape(3, 4.199999999999999, 6, 5, 5.199999999999999, 7),
  82.             Block.makeCuboidShape(2, 4.199999999999999, 5, 3, 5.199999999999999, 6),
  83.             Block.makeCuboidShape(6, 4.199999999999999, 3, 7, 5.199999999999999, 5),
  84.             Block.makeCuboidShape(5, 4.199999999999999, 2, 6, 5.199999999999999, 3),
  85.             Block.makeCuboidShape(9, 4.199999999999999, 3, 10, 5.199999999999999, 5),
  86.             Block.makeCuboidShape(10, 4.199999999999999, 2, 11, 5.199999999999999, 3),
  87.             Block.makeCuboidShape(11, 4.199999999999999, 6, 13, 5.199999999999999, 7),
  88.             Block.makeCuboidShape(13, 4.199999999999999, 5, 14, 5.199999999999999, 6),
  89.             Block.makeCuboidShape(13, 4.199999999999999, 10, 14, 5.199999999999999, 11),
  90.             Block.makeCuboidShape(11, 4.199999999999999, 9, 13, 5.199999999999999, 10),
  91.             Block.makeCuboidShape(9, 4.199999999999999, 11, 10, 5.199999999999999, 13),
  92.             Block.makeCuboidShape(10, 4.199999999999999, 13, 11, 5.199999999999999, 14),
  93.             Block.makeCuboidShape(6, 4.199999999999999, 11, 7, 5.199999999999999, 13),
  94.             Block.makeCuboidShape(5, 4.199999999999999, 13, 6, 5.199999999999999, 14),
  95.             Block.makeCuboidShape(6, 4, 6, 10, 6, 10),
  96.             Block.makeCuboidShape(7, 4, 10, 9, 6, 11),
  97.             Block.makeCuboidShape(5, 4, 7, 6, 6, 9),
  98.             Block.makeCuboidShape(7, 4, 5, 9, 6, 6),
  99.             Block.makeCuboidShape(10, 4, 7, 11, 6, 9),
  100.             Block.makeCuboidShape(0.5, 0, 0.5, 15.5, 1, 15.5)
  101.     ).reduce((v1, v2) -> {return VoxelShapes.combineAndSimplify(v1, v2, IBooleanFunction.OR);}).get();
  102.  
  103.     public PotterWheel() {
  104.         super(Properties.create(Material.ROCK, MaterialColor.STONE).setRequiresTool().hardnessAndResistance(1.25F, 4.2F));
  105.     }
  106.  
  107. }