[Crash] [Fabric] [1.18.1] Better End/Nether, Terralilith, TerraBlender
greensad opened this issue · 21 comments
What's the issue you encountered?
After extensive testing I've confirmed that using TerraBlender, Terralilith, Better Nether or Better End in conjunction will crash the game when creating a new world, removing any one of these mods will allow the game to create a new world normally. BCLib without Better Nether or Better End will allow the game to create a new world normally. I've never encountered a crash like this before and so I'm not sure where the best place to post the issue would be so I'm opening an issue here and on Better Nether's issue tracker as well: paulevsGitch/BetterNether#503
How can the issue be reproduced?
Launch the game with Better Nether or Better End, Terralilith, and TerraBlender installed -> Create a new world and the game will crash immediately as the world begins to generate.
Logs
https://bytebin.lucko.me/VITCgd380c or https://crashy.net/pBp1LPn4rD8799dniMXP
Mod Version
1.1.0.70
Additional information
Fabric 0.12.12
Fabric API 0.46.1
Better End 1.0.1
Terralilith 2.0.12
Better Nether 6.0.9
BCLib 1.2.5
Not Enough Crashes 4.1.4
MultiMC Instance: https://drive.google.com/file/d/1m5v6mpfDx3uHTJoUwXLfVbefaxp7x4IO/view?usp=sharing
Could you please provide a full log, that crash report seems to just suggest you have a stack overflow and doesn’t indicate what originally caused it
Could you please provide a full log, that crash report seems to just suggest you have a stack overflow and doesn’t indicate what originally caused it
Here's another Log: https://paste.ee/p/eYecJ
Hi, I am a contributor to BetterNether and I am currently fixing this crash on our side. However, we found that there are other compatibility issues if both BCLib and TerraBlender are installed as both mods want to change the BiomeSource of the level (paulevsGitch/BetterNether#504 may be an indication of this).
So I was hoping that we can work together to make both mods work in parallel. We have internally discussed this issue, and would like to suggest a first proposal as a starting point (obviously we do not know the internals of your mod yet, so feel free to point out if something may not work as we think it would). We think it will be possible to integrate the Biomes managed by TerraBlender into the BiomeSource provided by BCLib as this cross integration is a significant reason why BCLib was created. In order to do this in a consistent way, we would need an API hook into your mod that returns all Biomes you'd need to add. It would also help if that call would signal to your Mod that you do not overwrite the levels BiomeSource. In that case your users do not need to install BCLib.
So please let us know your thoughts. We are really interested in making all involved mods work together in a way that is non disruptive to the players and want to find a solution that warks for both teams.
Well, TerraBlender adds no content itself and doesn’t really operate with a simple list of biomes either. Rather, it adds a new noise source called uniqueness to segregate mod biomes into different regions and allows them to use all of Mojang’s parameters within that region as they see fit. This is kinda heavily dependent on our biome source. In addition to mods relying on this system, we also give datapacks their own region which allows them to generate using the parameters intended by their author in their own regions
Thank you so much for the quick fix.
About the Biomes. We will de-duplicate the Biomes before adding them.
About the parameters. I absolutley get that concern. Could you describe what kind of control those parameters offer? Maybe we can come up with a solution for that (allowing a hook into our BiomeSource or something).
The nether offers the same set of parameters that the overworld does in 1.18. Namely temperature, humidity, continentalness, erosion, weirdness, depth, offset and in the case of TerraBlender uniqueness.
Temperature and humidity are reasonably self-explanatory and could be used for the purpose of separating e.g. frozen Nether biomes from extremely hot ones.
Continentalness in the overworld can be considered to be distance from the shore. It's less applicable to the Nether under Vanilla, but if someone wanted to use it they could theoretically could as the values are still generated.
Erosion is about terrain shape, though similar to Continentalness that's also less likely to be used by many mods in the Nether.
Weirdness is important as it is used to distinguish normal biomes from variant biomes. In the overworld it also dictates slices but that's not really applicable for the Nether.
Depth is fairly important in the context of 3D biomes, as some people may want their biomes to generate in the top, middle or bottom of the Nether.
Offset is kinda hard to explain, but a simplistic perspective could equate it to controlling biome rarity, with higher values being rarer.
Uniqueness is a custom parameter added by TerraBlender as I mentioned before, it's used to allow different mods to have full control over the parameters system within regions devoted entirely to their mod.
Thanks for the fast reply :)
Wouldn't it be possible to generate that list in
.BCLib could take that list and add the Biomes to our biome distribution. The distribution would look different of course, but all Biomes would show up for the players.
Some other things we were thinking about. We do not change the overworld, so at the Moment this issue is limited to the Nether. There, users will either see BetterNether Biomes (which include all DataPack Nether Biomes as well as NetherBiomes added to the Nether using Fabric-API) or the ones managed by TerraBlender.
Since (with default settings) BCLib currently offers to change the BiomeSource to use BetterNether this would simply deactivate TerraBlend Biomes (which we certainly do not want or like) for most users.
I also noticed that the lib uses an overwrite Mixin to a key method in the games lifecycle (
Sorry for the long text, but we really want to get this sorted as a lot of users will be confused or disappointed by that incompatibility.
Well, addBiomesWithVerification is used for all biomes, including Vanilla. Though yes, we can theoretically produce a list from that, it means discarding all of the parameters which I'm not entirely comfortable with.
On the note of that overwrite Mixin though I am certainly happy to change that to a cancelling head inject.
EDIT: Changed that overwrite to an inject in 3a99c4e
Ok, I think it is time to test this. I could create a PR that defines a fabric-entrypoint for a simple callback. I'll adapt your code such that this callback gets called whenever you a new Biome is added.
On our side we will use that information to include the biomes in our source.
Would you accept such a PR?
I'm happy to accept a compatibility PR, but my question would be how you're going to respect/use the parameters I've mentioned
Sorry for the delay :(
This would be my plan to solve this for the Nether:
- Get the Biomes you manage in our BiomeSource so we can get a picture what is missing. Currently we have a very fast implementation of the Biome distribution (for the Nether) which does not rely on any of the Parameters but just randomly selects a Biome. We also generate the BiomeMap very different (and in our opinion more natural) than a MultiNoise generator.
- Find a good example where the distribution we generate is worse than expected (so we can get a feel for what is and what is not important in the Nether). We will need your help to assess this, as we currently do have very little expectation of how Biomes are placed. The only rules we have are
- EdgeBiomes (which should always surround a specific biome)
- SubBiomes (which should always generate inside another biome)
- VerticalBiomes (which should occupy the entire height of the nether)
- Extend the distribution rules to adapt to some of your parameters. We will not be able to 100% reproduce the distribution as our nether generator currently works very different. But I hope we can learn from the failure cases to adapt our distribution such that we can respect the most important parameters.
As always, we are open for other suggestions :)
Terralith uses SeedFix dependency. Is the issue with SeedFix? Since it technically doesn't crash when Terralith isn't loaded, but works if you use Terralith as a datapack, I think this might be a big cause.
SeedFix mixins also use a few of the same classes as Terrablender uses (I am ignorant when it comes to mixins but this is something I came across, not sure if it helps)
Hi, I just wanted to add here: firstly, thanks a lot to everyone here for what you do and for working towards compatibility!
I don't want to muddy the water here, but it sounds potentially relevant: I'm currently using BetterEnd, BCLib and Terralith 2.0 (among 100+ other mods) with no issues - When I added TerraBlender and BYG into the mix, I did not experience any crashes and biomes from all mods were generating properly in new worlds, however, no modded structures were spawning in the overworld (specifically, boss structures from Bosses of Mass Destruction). It still seems compatibility related, but slightly different to what's been described already. I saw the same type of issue reported in issue #37
Interestingly, I setup a new modlist and noticed the same, that structures from mods were absent. I just removed the couple of extra small overworld biome changing mods I had, as well as Terrablender, and the structures all appeared correctly when I regenerated the world. Adding it back in again stops them showing up.
@JDtheHutt @ScoobyVI Did either of you happen to see if the better end or better nether generation features were working as intended?
@greensad I ran a few tests.
With Terralith and Terrablender: Better End and Better Nether biomes and content loaded as expected and I could locate and tp to their modded biomes and structures with no issue. Other mods that also add structures to the End and Nether also were able to generate in both dimensions with no issue. I tried Better Nether with Amplified Nether too, and that worked fine as well. I also tried without Better End and Better Nether, and in both vanilla dimensions other modded structures again spawned without issue.
However, in the Overworld no modded structures are appearing (tried Stoneholm, Repurposed Structures, Towers of the Wild and others), with one odd exception. The Graveyard mod is able to spawn its structures in the Overworld. I tried both the Graveyard version with its own biomes, as well as without its own biomes, and with both it has been the only mod able to spawn its structures into the Overworld when Terrablender and Terralith are used.
I also tried some mods that spawn additions to existing structure generation. Bountiful and Waystones are able to add a Bounty board structure and Waystone structure to vanilla villages just fine. So it seems that modifications to vanilla content already generating works, just not entire new mod structures standing alone, except for that odd Graveyard matter.
In my other tests, even with hundreds of mods and dozens of datapacks combined, everything spawns as expected in the Overworld so long as Terrablender is not used with Terralith. The moment Terrablender is involved, all Overworld structures added by mods stop spawning but End and Nether are fine even if those two dimensions are modded for their worldgen.
I hope that helps.
@greensad, I loaded into the End (BetterEnd) to verify modded End biomes were still generating, but I didn't do much in the way of checking End structures. I can do some more playing later today
Repurposed structures has a bad release that stops modded structures from spawning. (If you aren't on latest) check your version, it was fixed 3 or 4 versions ago.
Maybe try all that again, with terrablender, but no repurposed structures? Mayne that is a confliction itself.
I am on latest for Repurposed Structures, and in the tests I tried both with a bunch of structure mods all together, one at a time, and a couple at a time, so see if it made any difference. Repurposed Structures had no effect on anything, it was only when switching Terrablender in and out that things changed.
@greensad I ran a few tests.
With Terralith and Terrablender: Better End and Better Nether biomes and content loaded as expected and I could locate and tp to their modded biomes and structures with no issue. Other mods that also add structures to the End and Nether also were able to generate in both dimensions with no issue. I tried Better Nether with Amplified Nether too, and that worked fine as well. I also tried without Better End and Better Nether, and in both vanilla dimensions other modded structures again spawned without issue.
However, in the Overworld no modded structures are appearing (tried Stoneholm, Repurposed Structures, Towers of the Wild and others), with one odd exception. The Graveyard mod is able to spawn its structures in the Overworld. I tried both the Graveyard version with its own biomes, as well as without its own biomes, and with both it has been the only mod able to spawn its structures into the Overworld when Terrablender and Terralith are used.
I also tried some mods that spawn additions to existing structure generation. Bountiful and Waystones are able to add a Bounty board structure and Waystone structure to vanilla villages just fine. So it seems that modifications to vanilla content already generating works, just not entire new mod structures standing alone, except for that odd Graveyard matter.
In my other tests, even with hundreds of mods and dozens of datapacks combined, everything spawns as expected in the Overworld so long as Terrablender is not used with Terralith. The moment Terrablender is involved, all Overworld structures added by mods stop spawning but End and Nether are fine even if those two dimensions are modded for their worldgen.
I hope that helps.
Repurposed structures has a bad release that stops modded structures from spawning. (If you aren't on latest) check your version, it was fixed 3 or 4 versions ago.
Maybe try all that again, with terrablender, but no repurposed structures? Mayne that is a confliction itself.