Posted August 17, 20214 yr Hey, I was wondering how I could add a custom biome layer to vanilla world generation? I see in IForgeWorldType there is a getBiomeLayer method that takes an IAreaFactory, overworldGenSettings, and a LongFunction (world seed) and returns the same IAreaFactory with bamboo forests. I was thinking I'd use the WorldTypeEvent.BiomeSize event to seamlessly insert my custom biome layer into vanilla generation since the event occurs within the function that builds the vanilla biome layers. Because my understanding is that if I got the vanilla IAreaFactory I would have to return it with my custom biome layer before LayerUtil gives the layer to the OverworldBiomeProvider. The issue is I can't figure out how to get the vanilla IAreaFactory, so I was wondering if there was a better way to add a custom biome layer to vanilla world generation?
August 17, 20214 yr add a custom Biome to the overworld is very simple, just call BiomeManager#addAdditionalOverworldBiomes in FMLCommonSetupEvent
August 17, 20214 yr Author 1 minute ago, Luis_ST said: add a custom Biome to the overworld is very simple, just call BiomeManager#addAdditionalOverworldBiomes in FMLCommonSetupEvent Unfortunately that didn't work the way I wanted it to. What I'm trying to accomplish is to have a rare biome that spawns within another more common biome, similar to how bamboo forests spawn within jungles. I've found that if I just add my custom biome to world generation that it will generate on the outside between different biomes (Like in the middle of a jungle, desert, and plains) rather than within/surrounded by a single specific biome. Like its very jarring and unsatisfying, which is why I want to make it generate as a layer instead since I want my biome to behave more akin to bamboo jungles or sunflower plains.
August 17, 20214 yr than you need to overwrite the complete OverworldBiomeProvider, and the vanilla biome layer system
August 17, 20214 yr Author Thats what I was thinking, and unfortunately I don't think theres a good way to accomplish that, which is why I was hoping for an easy way to slip my biome layer into the world generation through some sort of forge manager (like the BiomeManager) or through an event (like one of the WorldEvents or WorldTypeEvent). The only other solution I can think of is by generating a feature and inserting my custom biome into the BiomeContainer using reflection, which is possible except I would need to know the exact obfuscated methods/fields (which is like trying to find a needle in a haystack).
August 17, 20214 yr 6 minutes ago, killerjdog51 said: hats what I was thinking, and unfortunately I don't think theres a good way to accomplish that, which is why I was hoping for an easy way to slip my biome layer into the world generation through some sort of forge manager (like the BiomeManager) or through an event (like one of the WorldEvents or WorldTypeEvent). forge has no really helpful tool for that 6 minutes ago, killerjdog51 said: The only other solution I can think of is by generating a feature and inserting my custom biome into the BiomeContainer using reflection, which is possible except I would need to know the exact obfuscated methods/fields (which is like trying to find a needle in a haystack). if you need the mapping names of methods/fields you can use the forge bot on discord
August 17, 20214 yr Author 21 minutes ago, Luis_ST said: if you need the mapping names of methods/fields you can use the forge bot on discord There's a discord channel and a forge bot? Honestly I'm not as surprised as I thought I'd be. Guess I'll check it out then. I didn't think it was possible since I didn't see anything past 1.15 on the old website.
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.