Skip to content

Commit

Permalink
Add conformVisibility for mixin overwrites
Browse files Browse the repository at this point in the history
We don't actually want to change the visibility of mixins when
overwriting them.

This reduces the surface area for mod conflicts.
  • Loading branch information
Spottedleaf committed May 29, 2024
1 parent c8fec9d commit b6a8fed
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public abstract class WorldGenRegionMixin implements WorldGenLevel {
public abstract ChunkAccess getChunk(int i, int j);

/**
* @reason During feature generation, light data is not initialised and will always return 15 in Starlight. Vanilla
* During feature generation, light data is not initialised and will always return 15 in Starlight. Vanilla
* can possibly return 0 if partially initialised, which allows some mushroom blocks to generate.
* In general, the brightness value from the light engine should not be used until the chunk is ready. To emulate
* Vanilla behavior better, we return 0 as the brightness during world gen unless the target chunk is finished
Expand All @@ -32,7 +32,7 @@ public int getBrightness(final LightLayer lightLayer, final BlockPos blockPos) {
}

/**
* @reason See above
* See above
* @author Spottedleaf
*/
@Override
Expand Down
5 changes: 4 additions & 1 deletion src/main/resources/moonrise.mixins.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,5 +106,8 @@
],
"injectors": {
"defaultRequire": 1
}
},
"overwrites": {
"conformVisibility": true
}
}

0 comments on commit b6a8fed

Please sign in to comment.