Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-12-17 20:10:10 +01:00
SPIGOT-4882: EntityExplodeEvent appears to fire every tick because of enderdragon
Dieser Commit ist enthalten in:
Ursprung
524facd24e
Commit
d20328368c
@ -70,11 +70,16 @@
|
||||
} else {
|
||||
flag = true;
|
||||
}
|
||||
@@ -407,6 +428,43 @@
|
||||
@@ -407,6 +428,48 @@
|
||||
}
|
||||
}
|
||||
|
||||
+ // CraftBukkit start - Set off an EntityExplodeEvent for the dragon exploding all these blocks
|
||||
+ // SPIGOT-4882: don't fire event if nothing hit
|
||||
+ if (!flag1) {
|
||||
+ return flag;
|
||||
+ }
|
||||
+
|
||||
+ org.bukkit.entity.Entity bukkitEntity = this.getBukkitEntity();
|
||||
+ EntityExplodeEvent event = new EntityExplodeEvent(bukkitEntity, bukkitEntity.getLocation(), destroyedBlocks, 0F);
|
||||
+ bukkitEntity.getServer().getPluginManager().callEvent(event);
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren