MrDood_Modding

BlockBasicBlock.java

Feb 3rd, 2017
160
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.89 KB | None | 0 0
  1. package com.josh.gomc.blocks;
  2.  
  3. import net.minecraft.block.Block;
  4. import net.minecraft.block.material.Material;
  5. import net.minecraft.world.IBlockAccess;
  6.  
  7. public class BlockBasicBlock extends Block{
  8.     private Block beaconBase;
  9.     public BlockBasicBlock(Material material, float hardness, float resistance, int harvestLevel, boolean beaconBase) {
  10.         super(material);
  11.         this.setHardness(hardness);
  12.         this.setResistance(resistance);
  13.         this.setLightLevel(0.0F);
  14.         this.setHarvestLevel("pickaxe", harvestLevel);
  15.         this.setStepSound(soundTypeStone);
  16.         if(beaconBase){
  17.             this.setBeaconBase();
  18.         }
  19.        
  20.     }
  21.     public Block setBeaconBase() {
  22.         return beaconBase = this;
  23.     }
  24.     @Override
  25.     public boolean isBeaconBase(IBlockAccess worldObj, int x, int y, int z, int beaconX, int beaconY, int beaconZ)
  26.     {
  27.         return this == beaconBase;
  28.     }
  29.  
  30.  
  31. }
Add Comment
Please, Sign In to add comment