Skip to content

Fix Citadel surface rules overwriting modded surface rules + Improve mixin compatibility#224

Draft
BluSpring wants to merge 5 commits intoAlexModGuy:1.21from
BluSpring:1.21-issue223
Draft

Fix Citadel surface rules overwriting modded surface rules + Improve mixin compatibility#224
BluSpring wants to merge 5 commits intoAlexModGuy:1.21from
BluSpring:1.21-issue223

Conversation

@BluSpring
Copy link
Copy Markdown

@BluSpring BluSpring commented Apr 14, 2026

Fixes #223.

Based on Raguto/Citadel-1.21.1#6. Needs further testing, I'm unsure which mods are affected by this issue.
Additional changes were made to try to improve Citadel's mixin compatibility with other mods.

@BluSpring BluSpring changed the title Fix #223 Fix Citadel surface rules overwriting modded surface rules Apr 14, 2026
@RhapsodySL
Copy link
Copy Markdown

Hi, after running into this issue myself, I can confirm that one of the impacted mods is Biomes We've Gone, and one of the impacted biomes is Rainbow Beach, if that helps with testing. With Citadel installed, Rainbow Beach generates grass instead of the rainbow sand as expected.

…1-issue223

# Conflicts:
#	src/main/java/com/github/alexthe666/citadel/mixin/MinecraftServerMixin.java
@BluSpring
Copy link
Copy Markdown
Author

Apparently my Git didn't properly sync with the upstream changes... Regardless, seems to work perfectly fine now.
image

@BluSpring BluSpring changed the title Fix Citadel surface rules overwriting modded surface rules Fix Citadel surface rules overwriting modded surface rules + Improve mixin compatibility Apr 15, 2026
@DENOBODY2
Copy link
Copy Markdown

Are the newest changes on your end published to this pull request? I'm using your changes as outlined in these commits and I am still experiencing issues with surface rules, with Atmospheric and Biomes We've Gone as my tests
image
image
Here is what I'm getting vs the intended biome. I'm also experiencing the above user's issue with rainbow beaches

@BluSpring
Copy link
Copy Markdown
Author

They're supposed to be, which biome is this?

@DENOBODY2
Copy link
Copy Markdown

Atmospheric's Dunes biome

@DENOBODY2
Copy link
Copy Markdown

I noticed the unofficial port, compared to the official port here, has a "SurfaceRuleInitializer" class and "IExtendedNoiseGeneratorSettings" interface in its implementation. I was able to achieve more success when combining these aspects with your pull request changes. However, with the changes from this pull request on their own I was not able to experience the correct surface rules.

@DENOBODY2
Copy link
Copy Markdown

DENOBODY2 commented Apr 26, 2026

(I will note adding that change breaks citadel's own surface rules, however, so I've stuck with just your changes for now)

@DENOBODY2
Copy link
Copy Markdown

DENOBODY2 commented Apr 26, 2026

After further testing the issue's I experienced with citadel's own surface rules were not to to including the changes I noticed in the official port's fix for the compatibility issue. It is a separate problem I will report to the Alexscaves github.

This is separate from the compatibility issues I have been experiencing that I mentioned in my first comment.

@BluSpring
Copy link
Copy Markdown
Author

Either way I fixed it now properly. Something I only just noticed was that NoiseGeneratorSettings is a record, and trying to add custom fields to records is not recommended due to issues that would be encountered on certain JVMs. I've fixed that now using a WeakHashMap to basically just "cache" the rule sources and using a ModifyReturnValue to not cancel out anyone else's mixins. Seems to work fine now.
image

@DENOBODY2
Copy link
Copy Markdown

DENOBODY2 commented Apr 26, 2026

Works fine now with the overworld mods, but I've noticed the change now breaks the Alex's Caves surface rules.
image

@BluSpring
Copy link
Copy Markdown
Author

Could you throw at me a build for Alex's Caves on 1.21.1? Need an actually good testing ground for this

@BluSpring BluSpring marked this pull request as draft April 26, 2026 20:40
@DENOBODY2
Copy link
Copy Markdown

https://github.com/AlexModGuy/AlexsCaves/tree/1.21.1

I'm compiling the latest version of the 1.21.1 branch for Alexscaves.

https://github.com/digi2303/AlexsCaves/releases/tag/1.0.0 this is a build version of the official 1.21 branch with PR 1717 merged in. I'm just using the base 1.21 branch without PR 1717 but I will test with this as well.

@DENOBODY2
Copy link
Copy Markdown

With citadel PR #224 (your fixes):
image
Without citadel PR #224 (old):
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants