Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-12-21 14:00:11 +01:00
Fixed entity damaged by entity event firing twice when players damage each other. Thanks Xolsom!
Dieser Commit ist enthalten in:
Ursprung
8b3f90f232
Commit
ef9295707a
@ -516,8 +516,8 @@ public abstract class EntityHuman extends EntityLiving {
|
|||||||
++i;
|
++i;
|
||||||
}
|
}
|
||||||
|
|
||||||
// CraftBukkit start
|
// CraftBukkit start - Don't call the event when the entity is human since it will be called with damageEntity
|
||||||
if (entity instanceof EntityLiving) {
|
if (entity instanceof EntityLiving && !(entity instanceof EntityHuman)) {
|
||||||
CraftServer server = ((WorldServer) this.world).getServer();
|
CraftServer server = ((WorldServer) this.world).getServer();
|
||||||
org.bukkit.entity.Entity damager = this.getBukkitEntity();
|
org.bukkit.entity.Entity damager = this.getBukkitEntity();
|
||||||
org.bukkit.entity.Entity damagee = (entity == null) ? null : entity.getBukkitEntity();
|
org.bukkit.entity.Entity damagee = (entity == null) ? null : entity.getBukkitEntity();
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren