aboutsummaryrefslogtreecommitdiffhomepage
path: root/patches/server/0747-Elder-Guardian-appearance-API.patch
blob: 75a2208ae0c3ddcf9744ccf1f427cdcf342dddce (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: SoSeDiK <mrsosedik@gmail.com>
Date: Tue, 11 Oct 2022 20:38:47 +0300
Subject: [PATCH] Elder Guardian appearance API


diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 7fd3cb7c69aa212449739f5733de661af662611f..997a90a7567a90ef357530f9ed5677f0fce4d402 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -3325,6 +3325,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
     }
     // Paper end
 
+    // Paper start
+    @Override
+    public void showElderGuardian(boolean silent) {
+        if (getHandle().connection != null) getHandle().connection.send(new ClientboundGameEventPacket(ClientboundGameEventPacket.GUARDIAN_ELDER_EFFECT, silent ? 0F : 1F));
+    }
+    // Paper end
+
     public Player.Spigot spigot()
     {
         return this.spigot;