Jump to content

How can I add custom tree shape/blocks to my Custom Biome?


ScottehBoeh

Recommended Posts

In my Vietnam mod, I have a custom biome named "Namcraft". (currently spawns in grass, sand etc.)

 

However I'm trying to have it spawn in this custom tree type:

 

7DXAp6s.jpg

(GRASS = Custom Leaves block called (WarBlocks.Palmleaves)

(LOG = Custom Log block called (WarBlocks.Palmlog)

 

Any idea on how I can implement custom trees?

 

My Biome Generator:

 

package net.mcheroesandgenerals.warblocks;

 

import java.util.Random;

 

import net.minecraft.init.Blocks;

import net.minecraft.world.biome.BiomeGenBase;

import net.minecraft.world.biome.BiomeGenBase.FlowerEntry;

import net.minecraft.world.gen.feature.WorldGenTallGrass;

import net.minecraft.world.gen.feature.WorldGenerator;

 

public class BiomeGenNamcraft extends BiomeGenBase

{

 

public BiomeGenNamcraft (int id){

 

super(id);

 

this.spawnableCreatureList.add(new SpawnListEntry(EntityVietcong.class, 30, 2, 10));

this.spawnableCreatureList.add(new SpawnListEntry(EntitySapper.class, 30, 1, 2));

this.spawnableCreatureList.add(new SpawnListEntry(EntityHuey.class, 50, 1, 1));

this.theBiomeDecorator.treesPerChunk = 5;

this.theBiomeDecorator.waterlilyPerChunk = 5;

this.theBiomeDecorator.reedsPerChunk = 100;

this.theBiomeDecorator.sandPerChunk2 = 20;

this.theBiomeDecorator.generateLakes = true;

this.theBiomeDecorator.grassPerChunk = 25;

 

 

this.topBlock = Blocks.grass;

this.fillerBlock = Blocks.stone;

 

 

}

 

@Override

    public void addDefaultFlowers()

    {

        this.flowers.add(new FlowerEntry(Blocks.yellow_flower, 0, 20));

        this.flowers.add(new FlowerEntry(Blocks.red_flower,    0, 10));

        this.flowers.add(new FlowerEntry(WarBlocks.blockLandmine, 0, 20));

        this.flowers.add(new FlowerEntry(WarBlocks.blockBambooSpikes, 0, 10));

    }

 

}

 

 

 

My Custom Biome Registry:

 

package net.mcheroesandgenerals.warblocks;

 

import net.minecraft.world.biome.BiomeGenBase;

import net.minecraftforge.common.BiomeDictionary;

import net.minecraftforge.common.BiomeDictionary.Type;

import net.minecraftforge.common.BiomeManager;

 

public class BiomeRegistry {

 

public static void MainRegistry(){

 

initializeBiome();

registerBiome();

 

}

 

public static BiomeGenBase biomeNamcraft;

 

public static void initializeBiome(){

 

biomeNamcraft = new BiomeGenNamcraft(137).setBiomeName("Namcraft").setTemperatureRainfall(1.2F, 0.9F);

 

}

 

public static void registerBiome(){

 

BiomeDictionary.registerBiomeType(biomeNamcraft, Type.FOREST);

BiomeManager.addSpawnBiome(biomeNamcraft);

 

}

 

}

 

 

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.

Guest
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.

Announcements



×
×
  • Create New...

Important Information

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