2021-06-11 14:02:28 +02:00
|
|
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
|
|
From: Esophose <esophose@gmail.com>
|
|
|
|
Date: Sat, 3 Oct 2020 18:57:47 -0600
|
|
|
|
Subject: [PATCH] Fix Player spawnParticle x/y/z precision loss
|
|
|
|
|
|
|
|
|
|
|
|
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
2023-12-12 07:02:06 +01:00
|
|
|
index bb5c1a3ce83d737ac218a5b590b585916ac2d4d7..b3cbd7779ca2046d952352a9cb9f509e8525b344 100644
|
2021-06-11 14:02:28 +02:00
|
|
|
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
|
|
|
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
2023-12-09 00:13:02 +01:00
|
|
|
@@ -2562,7 +2562,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
2023-06-13 01:51:45 +02:00
|
|
|
if (data != null) {
|
|
|
|
Preconditions.checkArgument(particle.getDataType().isInstance(data), "data (%s) should be %s", data.getClass(), particle.getDataType());
|
2021-06-11 14:02:28 +02:00
|
|
|
}
|
2023-10-26 23:56:40 +02:00
|
|
|
- ClientboundLevelParticlesPacket packetplayoutworldparticles = new ClientboundLevelParticlesPacket(CraftParticle.createParticleParam(particle, data), true, (float) x, (float) y, (float) z, (float) offsetX, (float) offsetY, (float) offsetZ, (float) extra, count);
|
|
|
|
+ ClientboundLevelParticlesPacket packetplayoutworldparticles = new ClientboundLevelParticlesPacket(CraftParticle.createParticleParam(particle, data), true, x, y, z, (float) offsetX, (float) offsetY, (float) offsetZ, (float) extra, count); // Paper - Fix x/y/z coordinate precision loss
|
2021-06-14 18:58:00 +02:00
|
|
|
this.getHandle().connection.send(packetplayoutworldparticles);
|
2021-06-11 14:02:28 +02:00
|
|
|
|
|
|
|
}
|