mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-17 08:27:43 +01:00
Upstream has released updates that appear to apply and compile correctly Paper Changes: PaperMC/Paper@e7e1c8a Fix and add new scoreboard API (#10037) PaperMC/Paper@49f9f6f Add Registry#getKey (#10066) PaperMC/Paper@4adca3d Update to adventure 4.15 (#10045) PaperMC/Paper@ff7b9b0 Increase default custom payload channel size limit (#10006)
37 lines
1.5 KiB
Diff
37 lines
1.5 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: MelnCat <melncatuwu@gmail.com>
|
|
Date: Fri, 23 Sep 2022 18:35:28 -0700
|
|
Subject: [PATCH] Add death screen API
|
|
|
|
|
|
diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java
|
|
index ac9f3b74a2c0d2fadb52cc3f3e11d635f9088cf8..ee76f84c8e341e4939ed0082a6ed889b701533cb 100644
|
|
--- a/src/main/java/org/bukkit/entity/Player.java
|
|
+++ b/src/main/java/org/bukkit/entity/Player.java
|
|
@@ -3633,5 +3633,25 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
|
* Clears all debug block highlights
|
|
*/
|
|
void clearBlockHighlights();
|
|
+
|
|
+ /**
|
|
+ * Sends a player the death screen with a specified death message.
|
|
+ *
|
|
+ * @param message The death message to show the player
|
|
+ */
|
|
+ void sendDeathScreen(@NotNull net.kyori.adventure.text.Component message);
|
|
+
|
|
+ /**
|
|
+ * Sends a player the death screen with a specified death message,
|
|
+ * along with the entity that caused the death.
|
|
+ *
|
|
+ * @param message The death message to show the player
|
|
+ * @param killer The entity that killed the player
|
|
+ * @deprecated Use {@link #sendDeathScreen(net.kyori.adventure.text.Component)} instead, as 1.20 removed the killer ID from the packet.
|
|
+ */
|
|
+ @Deprecated(since = "1.20")
|
|
+ default void sendDeathScreen(@NotNull net.kyori.adventure.text.Component message, @Nullable Entity killer) {
|
|
+ sendDeathScreen(message);
|
|
+ }
|
|
// Purpur end
|
|
}
|