2020-05-06 17:48:49 +08:00
|
|
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
2017-06-11 06:11:10 +08:00
|
|
|
From: Zach Brown <zach.brown@destroystokyo.com>
|
|
|
|
Date: Sat, 10 Jun 2017 16:59:40 -0500
|
|
|
|
Subject: [PATCH] Fix upstream javadoc warnings and errors
|
|
|
|
|
|
|
|
Upstream still refuses to use Java 8 with the API so they are likely unaware these are even issues.
|
|
|
|
|
|
|
|
diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java
|
2020-08-25 10:22:08 +08:00
|
|
|
index fefbe857676bdab750379a9d6c120099817a83e8..833f4cb13e9d3d1d0daa1ac1202a70e2606c80b8 100644
|
2017-06-11 06:11:10 +08:00
|
|
|
--- a/src/main/java/org/bukkit/World.java
|
|
|
|
+++ b/src/main/java/org/bukkit/World.java
|
2020-08-25 10:22:08 +08:00
|
|
|
@@ -2087,6 +2087,7 @@ public interface World extends PluginMessageRecipient, Metadatable {
|
2017-06-11 06:11:10 +08:00
|
|
|
* @param count the number of particles
|
|
|
|
* @param data the data to use for the particle or null,
|
|
|
|
* the type of this depends on {@link Particle#getDataType()}
|
|
|
|
+ * @param <T> Type
|
|
|
|
*/
|
2019-03-20 08:28:15 +08:00
|
|
|
public <T> void spawnParticle(@NotNull Particle particle, @NotNull Location location, int count, @Nullable T data);
|
2017-06-11 06:11:10 +08:00
|
|
|
|
2020-08-25 10:22:08 +08:00
|
|
|
@@ -2103,6 +2104,7 @@ public interface World extends PluginMessageRecipient, Metadatable {
|
2017-06-11 06:11:10 +08:00
|
|
|
* @param count the number of particles
|
|
|
|
* @param data the data to use for the particle or null,
|
|
|
|
* the type of this depends on {@link Particle#getDataType()}
|
|
|
|
+ * @param <T> Type
|
|
|
|
*/
|
2019-03-20 08:28:15 +08:00
|
|
|
public <T> void spawnParticle(@NotNull Particle particle, double x, double y, double z, int count, @Nullable T data);
|
2017-06-11 06:11:10 +08:00
|
|
|
|
2020-08-25 10:22:08 +08:00
|
|
|
@@ -2153,6 +2155,7 @@ public interface World extends PluginMessageRecipient, Metadatable {
|
2017-06-11 06:11:10 +08:00
|
|
|
* @param offsetZ the maximum random offset on the Z axis
|
|
|
|
* @param data the data to use for the particle or null,
|
|
|
|
* the type of this depends on {@link Particle#getDataType()}
|
|
|
|
+ * @param <T> Type
|
|
|
|
*/
|
2019-03-20 08:28:15 +08:00
|
|
|
public <T> void spawnParticle(@NotNull Particle particle, @NotNull Location location, int count, double offsetX, double offsetY, double offsetZ, @Nullable T data);
|
2017-06-11 06:11:10 +08:00
|
|
|
|
2020-08-25 10:22:08 +08:00
|
|
|
@@ -2173,6 +2176,7 @@ public interface World extends PluginMessageRecipient, Metadatable {
|
2017-06-11 06:11:10 +08:00
|
|
|
* @param offsetZ the maximum random offset on the Z axis
|
|
|
|
* @param data the data to use for the particle or null,
|
|
|
|
* the type of this depends on {@link Particle#getDataType()}
|
|
|
|
+ * @param <T> Type
|
|
|
|
*/
|
2019-03-20 08:28:15 +08:00
|
|
|
public <T> void spawnParticle(@NotNull Particle particle, double x, double y, double z, int count, double offsetX, double offsetY, double offsetZ, @Nullable T data);
|
2017-06-11 06:11:10 +08:00
|
|
|
|
2020-08-25 10:22:08 +08:00
|
|
|
@@ -2229,6 +2233,7 @@ public interface World extends PluginMessageRecipient, Metadatable {
|
2017-06-11 06:11:10 +08:00
|
|
|
* particle used (normally speed)
|
|
|
|
* @param data the data to use for the particle or null,
|
|
|
|
* the type of this depends on {@link Particle#getDataType()}
|
|
|
|
+ * @param <T> Type
|
|
|
|
*/
|
2019-03-20 08:28:15 +08:00
|
|
|
public <T> void spawnParticle(@NotNull Particle particle, @NotNull Location location, int count, double offsetX, double offsetY, double offsetZ, double extra, @Nullable T data);
|
2017-06-11 06:11:10 +08:00
|
|
|
|
2020-08-25 10:22:08 +08:00
|
|
|
@@ -2251,6 +2256,7 @@ public interface World extends PluginMessageRecipient, Metadatable {
|
2017-06-11 06:11:10 +08:00
|
|
|
* particle used (normally speed)
|
|
|
|
* @param data the data to use for the particle or null,
|
|
|
|
* the type of this depends on {@link Particle#getDataType()}
|
|
|
|
+ * @param <T> Type
|
|
|
|
*/
|
2019-03-20 08:28:15 +08:00
|
|
|
public <T> void spawnParticle(@NotNull Particle particle, double x, double y, double z, int count, double offsetX, double offsetY, double offsetZ, double extra, @Nullable T data);
|
2017-06-11 06:11:10 +08:00
|
|
|
|
2020-08-25 10:22:08 +08:00
|
|
|
@@ -2274,6 +2280,7 @@ public interface World extends PluginMessageRecipient, Metadatable {
|
2018-10-25 21:38:19 +08:00
|
|
|
* @param force whether to send the particle to players within an extended
|
|
|
|
* range and encourage their client to render it regardless of
|
|
|
|
* settings
|
|
|
|
+ * @param <T> Particle data type
|
|
|
|
*/
|
2019-03-20 08:28:15 +08:00
|
|
|
public <T> void spawnParticle(@NotNull Particle particle, @NotNull Location location, int count, double offsetX, double offsetY, double offsetZ, double extra, @Nullable T data, boolean force);
|
2018-10-25 21:38:19 +08:00
|
|
|
|
2020-08-25 10:22:08 +08:00
|
|
|
@@ -2299,6 +2306,7 @@ public interface World extends PluginMessageRecipient, Metadatable {
|
2018-10-25 21:38:19 +08:00
|
|
|
* @param force whether to send the particle to players within an extended
|
|
|
|
* range and encourage their client to render it regardless of
|
|
|
|
* settings
|
|
|
|
+ * @param <T> Particle data type
|
|
|
|
*/
|
2019-03-20 08:28:15 +08:00
|
|
|
public <T> void spawnParticle(@NotNull Particle particle, double x, double y, double z, int count, double offsetX, double offsetY, double offsetZ, double extra, @Nullable T data, boolean force);
|
2018-10-25 21:38:19 +08:00
|
|
|
|
2018-08-17 12:29:16 +08:00
|
|
|
diff --git a/src/main/java/org/bukkit/entity/AreaEffectCloud.java b/src/main/java/org/bukkit/entity/AreaEffectCloud.java
|
2020-05-06 17:48:49 +08:00
|
|
|
index c2096b5344d48d855d031538ec32e0154bd9054d..bca9d3659f6fceeca4b7fecbc7034d6fdbc4581e 100644
|
2018-08-17 12:29:16 +08:00
|
|
|
--- a/src/main/java/org/bukkit/entity/AreaEffectCloud.java
|
|
|
|
+++ b/src/main/java/org/bukkit/entity/AreaEffectCloud.java
|
2019-05-22 12:14:56 +08:00
|
|
|
@@ -142,6 +142,7 @@ public interface AreaEffectCloud extends Entity {
|
2018-08-17 12:29:16 +08:00
|
|
|
* @param particle the new particle type
|
|
|
|
* @param data the data to use for the particle or null,
|
|
|
|
* the type of this depends on {@link Particle#getDataType()}
|
|
|
|
+ * @param <T> the particle data type // Paper
|
|
|
|
*/
|
2019-03-20 08:28:15 +08:00
|
|
|
<T> void setParticle(@NotNull Particle particle, @Nullable T data);
|
2018-08-17 12:29:16 +08:00
|
|
|
|
2017-06-11 06:11:10 +08:00
|
|
|
diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java
|
2020-11-03 17:14:21 +08:00
|
|
|
index 742c7b5a1919e2c3a70891d6c34756076c386368..7e90c11066a7882a8ea4dfa757323616fb88e612 100644
|
2017-06-11 06:11:10 +08:00
|
|
|
--- a/src/main/java/org/bukkit/entity/Player.java
|
|
|
|
+++ b/src/main/java/org/bukkit/entity/Player.java
|
2020-11-03 17:14:21 +08:00
|
|
|
@@ -499,7 +499,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
2017-06-11 06:11:10 +08:00
|
|
|
*
|
|
|
|
* Use supplied alternative character to the section symbol to represent legacy color codes.
|
|
|
|
*
|
|
|
|
- * @param alternateChar Alternate symbol such as '&'
|
|
|
|
+ * @param alternateChar Alternate symbol such as '&'
|
|
|
|
* @param message The message to send
|
|
|
|
*/
|
2019-03-20 08:28:15 +08:00
|
|
|
public void sendActionBar(char alternateChar, @NotNull String message);
|
2020-11-03 17:14:21 +08:00
|
|
|
@@ -573,6 +573,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
2017-06-11 06:11:10 +08:00
|
|
|
/**
|
|
|
|
* Update the subtitle of titles displayed to the player
|
|
|
|
*
|
|
|
|
+ * @param subtitle Subtitle to set
|
|
|
|
* @deprecated Use {@link #updateTitle(Title)}
|
|
|
|
*/
|
|
|
|
@Deprecated
|
2020-11-03 17:14:21 +08:00
|
|
|
@@ -581,6 +582,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
2017-06-11 06:11:10 +08:00
|
|
|
/**
|
|
|
|
* Update the subtitle of titles displayed to the player
|
|
|
|
*
|
|
|
|
+ * @param subtitle Subtitle to set
|
|
|
|
* @deprecated Use {@link #updateTitle(Title)}
|
|
|
|
*/
|
|
|
|
@Deprecated
|
2020-11-03 17:14:21 +08:00
|
|
|
@@ -589,6 +591,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
2017-06-11 06:11:10 +08:00
|
|
|
/**
|
|
|
|
* Show the given title to the player, along with the last subtitle set, using the last set times
|
|
|
|
*
|
|
|
|
+ * @param title Title to set
|
|
|
|
* @deprecated Use {@link #sendTitle(Title)} or {@link #updateTitle(Title)}
|
|
|
|
*/
|
|
|
|
@Deprecated
|
2020-11-03 17:14:21 +08:00
|
|
|
@@ -597,6 +600,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
2017-06-11 06:11:10 +08:00
|
|
|
/**
|
|
|
|
* Show the given title to the player, along with the last subtitle set, using the last set times
|
|
|
|
*
|
|
|
|
+ * @param title Title to set
|
|
|
|
* @deprecated Use {@link #sendTitle(Title)} or {@link #updateTitle(Title)}
|
|
|
|
*/
|
|
|
|
@Deprecated
|
2020-11-03 17:14:21 +08:00
|
|
|
@@ -1246,6 +1250,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
2017-06-11 06:11:10 +08:00
|
|
|
* @param count the number of particles
|
|
|
|
* @param data the data to use for the particle or null,
|
|
|
|
* the type of this depends on {@link Particle#getDataType()}
|
|
|
|
+ * @param <T> Type
|
|
|
|
*/
|
2019-03-20 08:28:15 +08:00
|
|
|
public <T> void spawnParticle(@NotNull Particle particle, @NotNull Location location, int count, @Nullable T data);
|
2017-06-11 06:11:10 +08:00
|
|
|
|
2020-11-03 17:14:21 +08:00
|
|
|
@@ -1262,6 +1267,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
2017-06-11 06:11:10 +08:00
|
|
|
* @param count the number of particles
|
|
|
|
* @param data the data to use for the particle or null,
|
|
|
|
* the type of this depends on {@link Particle#getDataType()}
|
|
|
|
+ * @param <T> Type
|
|
|
|
*/
|
2019-03-20 08:28:15 +08:00
|
|
|
public <T> void spawnParticle(@NotNull Particle particle, double x, double y, double z, int count, @Nullable T data);
|
2017-06-11 06:11:10 +08:00
|
|
|
|
2020-11-03 17:14:21 +08:00
|
|
|
@@ -1312,6 +1318,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
2017-06-11 06:11:10 +08:00
|
|
|
* @param offsetZ the maximum random offset on the Z axis
|
|
|
|
* @param data the data to use for the particle or null,
|
|
|
|
* the type of this depends on {@link Particle#getDataType()}
|
|
|
|
+ * @param <T> Type
|
|
|
|
*/
|
2019-03-20 08:28:15 +08:00
|
|
|
public <T> void spawnParticle(@NotNull Particle particle, @NotNull Location location, int count, double offsetX, double offsetY, double offsetZ, @Nullable T data);
|
2017-06-11 06:11:10 +08:00
|
|
|
|
2020-11-03 17:14:21 +08:00
|
|
|
@@ -1332,6 +1339,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
2017-06-11 06:11:10 +08:00
|
|
|
* @param offsetZ the maximum random offset on the Z axis
|
|
|
|
* @param data the data to use for the particle or null,
|
|
|
|
* the type of this depends on {@link Particle#getDataType()}
|
|
|
|
+ * @param <T> Type
|
|
|
|
*/
|
2019-03-20 08:28:15 +08:00
|
|
|
public <T> void spawnParticle(@NotNull Particle particle, double x, double y, double z, int count, double offsetX, double offsetY, double offsetZ, @Nullable T data);
|
2017-06-11 06:11:10 +08:00
|
|
|
|
2020-11-03 17:14:21 +08:00
|
|
|
@@ -1388,6 +1396,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
2017-06-11 06:11:10 +08:00
|
|
|
* particle used (normally speed)
|
|
|
|
* @param data the data to use for the particle or null,
|
|
|
|
* the type of this depends on {@link Particle#getDataType()}
|
|
|
|
+ * @param <T> Type
|
|
|
|
*/
|
2019-03-20 08:28:15 +08:00
|
|
|
public <T> void spawnParticle(@NotNull Particle particle, @NotNull Location location, int count, double offsetX, double offsetY, double offsetZ, double extra, @Nullable T data);
|
2017-06-11 06:11:10 +08:00
|
|
|
|
2020-11-03 17:14:21 +08:00
|
|
|
@@ -1410,6 +1419,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
2017-06-11 06:11:10 +08:00
|
|
|
* particle used (normally speed)
|
|
|
|
* @param data the data to use for the particle or null,
|
|
|
|
* the type of this depends on {@link Particle#getDataType()}
|
|
|
|
+ * @param <T> Type
|
|
|
|
*/
|
2019-03-20 08:28:15 +08:00
|
|
|
public <T> void spawnParticle(@NotNull Particle particle, double x, double y, double z, int count, double offsetX, double offsetY, double offsetZ, double extra, @Nullable T data);
|
2017-06-11 06:11:10 +08:00
|
|
|
|
2019-04-15 06:45:42 +08:00
|
|
|
diff --git a/src/main/java/org/bukkit/event/player/PlayerMoveEvent.java b/src/main/java/org/bukkit/event/player/PlayerMoveEvent.java
|
2020-05-06 17:48:49 +08:00
|
|
|
index 1b2267f4e8ebded198773ec80e2bff2c861c7084..1a58734d919fae247eeb85dd785fd59990856505 100644
|
2019-04-15 06:45:42 +08:00
|
|
|
--- a/src/main/java/org/bukkit/event/player/PlayerMoveEvent.java
|
|
|
|
+++ b/src/main/java/org/bukkit/event/player/PlayerMoveEvent.java
|
2019-05-06 10:58:04 +08:00
|
|
|
@@ -78,7 +78,7 @@ public class PlayerMoveEvent extends PlayerEvent implements Cancellable {
|
2019-04-15 06:45:42 +08:00
|
|
|
*
|
|
|
|
* @return Location the player moved to
|
|
|
|
*/
|
|
|
|
- @Nullable
|
|
|
|
+ @NotNull // Paper
|
|
|
|
public Location getTo() {
|
|
|
|
return to;
|
|
|
|
}
|