[ci skip] spotlessApply with the new settings

This commit is contained in:
Jason Mitchell committed 2023-01-29 10:09:28 -08:00
1 parent a314fccd1b
commit 8f026dad8f
161 files changed
+14073 -12846

No files matched your search

@@ -11,6 +11,7 @@ import net.minecraft.item.Item;
import net.minecraft.util.IIcon;
import net.minecraft.world.IBlockAccess;
import net.minecraftforge.common.util.ForgeDirection;
import team.chisel.ctmlib.CTM;
import com.cricketcraft.chisel.api.ChiselTabs;
@@ -24,84 +25,84 @@ import cpw.mods.fml.relauncher.SideOnly;
public class BlockCarvableGlass extends BlockGlass implements ICarvable {
public CarvableHelper carverHelper;
private boolean isAlpha = false;
private CTM ctm = CTM.getInstance();
public CarvableHelper carverHelper;
private boolean isAlpha = false;
private CTM ctm = CTM.getInstance();
public BlockCarvableGlass() {
super(Material.glass, false);
public BlockCarvableGlass() {
super(Material.glass, false);
carverHelper = new CarvableHelper(this);
setCreativeTab(ChiselTabs.tabOtherChiselBlocks);
}
carverHelper = new CarvableHelper(this);
setCreativeTab(ChiselTabs.tabOtherChiselBlocks);
}
public BlockCarvableGlass setStained(boolean a) {
this.isAlpha = a;
return this;
}
public BlockCarvableGlass setStained(boolean a) {
this.isAlpha = a;
return this;
}
@Override
public boolean renderAsNormalBlock() {
return false;
}
@Override
public boolean renderAsNormalBlock() {
return false;
}
@Override
public boolean isNormalCube() {
return true;
}
@Override
public boolean isNormalCube() {
return true;
}
@Override
public int getRenderType() {
return ClientUtils.renderCTMId;
}
@Override
public int getRenderType() {
return ClientUtils.renderCTMId;
}
@Override
public IIcon getIcon(int side, int metadata) {
return carverHelper.getIcon(side, metadata);
}
@Override
public boolean shouldSideBeRendered(IBlockAccess world, int x, int y, int z, int side) {
ForgeDirection face = ForgeDirection.getOrientation(side).getOpposite();
int meX = x + face.offsetX;
int meY = y + face.offsetY;
int meZ = z + face.offsetZ;
Block block = world.getBlock(meX, meY, meZ);
int meta = world.getBlockMetadata(meX, meY, meZ);
Block otherBlock = ctm.getBlockOrFacade(world, x, y, z, face.ordinal());
int otherMeta = ctm.getBlockOrFacadeMetadata(world, x, y, z, face.ordinal());
return block != otherBlock || meta != otherMeta;
}
@Override
public IIcon getIcon(int side, int metadata) {
return carverHelper.getIcon(side, metadata);
}
@Override
public int damageDropped(int i) {
return i;
}
@Override
public boolean shouldSideBeRendered(IBlockAccess world, int x, int y, int z, int side) {
ForgeDirection face = ForgeDirection.getOrientation(side).getOpposite();
int meX = x + face.offsetX;
int meY = y + face.offsetY;
int meZ = z + face.offsetZ;
Block block = world.getBlock(meX, meY, meZ);
int meta = world.getBlockMetadata(meX, meY, meZ);
Block otherBlock = ctm.getBlockOrFacade(world, x, y, z, face.ordinal());
int otherMeta = ctm.getBlockOrFacadeMetadata(world, x, y, z, face.ordinal());
return block != otherBlock || meta != otherMeta;
}
@Override
public void registerBlockIcons(IIconRegister register) {
carverHelper.registerBlockIcons("Chisel", this, register);
}
@Override
public int damageDropped(int i) {
return i;
}
@SuppressWarnings({ "unchecked", "rawtypes" })
@Override
public void getSubBlocks(Item item, CreativeTabs tabs, List list) {
carverHelper.registerSubBlocks(this, tabs, list);
}
@Override
public void registerBlockIcons(IIconRegister register) {
carverHelper.registerBlockIcons("Chisel", this, register);
}
@Override
public IVariationInfo getManager(IBlockAccess world, int x, int y, int z, int metadata) {
return carverHelper.getVariation(metadata);
}
@SuppressWarnings({ "unchecked", "rawtypes" })
@Override
public void getSubBlocks(Item item, CreativeTabs tabs, List list) {
carverHelper.registerSubBlocks(this, tabs, list);
}
@Override
public IVariationInfo getManager(int meta) {
return carverHelper.getVariation(meta);
}
@Override
public IVariationInfo getManager(IBlockAccess world, int x, int y, int z, int metadata) {
return carverHelper.getVariation(metadata);
}
@Override
@SideOnly(Side.CLIENT)
public int getRenderBlockPass() {
return isAlpha ? 1 : 0;
}
@Override
public IVariationInfo getManager(int meta) {
return carverHelper.getVariation(meta);
}
@Override
@SideOnly(Side.CLIENT)
public int getRenderBlockPass() {
return isAlpha ? 1 : 0;
}
}