Repackage NMS

By: md_5 <git@md-5.net>
This commit is contained in:
CraftBukkit/Spigot
2021-03-16 09:00:00 +11:00
parent 18496e998f
commit 9da047989c
968 changed files with 5448 additions and 5050 deletions

View File

@@ -1,8 +1,8 @@
--- a/net/minecraft/server/EntityFishingHook.java
+++ b/net/minecraft/server/EntityFishingHook.java
@@ -7,6 +7,12 @@
import java.util.Random;
import javax.annotation.Nullable;
--- a/net/minecraft/world/entity/projectile/EntityFishingHook.java
+++ b/net/minecraft/world/entity/projectile/EntityFishingHook.java
@@ -45,6 +45,12 @@
import net.minecraft.world.phys.MovingObjectPositionEntity;
import net.minecraft.world.phys.Vec3D;
+// CraftBukkit start
+import org.bukkit.entity.Player;
@@ -13,7 +13,7 @@
public class EntityFishingHook extends IProjectile {
private final Random b;
@@ -25,6 +31,12 @@
@@ -63,6 +69,12 @@
private final int an;
private final int lureLevel;
@@ -26,7 +26,7 @@
private EntityFishingHook(World world, EntityHuman entityhuman, int i, int j) {
super(EntityTypes.FISHING_BOBBER, world);
this.b = new Random();
@@ -253,6 +265,10 @@
@@ -291,6 +303,10 @@
this.waitTime = 0;
this.ai = 0;
this.getDataWatcher().set(EntityFishingHook.f, false);
@@ -37,7 +37,7 @@
}
} else {
float f;
@@ -286,6 +302,13 @@
@@ -324,6 +340,13 @@
worldserver.a(Particles.FISHING, d0, d1, d2, 0, (double) (-f4), 0.01D, (double) f3, 1.0D);
}
} else {
@@ -51,7 +51,7 @@
this.playSound(SoundEffects.ENTITY_FISHING_BOBBER_SPLASH, 0.25F, 1.0F + (this.random.nextFloat() - this.random.nextFloat()) * 0.4F);
double d3 = this.locY() + 0.5D;
@@ -322,8 +345,10 @@
@@ -360,8 +383,10 @@
this.ai = MathHelper.nextInt(this.random, 20, 80);
}
} else {
@@ -64,7 +64,7 @@
}
}
@@ -390,6 +415,14 @@
@@ -428,6 +453,14 @@
int i = 0;
if (this.hooked != null) {
@@ -79,7 +79,7 @@
this.reel();
CriterionTriggers.D.a((EntityPlayer) entityhuman, itemstack, this, (Collection) Collections.emptyList());
this.world.broadcastEntityEffect(this, (byte) 31);
@@ -405,6 +438,15 @@
@@ -443,6 +476,15 @@
while (iterator.hasNext()) {
ItemStack itemstack1 = (ItemStack) iterator.next();
EntityItem entityitem = new EntityItem(this.world, this.locX(), this.locY(), this.locZ(), itemstack1);
@@ -95,7 +95,7 @@
double d0 = entityhuman.locX() - this.locX();
double d1 = entityhuman.locY() - this.locY();
double d2 = entityhuman.locZ() - this.locZ();
@@ -412,7 +454,11 @@
@@ -450,7 +492,11 @@
entityitem.setMot(d0 * 0.1D, d1 * 0.1D + Math.sqrt(Math.sqrt(d0 * d0 + d1 * d1 + d2 * d2)) * 0.08D, d2 * 0.1D);
this.world.addEntity(entityitem);
@@ -108,7 +108,7 @@
if (itemstack1.getItem().a((Tag) TagsItem.FISHES)) {
entityhuman.a(StatisticList.FISH_CAUGHT, 1);
}
@@ -422,8 +468,25 @@
@@ -460,8 +506,25 @@
}
if (this.onGround) {