From 3591bfe1a407cf4d869ef5a75b9b9f413ca4a5a7 Mon Sep 17 00:00:00 2001 From: Christian Koop Date: Thu, 28 Mar 2024 10:49:23 +0100 Subject: [PATCH] hotfix: Copy over old normalization logic for Hologram hooks for ceze --- .../com/craftaro/core/hooks/hologram/HologramHook.java | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/Core/src/main/java/com/craftaro/core/hooks/hologram/HologramHook.java b/Core/src/main/java/com/craftaro/core/hooks/hologram/HologramHook.java index c738b0a9..29c072af 100644 --- a/Core/src/main/java/com/craftaro/core/hooks/hologram/HologramHook.java +++ b/Core/src/main/java/com/craftaro/core/hooks/hologram/HologramHook.java @@ -1,7 +1,6 @@ package com.craftaro.core.hooks.hologram; import com.craftaro.core.hooks.Hook; -import com.craftaro.core.utils.LocationUtils; import org.bukkit.Location; import org.jetbrains.annotations.NotNull; @@ -64,8 +63,11 @@ public abstract class HologramHook implements Hook { } protected @NotNull Location getNormalizedLocation(Location location) { - return LocationUtils - .getCenter(location) - .add(0, getYOffset(), 0); + return new Location( + location.getWorld(), + location.getX() + (location.getX() - (int) location.getX()) + 0.5, + location.getY() + (location.getY() - (int) location.getY()) + 0.5 + getYOffset(), + location.getZ() + (location.getZ() - (int) location.getZ()) + 0.5 + ); } }