Jump to content

1.6.2 Nether Ore Generating


Recommended Posts

Hey, me again, I have been trying to get an ore to generate in the nether but it wont generate. It doesn't crash or anything.



World Gen File:


package MOnM;

import java.util.Random;

import net.minecraft.world.World;
import net.minecraft.world.chunk.IChunkProvider;
import net.minecraft.world.gen.feature.WorldGenMinable;
import cpw.mods.fml.common.IWorldGenerator;

public class WorldGeneratorMOnM implements IWorldGenerator{
public void generate(Random random, int chunkX, int chunkZ, World world,IChunkProvider chunkGenerator, IChunkProvider chunkProvider){
            case 1:
                generateNether(world, random, chunkX * 16, chunkZ * 16);
            case 0:
                generateSurface(world, random, chunkX * 16, chunkZ * 16);
            case -1:
                generateEnd(world, random, chunkX * 16, chunkZ * 16);

private void generateEnd(World world, Random random, int chunkX, int chunkZ){

private void generateSurface(World world, Random random, int chunkX,int chunkZ){
	for(int i = 0; i < 20; i++){
		int xCoord = chunkX + random.nextInt(16);
		int yCoord = random.nextInt(80);
		int zCoord = chunkZ + random.nextInt(16);

		(new WorldGenMinable(MOnM.MineriteOre.blockID, 10)).generate(world, random, xCoord, yCoord, zCoord);

private void generateNether(World world, Random random, int chunkX, int chunkZ){
	for(int i = 0; i < 40; i++){
		int xCoord = chunkX + random.nextInt(16);
		int yCoord = random.nextInt(60);
		int zCoord = chunkZ + random.nextInt(16);

		(new WorldGenMinable(MOnM.SataniteOre.blockID, 10)).generate(world, random, xCoord, yCoord, zCoord);




Main File:


package MOnM;

import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import cpw.mods.fml.common.Mod;
import cpw.mods.fml.common.Mod.EventHandler;
import cpw.mods.fml.common.event.FMLInitializationEvent;
import cpw.mods.fml.common.network.NetworkMod;
import cpw.mods.fml.common.registry.GameRegistry;
import cpw.mods.fml.common.registry.LanguageRegistry;

@Mod(modid = MOnM.modID, version = "0.1", name = "More Ores 'n Minerals")
@NetworkMod(clientSideRequired = true, serverSideRequired = false)
public class MOnM {

public static final String modID = "MOnM";

public static Block MineriteGemBlock;
public static Block MineriteOre;
public static Item MineriteDust;
public static Item MineriteGem;
public static Item MineriteIngot;

public static Block SataniteOre;
public static Block SataniteBlock;

public void load(FMLInitializationEvent event){
MineriteOre = new MineriteOre(2000,"mineriteore").setHardness(3.0F).setLightValue(1).setUnlocalizedName("mineriteore");
registerBlock(MineriteOre, "Minerite Ore", MineriteOre.getUnlocalizedName());

MineriteGemBlock = new MineriteGemBlock(2001,"mineritegemblock").setHardness(3.0F).setLightValue(1).setUnlocalizedName("mineritegemblock");
registerBlock(MineriteGemBlock, "Minerite Gem Block", MineriteGemBlock.getUnlocalizedName());

SataniteOre = new SataniteOre(2002,"sataniteore").setHardness(3.0F).setLightValue(1).setUnlocalizedName("sataniteore");
registerBlock(SataniteOre, "Satanite Ore", SataniteOre.getUnlocalizedName());

MineriteDust = new MineriteDust(2500,"mineritedust").setUnlocalizedName("mineritedust");

LanguageRegistry.addName(MineriteDust, "Minerite Dust");

//World Generator Registry
GameRegistry.registerWorldGenerator(new WorldGeneratorMOnM());

	public static void registerBlock(Block block, String name, String unlocalizedName){
		GameRegistry.registerBlock(block, MOnM.modID + unlocalizedName);
		LanguageRegistry.addName(block, name);



Link to comment
Share on other sites

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.

Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Create New...

Important Information

By using this site, you agree to our Terms of Use.