Update to Minecraft 1.19.3

By: md_5 <git@md-5.net>
This commit is contained in:
CraftBukkit/Spigot
2022-12-08 03:00:00 +11:00
parent a13136ada2
commit 8b26bb8f3e
305 changed files with 3331 additions and 2864 deletions

View File

@@ -1,6 +1,6 @@
--- a/net/minecraft/world/entity/vehicle/EntityMinecartAbstract.java
+++ b/net/minecraft/world/entity/vehicle/EntityMinecartAbstract.java
@@ -48,6 +48,15 @@
@@ -47,6 +47,15 @@
import net.minecraft.world.phys.AxisAlignedBB;
import net.minecraft.world.phys.Vec3D;
@@ -16,7 +16,7 @@
public abstract class EntityMinecartAbstract extends Entity {
private static final DataWatcherObject<Integer> DATA_ID_HURT = DataWatcher.defineId(EntityMinecartAbstract.class, DataWatcherRegistry.INT);
@@ -90,6 +99,17 @@
@@ -89,6 +98,17 @@
private double lyd;
private double lzd;
@@ -34,7 +34,7 @@
protected EntityMinecartAbstract(EntityTypes<?> entitytypes, World world) {
super(entitytypes, world);
this.blocksBuilding = true;
@@ -216,6 +236,19 @@
@@ -215,6 +235,19 @@
if (this.isInvulnerableTo(damagesource)) {
return false;
} else {
@@ -54,7 +54,7 @@
this.setHurtDir(-this.getHurtDir());
this.setHurtTime(10);
this.markHurt();
@@ -224,6 +257,15 @@
@@ -223,6 +256,15 @@
boolean flag = damagesource.getEntity() instanceof EntityHuman && ((EntityHuman) damagesource.getEntity()).getAbilities().instabuild;
if (flag || this.getDamage() > 40.0F) {
@@ -70,7 +70,7 @@
this.ejectPassengers();
if (flag && !this.hasCustomName()) {
this.discard();
@@ -285,6 +327,14 @@
@@ -284,6 +326,14 @@
@Override
public void tick() {
@@ -85,7 +85,7 @@
if (this.getHurtTime() > 0) {
this.setHurtTime(this.getHurtTime() - 1);
}
@@ -294,7 +344,7 @@
@@ -293,7 +343,7 @@
}
this.checkOutOfWorld();
@@ -94,7 +94,7 @@
double d0;
if (this.level.isClientSide) {
@@ -360,6 +410,18 @@
@@ -359,6 +409,18 @@
}
this.setRot(this.getYRot(), this.getXRot());
@@ -113,7 +113,7 @@
if (this.getMinecartType() == EntityMinecartAbstract.EnumMinecartType.RIDEABLE && this.getDeltaMovement().horizontalDistanceSqr() > 0.01D) {
List<Entity> list = this.level.getEntities((Entity) this, this.getBoundingBox().inflate(0.20000000298023224D, 0.0D, 0.20000000298023224D), IEntitySelector.pushableBy(this));
@@ -368,8 +430,26 @@
@@ -367,8 +429,26 @@
Entity entity = (Entity) list.get(l);
if (!(entity instanceof EntityHuman) && !(entity instanceof EntityIronGolem) && !(entity instanceof EntityMinecartAbstract) && !this.isVehicle() && !entity.isPassenger()) {
@@ -140,7 +140,7 @@
entity.push(this);
}
}
@@ -381,6 +461,14 @@
@@ -380,6 +460,14 @@
Entity entity1 = (Entity) iterator.next();
if (!this.hasPassenger(entity1) && entity1.isPushable() && entity1 instanceof EntityMinecartAbstract) {
@@ -155,7 +155,7 @@
entity1.push(this);
}
}
@@ -397,7 +485,7 @@
@@ -396,7 +484,7 @@
}
protected double getMaxSpeed() {
@@ -164,7 +164,7 @@
}
public void activateMinecart(int i, int j, int k, boolean flag) {}
@@ -408,12 +496,16 @@
@@ -407,12 +495,16 @@
this.setDeltaMovement(MathHelper.clamp(vec3d.x, -d0, d0), vec3d.y, MathHelper.clamp(vec3d.z, -d0, d0));
if (this.onGround) {
@@ -183,7 +183,7 @@
}
}
@@ -604,7 +696,7 @@
@@ -603,7 +695,7 @@
}
protected void applyNaturalSlowdown() {
@@ -192,7 +192,7 @@
Vec3D vec3d = this.getDeltaMovement();
vec3d = vec3d.multiply(d0, 0.0D, d0);
@@ -743,6 +835,14 @@
@@ -742,6 +834,14 @@
if (!this.level.isClientSide) {
if (!entity.noPhysics && !this.noPhysics) {
if (!this.hasPassenger(entity)) {
@@ -207,7 +207,7 @@
double d0 = entity.getX() - this.getX();
double d1 = entity.getZ() - this.getZ();
double d2 = d0 * d0 + d1 * d1;
@@ -922,4 +1022,26 @@
@@ -916,4 +1016,26 @@
private EnumMinecartType() {}
}