Skip to content

Commit 7609276

Browse files
Fix incorrect biome color representation (#66)
1 parent e66addd commit 7609276

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

mc/1.21.11/src/main/java/dev/u9g/minecraftdatagenerator/generators/BiomesDataGenerator.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,8 @@ public static JsonObject generateBiomeInfo(Registry<Biome> registry, Biome biome
9696
EnvironmentAttributeMap.Entry<Integer, ?> skyColorEntry = biome.getAttributes().get(EnvironmentAttributes.SKY_COLOR);
9797
int skyColor = 0;
9898
if (skyColorEntry != null && skyColorEntry.argument() instanceof Integer) {
99-
skyColor = (Integer) skyColorEntry.argument();
99+
// convert to RGB
100+
skyColor = (Integer) skyColorEntry.argument() & 0xFFFFFF;
100101
}
101102
biomeDesc.addProperty("color", skyColor);
102103
//biomeDesc.addProperty("rainfall", biome.getDownfall());// - removed in 1.19.4

0 commit comments

Comments
 (0)