mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-10 12:02:36 +01:00
Fire EntityDamageEvent for armor stands
Somewhat of a lazy way of doing it but it will do for now By: Thinkofdeath <thinkofdeath@spigotmc.org>
This commit is contained in:
parent
3d5cd0953f
commit
3bcc7b2868
1 changed files with 14 additions and 0 deletions
14
paper-server/nms-patches/EntityArmorStand.patch
Normal file
14
paper-server/nms-patches/EntityArmorStand.patch
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
--- ../work/decompile-8eb82bde//net/minecraft/server/EntityArmorStand.java 2014-11-29 16:03:15.597435308 +0000
|
||||||
|
+++ src/main/java/net/minecraft/server/EntityArmorStand.java 2014-11-29 16:02:17.625436595 +0000
|
||||||
|
@@ -343,6 +343,11 @@
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean damageEntity(DamageSource damagesource, float f) {
|
||||||
|
+ // CraftBukkit start
|
||||||
|
+ if (org.bukkit.craftbukkit.event.CraftEventFactory.handleNonLivingEntityDamageEvent(this, damagesource, f)) {
|
||||||
|
+ return false;
|
||||||
|
+ }
|
||||||
|
+ // CraftBukkit end
|
||||||
|
if (!this.world.isStatic && !this.h) {
|
||||||
|
if (DamageSource.OUT_OF_WORLD.equals(damagesource)) {
|
||||||
|
this.die();
|
Loading…
Reference in a new issue