From c044f3b0c4407a368ad77f69547cac3b12eb32e7 Mon Sep 17 00:00:00 2001 From: DaemonUmbra Date: Fri, 1 Nov 2019 14:24:01 -0400 Subject: [PATCH] Replaced getTypes invocation in ensureHasTypes with a direct reference to types, preventing infinite recursion (#6284) The direct reference is checked via ternary and reports if the set is empty, this is likely to result in log spam if modders don't assign types to their biomes --- src/main/java/net/minecraftforge/common/BiomeDictionary.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/net/minecraftforge/common/BiomeDictionary.java b/src/main/java/net/minecraftforge/common/BiomeDictionary.java index 9002286b21..4827d113ac 100644 --- a/src/main/java/net/minecraftforge/common/BiomeDictionary.java +++ b/src/main/java/net/minecraftforge/common/BiomeDictionary.java @@ -338,7 +338,7 @@ public class BiomeDictionary if (!hasAnyType(biome)) { makeBestGuess(biome); - LOGGER.warn("No types have been added to Biome {}, types have been assigned on a best-effort guess: {}", biome.getRegistryName(), getTypes(biome)); + LOGGER.warn("No types have been added to Biome {}, types have been assigned on a best-effort guess: {}", biome.getRegistryName(), !getBiomeInfo(biome).types.isEmpty() ? getBiomeInfo(biome).types : "could not guess types"); } }