aboutsummaryrefslogtreecommitdiffhomepage
path: root/patches/server/0785-Add-TameableDeathMessageEvent.patch
diff options
context:
space:
mode:
authorJake Potrebic <[email protected]>2023-09-22 16:26:10 -0700
committerJake Potrebic <[email protected]>2023-09-22 16:26:10 -0700
commit81c5901c674e6ee89dbfed4848c9eb645bfb0f16 (patch)
treef6c716a6060d6d6a4757ed83ddd600fb40276cdb /patches/server/0785-Add-TameableDeathMessageEvent.patch
parent47aeab84ad94196bc24530ff8ad02342fc16f336 (diff)
downloadPaper-81c5901c674e6ee89dbfed4848c9eb645bfb0f16.tar.gz
Paper-81c5901c674e6ee89dbfed4848c9eb645bfb0f16.zip
re-add distance map patch
Diffstat (limited to 'patches/server/0785-Add-TameableDeathMessageEvent.patch')
-rw-r--r--patches/server/0785-Add-TameableDeathMessageEvent.patch24
1 files changed, 0 insertions, 24 deletions
diff --git a/patches/server/0785-Add-TameableDeathMessageEvent.patch b/patches/server/0785-Add-TameableDeathMessageEvent.patch
deleted file mode 100644
index b08801fd3d..0000000000
--- a/patches/server/0785-Add-TameableDeathMessageEvent.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
-From: Owen1212055 <[email protected]>
-Date: Mon, 21 Jun 2021 21:24:45 -0400
-Subject: [PATCH] Add TameableDeathMessageEvent
-
-
-diff --git a/src/main/java/net/minecraft/world/entity/TamableAnimal.java b/src/main/java/net/minecraft/world/entity/TamableAnimal.java
-index d33716ddab40185ff77625c20a8a107c18d1f76d..9fb11df7131f400e6e631146c32efccea83adf56 100644
---- a/src/main/java/net/minecraft/world/entity/TamableAnimal.java
-+++ b/src/main/java/net/minecraft/world/entity/TamableAnimal.java
-@@ -197,7 +197,12 @@ public abstract class TamableAnimal extends Animal implements OwnableEntity {
- @Override
- public void die(DamageSource damageSource) {
- if (!this.level().isClientSide && this.level().getGameRules().getBoolean(GameRules.RULE_SHOWDEATHMESSAGES) && this.getOwner() instanceof ServerPlayer) {
-- this.getOwner().sendSystemMessage(this.getCombatTracker().getDeathMessage());
-+ // Paper start - TameableDeathMessageEvent
-+ io.papermc.paper.event.entity.TameableDeathMessageEvent event = new io.papermc.paper.event.entity.TameableDeathMessageEvent((org.bukkit.entity.Tameable) getBukkitEntity(), io.papermc.paper.adventure.PaperAdventure.asAdventure(this.getCombatTracker().getDeathMessage()));
-+ if (event.callEvent()) {
-+ this.getOwner().sendSystemMessage(io.papermc.paper.adventure.PaperAdventure.asVanilla(event.deathMessage()));
-+ }
-+ // Paper end - TameableDeathMessageEvent
- }
-
- super.die(damageSource);