Don't check chunk for portal on world gen entity add

This commit is contained in:
Aikar 2020-07-05 14:59:31 -04:00
parent ea5eaa7503
commit 9cb53a41ca

View File

@ -1350,9 +1350,10 @@
}
- ItemStack itemstack2 = itemstack1;
+ ItemStack itemstack2 = itemstack1; final ItemStack oldEquipment = itemstack2; // Paper - PlayerArmorChangeEvent - obfhelper
-
- itemstack = this.getItemBySlot(enumitemslot);
+ ItemStack itemstack2 = itemstack1; final ItemStack oldEquipment = itemstack2; // Paper - PlayerArmorChangeEvent - obfhelper
+
+ itemstack = this.getItemBySlot(enumitemslot); final ItemStack newEquipment = itemstack;// Paper - PlayerArmorChangeEvent - obfhelper
if (this.equipmentHasChanged(itemstack2, itemstack)) {
+ // Paper start - PlayerArmorChangeEvent
@ -1437,7 +1438,7 @@
this.doPush(entity1);
}
}
@@ -3190,9 +3799,15 @@
@@ -3190,10 +3799,16 @@
@Override
public void stopRiding() {
@ -1450,10 +1451,12 @@
Entity entity = this.getVehicle();
- super.stopRiding();
- if (entity != null && entity != this.getVehicle() && !this.level().isClientSide) {
+ super.stopRiding(suppressCancellation); // Paper - Force entity dismount during teleportation
if (entity != null && entity != this.getVehicle() && !this.level().isClientSide) {
+ if (entity != null && entity != this.getVehicle() && !this.level().isClientSide && entity.valid) { // Paper - don't process on world gen
this.dismountVehicle(entity);
}
@@ -3305,15 +3920,22 @@
@Override