From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: 2No2Name <2No2Name@web.de> Date: Sat, 8 Jan 2022 03:51:28 +0100 Subject: [PATCH] lithium: entity.fast_powder_snow_check Original code by CaffeineMC, licensed under GNU Lesser General Public License v3.0 You can find the original code on https://github.com/CaffeineMC/lithium-fabric (Yarn mappings) diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java index 85f4b06cf4062fcc8199b66dd926dbe352584210..be8060a46399f5d9c09003c2144f4b46b659cef5 100644 --- a/src/main/java/net/minecraft/world/entity/LivingEntity.java +++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java @@ -565,11 +565,11 @@ public abstract class LivingEntity extends Entity implements Attackable { } protected void tryAddFrost() { - if (!this.getBlockStateOnLegacy().isAir()) { + //if (!this.getBlockStateOnLegacy().isAir()) { // DivineMC int i = this.getTicksFrozen(); if (i > 0) { - AttributeInstance attributemodifiable = this.getAttribute(Attributes.MOVEMENT_SPEED); + AttributeInstance attributemodifiable = this.getBlockStateOnLegacy().isAir() ? null : this.getAttribute(Attributes.MOVEMENT_SPEED); // DivineMC if (attributemodifiable == null) { return; @@ -579,7 +579,7 @@ public abstract class LivingEntity extends Entity implements Attackable { attributemodifiable.addTransientModifier(new AttributeModifier(LivingEntity.SPEED_MODIFIER_POWDER_SNOW_UUID, "Powder snow slow", (double) f, AttributeModifier.Operation.ADDITION)); } - } + //} // DivineMC }