Posted May 24, 20169 yr I'm trying to make a new WorldType that generates my custom biomes only, with alternative ores instead of the Vanilla ones. But for some reason it's only generating one biome and the Vanilla Rivers. And on top of that the Wasteland is generating too many trees and NOT generating the alternative ores. Anyone know what's causing this? [spoiler=Biome registry]public class Biomes { public static BiomeGenBase wasteland, harsh_desert, stone_jungle, oasis; public static void init() //Called in main class' preInit() { wasteland = new BiomeWasteland(Config.getBiomeIdWasteland()); harsh_desert = new BiomeWasteland(Config.getBiomeIdHarshDesert()); stone_jungle = new BiomeWasteland(Config.getBiomeIdStoneJungle()); oasis = new BiomeWasteland(Config.getBiomeIdOasis()); } public static void register() //Called in main class' postInit() { BiomeDictionary.registerBiomeType(wasteland, BiomeDictionary.Type.DEAD, Type.WASTELAND, Type.DRY); BiomeManager.addSpawnBiome(wasteland); BiomeDictionary.registerBiomeType(harsh_desert, BiomeDictionary.Type.DEAD, Type.WASTELAND, Type.DRY, Type.HOT); BiomeManager.addSpawnBiome(harsh_desert); BiomeDictionary.registerBiomeType(stone_jungle, BiomeDictionary.Type.DEAD, Type.WASTELAND, Type.MOUNTAIN); BiomeManager.addSpawnBiome(stone_jungle); BiomeDictionary.registerBiomeType(oasis, BiomeDictionary.Type.LUSH, Type.MAGICAL, Type.RIVER, Type.WET); BiomeManager.addSpawnBiome(oasis); } } [spoiler=WorldTypeApocalypse]public class WorldTypeApocalypse extends WorldType { public WorldTypeApocalypse(String name) { super(name); } @Override public GenLayer getBiomeLayer(long worldSeed, GenLayer parentLayer) { GenLayer ret = new GenLayerApocalypse(3L); ret = GenLayerZoom.magnify(100L, ret, 2); ret = new GenLayerBiomeEdge(100L, ret); return ret; } } [spoiler=GenLayerApocalypse]public class GenLayerApocalypse extends GenLayer { public GenLayerApocalypse(long seed) { super(seed); } protected BiomeGenBase[] allowedBiomes = { Biomes.harsh_desert, Biomes.stone_jungle, Biomes.wasteland }; protected BiomeGenBase[] rareBiomes = { Biomes.oasis }; public int[] getInts(int x, int z, int width, int depth) { int[] dest = IntCache.getIntCache(width * depth); int rarity = nextInt(100); for (int dz = 0; dz < depth; dz++) { for (int dx = 0; dx < width; dx++) { initChunkSeed(dx + x, dz + z); if (rarity < Config.getRareBiomeRarity()) { dest[(dx + dz * width)] = this.rareBiomes[nextInt(this.rareBiomes.length)].biomeID; } else { dest[(dx + dz * width)] = this.allowedBiomes[nextInt(this.allowedBiomes.length)].biomeID; } } } return dest; } } [spoiler=BiomeWasteland (the only one of my biomes that generates)]public class BiomeWasteland extends BiomeGenBase { public BiomeWasteland(int id) { super(id); this.setBiomeName("Wasteland"); this.setColor(new Color(150, 100, 0).getRGB()); this.setTemperatureRainfall(2.5f, 0.1f); this.theBiomeDecorator.treesPerChunk = 1; this.theBiomeDecorator.flowersPerChunk = 0; this.theBiomeDecorator.grassPerChunk = 2; this.theBiomeDecorator.cactiPerChunk = 1; this.theBiomeDecorator.clayPerChunk = 5; this.theBiomeDecorator.deadBushPerChunk = 3; this.theBiomeDecorator.mushroomsPerChunk = 0; this.topBlock = Blocks.dirt; this.theBiomeDecorator.ironGen = new WorldGenMinable(Content.tin_ore, ; this.theBiomeDecorator.goldGen = new WorldGenMinable(Content.silver_ore, ; this.theBiomeDecorator.redstoneGen = new WorldGenMinable(Content.halite_ore, 7); this.theBiomeDecorator.diamondGen = new WorldGenMinable(Content.titanium_ore, 7); this.theBiomeDecorator.lapisGen = new WorldGenMinable(Content.ignium_ore, 6); } @SideOnly(Side.CLIENT) public int getSkyColorByTemp(float f) { return Color.GRAY.getRGB(); } public boolean canSpawnLightningBolt() { return true; } public float getSpawningChance() { return 0.05F; } public int getWaterColorMultiplier() { return new Color(100, 200, 50).getRGB(); } public int getModdedBiomeFoliageColor(int original) { return new Color(150, 100, 0).getRGB(); } }
May 24, 20169 yr Author I'm trying to make a new WorldType that generates my custom biomes only, with alternative ores instead of the Vanilla ones. But for some reason it's only generating one biome and the Vanilla Rivers. And on top of that the Wasteland is generating too many trees and NOT generating the alternative ores. Anyone know what's causing this? [spoiler=Biome registry]public class Biomes { public static BiomeGenBase wasteland, harsh_desert, stone_jungle, oasis; public static void init() //Called in main class' preInit() { wasteland = new BiomeWasteland(Config.getBiomeIdWasteland()); harsh_desert = new BiomeWasteland(Config.getBiomeIdHarshDesert()); stone_jungle = new BiomeWasteland(Config.getBiomeIdStoneJungle()); oasis = new BiomeWasteland(Config.getBiomeIdOasis()); } public static void register() //Called in main class' postInit() { BiomeDictionary.registerBiomeType(wasteland, BiomeDictionary.Type.DEAD, Type.WASTELAND, Type.DRY); BiomeManager.addSpawnBiome(wasteland); BiomeDictionary.registerBiomeType(harsh_desert, BiomeDictionary.Type.DEAD, Type.WASTELAND, Type.DRY, Type.HOT); BiomeManager.addSpawnBiome(harsh_desert); BiomeDictionary.registerBiomeType(stone_jungle, BiomeDictionary.Type.DEAD, Type.WASTELAND, Type.MOUNTAIN); BiomeManager.addSpawnBiome(stone_jungle); BiomeDictionary.registerBiomeType(oasis, BiomeDictionary.Type.LUSH, Type.MAGICAL, Type.RIVER, Type.WET); BiomeManager.addSpawnBiome(oasis); } } [spoiler=WorldTypeApocalypse]public class WorldTypeApocalypse extends WorldType { public WorldTypeApocalypse(String name) { super(name); } @Override public GenLayer getBiomeLayer(long worldSeed, GenLayer parentLayer) { GenLayer ret = new GenLayerApocalypse(3L); ret = GenLayerZoom.magnify(100L, ret, 2); ret = new GenLayerBiomeEdge(100L, ret); return ret; } } [spoiler=GenLayerApocalypse]public class GenLayerApocalypse extends GenLayer { public GenLayerApocalypse(long seed) { super(seed); } protected BiomeGenBase[] allowedBiomes = { Biomes.harsh_desert, Biomes.stone_jungle, Biomes.wasteland }; protected BiomeGenBase[] rareBiomes = { Biomes.oasis }; public int[] getInts(int x, int z, int width, int depth) { int[] dest = IntCache.getIntCache(width * depth); int rarity = nextInt(100); for (int dz = 0; dz < depth; dz++) { for (int dx = 0; dx < width; dx++) { initChunkSeed(dx + x, dz + z); if (rarity < Config.getRareBiomeRarity()) { dest[(dx + dz * width)] = this.rareBiomes[nextInt(this.rareBiomes.length)].biomeID; } else { dest[(dx + dz * width)] = this.allowedBiomes[nextInt(this.allowedBiomes.length)].biomeID; } } } return dest; } } [spoiler=BiomeWasteland (the only one of my biomes that generates)]public class BiomeWasteland extends BiomeGenBase { public BiomeWasteland(int id) { super(id); this.setBiomeName("Wasteland"); this.setColor(new Color(150, 100, 0).getRGB()); this.setTemperatureRainfall(2.5f, 0.1f); this.theBiomeDecorator.treesPerChunk = 1; this.theBiomeDecorator.flowersPerChunk = 0; this.theBiomeDecorator.grassPerChunk = 2; this.theBiomeDecorator.cactiPerChunk = 1; this.theBiomeDecorator.clayPerChunk = 5; this.theBiomeDecorator.deadBushPerChunk = 3; this.theBiomeDecorator.mushroomsPerChunk = 0; this.topBlock = Blocks.dirt; this.theBiomeDecorator.ironGen = new WorldGenMinable(Content.tin_ore, ; this.theBiomeDecorator.goldGen = new WorldGenMinable(Content.silver_ore, ; this.theBiomeDecorator.redstoneGen = new WorldGenMinable(Content.halite_ore, 7); this.theBiomeDecorator.diamondGen = new WorldGenMinable(Content.titanium_ore, 7); this.theBiomeDecorator.lapisGen = new WorldGenMinable(Content.ignium_ore, 6); } @SideOnly(Side.CLIENT) public int getSkyColorByTemp(float f) { return Color.GRAY.getRGB(); } public boolean canSpawnLightningBolt() { return true; } public float getSpawningChance() { return 0.05F; } public int getWaterColorMultiplier() { return new Color(100, 200, 50).getRGB(); } public int getModdedBiomeFoliageColor(int original) { return new Color(150, 100, 0).getRGB(); } }
June 4, 20169 yr GenLayer#getInts does not only contain biome information, which you only provides from your GenLayer. Either implement your own WorldChunkManager or change the GenLayerApocalypse to give all the informations. (Take a look at GenLayerBiome) I. Stellarium for Minecraft: Configurable Universe for Minecraft! (WIP) II. Stellar Sky, Better Star Rendering&Sky Utility mod, had separated from Stellarium.
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.