Blogs Tutorial

Modding Tutorial episode 4 - Biomes

  • 245 views 0 today
  • 3
  • 0
  • 2
gabe4356
Lvl 53Grandmaster Blob
204
Ok guys, today im going to be showing you how to code a biome! first to get started i am going to say, this is not complicated at all!!!!! making a biome generate is very simple. So shall we get started? YES!!!!!!!

Code
just copy and paste this into your load method:

ModLoader.addBiome(Test); //registers the biome

After that paste this in the public static final area, we are now calling that the "Variables Section"

BiomeGenTest Test = new BiomeGenTest(23); //creates the biome

then create a new class called BiomeGenTest.class and paste this code:

package net.minecraft.src;

public class BiomeGenTest extends BiomeGenBase
{
protected BiomeGenTest(int par1)
{
super(par1);
this.theBiomeDecorator.treesPerChunk = -999; //-999 is equal to 0
this.theBiomeDecorator.flowersPerChunk = 4; //flowers per chunk
this.theBiomeDecorator.grassPerChunk = 10; //grass per chunk
this.fillerBlock=(byte)Block.glass.blockID; //sets the block that spawns below the top block
this.topBlock=(byte)Block.dirt.blockID; //sets the block that spawns on top
this.biomeName="Test Biome"; //sets the ingame name when f3 pressed
}
}

That's all of the code needed!

Video Tutorial

More like this

  Have something to say?

minegeek360
10/12/2013 3:01 pm
Level 47 : Master Modder
thanks so much
1
gabe4356
10/12/2013 10:45 pm
Level 53 : Grandmaster Blob
Your Welcome.
1

Welcome