aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/com/dulkirfabric/mixin/render/LivingEntityMixin.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/com/dulkirfabric/mixin/render/LivingEntityMixin.java')
-rw-r--r--src/main/java/com/dulkirfabric/mixin/render/LivingEntityMixin.java7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/main/java/com/dulkirfabric/mixin/render/LivingEntityMixin.java b/src/main/java/com/dulkirfabric/mixin/render/LivingEntityMixin.java
index c0f9a03..b615136 100644
--- a/src/main/java/com/dulkirfabric/mixin/render/LivingEntityMixin.java
+++ b/src/main/java/com/dulkirfabric/mixin/render/LivingEntityMixin.java
@@ -59,14 +59,15 @@ public class LivingEntityMixin implements GlowingEntityInterface {
@Inject(method = "tickMovement", at = @At(value = "INVOKE", target = "Lnet/minecraft/entity/LivingEntity;tickNewAi()V",
shift = At.Shift.AFTER))
public void onWhatever(CallbackInfo ci) {
- if (DulkirConfig.ConfigVars.getConfigOptions().getHandSwingDuration() == 6) return;
- if (animationTicks > DulkirConfig.ConfigVars.getConfigOptions().getHandSwingDuration()) {
+ if (DulkirConfig.ConfigVars.getConfigOptions().getAnimationPreset().getSwingDuration() == 6) return;
+ if (animationTicks > DulkirConfig.ConfigVars.getConfigOptions().getAnimationPreset().getSwingDuration()) {
animationTicks = 0;
}
if (animationTicks == 0) {
handSwingProgress = 1F;
} else {
- handSwingProgress = (animationTicks - 1F) / DulkirConfig.ConfigVars.getConfigOptions().getHandSwingDuration();
+ handSwingProgress = (animationTicks - 1F) /
+ DulkirConfig.ConfigVars.getConfigOptions().getAnimationPreset().getSwingDuration();
animationTicks++;
}
}