custom hit box

This commit is contained in:
zimzaza4
2024-03-31 21:35:59 +08:00
parent bb2e8d0fdf
commit fb42a208bb
4 changed files with 33 additions and 1 deletions

View File

@@ -59,4 +59,10 @@ public class PlayerUtils {
player.sendPluginMessage(GeyserUtils.getInstance(), GeyserUtilsChannels.MAIN, GeyserUtils.getPacketManager().encodePacket(skinPayloadPacket));
}
public static void sendCustomHitBox(Player player, Entity entity, float height, float width) {
CustomHitBoxPacket packet = new CustomHitBoxPacket(entity.getEntityId(), height, width);
player.sendPluginMessage(GeyserUtils.getInstance(), GeyserUtilsChannels.MAIN, GeyserUtils.getPacketManager().encodePacket(packet));
}
}