mirror of
https://github.com/PaperMC/Paper.git
synced 2025-08-24 00:33:49 -07:00
SPIGOT-5309: Call cancelled EntityDamageEvent when damaging invisible armor stands
By: jojokobi <jhocheneder@gmx.at>
This commit is contained in:
@@ -64,9 +64,10 @@
|
||||
+ // CraftBukkit end
|
||||
+ this.killEntity(); // CraftBukkit - this.die() -> this.killEntity()
|
||||
return false;
|
||||
} else if (!this.isInvulnerable(damagesource) && !this.bD && !this.isMarker()) {
|
||||
- } else if (!this.isInvulnerable(damagesource) && !this.bD && !this.isMarker()) {
|
||||
+ } else if (!this.isInvulnerable(damagesource) && (true || !this.bD) && !this.isMarker()) { // CraftBukkit
|
||||
+ // CraftBukkit start
|
||||
+ if (org.bukkit.craftbukkit.event.CraftEventFactory.handleNonLivingEntityDamageEvent(this, damagesource, f)) {
|
||||
+ if (org.bukkit.craftbukkit.event.CraftEventFactory.handleNonLivingEntityDamageEvent(this, damagesource, f, true, this.bD)) { // PAIL: armorStandInvisible
|
||||
+ return false;
|
||||
+ }
|
||||
+ // CraftBukkit end
|
||||
|
Reference in New Issue
Block a user