mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-27 23:10:16 +01:00
readd potion splash effect cause
This commit is contained in:
parent
cb51a4fbcd
commit
9bb6731cc4
2 changed files with 5 additions and 3 deletions
|
@ -20,7 +20,7 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -138,15 +_,15 @@
|
@@ -138,15 +_,17 @@
|
||||||
owner.setPortalCooldown();
|
owner.setPortalCooldown();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -29,11 +29,13 @@
|
||||||
- serverLevel, vec3, Vec3.ZERO, 0.0F, 0.0F, Relative.union(Relative.ROTATION, Relative.DELTA), TeleportTransition.DO_NOTHING
|
- serverLevel, vec3, Vec3.ZERO, 0.0F, 0.0F, Relative.union(Relative.ROTATION, Relative.DELTA), TeleportTransition.DO_NOTHING
|
||||||
- )
|
- )
|
||||||
- );
|
- );
|
||||||
|
+ // CraftBukkit start - moved up
|
||||||
+ // ServerPlayer serverPlayer1 = serverPlayer.teleport(
|
+ // ServerPlayer serverPlayer1 = serverPlayer.teleport(
|
||||||
+ // new TeleportTransition(
|
+ // new TeleportTransition(
|
||||||
+ // serverLevel, vec3, Vec3.ZERO, 0.0F, 0.0F, Relative.union(Relative.ROTATION, Relative.DELTA), TeleportTransition.DO_NOTHING
|
+ // serverLevel, vec3, Vec3.ZERO, 0.0F, 0.0F, Relative.union(Relative.ROTATION, Relative.DELTA), TeleportTransition.DO_NOTHING
|
||||||
+ // )
|
+ // )
|
||||||
+ // );
|
+ // );
|
||||||
|
+ // CraftBukkit end - moved up
|
||||||
if (serverPlayer1 != null) {
|
if (serverPlayer1 != null) {
|
||||||
serverPlayer1.resetFallDistance();
|
serverPlayer1.resetFallDistance();
|
||||||
serverPlayer1.resetCurrentImpulseContext();
|
serverPlayer1.resetCurrentImpulseContext();
|
||||||
|
|
|
@ -33,7 +33,7 @@
|
||||||
- this.applySplash(
|
- this.applySplash(
|
||||||
- serverLevel, potionContents.getAllEffects(), result.getType() == HitResult.Type.ENTITY ? ((EntityHitResult)result).getEntity() : null
|
- serverLevel, potionContents.getAllEffects(), result.getType() == HitResult.Type.ENTITY ? ((EntityHitResult)result).getEntity() : null
|
||||||
+ showParticles = this.applySplash(
|
+ showParticles = this.applySplash(
|
||||||
+ serverLevel, potionContents.getAllEffects(), result != null && result.getType() == HitResult.Type.ENTITY ? ((EntityHitResult)result).getEntity() : null, result // CraftBukkit - Pass MovingObjectPosition // Paper - More projectile API
|
+ serverLevel, potionContents.getAllEffects(), result != null && result.getType() == HitResult.Type.ENTITY ? ((EntityHitResult)result).getEntity() : null, result // CraftBukkit - Pass MovingObjectPosition // Paper - More projectile API
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -172,7 +172,7 @@
|
||||||
+ effect, i, mobEffectInstance.getAmplifier(), mobEffectInstance.isAmbient(), mobEffectInstance.isVisible()
|
+ effect, i, mobEffectInstance.getAmplifier(), mobEffectInstance.isAmbient(), mobEffectInstance.isVisible()
|
||||||
+ );
|
+ );
|
||||||
+ if (!mobEffectInstance1.endsWithin(20)) {
|
+ if (!mobEffectInstance1.endsWithin(20)) {
|
||||||
+ livingEntity.addEffect(mobEffectInstance1, effectSource);
|
+ livingEntity.addEffect(mobEffectInstance1, effectSource, org.bukkit.event.entity.EntityPotionEffectEvent.Cause.POTION_SPLASH); // CraftBukkit
|
||||||
+ }
|
+ }
|
||||||
+ }
|
+ }
|
||||||
+ }
|
+ }
|
||||||
|
|
Loading…
Reference in a new issue