Posted August 8, 201510 yr I decided to work on my mod again, thing is its it for 1.7.2. So I decided to update it. I fixed everything, but I'm getting 1 error for the worldgen. This is the line: (new WorldGenMinable(mainClass.darkOre, 2)).generate(world, random, chunkX, chunkY, chunkZ); Its saying: - The constructor WorldGenMinable(Block, int) is undefined - The method generate(World, Random, BlockPos) in the type WorldGenMinable is not applicable for the arguments (World, Random, int, I'm still pretty new, but I need some help.
August 8, 201510 yr First, you need to make sure you have a line like this in what ever case of the dimension you are generating it in: generateSurface(random, chunkX, chunkZ, world, chunkGenerator, chunkProvider); inside a constructor like this: public void generate(Random random, int chunkX, int chunkZ, World world, IChunkProvider chunkGenerator, IChunkProvider chunkProvider) { } then, you need to generate the ore: public void generateSurface(Random random, int chunkX, int chunkZ, World world, IChunkProvider ChunkGenerator, IChunkProvider chunkProvider){ for(int i = 0; i < 2; i++){ //rarity int startX = chunkX * 16 + random.nextInt(16); int startZ = chunkZ * 16 + random.nextInt(16); int startY = random.nextInt(32) + 16; //height spawning BlockPos start = new BlockPos(startX, startY, startZ); (new WorldGenMinable(your block class.your ore.getDefaultState(), random.nextInt(2) + 10)).generate(world, random, start); //vein size and block to generate }
August 8, 201510 yr Author The method generate takes a BlockPos now, it tells you the problem exactly... And the WorldGenMinable constructor needs an IBlockState now. Ok, I fixed it now
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.