From 66d49727b8a86008f201742d2dc4583edf77ff96 Mon Sep 17 00:00:00 2001 From: filoghost Date: Wed, 25 Aug 2021 18:27:45 +0200 Subject: [PATCH] Rename HologramPosition to Position and Position to PositionCoordinates --- .../api/HolographicDisplaysAPI.java | 3 +-- .../HologramPosition.java => Position.java} | 18 +++++++++--------- .../api/hologram/Hologram.java | 5 +++-- .../HolographicDisplaysAPIProvider.java | 8 ++++---- ...{Position.java => PositionCoordinates.java} | 10 +++++----- .../entity/ClickableNMSPacketEntity.java | 4 ++-- .../nms/common/entity/ItemNMSPacketEntity.java | 4 ++-- .../nms/common/entity/NMSPacketEntity.java | 4 ++-- .../nms/common/entity/TextNMSPacketEntity.java | 6 +++--- .../v1_10_R1/EntityLivingSpawnNMSPacket.java | 4 ++-- .../nms/v1_10_R1/EntitySpawnNMSPacket.java | 4 ++-- .../nms/v1_10_R1/EntityTeleportNMSPacket.java | 4 ++-- .../VersionClickableNMSPacketEntity.java | 6 +++--- .../v1_10_R1/VersionItemNMSPacketEntity.java | 6 +++--- .../v1_10_R1/VersionTextNMSPacketEntity.java | 8 ++++---- .../v1_11_R1/EntityLivingSpawnNMSPacket.java | 4 ++-- .../nms/v1_11_R1/EntitySpawnNMSPacket.java | 4 ++-- .../nms/v1_11_R1/EntityTeleportNMSPacket.java | 4 ++-- .../VersionClickableNMSPacketEntity.java | 6 +++--- .../v1_11_R1/VersionItemNMSPacketEntity.java | 6 +++--- .../v1_11_R1/VersionTextNMSPacketEntity.java | 8 ++++---- .../v1_12_R1/EntityLivingSpawnNMSPacket.java | 4 ++-- .../nms/v1_12_R1/EntitySpawnNMSPacket.java | 4 ++-- .../nms/v1_12_R1/EntityTeleportNMSPacket.java | 4 ++-- .../VersionClickableNMSPacketEntity.java | 6 +++--- .../v1_12_R1/VersionItemNMSPacketEntity.java | 6 +++--- .../v1_12_R1/VersionTextNMSPacketEntity.java | 8 ++++---- .../v1_13_R2/EntityLivingSpawnNMSPacket.java | 4 ++-- .../nms/v1_13_R2/EntitySpawnNMSPacket.java | 4 ++-- .../nms/v1_13_R2/EntityTeleportNMSPacket.java | 4 ++-- .../VersionClickableNMSPacketEntity.java | 6 +++--- .../v1_13_R2/VersionItemNMSPacketEntity.java | 6 +++--- .../v1_13_R2/VersionTextNMSPacketEntity.java | 8 ++++---- .../v1_14_R1/EntityLivingSpawnNMSPacket.java | 4 ++-- .../nms/v1_14_R1/EntitySpawnNMSPacket.java | 4 ++-- .../nms/v1_14_R1/EntityTeleportNMSPacket.java | 4 ++-- .../VersionClickableNMSPacketEntity.java | 6 +++--- .../v1_14_R1/VersionItemNMSPacketEntity.java | 6 +++--- .../v1_14_R1/VersionTextNMSPacketEntity.java | 8 ++++---- .../v1_15_R1/EntityLivingSpawnNMSPacket.java | 4 ++-- .../nms/v1_15_R1/EntitySpawnNMSPacket.java | 4 ++-- .../nms/v1_15_R1/EntityTeleportNMSPacket.java | 4 ++-- .../VersionClickableNMSPacketEntity.java | 6 +++--- .../v1_15_R1/VersionItemNMSPacketEntity.java | 6 +++--- .../v1_15_R1/VersionTextNMSPacketEntity.java | 8 ++++---- .../v1_16_R1/EntityLivingSpawnNMSPacket.java | 4 ++-- .../nms/v1_16_R1/EntitySpawnNMSPacket.java | 4 ++-- .../nms/v1_16_R1/EntityTeleportNMSPacket.java | 4 ++-- .../VersionClickableNMSPacketEntity.java | 6 +++--- .../v1_16_R1/VersionItemNMSPacketEntity.java | 6 +++--- .../v1_16_R1/VersionTextNMSPacketEntity.java | 8 ++++---- .../v1_16_R2/EntityLivingSpawnNMSPacket.java | 4 ++-- .../nms/v1_16_R2/EntitySpawnNMSPacket.java | 4 ++-- .../nms/v1_16_R2/EntityTeleportNMSPacket.java | 4 ++-- .../VersionClickableNMSPacketEntity.java | 6 +++--- .../v1_16_R2/VersionItemNMSPacketEntity.java | 6 +++--- .../v1_16_R2/VersionTextNMSPacketEntity.java | 8 ++++---- .../v1_16_R3/EntityLivingSpawnNMSPacket.java | 4 ++-- .../nms/v1_16_R3/EntitySpawnNMSPacket.java | 4 ++-- .../nms/v1_16_R3/EntityTeleportNMSPacket.java | 4 ++-- .../VersionClickableNMSPacketEntity.java | 6 +++--- .../v1_16_R3/VersionItemNMSPacketEntity.java | 6 +++--- .../v1_16_R3/VersionTextNMSPacketEntity.java | 8 ++++---- .../v1_17_R1/EntityLivingSpawnNMSPacket.java | 4 ++-- .../nms/v1_17_R1/EntitySpawnNMSPacket.java | 4 ++-- .../nms/v1_17_R1/EntityTeleportNMSPacket.java | 4 ++-- .../VersionClickableNMSPacketEntity.java | 6 +++--- .../v1_17_R1/VersionItemNMSPacketEntity.java | 6 +++--- .../v1_17_R1/VersionTextNMSPacketEntity.java | 8 ++++---- .../v1_8_R3/EntityLivingSpawnNMSPacket.java | 4 ++-- .../nms/v1_8_R3/EntitySpawnNMSPacket.java | 4 ++-- .../nms/v1_8_R3/EntityTeleportNMSPacket.java | 4 ++-- .../VersionClickableNMSPacketEntity.java | 6 +++--- .../v1_8_R3/VersionItemNMSPacketEntity.java | 6 +++--- .../v1_8_R3/VersionTextNMSPacketEntity.java | 8 ++++---- .../v1_9_R2/EntityLivingSpawnNMSPacket.java | 4 ++-- .../nms/v1_9_R2/EntitySpawnNMSPacket.java | 4 ++-- .../nms/v1_9_R2/EntityTeleportNMSPacket.java | 4 ++-- .../VersionClickableNMSPacketEntity.java | 6 +++--- .../v1_9_R2/VersionItemNMSPacketEntity.java | 6 +++--- .../v1_9_R2/VersionTextNMSPacketEntity.java | 8 ++++---- .../plugin/api/current/APIHologram.java | 4 ++-- .../plugin/api/current/APIHologramManager.java | 4 ++-- .../current/DefaultHolographicDisplaysAPI.java | 10 +++++----- .../DefaultHolographicDisplaysAPIProvider.java | 16 ++++++++-------- .../plugin/api/v2/V2Hologram.java | 4 ++-- .../plugin/api/v2/V2HologramManager.java | 4 ++-- .../plugin/api/v2/V2HologramsAPIProvider.java | 4 ++-- .../commands/InternalHologramEditor.java | 4 ++-- .../plugin/commands/subs/AlignCommand.java | 6 +++--- .../plugin/commands/subs/CreateCommand.java | 4 ++-- .../plugin/commands/subs/NearCommand.java | 4 ++-- .../plugin/config/HologramConfig.java | 10 +++++----- .../plugin/format/DisplayFormat.java | 4 ++-- .../base/BaseClickableHologramLine.java | 4 ++-- .../plugin/hologram/base/BaseHologram.java | 12 ++++++------ .../plugin/hologram/base/BaseHologramLine.java | 8 ++++---- .../hologram/base/BaseHologramLines.java | 4 ++-- ...gramPosition.java => HologramPosition.java} | 10 +++++----- .../tracking/ClickableLineTracker.java | 4 ++-- .../hologram/tracking/CollisionHelper.java | 4 ++-- .../tracking/PositionBasedLineTracker.java | 6 +++--- .../internal/hologram/InternalHologram.java | 4 ++-- .../hologram/InternalHologramManager.java | 4 ++-- .../plugin/api/v2/V2HologramTest.java | 4 ++-- 105 files changed, 294 insertions(+), 294 deletions(-) rename api/src/main/java/me/filoghost/holographicdisplays/api/{hologram/HologramPosition.java => Position.java} (61%) rename common/src/main/java/me/filoghost/holographicdisplays/common/{Position.java => PositionCoordinates.java} (80%) rename plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/{WorldAwareHologramPosition.java => HologramPosition.java} (90%) diff --git a/api/src/main/java/me/filoghost/holographicdisplays/api/HolographicDisplaysAPI.java b/api/src/main/java/me/filoghost/holographicdisplays/api/HolographicDisplaysAPI.java index 7052f3d9..e1b79637 100644 --- a/api/src/main/java/me/filoghost/holographicdisplays/api/HolographicDisplaysAPI.java +++ b/api/src/main/java/me/filoghost/holographicdisplays/api/HolographicDisplaysAPI.java @@ -6,7 +6,6 @@ package me.filoghost.holographicdisplays.api; import me.filoghost.holographicdisplays.api.hologram.Hologram; -import me.filoghost.holographicdisplays.api.hologram.HologramPosition; import me.filoghost.holographicdisplays.api.internal.HolographicDisplaysAPIProvider; import me.filoghost.holographicdisplays.api.placeholder.PlaceholderReplacer; import org.bukkit.Location; @@ -65,7 +64,7 @@ public interface HolographicDisplaysAPI { */ @NotNull Hologram createHologram(@NotNull Location location); - @NotNull Hologram createHologram(@NotNull HologramPosition position); + @NotNull Hologram createHologram(@NotNull Position position); /** * Returns all the active holograms. A hologram is no longer active after {@link Hologram#delete()} is invoked. diff --git a/api/src/main/java/me/filoghost/holographicdisplays/api/hologram/HologramPosition.java b/api/src/main/java/me/filoghost/holographicdisplays/api/Position.java similarity index 61% rename from api/src/main/java/me/filoghost/holographicdisplays/api/hologram/HologramPosition.java rename to api/src/main/java/me/filoghost/holographicdisplays/api/Position.java index 03de5297..b2b38497 100644 --- a/api/src/main/java/me/filoghost/holographicdisplays/api/hologram/HologramPosition.java +++ b/api/src/main/java/me/filoghost/holographicdisplays/api/Position.java @@ -3,7 +3,7 @@ * * SPDX-License-Identifier: GPL-3.0-or-later */ -package me.filoghost.holographicdisplays.api.hologram; +package me.filoghost.holographicdisplays.api; import me.filoghost.holographicdisplays.api.internal.HolographicDisplaysAPIProvider; import org.bukkit.Location; @@ -11,18 +11,18 @@ import org.bukkit.World; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; -public interface HologramPosition { +public interface Position { - static @NotNull HologramPosition create(@NotNull World world, double x, double y, double z) { - return HolographicDisplaysAPIProvider.getImplementation().createHologramPosition(world, x, y, z); + static @NotNull Position create(@NotNull World world, double x, double y, double z) { + return HolographicDisplaysAPIProvider.getImplementation().createPosition(world, x, y, z); } - static @NotNull HologramPosition create(@NotNull String worldName, double x, double y, double z) { - return HolographicDisplaysAPIProvider.getImplementation().createHologramPosition(worldName, x, y, z); + static @NotNull Position create(@NotNull String worldName, double x, double y, double z) { + return HolographicDisplaysAPIProvider.getImplementation().createPosition(worldName, x, y, z); } - static @NotNull HologramPosition fromLocation(@NotNull Location location) { - return HolographicDisplaysAPIProvider.getImplementation().createHologramPosition(location); + static @NotNull Position fromLocation(@NotNull Location location) { + return HolographicDisplaysAPIProvider.getImplementation().createPosition(location); } @NotNull String getWorldName(); @@ -35,7 +35,7 @@ public interface HologramPosition { double getZ(); - @NotNull HologramPosition add(double x, double y, double z); + @NotNull Position add(double x, double y, double z); int getBlockX(); diff --git a/api/src/main/java/me/filoghost/holographicdisplays/api/hologram/Hologram.java b/api/src/main/java/me/filoghost/holographicdisplays/api/hologram/Hologram.java index f0d16e9d..ff997bb6 100644 --- a/api/src/main/java/me/filoghost/holographicdisplays/api/hologram/Hologram.java +++ b/api/src/main/java/me/filoghost/holographicdisplays/api/hologram/Hologram.java @@ -6,6 +6,7 @@ package me.filoghost.holographicdisplays.api.hologram; import me.filoghost.holographicdisplays.api.HolographicDisplaysAPI; +import me.filoghost.holographicdisplays.api.Position; import org.bukkit.Location; import org.bukkit.World; import org.jetbrains.annotations.NotNull; @@ -31,7 +32,7 @@ public interface Hologram { * @return the current position * @since 1 */ - @NotNull HologramPosition getPosition(); + @NotNull Position getPosition(); /** * Moves the hologram to the given position. @@ -39,7 +40,7 @@ public interface Hologram { * @param position the new position * @since 1 */ - void setPosition(@NotNull HologramPosition position); + void setPosition(@NotNull Position position); /** * Moves the hologram to the given position. diff --git a/api/src/main/java/me/filoghost/holographicdisplays/api/internal/HolographicDisplaysAPIProvider.java b/api/src/main/java/me/filoghost/holographicdisplays/api/internal/HolographicDisplaysAPIProvider.java index cd4a22a7..9eec544a 100644 --- a/api/src/main/java/me/filoghost/holographicdisplays/api/internal/HolographicDisplaysAPIProvider.java +++ b/api/src/main/java/me/filoghost/holographicdisplays/api/internal/HolographicDisplaysAPIProvider.java @@ -6,7 +6,7 @@ package me.filoghost.holographicdisplays.api.internal; import me.filoghost.holographicdisplays.api.HolographicDisplaysAPI; -import me.filoghost.holographicdisplays.api.hologram.HologramPosition; +import me.filoghost.holographicdisplays.api.Position; import org.bukkit.Location; import org.bukkit.World; import org.bukkit.plugin.Plugin; @@ -33,10 +33,10 @@ public abstract class HolographicDisplaysAPIProvider { public abstract HolographicDisplaysAPI getHolographicDisplaysAPI(Plugin plugin); - public abstract HologramPosition createHologramPosition(World world, double x, double y, double z); + public abstract Position createPosition(World world, double x, double y, double z); - public abstract HologramPosition createHologramPosition(String worldName, double x, double y, double z); + public abstract Position createPosition(String worldName, double x, double y, double z); - public abstract HologramPosition createHologramPosition(Location location); + public abstract Position createPosition(Location location); } diff --git a/common/src/main/java/me/filoghost/holographicdisplays/common/Position.java b/common/src/main/java/me/filoghost/holographicdisplays/common/PositionCoordinates.java similarity index 80% rename from common/src/main/java/me/filoghost/holographicdisplays/common/Position.java rename to common/src/main/java/me/filoghost/holographicdisplays/common/PositionCoordinates.java index b506aa29..0992c77c 100644 --- a/common/src/main/java/me/filoghost/holographicdisplays/common/Position.java +++ b/common/src/main/java/me/filoghost/holographicdisplays/common/PositionCoordinates.java @@ -5,11 +5,11 @@ */ package me.filoghost.holographicdisplays.common; -public final class Position { +public final class PositionCoordinates { private final double x, y, z; - public Position(double x, double y, double z) { + public PositionCoordinates(double x, double y, double z) { this.x = x; this.y = y; this.z = z; @@ -27,12 +27,12 @@ public final class Position { return z; } - public Position addY(double y) { + public PositionCoordinates addY(double y) { if (y == 0) { return this; } - return new Position(this.x, this.y + y, this.z); + return new PositionCoordinates(this.x, this.y + y, this.z); } @Override @@ -44,7 +44,7 @@ public final class Position { return false; } - Position other = (Position) obj; + PositionCoordinates other = (PositionCoordinates) obj; return Double.doubleToLongBits(this.x) == Double.doubleToLongBits(other.x) && Double.doubleToLongBits(this.y) == Double.doubleToLongBits(other.y) && Double.doubleToLongBits(this.z) == Double.doubleToLongBits(other.z); diff --git a/nms/common/src/main/java/me/filoghost/holographicdisplays/nms/common/entity/ClickableNMSPacketEntity.java b/nms/common/src/main/java/me/filoghost/holographicdisplays/nms/common/entity/ClickableNMSPacketEntity.java index 2d74c0aa..92774ee2 100644 --- a/nms/common/src/main/java/me/filoghost/holographicdisplays/nms/common/entity/ClickableNMSPacketEntity.java +++ b/nms/common/src/main/java/me/filoghost/holographicdisplays/nms/common/entity/ClickableNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.common.entity; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; @@ -16,6 +16,6 @@ public interface ClickableNMSPacketEntity extends NMSPacketEntity { EntityID getID(); - void addSpawnPackets(NMSPacketList packetList, Position position); + void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position); } diff --git a/nms/common/src/main/java/me/filoghost/holographicdisplays/nms/common/entity/ItemNMSPacketEntity.java b/nms/common/src/main/java/me/filoghost/holographicdisplays/nms/common/entity/ItemNMSPacketEntity.java index 8e82f0a2..0db1eb0c 100644 --- a/nms/common/src/main/java/me/filoghost/holographicdisplays/nms/common/entity/ItemNMSPacketEntity.java +++ b/nms/common/src/main/java/me/filoghost/holographicdisplays/nms/common/entity/ItemNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.common.entity; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import org.bukkit.inventory.ItemStack; @@ -14,7 +14,7 @@ public interface ItemNMSPacketEntity extends NMSPacketEntity { double ITEM_Y_OFFSET = 0; double ITEM_HEIGHT = 0.7; - void addSpawnPackets(NMSPacketList packetList, Position position, ItemStack itemStack); + void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, ItemStack itemStack); void addChangePackets(NMSPacketList packetList, ItemStack itemStack); diff --git a/nms/common/src/main/java/me/filoghost/holographicdisplays/nms/common/entity/NMSPacketEntity.java b/nms/common/src/main/java/me/filoghost/holographicdisplays/nms/common/entity/NMSPacketEntity.java index 4925673d..2c028e55 100644 --- a/nms/common/src/main/java/me/filoghost/holographicdisplays/nms/common/entity/NMSPacketEntity.java +++ b/nms/common/src/main/java/me/filoghost/holographicdisplays/nms/common/entity/NMSPacketEntity.java @@ -5,12 +5,12 @@ */ package me.filoghost.holographicdisplays.nms.common.entity; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; public interface NMSPacketEntity { - void addTeleportPackets(NMSPacketList packetList, Position position); + void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position); void addDestroyPackets(NMSPacketList packetList); diff --git a/nms/common/src/main/java/me/filoghost/holographicdisplays/nms/common/entity/TextNMSPacketEntity.java b/nms/common/src/main/java/me/filoghost/holographicdisplays/nms/common/entity/TextNMSPacketEntity.java index b74dedb8..1c060a58 100644 --- a/nms/common/src/main/java/me/filoghost/holographicdisplays/nms/common/entity/TextNMSPacketEntity.java +++ b/nms/common/src/main/java/me/filoghost/holographicdisplays/nms/common/entity/TextNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.common.entity; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.IndividualText; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; @@ -14,9 +14,9 @@ public interface TextNMSPacketEntity extends NMSPacketEntity { double ARMOR_STAND_Y_OFFSET = -0.29; double ARMOR_STAND_TEXT_HEIGHT = 0.23; - void addSpawnPackets(NMSPacketList packetList, Position position, String text); + void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, String text); - void addSpawnPackets(NMSPacketList packetList, Position position, IndividualText individualText); + void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, IndividualText individualText); void addChangePackets(NMSPacketList packetList, String text); diff --git a/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/EntityLivingSpawnNMSPacket.java b/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/EntityLivingSpawnNMSPacket.java index 3b434861..bc8c3245 100644 --- a/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/EntityLivingSpawnNMSPacket.java +++ b/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/EntityLivingSpawnNMSPacket.java @@ -6,7 +6,7 @@ package me.filoghost.holographicdisplays.nms.v1_10_R1; import me.filoghost.fcommons.reflection.ReflectField; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_10_R1.DataWatcher; import net.minecraft.server.v1_10_R1.Packet; @@ -35,7 +35,7 @@ class EntityLivingSpawnNMSPacket extends VersionNMSPacket { } public static DataWatcherPacketBuilder builder( - EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/EntitySpawnNMSPacket.java b/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/EntitySpawnNMSPacket.java index 32a32f2f..06cc962f 100644 --- a/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/EntitySpawnNMSPacket.java +++ b/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/EntitySpawnNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_10_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_10_R1.Packet; import net.minecraft.server.v1_10_R1.PacketPlayOutSpawnEntity; @@ -14,7 +14,7 @@ class EntitySpawnNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/EntityTeleportNMSPacket.java b/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/EntityTeleportNMSPacket.java index 078b8bd3..414d1448 100644 --- a/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/EntityTeleportNMSPacket.java +++ b/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/EntityTeleportNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_10_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_10_R1.Packet; import net.minecraft.server.v1_10_R1.PacketPlayOutEntityTeleport; @@ -14,7 +14,7 @@ class EntityTeleportNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntityTeleportNMSPacket(EntityID entityID, Position position, double positionOffsetY) { + EntityTeleportNMSPacket(EntityID entityID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/VersionClickableNMSPacketEntity.java b/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/VersionClickableNMSPacketEntity.java index d6d1543f..c18bd5e5 100644 --- a/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/VersionClickableNMSPacketEntity.java +++ b/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/VersionClickableNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_10_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ClickableNMSPacketEntity; @@ -24,7 +24,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(EntityLivingSpawnNMSPacket.builder(slimeID, EntityTypeID.SLIME, position, SLIME_Y_OFFSET) .setInvisible() .setSlimeSmall() // Required for a correct client-side collision box @@ -33,7 +33,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(slimeID, position, SLIME_Y_OFFSET)); } diff --git a/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/VersionItemNMSPacketEntity.java b/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/VersionItemNMSPacketEntity.java index 7b3dfaea..1f85a1f6 100644 --- a/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/VersionItemNMSPacketEntity.java +++ b/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/VersionItemNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_10_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ItemNMSPacketEntity; @@ -22,7 +22,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, ItemStack itemStack) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, ItemStack itemStack) { packetList.add(new EntitySpawnNMSPacket(vehicleID, EntityTypeID.ARMOR_STAND, position, ITEM_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(vehicleID) .setArmorStandMarker() @@ -45,7 +45,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(vehicleID, position, ITEM_Y_OFFSET)); } diff --git a/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/VersionTextNMSPacketEntity.java b/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/VersionTextNMSPacketEntity.java index f94185c5..46cd665d 100644 --- a/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/VersionTextNMSPacketEntity.java +++ b/nms/v1_10_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_10_R1/VersionTextNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_10_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.IndividualNMSPacket; import me.filoghost.holographicdisplays.nms.common.IndividualText; @@ -21,7 +21,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, String text) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, String text) { packetList.add(new EntitySpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(armorStandID) .setArmorStandMarker() @@ -31,7 +31,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, IndividualText individualText) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, IndividualText individualText) { packetList.add(new EntitySpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(new IndividualNMSPacket(player -> EntityMetadataNMSPacket.builder(armorStandID) @@ -59,7 +59,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(armorStandID, position, ARMOR_STAND_Y_OFFSET)); } diff --git a/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/EntityLivingSpawnNMSPacket.java b/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/EntityLivingSpawnNMSPacket.java index fb4a40bf..1431333d 100644 --- a/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/EntityLivingSpawnNMSPacket.java +++ b/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/EntityLivingSpawnNMSPacket.java @@ -6,7 +6,7 @@ package me.filoghost.holographicdisplays.nms.v1_11_R1; import me.filoghost.fcommons.reflection.ReflectField; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_11_R1.DataWatcher; import net.minecraft.server.v1_11_R1.Packet; @@ -35,7 +35,7 @@ class EntityLivingSpawnNMSPacket extends VersionNMSPacket { } public static DataWatcherPacketBuilder builder( - EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/EntitySpawnNMSPacket.java b/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/EntitySpawnNMSPacket.java index 11dfed3b..08cc27f1 100644 --- a/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/EntitySpawnNMSPacket.java +++ b/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/EntitySpawnNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_11_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_11_R1.Packet; import net.minecraft.server.v1_11_R1.PacketPlayOutSpawnEntity; @@ -14,7 +14,7 @@ class EntitySpawnNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/EntityTeleportNMSPacket.java b/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/EntityTeleportNMSPacket.java index 241f7445..e0aa6697 100644 --- a/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/EntityTeleportNMSPacket.java +++ b/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/EntityTeleportNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_11_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_11_R1.Packet; import net.minecraft.server.v1_11_R1.PacketPlayOutEntityTeleport; @@ -14,7 +14,7 @@ class EntityTeleportNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntityTeleportNMSPacket(EntityID entityID, Position position, double positionOffsetY) { + EntityTeleportNMSPacket(EntityID entityID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/VersionClickableNMSPacketEntity.java b/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/VersionClickableNMSPacketEntity.java index 1f0e9cfa..d835a987 100644 --- a/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/VersionClickableNMSPacketEntity.java +++ b/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/VersionClickableNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_11_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ClickableNMSPacketEntity; @@ -24,7 +24,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(EntityLivingSpawnNMSPacket.builder(slimeID, EntityTypeID.SLIME, position, SLIME_Y_OFFSET) .setInvisible() .setSlimeSmall() // Required for a correct client-side collision box @@ -33,7 +33,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(slimeID, position, SLIME_Y_OFFSET)); } diff --git a/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/VersionItemNMSPacketEntity.java b/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/VersionItemNMSPacketEntity.java index 055c2134..1e7f5af5 100644 --- a/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/VersionItemNMSPacketEntity.java +++ b/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/VersionItemNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_11_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ItemNMSPacketEntity; @@ -22,7 +22,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, ItemStack itemStack) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, ItemStack itemStack) { packetList.add(new EntitySpawnNMSPacket(vehicleID, EntityTypeID.ARMOR_STAND, position, ITEM_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(vehicleID) .setArmorStandMarker() @@ -45,7 +45,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(vehicleID, position, ITEM_Y_OFFSET)); } diff --git a/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/VersionTextNMSPacketEntity.java b/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/VersionTextNMSPacketEntity.java index 0a8f7f7e..e8eb727b 100644 --- a/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/VersionTextNMSPacketEntity.java +++ b/nms/v1_11_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_11_R1/VersionTextNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_11_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.IndividualNMSPacket; import me.filoghost.holographicdisplays.nms.common.IndividualText; @@ -21,7 +21,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, String text) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, String text) { packetList.add(new EntitySpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(armorStandID) .setArmorStandMarker() @@ -31,7 +31,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, IndividualText individualText) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, IndividualText individualText) { packetList.add(new EntitySpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(new IndividualNMSPacket(player -> EntityMetadataNMSPacket.builder(armorStandID) @@ -59,7 +59,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(armorStandID, position, ARMOR_STAND_Y_OFFSET)); } diff --git a/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/EntityLivingSpawnNMSPacket.java b/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/EntityLivingSpawnNMSPacket.java index f095795b..9f452c19 100644 --- a/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/EntityLivingSpawnNMSPacket.java +++ b/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/EntityLivingSpawnNMSPacket.java @@ -6,7 +6,7 @@ package me.filoghost.holographicdisplays.nms.v1_12_R1; import me.filoghost.fcommons.reflection.ReflectField; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_12_R1.DataWatcher; import net.minecraft.server.v1_12_R1.Packet; @@ -35,7 +35,7 @@ class EntityLivingSpawnNMSPacket extends VersionNMSPacket { } public static DataWatcherPacketBuilder builder( - EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/EntitySpawnNMSPacket.java b/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/EntitySpawnNMSPacket.java index 5277c04a..12550e7b 100644 --- a/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/EntitySpawnNMSPacket.java +++ b/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/EntitySpawnNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_12_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_12_R1.Packet; import net.minecraft.server.v1_12_R1.PacketPlayOutSpawnEntity; @@ -14,7 +14,7 @@ class EntitySpawnNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/EntityTeleportNMSPacket.java b/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/EntityTeleportNMSPacket.java index f18773c2..b19eb9b8 100644 --- a/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/EntityTeleportNMSPacket.java +++ b/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/EntityTeleportNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_12_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_12_R1.Packet; import net.minecraft.server.v1_12_R1.PacketPlayOutEntityTeleport; @@ -14,7 +14,7 @@ class EntityTeleportNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntityTeleportNMSPacket(EntityID entityID, Position position, double positionOffsetY) { + EntityTeleportNMSPacket(EntityID entityID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/VersionClickableNMSPacketEntity.java b/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/VersionClickableNMSPacketEntity.java index 75abefb8..0e3b8e74 100644 --- a/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/VersionClickableNMSPacketEntity.java +++ b/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/VersionClickableNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_12_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ClickableNMSPacketEntity; @@ -24,7 +24,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(EntityLivingSpawnNMSPacket.builder(slimeID, EntityTypeID.SLIME, position, SLIME_Y_OFFSET) .setInvisible() .setSlimeSmall() // Required for a correct client-side collision box @@ -33,7 +33,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(slimeID, position, SLIME_Y_OFFSET)); } diff --git a/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/VersionItemNMSPacketEntity.java b/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/VersionItemNMSPacketEntity.java index 498b36a6..01f67fe3 100644 --- a/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/VersionItemNMSPacketEntity.java +++ b/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/VersionItemNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_12_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ItemNMSPacketEntity; @@ -22,7 +22,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, ItemStack itemStack) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, ItemStack itemStack) { packetList.add(new EntitySpawnNMSPacket(vehicleID, EntityTypeID.ARMOR_STAND, position, ITEM_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(vehicleID) .setArmorStandMarker() @@ -45,7 +45,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(vehicleID, position, ITEM_Y_OFFSET)); } diff --git a/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/VersionTextNMSPacketEntity.java b/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/VersionTextNMSPacketEntity.java index 62ad97fc..e7a68566 100644 --- a/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/VersionTextNMSPacketEntity.java +++ b/nms/v1_12_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_12_R1/VersionTextNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_12_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.IndividualNMSPacket; import me.filoghost.holographicdisplays.nms.common.IndividualText; @@ -21,7 +21,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, String text) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, String text) { packetList.add(new EntitySpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(armorStandID) .setArmorStandMarker() @@ -31,7 +31,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, IndividualText individualText) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, IndividualText individualText) { packetList.add(new EntitySpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(new IndividualNMSPacket(player -> EntityMetadataNMSPacket.builder(armorStandID) @@ -59,7 +59,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(armorStandID, position, ARMOR_STAND_Y_OFFSET)); } diff --git a/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/EntityLivingSpawnNMSPacket.java b/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/EntityLivingSpawnNMSPacket.java index 4dad1996..50818675 100644 --- a/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/EntityLivingSpawnNMSPacket.java +++ b/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/EntityLivingSpawnNMSPacket.java @@ -6,7 +6,7 @@ package me.filoghost.holographicdisplays.nms.v1_13_R2; import me.filoghost.fcommons.reflection.ReflectField; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_13_R2.DataWatcher; import net.minecraft.server.v1_13_R2.Packet; @@ -35,7 +35,7 @@ class EntityLivingSpawnNMSPacket extends VersionNMSPacket { } public static DataWatcherPacketBuilder builder( - EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/EntitySpawnNMSPacket.java b/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/EntitySpawnNMSPacket.java index 19a6b0cf..dd176637 100644 --- a/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/EntitySpawnNMSPacket.java +++ b/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/EntitySpawnNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_13_R2; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_13_R2.Packet; import net.minecraft.server.v1_13_R2.PacketPlayOutSpawnEntity; @@ -14,7 +14,7 @@ class EntitySpawnNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/EntityTeleportNMSPacket.java b/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/EntityTeleportNMSPacket.java index 2ae7f789..709bbb95 100644 --- a/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/EntityTeleportNMSPacket.java +++ b/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/EntityTeleportNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_13_R2; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_13_R2.Packet; import net.minecraft.server.v1_13_R2.PacketPlayOutEntityTeleport; @@ -14,7 +14,7 @@ class EntityTeleportNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntityTeleportNMSPacket(EntityID entityID, Position position, double positionOffsetY) { + EntityTeleportNMSPacket(EntityID entityID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/VersionClickableNMSPacketEntity.java b/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/VersionClickableNMSPacketEntity.java index d48b16ac..78011651 100644 --- a/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/VersionClickableNMSPacketEntity.java +++ b/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/VersionClickableNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_13_R2; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ClickableNMSPacketEntity; @@ -24,7 +24,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(EntityLivingSpawnNMSPacket.builder(slimeID, EntityTypeID.SLIME, position, SLIME_Y_OFFSET) .setInvisible() .setSlimeSmall() // Required for a correct client-side collision box @@ -33,7 +33,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(slimeID, position, SLIME_Y_OFFSET)); } diff --git a/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/VersionItemNMSPacketEntity.java b/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/VersionItemNMSPacketEntity.java index 2f8faa5e..f7fd7574 100644 --- a/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/VersionItemNMSPacketEntity.java +++ b/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/VersionItemNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_13_R2; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ItemNMSPacketEntity; @@ -22,7 +22,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, ItemStack itemStack) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, ItemStack itemStack) { packetList.add(new EntitySpawnNMSPacket(vehicleID, EntityTypeID.ARMOR_STAND, position, ITEM_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(vehicleID) .setArmorStandMarker() @@ -45,7 +45,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(vehicleID, position, ITEM_Y_OFFSET)); } diff --git a/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/VersionTextNMSPacketEntity.java b/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/VersionTextNMSPacketEntity.java index bd19af80..6a173e27 100644 --- a/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/VersionTextNMSPacketEntity.java +++ b/nms/v1_13_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_13_R2/VersionTextNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_13_R2; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.IndividualNMSPacket; import me.filoghost.holographicdisplays.nms.common.IndividualText; @@ -21,7 +21,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, String text) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, String text) { packetList.add(new EntitySpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(armorStandID) .setArmorStandMarker() @@ -31,7 +31,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, IndividualText individualText) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, IndividualText individualText) { packetList.add(new EntitySpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(new IndividualNMSPacket(player -> EntityMetadataNMSPacket.builder(armorStandID) @@ -59,7 +59,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(armorStandID, position, ARMOR_STAND_Y_OFFSET)); } diff --git a/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/EntityLivingSpawnNMSPacket.java b/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/EntityLivingSpawnNMSPacket.java index 83584fe2..3bea182b 100644 --- a/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/EntityLivingSpawnNMSPacket.java +++ b/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/EntityLivingSpawnNMSPacket.java @@ -6,7 +6,7 @@ package me.filoghost.holographicdisplays.nms.v1_14_R1; import me.filoghost.fcommons.reflection.ReflectField; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_14_R1.DataWatcher; import net.minecraft.server.v1_14_R1.Packet; @@ -35,7 +35,7 @@ class EntityLivingSpawnNMSPacket extends VersionNMSPacket { } public static DataWatcherPacketBuilder builder( - EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/EntitySpawnNMSPacket.java b/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/EntitySpawnNMSPacket.java index cba0d8aa..77779a6d 100644 --- a/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/EntitySpawnNMSPacket.java +++ b/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/EntitySpawnNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_14_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_14_R1.Packet; import net.minecraft.server.v1_14_R1.PacketPlayOutSpawnEntity; @@ -14,7 +14,7 @@ class EntitySpawnNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/EntityTeleportNMSPacket.java b/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/EntityTeleportNMSPacket.java index 8ea442d7..8c00000b 100644 --- a/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/EntityTeleportNMSPacket.java +++ b/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/EntityTeleportNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_14_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_14_R1.Packet; import net.minecraft.server.v1_14_R1.PacketPlayOutEntityTeleport; @@ -14,7 +14,7 @@ class EntityTeleportNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntityTeleportNMSPacket(EntityID entityID, Position position, double positionOffsetY) { + EntityTeleportNMSPacket(EntityID entityID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/VersionClickableNMSPacketEntity.java b/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/VersionClickableNMSPacketEntity.java index 401ae21e..841c2cd4 100644 --- a/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/VersionClickableNMSPacketEntity.java +++ b/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/VersionClickableNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_14_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ClickableNMSPacketEntity; @@ -24,7 +24,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(EntityLivingSpawnNMSPacket.builder(slimeID, EntityTypeID.SLIME, position, SLIME_Y_OFFSET) .setInvisible() .setSlimeSmall() // Required for a correct client-side collision box @@ -33,7 +33,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(slimeID, position, SLIME_Y_OFFSET)); } diff --git a/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/VersionItemNMSPacketEntity.java b/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/VersionItemNMSPacketEntity.java index bbd0b284..08298eb3 100644 --- a/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/VersionItemNMSPacketEntity.java +++ b/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/VersionItemNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_14_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ItemNMSPacketEntity; @@ -22,7 +22,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, ItemStack itemStack) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, ItemStack itemStack) { packetList.add(EntityLivingSpawnNMSPacket.builder(vehicleID, EntityTypeID.ARMOR_STAND, position, ITEM_Y_OFFSET) .setArmorStandMarker() .build() @@ -44,7 +44,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(vehicleID, position, ITEM_Y_OFFSET)); } diff --git a/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/VersionTextNMSPacketEntity.java b/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/VersionTextNMSPacketEntity.java index 5ce006b8..7a317a8e 100644 --- a/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/VersionTextNMSPacketEntity.java +++ b/nms/v1_14_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_14_R1/VersionTextNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_14_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.IndividualNMSPacket; import me.filoghost.holographicdisplays.nms.common.IndividualText; @@ -21,7 +21,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, String text) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, String text) { packetList.add(EntityLivingSpawnNMSPacket.builder(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET) .setArmorStandMarker() .setCustomName(text) @@ -30,7 +30,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, IndividualText individualText) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, IndividualText individualText) { packetList.add(new IndividualNMSPacket(player -> EntityLivingSpawnNMSPacket.builder(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET) .setArmorStandMarker() @@ -57,7 +57,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(armorStandID, position, ARMOR_STAND_Y_OFFSET)); } diff --git a/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/EntityLivingSpawnNMSPacket.java b/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/EntityLivingSpawnNMSPacket.java index 50de448d..284b8082 100644 --- a/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/EntityLivingSpawnNMSPacket.java +++ b/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/EntityLivingSpawnNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_15_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_15_R1.Packet; import net.minecraft.server.v1_15_R1.PacketPlayOutSpawnEntityLiving; @@ -14,7 +14,7 @@ class EntityLivingSpawnNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntityLivingSpawnNMSPacket(EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntityLivingSpawnNMSPacket(EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/EntitySpawnNMSPacket.java b/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/EntitySpawnNMSPacket.java index 32a81548..c22ff511 100644 --- a/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/EntitySpawnNMSPacket.java +++ b/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/EntitySpawnNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_15_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_15_R1.Packet; import net.minecraft.server.v1_15_R1.PacketPlayOutSpawnEntity; @@ -14,7 +14,7 @@ class EntitySpawnNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/EntityTeleportNMSPacket.java b/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/EntityTeleportNMSPacket.java index 9dbf18db..5a34375a 100644 --- a/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/EntityTeleportNMSPacket.java +++ b/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/EntityTeleportNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_15_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_15_R1.Packet; import net.minecraft.server.v1_15_R1.PacketPlayOutEntityTeleport; @@ -14,7 +14,7 @@ class EntityTeleportNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntityTeleportNMSPacket(EntityID entityID, Position position, double positionOffsetY) { + EntityTeleportNMSPacket(EntityID entityID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/VersionClickableNMSPacketEntity.java b/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/VersionClickableNMSPacketEntity.java index e516541c..f5375ea5 100644 --- a/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/VersionClickableNMSPacketEntity.java +++ b/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/VersionClickableNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_15_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ClickableNMSPacketEntity; @@ -24,7 +24,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityLivingSpawnNMSPacket(slimeID, EntityTypeID.SLIME, position, SLIME_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(slimeID) .setInvisible() @@ -34,7 +34,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(slimeID, position, SLIME_Y_OFFSET)); } diff --git a/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/VersionItemNMSPacketEntity.java b/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/VersionItemNMSPacketEntity.java index f7846d68..3bccb574 100644 --- a/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/VersionItemNMSPacketEntity.java +++ b/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/VersionItemNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_15_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ItemNMSPacketEntity; @@ -22,7 +22,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, ItemStack itemStack) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, ItemStack itemStack) { packetList.add(new EntityLivingSpawnNMSPacket(vehicleID, EntityTypeID.ARMOR_STAND, position, ITEM_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(vehicleID) .setArmorStandMarker() @@ -45,7 +45,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(vehicleID, position, ITEM_Y_OFFSET)); } diff --git a/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/VersionTextNMSPacketEntity.java b/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/VersionTextNMSPacketEntity.java index 311ab1b7..67153010 100644 --- a/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/VersionTextNMSPacketEntity.java +++ b/nms/v1_15_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_15_R1/VersionTextNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_15_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.IndividualNMSPacket; import me.filoghost.holographicdisplays.nms.common.IndividualText; @@ -21,7 +21,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, String text) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, String text) { packetList.add(new EntityLivingSpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(armorStandID) .setArmorStandMarker() @@ -31,7 +31,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, IndividualText individualText) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, IndividualText individualText) { packetList.add(new EntityLivingSpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(new IndividualNMSPacket(player -> EntityMetadataNMSPacket.builder(armorStandID) @@ -59,7 +59,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(armorStandID, position, ARMOR_STAND_Y_OFFSET)); } diff --git a/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/EntityLivingSpawnNMSPacket.java b/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/EntityLivingSpawnNMSPacket.java index 24d495fe..0e9d7b97 100644 --- a/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/EntityLivingSpawnNMSPacket.java +++ b/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/EntityLivingSpawnNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_16_R1.Packet; import net.minecraft.server.v1_16_R1.PacketPlayOutSpawnEntityLiving; @@ -14,7 +14,7 @@ class EntityLivingSpawnNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntityLivingSpawnNMSPacket(EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntityLivingSpawnNMSPacket(EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/EntitySpawnNMSPacket.java b/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/EntitySpawnNMSPacket.java index 9fab5704..9d658bd9 100644 --- a/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/EntitySpawnNMSPacket.java +++ b/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/EntitySpawnNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_16_R1.Packet; import net.minecraft.server.v1_16_R1.PacketPlayOutSpawnEntity; @@ -14,7 +14,7 @@ class EntitySpawnNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/EntityTeleportNMSPacket.java b/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/EntityTeleportNMSPacket.java index 5870612c..0dd2f379 100644 --- a/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/EntityTeleportNMSPacket.java +++ b/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/EntityTeleportNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_16_R1.Packet; import net.minecraft.server.v1_16_R1.PacketPlayOutEntityTeleport; @@ -14,7 +14,7 @@ class EntityTeleportNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntityTeleportNMSPacket(EntityID entityID, Position position, double positionOffsetY) { + EntityTeleportNMSPacket(EntityID entityID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/VersionClickableNMSPacketEntity.java b/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/VersionClickableNMSPacketEntity.java index 8047dcec..4c7d7027 100644 --- a/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/VersionClickableNMSPacketEntity.java +++ b/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/VersionClickableNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ClickableNMSPacketEntity; @@ -24,7 +24,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityLivingSpawnNMSPacket(slimeID, EntityTypeID.SLIME, position, SLIME_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(slimeID) .setInvisible() @@ -34,7 +34,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(slimeID, position, SLIME_Y_OFFSET)); } diff --git a/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/VersionItemNMSPacketEntity.java b/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/VersionItemNMSPacketEntity.java index 7075afc0..41219496 100644 --- a/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/VersionItemNMSPacketEntity.java +++ b/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/VersionItemNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ItemNMSPacketEntity; @@ -22,7 +22,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, ItemStack itemStack) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, ItemStack itemStack) { packetList.add(new EntityLivingSpawnNMSPacket(vehicleID, EntityTypeID.ARMOR_STAND, position, ITEM_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(vehicleID) .setArmorStandMarker() @@ -45,7 +45,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(vehicleID, position, ITEM_Y_OFFSET)); } diff --git a/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/VersionTextNMSPacketEntity.java b/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/VersionTextNMSPacketEntity.java index 37d4abbf..175b423b 100644 --- a/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/VersionTextNMSPacketEntity.java +++ b/nms/v1_16_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R1/VersionTextNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.IndividualNMSPacket; import me.filoghost.holographicdisplays.nms.common.IndividualText; @@ -21,7 +21,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, String text) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, String text) { packetList.add(new EntityLivingSpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(armorStandID) .setArmorStandMarker() @@ -31,7 +31,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, IndividualText individualText) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, IndividualText individualText) { packetList.add(new EntityLivingSpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(new IndividualNMSPacket(player -> EntityMetadataNMSPacket.builder(armorStandID) @@ -59,7 +59,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(armorStandID, position, ARMOR_STAND_Y_OFFSET)); } diff --git a/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/EntityLivingSpawnNMSPacket.java b/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/EntityLivingSpawnNMSPacket.java index e696fe37..9e1244c0 100644 --- a/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/EntityLivingSpawnNMSPacket.java +++ b/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/EntityLivingSpawnNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R2; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_16_R2.Packet; import net.minecraft.server.v1_16_R2.PacketPlayOutSpawnEntityLiving; @@ -14,7 +14,7 @@ class EntityLivingSpawnNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntityLivingSpawnNMSPacket(EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntityLivingSpawnNMSPacket(EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/EntitySpawnNMSPacket.java b/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/EntitySpawnNMSPacket.java index 9a58ddc7..0fe5987f 100644 --- a/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/EntitySpawnNMSPacket.java +++ b/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/EntitySpawnNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R2; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_16_R2.Packet; import net.minecraft.server.v1_16_R2.PacketPlayOutSpawnEntity; @@ -14,7 +14,7 @@ class EntitySpawnNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/EntityTeleportNMSPacket.java b/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/EntityTeleportNMSPacket.java index 00f5afa9..87817817 100644 --- a/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/EntityTeleportNMSPacket.java +++ b/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/EntityTeleportNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R2; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_16_R2.Packet; import net.minecraft.server.v1_16_R2.PacketPlayOutEntityTeleport; @@ -14,7 +14,7 @@ class EntityTeleportNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntityTeleportNMSPacket(EntityID entityID, Position position, double positionOffsetY) { + EntityTeleportNMSPacket(EntityID entityID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/VersionClickableNMSPacketEntity.java b/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/VersionClickableNMSPacketEntity.java index 9a1728f1..f51d204e 100644 --- a/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/VersionClickableNMSPacketEntity.java +++ b/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/VersionClickableNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R2; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ClickableNMSPacketEntity; @@ -24,7 +24,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityLivingSpawnNMSPacket(slimeID, EntityTypeID.SLIME, position, SLIME_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(slimeID) .setInvisible() @@ -34,7 +34,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(slimeID, position, SLIME_Y_OFFSET)); } diff --git a/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/VersionItemNMSPacketEntity.java b/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/VersionItemNMSPacketEntity.java index a4fabcde..d790ca76 100644 --- a/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/VersionItemNMSPacketEntity.java +++ b/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/VersionItemNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R2; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ItemNMSPacketEntity; @@ -22,7 +22,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, ItemStack itemStack) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, ItemStack itemStack) { packetList.add(new EntityLivingSpawnNMSPacket(vehicleID, EntityTypeID.ARMOR_STAND, position, ITEM_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(vehicleID) .setArmorStandMarker() @@ -45,7 +45,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(vehicleID, position, ITEM_Y_OFFSET)); } diff --git a/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/VersionTextNMSPacketEntity.java b/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/VersionTextNMSPacketEntity.java index 5dac3453..15058bfb 100644 --- a/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/VersionTextNMSPacketEntity.java +++ b/nms/v1_16_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R2/VersionTextNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R2; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.IndividualNMSPacket; import me.filoghost.holographicdisplays.nms.common.IndividualText; @@ -21,7 +21,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, String text) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, String text) { packetList.add(new EntityLivingSpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(armorStandID) .setArmorStandMarker() @@ -31,7 +31,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, IndividualText individualText) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, IndividualText individualText) { packetList.add(new EntityLivingSpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(new IndividualNMSPacket(player -> EntityMetadataNMSPacket.builder(armorStandID) @@ -59,7 +59,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(armorStandID, position, ARMOR_STAND_Y_OFFSET)); } diff --git a/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/EntityLivingSpawnNMSPacket.java b/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/EntityLivingSpawnNMSPacket.java index 9b4c3406..73a3b5b6 100644 --- a/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/EntityLivingSpawnNMSPacket.java +++ b/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/EntityLivingSpawnNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R3; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_16_R3.Packet; import net.minecraft.server.v1_16_R3.PacketPlayOutSpawnEntityLiving; @@ -14,7 +14,7 @@ class EntityLivingSpawnNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntityLivingSpawnNMSPacket(EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntityLivingSpawnNMSPacket(EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/EntitySpawnNMSPacket.java b/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/EntitySpawnNMSPacket.java index 360cbac5..69b8bba6 100644 --- a/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/EntitySpawnNMSPacket.java +++ b/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/EntitySpawnNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R3; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_16_R3.Packet; import net.minecraft.server.v1_16_R3.PacketPlayOutSpawnEntity; @@ -14,7 +14,7 @@ class EntitySpawnNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/EntityTeleportNMSPacket.java b/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/EntityTeleportNMSPacket.java index 5f885714..28d1dbc8 100644 --- a/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/EntityTeleportNMSPacket.java +++ b/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/EntityTeleportNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R3; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_16_R3.Packet; import net.minecraft.server.v1_16_R3.PacketPlayOutEntityTeleport; @@ -14,7 +14,7 @@ class EntityTeleportNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntityTeleportNMSPacket(EntityID entityID, Position position, double positionOffsetY) { + EntityTeleportNMSPacket(EntityID entityID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/VersionClickableNMSPacketEntity.java b/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/VersionClickableNMSPacketEntity.java index f3cea9b2..1352bb27 100644 --- a/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/VersionClickableNMSPacketEntity.java +++ b/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/VersionClickableNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R3; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ClickableNMSPacketEntity; @@ -24,7 +24,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityLivingSpawnNMSPacket(slimeID, EntityTypeID.SLIME, position, SLIME_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(slimeID) .setInvisible() @@ -34,7 +34,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(slimeID, position, SLIME_Y_OFFSET)); } diff --git a/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/VersionItemNMSPacketEntity.java b/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/VersionItemNMSPacketEntity.java index 140be897..692a2747 100644 --- a/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/VersionItemNMSPacketEntity.java +++ b/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/VersionItemNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R3; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ItemNMSPacketEntity; @@ -22,7 +22,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, ItemStack itemStack) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, ItemStack itemStack) { packetList.add(new EntityLivingSpawnNMSPacket(vehicleID, EntityTypeID.ARMOR_STAND, position, ITEM_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(vehicleID) .setArmorStandMarker() @@ -45,7 +45,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(vehicleID, position, ITEM_Y_OFFSET)); } diff --git a/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/VersionTextNMSPacketEntity.java b/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/VersionTextNMSPacketEntity.java index b1a207ca..65f91509 100644 --- a/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/VersionTextNMSPacketEntity.java +++ b/nms/v1_16_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_16_R3/VersionTextNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_16_R3; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.IndividualNMSPacket; import me.filoghost.holographicdisplays.nms.common.IndividualText; @@ -21,7 +21,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, String text) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, String text) { packetList.add(new EntityLivingSpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(armorStandID) .setArmorStandMarker() @@ -31,7 +31,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, IndividualText individualText) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, IndividualText individualText) { packetList.add(new EntityLivingSpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(new IndividualNMSPacket(player -> EntityMetadataNMSPacket.builder(armorStandID) @@ -59,7 +59,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(armorStandID, position, ARMOR_STAND_Y_OFFSET)); } diff --git a/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/EntityLivingSpawnNMSPacket.java b/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/EntityLivingSpawnNMSPacket.java index 4efea159..1cb60c1a 100644 --- a/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/EntityLivingSpawnNMSPacket.java +++ b/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/EntityLivingSpawnNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_17_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.network.protocol.Packet; import net.minecraft.network.protocol.game.PacketPlayOutSpawnEntityLiving; @@ -14,7 +14,7 @@ class EntityLivingSpawnNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntityLivingSpawnNMSPacket(EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntityLivingSpawnNMSPacket(EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/EntitySpawnNMSPacket.java b/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/EntitySpawnNMSPacket.java index 9c6450e6..eabba365 100644 --- a/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/EntitySpawnNMSPacket.java +++ b/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/EntitySpawnNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_17_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.network.protocol.Packet; import net.minecraft.network.protocol.game.PacketPlayOutSpawnEntity; @@ -14,7 +14,7 @@ class EntitySpawnNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/EntityTeleportNMSPacket.java b/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/EntityTeleportNMSPacket.java index 4817509f..4d5d701d 100644 --- a/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/EntityTeleportNMSPacket.java +++ b/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/EntityTeleportNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_17_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.network.protocol.Packet; import net.minecraft.network.protocol.game.PacketPlayOutEntityTeleport; @@ -14,7 +14,7 @@ class EntityTeleportNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntityTeleportNMSPacket(EntityID entityID, Position position, double positionOffsetY) { + EntityTeleportNMSPacket(EntityID entityID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/VersionClickableNMSPacketEntity.java b/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/VersionClickableNMSPacketEntity.java index 982ad8cd..aedce929 100644 --- a/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/VersionClickableNMSPacketEntity.java +++ b/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/VersionClickableNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_17_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ClickableNMSPacketEntity; @@ -24,7 +24,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityLivingSpawnNMSPacket(slimeID, EntityTypeID.SLIME, position, SLIME_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(slimeID) .setInvisible() @@ -34,7 +34,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(slimeID, position, SLIME_Y_OFFSET)); } diff --git a/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/VersionItemNMSPacketEntity.java b/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/VersionItemNMSPacketEntity.java index 7ea1b0d0..80f5c2dd 100644 --- a/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/VersionItemNMSPacketEntity.java +++ b/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/VersionItemNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_17_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ItemNMSPacketEntity; @@ -22,7 +22,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, ItemStack itemStack) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, ItemStack itemStack) { packetList.add(new EntityLivingSpawnNMSPacket(vehicleID, EntityTypeID.ARMOR_STAND, position, ITEM_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(vehicleID) .setArmorStandMarker() @@ -45,7 +45,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(vehicleID, position, ITEM_Y_OFFSET)); } diff --git a/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/VersionTextNMSPacketEntity.java b/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/VersionTextNMSPacketEntity.java index fbd31edd..47f225bb 100644 --- a/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/VersionTextNMSPacketEntity.java +++ b/nms/v1_17_r1/src/main/java/me/filoghost/holographicdisplays/nms/v1_17_R1/VersionTextNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_17_R1; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.IndividualNMSPacket; import me.filoghost.holographicdisplays.nms.common.IndividualText; @@ -21,7 +21,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, String text) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, String text) { packetList.add(new EntityLivingSpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(armorStandID) .setArmorStandMarker() @@ -31,7 +31,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, IndividualText individualText) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, IndividualText individualText) { packetList.add(new EntityLivingSpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(new IndividualNMSPacket(player -> EntityMetadataNMSPacket.builder(armorStandID) @@ -59,7 +59,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(armorStandID, position, ARMOR_STAND_Y_OFFSET)); } diff --git a/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/EntityLivingSpawnNMSPacket.java b/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/EntityLivingSpawnNMSPacket.java index 3a34a829..8350fb25 100644 --- a/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/EntityLivingSpawnNMSPacket.java +++ b/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/EntityLivingSpawnNMSPacket.java @@ -6,7 +6,7 @@ package me.filoghost.holographicdisplays.nms.v1_8_R3; import me.filoghost.fcommons.reflection.ReflectField; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_8_R3.DataWatcher; import net.minecraft.server.v1_8_R3.MathHelper; @@ -36,7 +36,7 @@ class EntityLivingSpawnNMSPacket extends VersionNMSPacket { } public static DataWatcherPacketBuilder builder( - EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/EntitySpawnNMSPacket.java b/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/EntitySpawnNMSPacket.java index 19269ad2..5042a3c0 100644 --- a/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/EntitySpawnNMSPacket.java +++ b/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/EntitySpawnNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_8_R3; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_8_R3.MathHelper; import net.minecraft.server.v1_8_R3.Packet; @@ -15,7 +15,7 @@ class EntitySpawnNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/EntityTeleportNMSPacket.java b/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/EntityTeleportNMSPacket.java index bd2b3592..7b5512eb 100644 --- a/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/EntityTeleportNMSPacket.java +++ b/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/EntityTeleportNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_8_R3; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_8_R3.MathHelper; import net.minecraft.server.v1_8_R3.Packet; @@ -15,7 +15,7 @@ class EntityTeleportNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntityTeleportNMSPacket(EntityID entityID, Position position, double positionOffsetY) { + EntityTeleportNMSPacket(EntityID entityID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/VersionClickableNMSPacketEntity.java b/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/VersionClickableNMSPacketEntity.java index d78c67db..736b67e1 100644 --- a/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/VersionClickableNMSPacketEntity.java +++ b/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/VersionClickableNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_8_R3; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ClickableNMSPacketEntity; @@ -24,7 +24,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(EntityLivingSpawnNMSPacket.builder(slimeID, EntityTypeID.SLIME, position, SLIME_Y_OFFSET) .setInvisible() .setSlimeSmall() // Required for a correct client-side collision box @@ -33,7 +33,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(slimeID, position, SLIME_Y_OFFSET)); } diff --git a/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/VersionItemNMSPacketEntity.java b/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/VersionItemNMSPacketEntity.java index 6244d1f6..2559ebc1 100644 --- a/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/VersionItemNMSPacketEntity.java +++ b/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/VersionItemNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_8_R3; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ItemNMSPacketEntity; @@ -22,7 +22,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, ItemStack itemStack) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, ItemStack itemStack) { packetList.add(new EntitySpawnNMSPacket(vehicleID, EntityTypeID.ARMOR_STAND, position, ITEM_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(vehicleID) .setArmorStandMarker() @@ -45,7 +45,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(vehicleID, position, ITEM_Y_OFFSET)); } diff --git a/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/VersionTextNMSPacketEntity.java b/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/VersionTextNMSPacketEntity.java index 4dacf648..abdb1198 100644 --- a/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/VersionTextNMSPacketEntity.java +++ b/nms/v1_8_r3/src/main/java/me/filoghost/holographicdisplays/nms/v1_8_R3/VersionTextNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_8_R3; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.IndividualNMSPacket; import me.filoghost.holographicdisplays.nms.common.IndividualText; @@ -21,7 +21,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, String text) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, String text) { packetList.add(new EntitySpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(armorStandID) .setArmorStandMarker() @@ -31,7 +31,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, IndividualText individualText) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, IndividualText individualText) { packetList.add(new EntitySpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(new IndividualNMSPacket(player -> EntityMetadataNMSPacket.builder(armorStandID) @@ -59,7 +59,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(armorStandID, position, ARMOR_STAND_Y_OFFSET)); } diff --git a/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/EntityLivingSpawnNMSPacket.java b/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/EntityLivingSpawnNMSPacket.java index 4bc02576..e9c3a5f4 100644 --- a/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/EntityLivingSpawnNMSPacket.java +++ b/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/EntityLivingSpawnNMSPacket.java @@ -6,7 +6,7 @@ package me.filoghost.holographicdisplays.nms.v1_9_R2; import me.filoghost.fcommons.reflection.ReflectField; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_9_R2.DataWatcher; import net.minecraft.server.v1_9_R2.Packet; @@ -35,7 +35,7 @@ class EntityLivingSpawnNMSPacket extends VersionNMSPacket { } public static DataWatcherPacketBuilder builder( - EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/EntitySpawnNMSPacket.java b/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/EntitySpawnNMSPacket.java index 3868a403..4edd3fb6 100644 --- a/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/EntitySpawnNMSPacket.java +++ b/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/EntitySpawnNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_9_R2; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_9_R2.Packet; import net.minecraft.server.v1_9_R2.PacketPlayOutSpawnEntity; @@ -14,7 +14,7 @@ class EntitySpawnNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, Position position, double positionOffsetY) { + EntitySpawnNMSPacket(EntityID entityID, int entityTypeID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/EntityTeleportNMSPacket.java b/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/EntityTeleportNMSPacket.java index 2d78c060..18cbdcda 100644 --- a/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/EntityTeleportNMSPacket.java +++ b/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/EntityTeleportNMSPacket.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_9_R2; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import net.minecraft.server.v1_9_R2.Packet; import net.minecraft.server.v1_9_R2.PacketPlayOutEntityTeleport; @@ -14,7 +14,7 @@ class EntityTeleportNMSPacket extends VersionNMSPacket { private final Packet rawPacket; - EntityTeleportNMSPacket(EntityID entityID, Position position, double positionOffsetY) { + EntityTeleportNMSPacket(EntityID entityID, PositionCoordinates position, double positionOffsetY) { PacketByteBuffer packetByteBuffer = PacketByteBuffer.get(); packetByteBuffer.writeVarInt(entityID.getNumericID()); diff --git a/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/VersionClickableNMSPacketEntity.java b/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/VersionClickableNMSPacketEntity.java index 92e2800e..fa3ab4d0 100644 --- a/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/VersionClickableNMSPacketEntity.java +++ b/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/VersionClickableNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_9_R2; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ClickableNMSPacketEntity; @@ -24,7 +24,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(EntityLivingSpawnNMSPacket.builder(slimeID, EntityTypeID.SLIME, position, SLIME_Y_OFFSET) .setInvisible() .setSlimeSmall() // Required for a correct client-side collision box @@ -33,7 +33,7 @@ public class VersionClickableNMSPacketEntity implements ClickableNMSPacketEntity } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(slimeID, position, SLIME_Y_OFFSET)); } diff --git a/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/VersionItemNMSPacketEntity.java b/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/VersionItemNMSPacketEntity.java index 366bcc7c..0b09a774 100644 --- a/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/VersionItemNMSPacketEntity.java +++ b/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/VersionItemNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_9_R2; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ItemNMSPacketEntity; @@ -22,7 +22,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, ItemStack itemStack) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, ItemStack itemStack) { packetList.add(new EntitySpawnNMSPacket(vehicleID, EntityTypeID.ARMOR_STAND, position, ITEM_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(vehicleID) .setArmorStandMarker() @@ -45,7 +45,7 @@ public class VersionItemNMSPacketEntity implements ItemNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(vehicleID, position, ITEM_Y_OFFSET)); } diff --git a/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/VersionTextNMSPacketEntity.java b/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/VersionTextNMSPacketEntity.java index 67af41a1..2fae6bea 100644 --- a/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/VersionTextNMSPacketEntity.java +++ b/nms/v1_9_r2/src/main/java/me/filoghost/holographicdisplays/nms/v1_9_R2/VersionTextNMSPacketEntity.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.nms.v1_9_R2; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.EntityID; import me.filoghost.holographicdisplays.nms.common.IndividualNMSPacket; import me.filoghost.holographicdisplays.nms.common.IndividualText; @@ -21,7 +21,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, String text) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, String text) { packetList.add(new EntitySpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(EntityMetadataNMSPacket.builder(armorStandID) .setArmorStandMarker() @@ -31,7 +31,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addSpawnPackets(NMSPacketList packetList, Position position, IndividualText individualText) { + public void addSpawnPackets(NMSPacketList packetList, PositionCoordinates position, IndividualText individualText) { packetList.add(new EntitySpawnNMSPacket(armorStandID, EntityTypeID.ARMOR_STAND, position, ARMOR_STAND_Y_OFFSET)); packetList.add(new IndividualNMSPacket(player -> EntityMetadataNMSPacket.builder(armorStandID) @@ -59,7 +59,7 @@ class VersionTextNMSPacketEntity implements TextNMSPacketEntity { } @Override - public void addTeleportPackets(NMSPacketList packetList, Position position) { + public void addTeleportPackets(NMSPacketList packetList, PositionCoordinates position) { packetList.add(new EntityTeleportNMSPacket(armorStandID, position, ARMOR_STAND_Y_OFFSET)); } diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/current/APIHologram.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/current/APIHologram.java index 996bc63a..d792d514 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/current/APIHologram.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/current/APIHologram.java @@ -8,7 +8,7 @@ package me.filoghost.holographicdisplays.plugin.api.current; import me.filoghost.fcommons.Preconditions; import me.filoghost.holographicdisplays.api.hologram.Hologram; import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologram; -import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramPosition; +import me.filoghost.holographicdisplays.plugin.hologram.base.ImmutablePosition; import me.filoghost.holographicdisplays.plugin.hologram.tracking.LineTrackerManager; import org.bukkit.entity.Player; import org.bukkit.plugin.Plugin; @@ -24,7 +24,7 @@ public class APIHologram extends BaseHologram implements Hologram { private boolean allowPlaceholders; protected APIHologram( - BaseHologramPosition position, + ImmutablePosition position, Plugin plugin, APIHologramManager apiHologramManager, LineTrackerManager lineTrackerManager) { diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/current/APIHologramManager.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/current/APIHologramManager.java index a2a0fb87..7ebb0945 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/current/APIHologramManager.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/current/APIHologramManager.java @@ -7,7 +7,7 @@ package me.filoghost.holographicdisplays.plugin.api.current; import me.filoghost.holographicdisplays.api.hologram.Hologram; import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramManager; -import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramPosition; +import me.filoghost.holographicdisplays.plugin.hologram.base.ImmutablePosition; import me.filoghost.holographicdisplays.plugin.hologram.tracking.LineTrackerManager; import org.bukkit.plugin.Plugin; @@ -24,7 +24,7 @@ public class APIHologramManager extends BaseHologramManager { this.lineTrackerManager = lineTrackerManager; } - public APIHologram createHologram(BaseHologramPosition position, Plugin plugin) { + public APIHologram createHologram(ImmutablePosition position, Plugin plugin) { APIHologram hologram = new APIHologram(position, plugin, this, lineTrackerManager); super.addHologram(hologram); return hologram; diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/current/DefaultHolographicDisplaysAPI.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/current/DefaultHolographicDisplaysAPI.java index 0957b92b..bb2cb808 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/current/DefaultHolographicDisplaysAPI.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/current/DefaultHolographicDisplaysAPI.java @@ -8,9 +8,9 @@ package me.filoghost.holographicdisplays.plugin.api.current; import me.filoghost.fcommons.Preconditions; import me.filoghost.holographicdisplays.api.HolographicDisplaysAPI; import me.filoghost.holographicdisplays.api.hologram.Hologram; -import me.filoghost.holographicdisplays.api.hologram.HologramPosition; +import me.filoghost.holographicdisplays.api.Position; import me.filoghost.holographicdisplays.api.placeholder.PlaceholderReplacer; -import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramPosition; +import me.filoghost.holographicdisplays.plugin.hologram.base.ImmutablePosition; import me.filoghost.holographicdisplays.plugin.placeholder.registry.PlaceholderRegistry; import org.bukkit.Location; import org.bukkit.plugin.Plugin; @@ -36,16 +36,16 @@ class DefaultHolographicDisplaysAPI implements HolographicDisplaysAPI { Preconditions.notNull(location.getWorld(), "location.getWorld()"); Preconditions.checkMainThread("async hologram creation"); - return apiHologramManager.createHologram(new BaseHologramPosition(location), plugin); + return apiHologramManager.createHologram(new ImmutablePosition(location), plugin); } @Override - public @NotNull Hologram createHologram(@NotNull HologramPosition position) { + public @NotNull Hologram createHologram(@NotNull Position position) { Preconditions.notNull(position, "position"); Preconditions.notNull(position.getWorldName(), "position world name"); Preconditions.checkMainThread("async hologram creation"); - return apiHologramManager.createHologram(new BaseHologramPosition(position), plugin); + return apiHologramManager.createHologram(new ImmutablePosition(position), plugin); } @Override diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/current/DefaultHolographicDisplaysAPIProvider.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/current/DefaultHolographicDisplaysAPIProvider.java index a92e489d..3070c965 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/current/DefaultHolographicDisplaysAPIProvider.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/current/DefaultHolographicDisplaysAPIProvider.java @@ -7,9 +7,9 @@ package me.filoghost.holographicdisplays.plugin.api.current; import me.filoghost.fcommons.Preconditions; import me.filoghost.holographicdisplays.api.HolographicDisplaysAPI; -import me.filoghost.holographicdisplays.api.hologram.HologramPosition; +import me.filoghost.holographicdisplays.api.Position; import me.filoghost.holographicdisplays.api.internal.HolographicDisplaysAPIProvider; -import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramPosition; +import me.filoghost.holographicdisplays.plugin.hologram.base.ImmutablePosition; import me.filoghost.holographicdisplays.plugin.placeholder.registry.PlaceholderRegistry; import org.bukkit.Location; import org.bukkit.World; @@ -41,19 +41,19 @@ public class DefaultHolographicDisplaysAPIProvider extends HolographicDisplaysAP } @Override - public HologramPosition createHologramPosition(World world, double x, double y, double z) { + public Position createPosition(World world, double x, double y, double z) { Preconditions.notNull(world, "world"); - return new BaseHologramPosition(world.getName(), x, y, z); + return new ImmutablePosition(world.getName(), x, y, z); } @Override - public HologramPosition createHologramPosition(String worldName, double x, double y, double z) { - return new BaseHologramPosition(worldName, x, y, z); + public Position createPosition(String worldName, double x, double y, double z) { + return new ImmutablePosition(worldName, x, y, z); } @Override - public HologramPosition createHologramPosition(Location location) { - return new BaseHologramPosition(location); + public Position createPosition(Location location) { + return new ImmutablePosition(location); } } diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/v2/V2Hologram.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/v2/V2Hologram.java index 853e0554..1aee5c43 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/v2/V2Hologram.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/v2/V2Hologram.java @@ -12,7 +12,7 @@ import com.gmail.filoghost.holographicdisplays.api.line.ItemLine; import com.gmail.filoghost.holographicdisplays.api.line.TextLine; import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologram; import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramLines; -import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramPosition; +import me.filoghost.holographicdisplays.plugin.hologram.base.ImmutablePosition; import me.filoghost.holographicdisplays.plugin.hologram.tracking.LineTrackerManager; import org.bukkit.Location; import org.bukkit.World; @@ -31,7 +31,7 @@ public class V2Hologram extends BaseHologram implements Hologram { private boolean allowPlaceholders; public V2Hologram( - BaseHologramPosition position, + ImmutablePosition position, Plugin plugin, LineTrackerManager lineTrackerManager, V2HologramManager hologramManager) { diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/v2/V2HologramManager.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/v2/V2HologramManager.java index ed638b6b..241b8107 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/v2/V2HologramManager.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/v2/V2HologramManager.java @@ -6,7 +6,7 @@ package me.filoghost.holographicdisplays.plugin.api.v2; import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramManager; -import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramPosition; +import me.filoghost.holographicdisplays.plugin.hologram.base.ImmutablePosition; import me.filoghost.holographicdisplays.plugin.hologram.tracking.LineTrackerManager; import org.bukkit.plugin.Plugin; @@ -18,7 +18,7 @@ public class V2HologramManager extends BaseHologramManager { this.lineTrackerManager = lineTrackerManager; } - public V2Hologram createHologram(BaseHologramPosition position, Plugin plugin) { + public V2Hologram createHologram(ImmutablePosition position, Plugin plugin) { V2Hologram hologram = new V2Hologram(position, plugin, lineTrackerManager, this); super.addHologram(hologram); return hologram; diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/v2/V2HologramsAPIProvider.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/v2/V2HologramsAPIProvider.java index 4ee80041..bd595251 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/v2/V2HologramsAPIProvider.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/api/v2/V2HologramsAPIProvider.java @@ -9,7 +9,7 @@ import com.gmail.filoghost.holographicdisplays.api.Hologram; import com.gmail.filoghost.holographicdisplays.api.internal.HologramsAPIProvider; import com.gmail.filoghost.holographicdisplays.api.placeholder.PlaceholderReplacer; import me.filoghost.fcommons.Preconditions; -import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramPosition; +import me.filoghost.holographicdisplays.plugin.hologram.base.ImmutablePosition; import me.filoghost.holographicdisplays.plugin.placeholder.registry.PlaceholderRegistry; import org.bukkit.Location; import org.bukkit.entity.Entity; @@ -38,7 +38,7 @@ public class V2HologramsAPIProvider extends HologramsAPIProvider { Preconditions.notNull(source.getWorld(), "source.getWorld()"); Preconditions.checkMainThread("async hologram creation"); - return hologramManager.createHologram(new BaseHologramPosition(source), plugin); + return hologramManager.createHologram(new ImmutablePosition(source), plugin); } @Override diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/commands/InternalHologramEditor.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/commands/InternalHologramEditor.java index 2de409ff..0f13ecbe 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/commands/InternalHologramEditor.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/commands/InternalHologramEditor.java @@ -13,7 +13,7 @@ import me.filoghost.holographicdisplays.plugin.config.HologramLineParser; import me.filoghost.holographicdisplays.plugin.config.HologramLoadException; import me.filoghost.holographicdisplays.plugin.event.InternalHologramChangeEvent; import me.filoghost.holographicdisplays.plugin.event.InternalHologramChangeEvent.ChangeType; -import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramPosition; +import me.filoghost.holographicdisplays.plugin.hologram.base.ImmutablePosition; import me.filoghost.holographicdisplays.plugin.internal.hologram.InternalHologram; import me.filoghost.holographicdisplays.plugin.internal.hologram.InternalHologramLine; import me.filoghost.holographicdisplays.plugin.internal.hologram.InternalHologramManager; @@ -73,7 +73,7 @@ public class InternalHologramEditor { return internalHologramManager.getHolograms(); } - public InternalHologram create(BaseHologramPosition spawnPosition, String hologramName) { + public InternalHologram create(ImmutablePosition spawnPosition, String hologramName) { return internalHologramManager.createHologram(spawnPosition, hologramName); } diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/commands/subs/AlignCommand.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/commands/subs/AlignCommand.java index 66dddf13..a4004972 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/commands/subs/AlignCommand.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/commands/subs/AlignCommand.java @@ -12,7 +12,7 @@ import me.filoghost.holographicdisplays.plugin.commands.HologramSubCommand; import me.filoghost.holographicdisplays.plugin.commands.InternalHologramEditor; import me.filoghost.holographicdisplays.plugin.event.InternalHologramChangeEvent.ChangeType; import me.filoghost.holographicdisplays.plugin.format.ColorScheme; -import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramPosition; +import me.filoghost.holographicdisplays.plugin.hologram.base.ImmutablePosition; import me.filoghost.holographicdisplays.plugin.internal.hologram.InternalHologram; import org.bukkit.command.CommandSender; @@ -36,8 +36,8 @@ public class AlignCommand extends HologramSubCommand { CommandValidate.check(hologram != referenceHologram, "The holograms must not be the same."); - BaseHologramPosition referencePosition = referenceHologram.getPosition(); - BaseHologramPosition newPosition = hologram.getPosition(); + ImmutablePosition referencePosition = referenceHologram.getPosition(); + ImmutablePosition newPosition = hologram.getPosition(); String axis = args[0]; if (axis.equalsIgnoreCase("x")) { diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/commands/subs/CreateCommand.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/commands/subs/CreateCommand.java index 8dbd3e50..c9304ffa 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/commands/subs/CreateCommand.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/commands/subs/CreateCommand.java @@ -13,7 +13,7 @@ import me.filoghost.holographicdisplays.plugin.commands.HologramSubCommand; import me.filoghost.holographicdisplays.plugin.commands.InternalHologramEditor; import me.filoghost.holographicdisplays.plugin.event.InternalHologramChangeEvent.ChangeType; import me.filoghost.holographicdisplays.plugin.format.ColorScheme; -import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramPosition; +import me.filoghost.holographicdisplays.plugin.hologram.base.ImmutablePosition; import me.filoghost.holographicdisplays.plugin.internal.hologram.InternalHologram; import me.filoghost.holographicdisplays.plugin.internal.hologram.InternalHologramLine; import net.md_5.bungee.api.ChatColor; @@ -46,7 +46,7 @@ public class CreateCommand extends HologramSubCommand { "The name must contain only alphanumeric characters, underscores and hyphens."); CommandValidate.check(!hologramEditor.hologramExists(hologramName), "A hologram with that name already exists."); - BaseHologramPosition spawnPosition = new BaseHologramPosition(player.getLocation()); + ImmutablePosition spawnPosition = new ImmutablePosition(player.getLocation()); boolean moveUp = player.isOnGround(); if (moveUp) { diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/commands/subs/NearCommand.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/commands/subs/NearCommand.java index 00693777..b6c7475e 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/commands/subs/NearCommand.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/commands/subs/NearCommand.java @@ -11,7 +11,7 @@ import me.filoghost.fcommons.command.validation.CommandValidate; import me.filoghost.holographicdisplays.plugin.commands.HologramSubCommand; import me.filoghost.holographicdisplays.plugin.commands.InternalHologramEditor; import me.filoghost.holographicdisplays.plugin.format.DisplayFormat; -import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramPosition; +import me.filoghost.holographicdisplays.plugin.hologram.base.ImmutablePosition; import me.filoghost.holographicdisplays.plugin.internal.hologram.InternalHologram; import org.bukkit.World; import org.bukkit.command.CommandSender; @@ -43,7 +43,7 @@ public class NearCommand extends HologramSubCommand { List nearHolograms = new ArrayList<>(); for (InternalHologram hologram : hologramEditor.getHolograms()) { - BaseHologramPosition position = hologram.getPosition(); + ImmutablePosition position = hologram.getPosition(); if (position.isInWorld(world) && position.distance(player.getLocation()) <= radius) { nearHolograms.add(hologram); } diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/config/HologramConfig.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/config/HologramConfig.java index 605190fc..a9153ecc 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/config/HologramConfig.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/config/HologramConfig.java @@ -7,7 +7,7 @@ package me.filoghost.holographicdisplays.plugin.config; import me.filoghost.fcommons.config.ConfigSection; import me.filoghost.fcommons.config.exception.ConfigValueException; -import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramPosition; +import me.filoghost.holographicdisplays.plugin.hologram.base.ImmutablePosition; import me.filoghost.holographicdisplays.plugin.internal.hologram.InternalHologram; import me.filoghost.holographicdisplays.plugin.internal.hologram.InternalHologramLine; import me.filoghost.holographicdisplays.plugin.internal.hologram.InternalHologramManager; @@ -34,7 +34,7 @@ public class HologramConfig { serializedLines.add(line.getSerializedConfigValue()); } - BaseHologramPosition position = hologram.getPosition(); + ImmutablePosition position = hologram.getPosition(); this.positionConfigSection = new ConfigSection(); positionConfigSection.setString("world", position.getWorldName()); positionConfigSection.setDouble("x", position.getX()); @@ -57,7 +57,7 @@ public class HologramConfig { throw new HologramLoadException("no position set"); } - BaseHologramPosition position = parsePosition(); + ImmutablePosition position = parsePosition(); InternalHologram hologram = internalHologramManager.createHologram(position, name); List lines = new ArrayList<>(); @@ -73,13 +73,13 @@ public class HologramConfig { hologram.lines().addAll(lines); } - private BaseHologramPosition parsePosition() throws HologramLoadException { + private ImmutablePosition parsePosition() throws HologramLoadException { try { String worldName = positionConfigSection.getRequiredString("world"); double x = positionConfigSection.getRequiredDouble("x"); double y = positionConfigSection.getRequiredDouble("y"); double z = positionConfigSection.getRequiredDouble("z"); - return new BaseHologramPosition(worldName, x, y, z); + return new ImmutablePosition(worldName, x, y, z); } catch (ConfigValueException e) { throw new HologramLoadException("invalid position attribute \"" + e.getConfigPath() + "\"", e); } diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/format/DisplayFormat.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/format/DisplayFormat.java index 8029b117..65755b72 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/format/DisplayFormat.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/format/DisplayFormat.java @@ -8,7 +8,7 @@ package me.filoghost.holographicdisplays.plugin.format; import me.filoghost.fcommons.Colors; import me.filoghost.holographicdisplays.plugin.config.StaticReplacements; -import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramPosition; +import me.filoghost.holographicdisplays.plugin.hologram.base.ImmutablePosition; import me.filoghost.holographicdisplays.plugin.internal.hologram.InternalHologram; import net.md_5.bungee.api.ChatColor; import net.md_5.bungee.api.chat.ClickEvent; @@ -87,7 +87,7 @@ public class DisplayFormat { } public static void sendHologramSummary(CommandSender sender, InternalHologram hologram, boolean showWorld) { - BaseHologramPosition position = hologram.getPosition(); + ImmutablePosition position = hologram.getPosition(); sender.sendMessage(ColorScheme.SECONDARY_DARK + "- " + ColorScheme.SECONDARY_BOLD + hologram.getName() + ColorScheme.SECONDARY_DARK + " (" + hologram.lines().size() + " lines) at " + (showWorld ? "world: \"" + position.getWorldName() + "\", " : "") diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/BaseClickableHologramLine.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/BaseClickableHologramLine.java index f0e7f858..2a75d82a 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/BaseClickableHologramLine.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/BaseClickableHologramLine.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.plugin.hologram.base; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import org.bukkit.Location; import org.bukkit.entity.Player; @@ -23,7 +23,7 @@ public abstract class BaseClickableHologramLine extends BaseHologramLine impleme private boolean isInClickRange(Player player) { Location playerLocation = player.getLocation(); - Position position = this.getPosition(); + PositionCoordinates position = this.getPosition(); double xDiff = playerLocation.getX() - position.getX(); double yDiff = playerLocation.getY() + 1.3 - position.getY(); // Use shoulder height diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/BaseHologram.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/BaseHologram.java index 31679d99..8f4de8e6 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/BaseHologram.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/BaseHologram.java @@ -6,7 +6,7 @@ package me.filoghost.holographicdisplays.plugin.hologram.base; import me.filoghost.fcommons.Preconditions; -import me.filoghost.holographicdisplays.api.hologram.HologramPosition; +import me.filoghost.holographicdisplays.api.Position; import me.filoghost.holographicdisplays.plugin.hologram.tracking.LineTrackerManager; import org.bukkit.Chunk; import org.bukkit.Location; @@ -18,11 +18,11 @@ import org.jetbrains.annotations.Nullable; public abstract class BaseHologram extends BaseHologramComponent { - private final WorldAwareHologramPosition position; + private final HologramPosition position; private final LineTrackerManager lineTrackerManager; - public BaseHologram(BaseHologramPosition position, LineTrackerManager lineTrackerManager) { - this.position = new WorldAwareHologramPosition(position); + public BaseHologram(ImmutablePosition position, LineTrackerManager lineTrackerManager) { + this.position = new HologramPosition(position); this.lineTrackerManager = lineTrackerManager; } @@ -42,7 +42,7 @@ public abstract class BaseHologram extends BaseHologramComponent { lines().setDeleted(); } - public @NotNull BaseHologramPosition getPosition() { + public @NotNull ImmutablePosition getPosition() { return position.getPosition(); } @@ -50,7 +50,7 @@ public abstract class BaseHologram extends BaseHologramComponent { return position.getWorldIfLoaded(); } - public void setPosition(@NotNull HologramPosition position) { + public void setPosition(@NotNull Position position) { Preconditions.notNull(position, "position"); setPosition(position.getWorldName(), position.getX(), position.getY(), position.getZ()); } diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/BaseHologramLine.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/BaseHologramLine.java index 534c1d6b..3941bc53 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/BaseHologramLine.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/BaseHologramLine.java @@ -6,7 +6,7 @@ package me.filoghost.holographicdisplays.plugin.hologram.base; import me.filoghost.fcommons.Preconditions; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.plugin.hologram.tracking.LineTracker; import me.filoghost.holographicdisplays.plugin.hologram.tracking.LineTrackerManager; import org.bukkit.GameMode; @@ -21,7 +21,7 @@ public abstract class BaseHologramLine extends BaseHologramComponent implements private final BaseHologram hologram; private final LineTracker tracker; - private Position position; + private PositionCoordinates position; protected BaseHologramLine(BaseHologram hologram) { Preconditions.notNull(hologram, "hologram"); @@ -41,11 +41,11 @@ public abstract class BaseHologramLine extends BaseHologramComponent implements @Override public final void setPosition(double x, double y, double z) { - position = new Position(x, y, z); + position = new PositionCoordinates(x, y, z); setChanged(); } - public @NotNull Position getPosition() { + public @NotNull PositionCoordinates getPosition() { if (position == null) { throw new IllegalStateException("position not set"); } diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/BaseHologramLines.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/BaseHologramLines.java index 306671e7..bc374f77 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/BaseHologramLines.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/BaseHologramLines.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.plugin.hologram.base; -import me.filoghost.holographicdisplays.api.hologram.HologramPosition; +import me.filoghost.holographicdisplays.api.Position; import me.filoghost.holographicdisplays.plugin.config.Settings; import org.jetbrains.annotations.NotNull; @@ -116,7 +116,7 @@ public class BaseHologramLines implements Iterab * The second line is below the first, and so on. */ public void updatePositions() { - HologramPosition hologramPosition = hologram.getPosition(); + Position hologramPosition = hologram.getPosition(); double currentLineY = hologramPosition.getY(); for (int i = 0; i < lines.size(); i++) { diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/WorldAwareHologramPosition.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/HologramPosition.java similarity index 90% rename from plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/WorldAwareHologramPosition.java rename to plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/HologramPosition.java index 9643c55e..270a153a 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/WorldAwareHologramPosition.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/base/HologramPosition.java @@ -14,14 +14,14 @@ import org.bukkit.World; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; -class WorldAwareHologramPosition { +class HologramPosition { - private @NotNull BaseHologramPosition position; + private @NotNull ImmutablePosition position; private @Nullable World world; private int chunkX, chunkZ; private final CachedBoolean chunkLoaded; - WorldAwareHologramPosition(@NotNull BaseHologramPosition position) { + HologramPosition(@NotNull ImmutablePosition position) { Preconditions.notNull(position, "position"); this.position = position; this.world = Bukkit.getWorld(position.getWorldName()); @@ -35,7 +35,7 @@ class WorldAwareHologramPosition { int chunkX = getChunkCoordinate(x); int chunkZ = getChunkCoordinate(z); - position = new BaseHologramPosition(worldName, x, y, z); + position = new ImmutablePosition(worldName, x, y, z); if (worldChanged || this.chunkX != chunkX || this.chunkZ != chunkZ) { if (worldChanged) { @@ -85,7 +85,7 @@ class WorldAwareHologramPosition { return world; } - @NotNull BaseHologramPosition getPosition() { + @NotNull ImmutablePosition getPosition() { return position; } diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/tracking/ClickableLineTracker.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/tracking/ClickableLineTracker.java index bb7acd94..3fd306cf 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/tracking/ClickableLineTracker.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/tracking/ClickableLineTracker.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.plugin.hologram.tracking; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import me.filoghost.holographicdisplays.nms.common.NMSManager; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.nms.common.entity.ClickableNMSPacketEntity; @@ -98,7 +98,7 @@ public abstract class ClickableLineTracker } } - private Position getClickableEntityPosition() { + private PositionCoordinates getClickableEntityPosition() { return position.addY(positionOffsetY); } diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/tracking/CollisionHelper.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/tracking/CollisionHelper.java index 1b4f22a4..b7aae87c 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/tracking/CollisionHelper.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/tracking/CollisionHelper.java @@ -5,7 +5,7 @@ */ package me.filoghost.holographicdisplays.plugin.hologram.tracking; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import org.bukkit.Location; import org.bukkit.entity.Player; @@ -25,7 +25,7 @@ public class CollisionHelper { private static final double REQUIRED_DISTANCE_Z = REQUIRED_DISTANCE_X; private static final double REQUIRED_DISTANCE_Y = PLAYER_HEIGHT_RADIUS + PLAYER_GROW_HEIGHT + ITEM_HEIGHT_RADIUS; - public static boolean isInPickupRange(Player player, Position itemPosition) { + public static boolean isInPickupRange(Player player, PositionCoordinates itemPosition) { /* * Normally, the server determines if a player is picking up a dropped item * by checking if the bounding boxes of the player and the item intersect. diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/tracking/PositionBasedLineTracker.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/tracking/PositionBasedLineTracker.java index df32b934..a9e872de 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/tracking/PositionBasedLineTracker.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/hologram/tracking/PositionBasedLineTracker.java @@ -7,7 +7,7 @@ package me.filoghost.holographicdisplays.plugin.hologram.tracking; import me.filoghost.holographicdisplays.nms.common.NMSPacketList; import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramLine; -import me.filoghost.holographicdisplays.common.Position; +import me.filoghost.holographicdisplays.common.PositionCoordinates; import org.bukkit.Location; import org.bukkit.entity.Player; import org.jetbrains.annotations.MustBeInvokedByOverriders; @@ -18,7 +18,7 @@ abstract class PositionBasedLineTracker extends Line private static final int ENTITY_VIEW_RANGE = 64; - protected Position position; + protected PositionCoordinates position; private boolean positionChanged; PositionBasedLineTracker(T line) { @@ -28,7 +28,7 @@ abstract class PositionBasedLineTracker extends Line @MustBeInvokedByOverriders @Override protected void detectChanges() { - Position position = line.getPosition(); + PositionCoordinates position = line.getPosition(); if (!Objects.equals(this.position, position)) { this.position = position; this.positionChanged = true; diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/internal/hologram/InternalHologram.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/internal/hologram/InternalHologram.java index f745976f..745bad9f 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/internal/hologram/InternalHologram.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/internal/hologram/InternalHologram.java @@ -8,7 +8,7 @@ package me.filoghost.holographicdisplays.plugin.internal.hologram; import me.filoghost.holographicdisplays.plugin.HolographicDisplays; import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologram; import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramLines; -import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramPosition; +import me.filoghost.holographicdisplays.plugin.hologram.base.ImmutablePosition; import me.filoghost.holographicdisplays.plugin.hologram.tracking.LineTrackerManager; import org.bukkit.entity.Player; import org.bukkit.inventory.ItemStack; @@ -19,7 +19,7 @@ public class InternalHologram extends BaseHologram { private final BaseHologramLines lines; private final String name; - protected InternalHologram(BaseHologramPosition position, String name, LineTrackerManager lineTrackerManager) { + protected InternalHologram(ImmutablePosition position, String name, LineTrackerManager lineTrackerManager) { super(position, lineTrackerManager); this.lines = new BaseHologramLines<>(this); this.name = name; diff --git a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/internal/hologram/InternalHologramManager.java b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/internal/hologram/InternalHologramManager.java index 843bd52b..ce394e3e 100644 --- a/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/internal/hologram/InternalHologramManager.java +++ b/plugin/src/main/java/me/filoghost/holographicdisplays/plugin/internal/hologram/InternalHologramManager.java @@ -6,7 +6,7 @@ package me.filoghost.holographicdisplays.plugin.internal.hologram; import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramManager; -import me.filoghost.holographicdisplays.plugin.hologram.base.BaseHologramPosition; +import me.filoghost.holographicdisplays.plugin.hologram.base.ImmutablePosition; import me.filoghost.holographicdisplays.plugin.hologram.tracking.LineTrackerManager; public class InternalHologramManager extends BaseHologramManager { @@ -17,7 +17,7 @@ public class InternalHologramManager extends BaseHologramManager