mirror of
https://github.com/PolyhedralDev/Terra.git
synced 2025-07-01 07:26:09 +00:00
Corrected checks
This commit is contained in:
parent
d8524603c6
commit
d71c6bb25f
@ -95,12 +95,14 @@ public class CommonListener implements Listener {
|
||||
|
||||
NamespacedKey biomeKey = wolf.getWorld().getBiome(wolf.getLocation()).getKey();
|
||||
pack.getBiomeProvider().stream()
|
||||
.map(biome -> ((BukkitPlatformBiome) biome.getPlatformBiome()).getContext()
|
||||
.get(BukkitBiomeInfo.class)
|
||||
.vanillaBiomeKey())
|
||||
.filter(biomeKey::equals)
|
||||
.filter(biome -> ((BukkitPlatformBiome) biome.getPlatformBiome()).getHandle()
|
||||
.getKey().equals(biomeKey))
|
||||
.findFirst()
|
||||
.ifPresent(vanillaBiomeKey -> {
|
||||
.ifPresent(biome -> {
|
||||
NamespacedKey vanillaBiomeKey = ((BukkitPlatformBiome) biome.getPlatformBiome()).getContext()
|
||||
.get(BukkitBiomeInfo.class)
|
||||
.vanillaBiomeKey();
|
||||
|
||||
switch(vanillaBiomeKey.toString()) {
|
||||
case "minecraft:snowy_taiga" -> wolf.setVariant(Variant.ASHEN);
|
||||
case "minecraft:old_growth_pine_taiga" -> wolf.setVariant(Variant.BLACK);
|
||||
|
Loading…
x
Reference in New Issue
Block a user