Merge pull request #1050 from burningwater202/burningwater202

Sorry for being a pane
This commit is contained in:
HbmMods 2023-06-05 21:51:16 +02:00 committed by GitHub
commit 33005a0a18
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 57 additions and 0 deletions

View File

@ -31,6 +31,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.minecraft.item.ItemBlock;
@ -318,11 +319,13 @@ public class ModBlocks {
public static Block reinforced_brick;
public static Block reinforced_ducrete;
public static Block reinforced_glass;
public static Block reinforced_glass_pane;
public static Block reinforced_light;
public static Block reinforced_sand;
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;
@ -1507,11 +1510,13 @@ public class ModBlocks {
reinforced_brick = new BlockGeneric(Material.rock).setBlockName("reinforced_brick").setCreativeTab(MainRegistry.blockTab).setHardness(15.0F).setResistance(8000.0F).setBlockTextureName(RefStrings.MODID + ":reinforced_brick");
reinforced_glass = new BlockNTMGlassCT(0, RefStrings.MODID + ":reinforced_glass", Material.rock).setBlockName("reinforced_glass").setCreativeTab(MainRegistry.blockTab).setLightOpacity(0).setHardness(15.0F).setResistance(200.0F);
reinforced_glass_pane = new BlockNTMGlassPane(1, RefStrings.MODID + ":reinforced_glass_pane",RefStrings.MODID + ":reinforced_glass_pane_edge", Material.rock, false).setBlockName("reinforced_glass_pane").setCreativeTab(MainRegistry.blockTab).setLightOpacity(1).setHardness(15.0F).setResistance(200.0F);
reinforced_light = new BlockGeneric(Material.rock).setBlockName("reinforced_light").setCreativeTab(MainRegistry.blockTab).setLightLevel(1.0F).setHardness(15.0F).setResistance(300.0F).setBlockTextureName(RefStrings.MODID + ":reinforced_light");
reinforced_sand = new BlockGeneric(Material.rock).setBlockName("reinforced_sand").setCreativeTab(MainRegistry.blockTab).setHardness(15.0F).setResistance(400.0F).setBlockTextureName(RefStrings.MODID + ":reinforced_sand");
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 BlockNTMGlassPane(1, RefStrings.MODID + ":reinforced_laminate_pane",RefStrings.MODID + ":reinforced_laminate_pane_edge", Material.rock, false).setBlockName("reinforced_laminate_pane").setCreativeTab(MainRegistry.blockTab).setLightOpacity(1).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");
@ -2656,11 +2661,13 @@ public class ModBlocks {
GameRegistry.registerBlock(asphalt_light, ItemBlockBlastInfo.class, asphalt_light.getUnlocalizedName());
GameRegistry.registerBlock(reinforced_brick, ItemBlockBlastInfo.class, reinforced_brick.getUnlocalizedName());
GameRegistry.registerBlock(reinforced_glass, ItemBlockBlastInfo.class, reinforced_glass.getUnlocalizedName());
GameRegistry.registerBlock(reinforced_glass_pane, ItemBlockBlastInfo.class, reinforced_glass_pane.getUnlocalizedName());
GameRegistry.registerBlock(reinforced_light, ItemBlockBlastInfo.class, reinforced_light.getUnlocalizedName());
GameRegistry.registerBlock(reinforced_sand, ItemBlockBlastInfo.class, reinforced_sand.getUnlocalizedName());
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());

View File

@ -0,0 +1,45 @@
package com.hbm.blocks.generic;
import net.minecraft.block.BlockPane;
import net.minecraft.block.material.Material;
import net.minecraft.world.IBlockAccess;
import net.minecraftforge.common.util.ForgeDirection;
public class BlockNTMGlassPane 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 BlockNTMGlassPane(String flatFaceTextureName, String rimTextureName,
Material mat, boolean bool) {
super(flatFaceTextureName, rimTextureName, mat, bool);
// TODO Auto-generated constructor stub
this.setLightOpacity(1);
this.opaque = true;
}*/
public BlockNTMGlassPane(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);
}
public boolean canPaneConnectTo(IBlockAccess world, int x, int y, int z, ForgeDirection dir)
{
if (getIdFromBlock(world.getBlock(x,y,z)) == 0)
return false;
else
return true;
/*return canPaneConnectToBlock(world.getBlock(x, y, z)) ||
world.isSideSolid(x, y, z, dir.getOpposite(), false);*/
}
}

View File

@ -434,6 +434,8 @@ public class CraftingManager {
addRecipeAuto(new ItemStack(Item.getItemFromBlock(ModBlocks.reinforced_brick), 4), new Object[] { "FBF", "BFB", "FBF", 'F', Blocks.iron_bars, 'B', ModBlocks.brick_concrete });
addRecipeAuto(new ItemStack(Item.getItemFromBlock(ModBlocks.brick_compound), 4), new Object[] { "FBF", "BTB", "FBF", 'F', ModItems.bolt_tungsten, 'B', ModBlocks.reinforced_brick, 'T', ANY_TAR.any() });
addRecipeAuto(new ItemStack(Item.getItemFromBlock(ModBlocks.reinforced_glass), 4), new Object[] { "FBF", "BFB", "FBF", 'F', Blocks.iron_bars, 'B', Blocks.glass });
addRecipeAuto(new ItemStack(Item.getItemFromBlock(ModBlocks.reinforced_glass_pane), 16), new Object[] { " ", "GGG", "GGG", 'G', ModBlocks.reinforced_glass});
addRecipeAuto(new ItemStack(Item.getItemFromBlock(ModBlocks.reinforced_laminate_pane), 16), new Object[] { " ", "LLL", "LLL", 'L', ModBlocks.reinforced_laminate});
addRecipeAuto(new ItemStack(Item.getItemFromBlock(ModBlocks.reinforced_light), 1), new Object[] { "FFF", "FBF", "FFF", 'F', Blocks.iron_bars, 'B', Blocks.glowstone });
addRecipeAuto(new ItemStack(Item.getItemFromBlock(ModBlocks.reinforced_lamp_off), 1), new Object[] { "FFF", "FBF", "FFF", 'F', Blocks.iron_bars, 'B', Blocks.redstone_lamp });
addRecipeAuto(new ItemStack(Item.getItemFromBlock(ModBlocks.reinforced_sand), 4), new Object[] { "FBF", "BFB", "FBF", 'F', Blocks.iron_bars, 'B', Blocks.sandstone });

View File

@ -5016,12 +5016,15 @@ tile.reinforced_brick.name=Reinforced Stone
tile.reinforced_brick_stairs.name=Reinforced Stone Stairs
tile.reinforced_ducrete.name=Reinforced Ducrete
tile.reinforced_glass.name=Reinforced Glass
tile.reinforced_glass_pane.name=Reinforced Glass Pane
tile.reinforced_lamp_off.name=Reinforced Lamp
tile.reinforced_lamp_on.name=Reinforced Lamp
tile.reinforced_light.name=Reinforced Glowstone
tile.reinforced_sand.name=Reinforced Sandstone
tile.reinforced_stone.name=Dense Stone
tile.reinforced_stone_stairs.name=Dense Stone Stairs
tile.reinforced_laminate.name=Reinforced Laminate
tile.reinforced_laminate_pane.name=Reinforced Laminate Pane
tile.rejuvinator.name=Rejuvination Device
tile.residue.name=Cloud Residue
tile.safe.name=Safe

Binary file not shown.

After

Width:  |  Height:  |  Size: 236 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 146 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 206 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 140 B