From 903ebf779fdc13597c85dccd9da41d591363dd7a Mon Sep 17 00:00:00 2001 From: 2No2Name <2No2Name@web.de> Date: Fri, 14 Jul 2023 13:58:45 +0200 Subject: [PATCH] Update BoatEntityMixin --- src/main/java/mendedminecarts/mixin/boat/BoatEntityMixin.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/mendedminecarts/mixin/boat/BoatEntityMixin.java b/src/main/java/mendedminecarts/mixin/boat/BoatEntityMixin.java index 786c69a..c17de66 100644 --- a/src/main/java/mendedminecarts/mixin/boat/BoatEntityMixin.java +++ b/src/main/java/mendedminecarts/mixin/boat/BoatEntityMixin.java @@ -25,7 +25,7 @@ public BoatEntityMixin(EntityType type, World world) { cancellable = true ) private void setCartPosLikeOtherEntities(double x, double y, double z, float yaw, float pitch, int interpolationSteps, boolean interpolate, CallbackInfo ci) { - if (this.world.isClient && (MendedMinecartsMod.ACCURATE_CLIENT_BOATS.isEnabled())) { + if (this.getWorld().isClient && (MendedMinecartsMod.ACCURATE_CLIENT_BOATS.isEnabled())) { ci.cancel(); super.updateTrackedPositionAndAngles(x, y, z, yaw, pitch, interpolationSteps, interpolate); } @@ -36,7 +36,7 @@ private void setCartPosLikeOtherEntities(double x, double y, double z, float yaw method = "tick", at = @At(value = "INVOKE", target = "Lnet/minecraft/entity/vehicle/BoatEntity;isLogicalSideForUpdatingMovement()Z")) private boolean simulateCartsOnClientLikeOnServer(BoatEntity instance) { - if (this.world.isClient && (MendedMinecartsMod.ACCURATE_CLIENT_BOATS.isEnabled())) { + if (this.getWorld().isClient && (MendedMinecartsMod.ACCURATE_CLIENT_BOATS.isEnabled())) { return true; } else { return instance.isLogicalSideForUpdatingMovement();