#1390: Improve internal handling of damage sources

By: Doc <nachito94@msn.com>
This commit is contained in:
CraftBukkit/Spigot
2024-05-04 08:15:51 +10:00
parent f01e218606
commit 066665a979
12 changed files with 72 additions and 48 deletions

View File

@@ -25,7 +25,7 @@
if (entityliving.isAlive() && !entityliving.isInvulnerable() && entityliving != entityliving1) {
if (entityliving1 == null) {
- entityliving.hurt(this.damageSources().magic(), 6.0F);
+ entityliving.hurt(this.damageSources().magic().customCausingEntity(this), 6.0F); // CraftBukkit
+ entityliving.hurt(this.damageSources().magic().customEntityDamager(this), 6.0F); // CraftBukkit
} else {
if (entityliving1.isAlliedTo((Entity) entityliving)) {
return;