spigot/Bukkit-Patches/0015-View-Distance.patch

31 lines
985 B
Diff
Raw Normal View History

2021-07-07 00:00:00 +10:00
From a986bb2c6619e6c5ec52e38034c59d6ca3a9de89 Mon Sep 17 00:00:00 2001
From: Spottedleaf <Spottedleaf@users.noreply.github.com>
Date: Tue, 30 Jul 2019 13:47:34 -0700
Subject: [PATCH] View Distance
This commit allows the retrieval of per world view distances.
diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java
2021-06-11 15:00:00 +10:00
index 80752a2d..bc4417d8 100644
--- a/src/main/java/org/bukkit/World.java
+++ b/src/main/java/org/bukkit/World.java
2021-04-04 17:29:07 +10:00
@@ -2381,6 +2381,15 @@ public interface World extends PluginMessageRecipient, Metadatable {
@Nullable
public Location locateNearestStructure(@NotNull Location origin, @NotNull StructureType structureType, int radius, boolean findUnexplored);
+ // Spigot start
+ /**
+ * Returns the view distance used for this world.
+ *
+ * @return the view distance used for this world
+ */
+ int getViewDistance();
+ // Spigot end
+
// Spigot start
2020-01-24 17:56:32 +11:00
public class Spigot {
--
2.25.1