blob: b29ef7f2f246b7783388dbc116346eac47f28905 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
package goodgenerator.blocks.regularBlock;
import net.minecraft.block.material.Material;
import net.minecraft.world.IBlockAccess;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class BlockFrame extends BlockCasing {
public BlockFrame(String name, String[] texture) {
super(name, texture, Material.iron);
}
@Override
public boolean isOpaqueCube() {
return false;
}
@Override
@SideOnly(Side.CLIENT)
public boolean shouldSideBeRendered(IBlockAccess worldClient, int xCoord, int yCoord, int zCoord, int aSide) {
if (worldClient.getBlock(xCoord, yCoord, zCoord) instanceof BlockFrame) return false;
return super.shouldSideBeRendered(worldClient, xCoord, yCoord, zCoord, aSide);
}
@Override
@SideOnly(Side.CLIENT)
public int getRenderBlockPass() {
return 1;
}
@Override
public boolean renderAsNormalBlock() {
return false;
}
}
|