mirror of
https://github.com/HbmMods/Hbm-s-Nuclear-Tech-GIT.git
synced 2026-01-25 10:32:49 +00:00
god I wish it were me
Glass panes (I'm in pane)
This commit is contained in:
parent
36d4a4c4e0
commit
b6212b6110
6
.gitignore
vendored
6
.gitignore
vendored
@ -26,3 +26,9 @@ run
|
||||
|
||||
# Changelog backup
|
||||
/changelog.bak
|
||||
CREDITS-fml.txt
|
||||
forge-1.7.10-10.13.4.1614-1.7.10-changelog.txt
|
||||
LICENSE-fml.txt
|
||||
MinecraftForge-Credits.txt
|
||||
MinecraftForge-License.txt
|
||||
README.txt
|
||||
|
||||
@ -30,6 +30,7 @@ import com.hbm.tileentity.machine.storage.TileEntityFileCabinet;
|
||||
import cpw.mods.fml.common.registry.GameRegistry;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.BlockFalling;
|
||||
import net.minecraft.block.BlockPane;
|
||||
import net.minecraft.block.material.*;
|
||||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraftforge.fluids.Fluid;
|
||||
@ -318,6 +319,7 @@ public class ModBlocks {
|
||||
public static Block reinforced_lamp_off;
|
||||
public static Block reinforced_lamp_on;
|
||||
public static Block reinforced_laminate;
|
||||
public static Block reinforced_laminate_pane;
|
||||
|
||||
public static Block lamp_tritium_green_off;
|
||||
public static Block lamp_tritium_green_on;
|
||||
@ -1503,6 +1505,7 @@ public class ModBlocks {
|
||||
reinforced_lamp_off = new ReinforcedLamp(Material.rock, false).setBlockName("reinforced_lamp_off").setCreativeTab(MainRegistry.blockTab).setHardness(15.0F).setResistance(300.0F).setBlockTextureName(RefStrings.MODID + ":reinforced_lamp_off");
|
||||
reinforced_lamp_on = new ReinforcedLamp(Material.rock, true).setBlockName("reinforced_lamp_on").setHardness(15.0F).setResistance(300.0F).setBlockTextureName(RefStrings.MODID + ":reinforced_lamp_on");
|
||||
reinforced_laminate = new BlockNTMGlassCT(1, RefStrings.MODID + ":reinforced_laminate", Material.rock).setBlockName("reinforced_laminate").setCreativeTab(MainRegistry.blockTab).setLightOpacity(0).setHardness(15.0F).setResistance(1000.0F);
|
||||
reinforced_laminate_pane = new BlockNTMGlassPaneRot(1, RefStrings.MODID + ":reinforced_laminate_pane",RefStrings.MODID + ":reinforced_laminate_pane_edge", Material.rock, false).setBlockName("reinforced_laminate_pane").setCreativeTab(MainRegistry.blockTab).setLightOpacity(0).setHardness(15.0F).setResistance(1000.0F);
|
||||
|
||||
lamp_tritium_green_off = new ReinforcedLamp(Material.redstoneLight, false).setBlockName("lamp_tritium_green_off").setStepSound(Block.soundTypeGlass).setCreativeTab(MainRegistry.blockTab).setHardness(3.0F).setBlockTextureName(RefStrings.MODID + ":lamp_tritium_green_off");
|
||||
lamp_tritium_green_on = new ReinforcedLamp(Material.redstoneLight, true).setBlockName("lamp_tritium_green_on").setStepSound(Block.soundTypeGlass).setHardness(3.0F).setBlockTextureName(RefStrings.MODID + ":lamp_tritium_green_on");
|
||||
@ -2648,6 +2651,7 @@ public class ModBlocks {
|
||||
GameRegistry.registerBlock(reinforced_lamp_off, ItemBlockBlastInfo.class, reinforced_lamp_off.getUnlocalizedName());
|
||||
GameRegistry.registerBlock(reinforced_lamp_on, ItemBlockBlastInfo.class, reinforced_lamp_on.getUnlocalizedName());
|
||||
GameRegistry.registerBlock(reinforced_laminate, ItemBlockBlastInfo.class, reinforced_laminate.getUnlocalizedName());
|
||||
GameRegistry.registerBlock(reinforced_laminate_pane,ItemBlockBlastInfo.class, reinforced_laminate_pane.getUnlocalizedName());
|
||||
|
||||
//Bricks
|
||||
GameRegistry.registerBlock(reinforced_stone, ItemBlockBlastInfo.class, reinforced_stone.getUnlocalizedName());
|
||||
|
||||
43
src/main/java/com/hbm/blocks/generic/BlockNTMGlassPane.java
Normal file
43
src/main/java/com/hbm/blocks/generic/BlockNTMGlassPane.java
Normal file
@ -0,0 +1,43 @@
|
||||
package com.hbm.blocks.generic;
|
||||
|
||||
import java.util.Random;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.block.BlockBreakable;
|
||||
import net.minecraft.block.BlockPane;
|
||||
import net.minecraft.block.material.Material;
|
||||
|
||||
public class BlockNTMGlassPane extends BlockBreakable {
|
||||
|
||||
int renderLayer;
|
||||
boolean doesDrop = false;
|
||||
|
||||
public BlockNTMGlassPane(int layer, String name, Material material) {
|
||||
this(layer, name, material, false);
|
||||
}
|
||||
|
||||
public BlockNTMGlassPane(int layer, String name, Material material, boolean doesDrop) {
|
||||
super(name, material, false);
|
||||
this.renderLayer = layer;
|
||||
this.doesDrop = doesDrop;
|
||||
}
|
||||
|
||||
public int quantityDropped(Random rand) {
|
||||
return doesDrop ? 1 : 0;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public int getRenderBlockPass() {
|
||||
return renderLayer;
|
||||
}
|
||||
|
||||
public boolean renderAsNormalBlock() {
|
||||
return false;
|
||||
}
|
||||
|
||||
protected boolean canSilkHarvest() {
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,28 @@
|
||||
package com.hbm.blocks.generic;
|
||||
|
||||
import net.minecraft.block.BlockPane;
|
||||
import net.minecraft.block.material.Material;
|
||||
|
||||
public class BlockNTMGlassPaneRot extends BlockPane
|
||||
{
|
||||
int renderLayer;
|
||||
boolean doesDrop = false;
|
||||
|
||||
//NOTE when you have eclipse make the constructor for you it *WILL BE 'protected'* so make sure to make this public like below.
|
||||
public BlockNTMGlassPaneRot(String flatFaceTextureName, String rimTextureName,
|
||||
Material mat, boolean bool) {
|
||||
super(flatFaceTextureName, rimTextureName, mat, bool);
|
||||
// TODO Auto-generated constructor stub
|
||||
|
||||
this.opaque = true;
|
||||
}
|
||||
|
||||
public BlockNTMGlassPaneRot(int layer, String name, String rimTextureName, Material material, boolean doesDrop) {
|
||||
super(name, rimTextureName, material, false);
|
||||
this.renderLayer = layer;
|
||||
this.doesDrop = doesDrop;
|
||||
this.opaque = true;
|
||||
this.setLightOpacity(1);
|
||||
}
|
||||
|
||||
}
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 206 B |
Loading…
x
Reference in New Issue
Block a user