From 5d0d83bb90b240a065599e5144a91181c6212ca6 Mon Sep 17 00:00:00 2001 From: md_5 Date: Sun, 26 Aug 2018 18:26:09 +1000 Subject: SPIGOT-4309: Add "forced" display of particles --- src/main/java/org/bukkit/craftbukkit/CraftWorld.java | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'src/main/java') diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java index 303481a0..90451598 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java @@ -1566,6 +1566,16 @@ public class CraftWorld implements World { @Override public void spawnParticle(Particle particle, double x, double y, double z, int count, double offsetX, double offsetY, double offsetZ, double extra, T data) { + spawnParticle(particle, x, y, z, count, offsetX, offsetY, offsetZ, extra, data, false); + } + + @Override + public void spawnParticle(Particle particle, Location location, int count, double offsetX, double offsetY, double offsetZ, double extra, T data, boolean force) { + spawnParticle(particle, location.getX(), location.getY(), location.getZ(), count, offsetX, offsetY, offsetZ, extra, data, force); + } + + @Override + public void spawnParticle(Particle particle, double x, double y, double z, int count, double offsetX, double offsetY, double offsetZ, double extra, T data, boolean force) { if (data != null && !particle.getDataType().isInstance(data)) { throw new IllegalArgumentException("data should be " + particle.getDataType() + " got " + data.getClass()); } @@ -1575,7 +1585,8 @@ public class CraftWorld implements World { x, y, z, // Position count, // Count offsetX, offsetY, offsetZ, // Random offset - extra // Speed? + extra, // Speed? + force ); } -- cgit v1.2.3