mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-23 11:06:29 +01:00
Fix a mistake in EntityEnderPearl causing a double teleport
This commit is contained in:
parent
3f534696a3
commit
6f032cdc8a
@ -12,7 +12,7 @@
|
||||
public class EntityEnderPearl extends EntityProjectile {
|
||||
|
||||
private EntityLiving d;
|
||||
@@ -51,13 +57,35 @@
|
||||
@@ -51,21 +57,35 @@
|
||||
EntityPlayer entityplayer = (EntityPlayer) entityliving;
|
||||
|
||||
if (entityplayer.playerConnection.a().isConnected() && entityplayer.world == this.world && !entityplayer.isSleeping()) {
|
||||
@ -50,7 +50,15 @@
|
||||
+ entityliving.damageEntity(DamageSource.FALL, 5.0F);
|
||||
+ CraftEventFactory.entityDamage = null;
|
||||
}
|
||||
-
|
||||
- if (entityliving.isPassenger()) {
|
||||
- this.stopRiding();
|
||||
- }
|
||||
-
|
||||
- entityliving.enderTeleportTo(this.locX, this.locY, this.locZ);
|
||||
- entityliving.fallDistance = 0.0F;
|
||||
- entityliving.damageEntity(DamageSource.FALL, 5.0F);
|
||||
+ // CraftBukkit end
|
||||
|
||||
if (entityliving.isPassenger()) {
|
||||
this.stopRiding();
|
||||
}
|
||||
} else if (entityliving != null) {
|
||||
entityliving.enderTeleportTo(this.locX, this.locY, this.locZ);
|
||||
|
Loading…
Reference in New Issue
Block a user