mirror of
https://github.com/PaperMC/Paper.git
synced 2025-05-19 05:30:23 -07:00
Hide soul speed particles for vanished players (#12152)
Co-authored-by: Tamion <70228790+notTamion@users.noreply.github.com>
This commit is contained in:
parent
7b4d44f573
commit
e5a8ee849f
@ -870,11 +870,11 @@
|
|||||||
double zOffset,
|
double zOffset,
|
||||||
double speed
|
double speed
|
||||||
) {
|
) {
|
||||||
+ // CraftBukkit start - visibility api support
|
+ // Paper start - visibility api support
|
||||||
+ return this.sendParticlesSource(null, type, overrideLimiter, alwaysShow, posX, posY, posZ, particleCount, xOffset, yOffset, zOffset, speed);
|
+ return this.sendParticlesSource(null, type, overrideLimiter, alwaysShow, posX, posY, posZ, particleCount, xOffset, yOffset, zOffset, speed);
|
||||||
+ }
|
+ }
|
||||||
+ public <T extends ParticleOptions> int sendParticlesSource(
|
+ public <T extends ParticleOptions> int sendParticlesSource(
|
||||||
+ @javax.annotation.Nullable ServerPlayer sender,
|
+ @javax.annotation.Nullable Entity sender,
|
||||||
+ T type,
|
+ T type,
|
||||||
+ boolean overrideLimiter,
|
+ boolean overrideLimiter,
|
||||||
+ boolean alwaysShow,
|
+ boolean alwaysShow,
|
||||||
@ -891,7 +891,7 @@
|
|||||||
+ }
|
+ }
|
||||||
+ public <T extends ParticleOptions> int sendParticlesSource(
|
+ public <T extends ParticleOptions> int sendParticlesSource(
|
||||||
+ List<ServerPlayer> receivers,
|
+ List<ServerPlayer> receivers,
|
||||||
+ @javax.annotation.Nullable ServerPlayer sender,
|
+ @javax.annotation.Nullable Entity sender,
|
||||||
+ T type,
|
+ T type,
|
||||||
+ boolean overrideLimiter,
|
+ boolean overrideLimiter,
|
||||||
+ boolean alwaysShow,
|
+ boolean alwaysShow,
|
||||||
@ -904,7 +904,7 @@
|
|||||||
+ double zOffset,
|
+ double zOffset,
|
||||||
+ double speed
|
+ double speed
|
||||||
+ ) {
|
+ ) {
|
||||||
+ // CraftBukkit end - visibility api support
|
+ // Paper end - visibility api support
|
||||||
ClientboundLevelParticlesPacket clientboundLevelParticlesPacket = new ClientboundLevelParticlesPacket(
|
ClientboundLevelParticlesPacket clientboundLevelParticlesPacket = new ClientboundLevelParticlesPacket(
|
||||||
type, overrideLimiter, alwaysShow, posX, posY, posZ, (float)xOffset, (float)yOffset, (float)zOffset, (float)speed, particleCount
|
type, overrideLimiter, alwaysShow, posX, posY, posZ, (float)xOffset, (float)yOffset, (float)zOffset, (float)speed, particleCount
|
||||||
);
|
);
|
||||||
|
@ -0,0 +1,17 @@
|
|||||||
|
--- a/net/minecraft/world/item/enchantment/effects/SpawnParticlesEffect.java
|
||||||
|
+++ b/net/minecraft/world/item/enchantment/effects/SpawnParticlesEffect.java
|
||||||
|
@@ -58,8 +_,13 @@
|
||||||
|
Vec3 knownMovement = entity.getKnownMovement();
|
||||||
|
float bbWidth = entity.getBbWidth();
|
||||||
|
float bbHeight = entity.getBbHeight();
|
||||||
|
- level.sendParticles(
|
||||||
|
+ // Paper start - Hide soul speed particles for vanished players
|
||||||
|
+ level.sendParticlesSource(
|
||||||
|
+ entity,
|
||||||
|
this.particle,
|
||||||
|
+ false,
|
||||||
|
+ false,
|
||||||
|
+ // Paper end - Hide soul speed particles for vanished players
|
||||||
|
this.horizontalPosition.getCoordinate(origin.x(), origin.x(), bbWidth, random),
|
||||||
|
this.verticalPosition.getCoordinate(origin.y(), origin.y() + bbHeight / 2.0F, bbHeight, random),
|
||||||
|
this.horizontalPosition.getCoordinate(origin.z(), origin.z(), bbWidth, random),
|
Loading…
x
Reference in New Issue
Block a user