Update to Minecraft 1.16.1

By: md_5 <git@md-5.net>
This commit is contained in:
CraftBukkit/Spigot
2020-06-25 10:00:00 +10:00
parent 3862d2811e
commit 50503fd516
424 changed files with 5960 additions and 5636 deletions

View File

@@ -1,19 +1,19 @@
--- a/net/minecraft/server/EntityThrownExpBottle.java
+++ b/net/minecraft/server/EntityThrownExpBottle.java
@@ -27,9 +27,18 @@
@Override
@@ -28,9 +28,18 @@
protected void a(MovingObjectPosition movingobjectposition) {
super.a(movingobjectposition);
if (!this.world.isClientSide) {
- this.world.triggerEffect(2002, new BlockPosition(this), PotionUtil.a(Potions.WATER));
- this.world.triggerEffect(2002, this.getChunkCoordinates(), PotionUtil.a(Potions.WATER));
+ // CraftBukkit - moved to after event
+ // this.world.triggerEffect(2002, new BlockPosition(this), PotionUtil.a(Potions.WATER));
+ // this.world.triggerEffect(2002, this.getChunkCoordinates(), PotionUtil.a(Potions.WATER));
int i = 3 + this.world.random.nextInt(5) + this.world.random.nextInt(5);
+ // CraftBukkit start
+ org.bukkit.event.entity.ExpBottleEvent event = org.bukkit.craftbukkit.event.CraftEventFactory.callExpBottleEvent(this, i);
+ i = event.getExperience();
+ if (event.getShowEffect()) {
+ this.world.triggerEffect(2002, new BlockPosition(this), PotionUtil.a(Potions.WATER));
+ this.world.triggerEffect(2002, this.getChunkCoordinates(), PotionUtil.a(Potions.WATER));
+ }
+ // CraftBukkit end
+