aboutsummaryrefslogtreecommitdiffhomepage
path: root/Spigot-API-Patches/0275-Expose-Tracked-Players.patch
blob: 1f1fce583c42dc54375ca64a05f026fd10e718c6 (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
25
26
27
28
29
30
31
32
33
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Tom <cryptite@gmail.com>
Date: Fri, 26 Feb 2021 16:24:25 -0600
Subject: [PATCH] Expose Tracked Players


diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java
index 8a1e35952ae84ae1e41a2b7783e88eab52bd274c..2ea531eaef8c455fdd503f0c0258813fe9136085 100644
--- a/src/main/java/org/bukkit/entity/Player.java
+++ b/src/main/java/org/bukkit/entity/Player.java
@@ -1,6 +1,7 @@
 package org.bukkit.entity;
 
 import java.net.InetSocketAddress;
+import java.util.Set; // Paper
 import java.util.UUID;
 import com.destroystokyo.paper.ClientOption; // Paper
 import com.destroystokyo.paper.Title; // Paper
@@ -1927,6 +1928,14 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
     void sendOpLevel(byte level);
     // Paper end
 
+    // Paper start
+    /**
+     * @return Returns a set of Players within this player's tracking range (that the player's client can "see")
+     */
+    @NotNull
+    Set<Player> getTrackedPlayers();
+    // Paper end
+
     // Spigot start
     public class Spigot extends Entity.Spigot {