Posted July 31, 201312 yr I have a stone block I set up. It has the hardness and resistance of stone. It is programmed to require a diamond pickaxe to mine it. It's mineable with any pick, even wood. I even mined it with my fists! Forge 804 (Please fix this!)
August 1, 201312 yr Author I initalize all my Gallifrey- related stuff in another file: @EventHandler public void load(FMLInitializationEvent event) { // Loads Gallifrey package if (CoreConfiguration.enableGallifrey == true) { CoreGallifrey.initalize(); } else { System.out.println("[Whocraft-Core] Gallifrey is disabled, ignoring it..."); } proxy.registerRenderers(); } Let's look at that file. package net.pekkit.mcforge.whocraft.gallifrey; import cpw.mods.fml.common.registry.GameRegistry; import cpw.mods.fml.common.registry.LanguageRegistry; import net.minecraft.block.Block; import net.minecraft.block.material.Material; import net.minecraft.world.biome.BiomeGenBase; import net.minecraftforge.common.DimensionManager; import net.minecraftforge.common.MinecraftForge; import net.pekkit.mcforge.whocraft.CoreConfiguration; public class CoreGallifrey { public static Block gallifreyStone; public static Block gallifreyGrass; public static Block gallifreyDirt; public static Block gallifreyDiamondOre; public static Block gallifreyPortal; public static int gallifreyDimID = 10; public static BiomeGenBase BiomeGallifrey; public static int gallifreyBiomeID = 53; @SuppressWarnings("deprecation") public static void initalize() { System.out.println("[Whocraft-Core] Core module Gallifrey is enabled, loading it..."); loadBlocks(); registerDimension(); loadBiome(); } public static void loadBlocks() { gallifreyStone = new BlockGallifreyStone(241, Material.ground); gallifreyGrass = new BlockGallifreyGrass(242, Material.grass); gallifreyDirt = new BlockGallifreyDirt(243, Material.grass); gallifreyDiamondOre = new BlockGallifreyDiamondOre(244); gallifreyPortal = new BlockGallifreyPortal(CoreConfiguration.gallifreyPortalID).setUnlocalizedName("whocraft:gallifreyPortal"); LanguageRegistry.addName(gallifreyStone, "§4Stone"); MinecraftForge.setBlockHarvestLevel(gallifreyStone, "pickaxe", 3); GameRegistry.registerBlock(gallifreyStone, "gallifreyStone"); LanguageRegistry.addName(gallifreyDirt, "§4Dirt"); MinecraftForge.setBlockHarvestLevel(gallifreyDirt, "shovel", 0); GameRegistry.registerBlock(gallifreyDirt, "gallifreyDirt"); LanguageRegistry.addName(gallifreyGrass, "§4Grass Block"); MinecraftForge.setBlockHarvestLevel(gallifreyGrass, "shovel", 0); GameRegistry.registerBlock(gallifreyGrass, "gallifreyGrass"); LanguageRegistry.addName(gallifreyDiamondOre, "§4Diamond Ore"); MinecraftForge.setBlockHarvestLevel(gallifreyDiamondOre, "pickaxe", 2); GameRegistry.registerBlock(gallifreyDiamondOre, "gallifreyDiamondOre"); GameRegistry.registerBlock(gallifreyPortal, "gallifreyPortal"); LanguageRegistry.addName(gallifreyPortal, "§4[DEV] Gallifrey Portal Block"); System.out.println("[Whocraft-Core: Gallifrey] Loaded 5 blocks!"); } public static void registerDimension() { DimensionManager.registerProviderType(gallifreyDimID, WorldProviderGallifrey.class, false); DimensionManager.registerDimension(gallifreyDimID, gallifreyDimID); System.out.println("[Whocraft-Core: Gallifrey] Registered the dimension Gallifrey with the dimension ID " + gallifreyDimID + "!"); } public static void loadBiome() { BiomeGallifrey = new BiomeGenGallifrey(gallifreyBiomeID); System.out.println("[Whocraft-Core: Gallifrey] Registered the biome Gallifrey with the biome ID " + gallifreyBiomeID + "!"); } } Now for the affected block file: package net.pekkit.mcforge.whocraft.gallifrey; import net.minecraft.block.Block; import net.minecraft.block.material.Material; import net.minecraft.creativetab.CreativeTabs; public class BlockGallifreyStone extends Block { public BlockGallifreyStone(int id, Material material) { super(id, material); setHardness(1.5F); setResistance(10.0F); setStepSound(Block.soundStoneFootstep); setUnlocalizedName("gallifreyStone"); setCreativeTab(CreativeTabs.tabBlock); // Texture func_111022_d("whocraft:gallifreyStone"); } } I don't see a problem.
August 2, 201312 yr Im soooooo confused right now... send me ONLY the part that says the block harvest level and all that.
August 2, 201312 yr Author Taken from the Gallifrey class. I initalized the Blocks like this: public static Block gallifreyStone; public static void loadBlocks() { gallifreyStone = new BlockGallifreyStone(241, Material.ground); gallifreyGrass = new BlockGallifreyGrass(242, Material.grass); gallifreyDirt = new BlockGallifreyDirt(243, Material.grass); gallifreyDiamondOre = new BlockGallifreyDiamondOre(244); gallifreyPortal = new BlockGallifreyPortal(CoreConfiguration.gallifreyPortalID).setUnlocalizedName("whocraft:gallifreyPortal"); LanguageRegistry.addName(gallifreyStone, "§4Stone"); MinecraftForge.setBlockHarvestLevel(gallifreyStone, "pickaxe", 3); GameRegistry.registerBlock(gallifreyStone, "gallifreyStone"); LanguageRegistry.addName(gallifreyDirt, "§4Dirt"); MinecraftForge.setBlockHarvestLevel(gallifreyDirt, "shovel", 0); GameRegistry.registerBlock(gallifreyDirt, "gallifreyDirt"); LanguageRegistry.addName(gallifreyGrass, "§4Grass Block"); MinecraftForge.setBlockHarvestLevel(gallifreyGrass, "shovel", 0); GameRegistry.registerBlock(gallifreyGrass, "gallifreyGrass"); LanguageRegistry.addName(gallifreyDiamondOre, "§4Diamond Ore"); MinecraftForge.setBlockHarvestLevel(gallifreyDiamondOre, "pickaxe", 2); GameRegistry.registerBlock(gallifreyDiamondOre, "gallifreyDiamondOre"); GameRegistry.registerBlock(gallifreyPortal, "gallifreyPortal"); LanguageRegistry.addName(gallifreyPortal, "§4[DEV] Gallifrey Portal Block");
August 2, 201312 yr Problem found : You using wrong block material. Try this : gallifreyStone = new BlockGallifreyStone(241, Material.rock);
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.