Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-11-14 20:10:05 +01:00
[ci skip] Fix Effect javadocs (#11182)
Dieser Commit ist enthalten in:
Ursprung
098bd39092
Commit
f97aff74b6
@ -6,21 +6,44 @@ Subject: [PATCH] Add missing effects
|
||||
Co-authored-by: Jake Potrebic <jake.m.potrebic@gmail.com>
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/Effect.java b/src/main/java/org/bukkit/Effect.java
|
||||
index fd9cf25f2fdef5ee3b7143f27e5f43dfe3f21a38..f0e595c754afbbf2729ff093262459ac8010ce85 100644
|
||||
index fd9cf25f2fdef5ee3b7143f27e5f43dfe3f21a38..8a346d7a4ce07e0a73d7a1d1370321d4fb538547 100644
|
||||
--- a/src/main/java/org/bukkit/Effect.java
|
||||
+++ b/src/main/java/org/bukkit/Effect.java
|
||||
@@ -131,9 +131,9 @@ public enum Effect {
|
||||
@@ -97,7 +97,7 @@ public enum Effect {
|
||||
*/
|
||||
EXTINGUISH(1009, Type.SOUND),
|
||||
/**
|
||||
* Sound of a block breaking. Needs block ID as additional info.
|
||||
- * A song from a record. Needs the record item ID as additional info
|
||||
+ * A song from a record. Needs the record {@link Material} as additional info.
|
||||
*/
|
||||
RECORD_PLAY(1010, Type.SOUND, Material.class),
|
||||
/**
|
||||
@@ -125,20 +125,20 @@ public enum Effect {
|
||||
*/
|
||||
ZOMBIE_DESTROY_DOOR(1021, Type.SOUND),
|
||||
/**
|
||||
- * A visual smoke effect. Needs direction as additional info.
|
||||
+ * A visual smoke effect. Needs a {@link BlockFace} direction as additional info.
|
||||
*/
|
||||
SMOKE(2000, Type.VISUAL, BlockFace.class),
|
||||
/**
|
||||
- * Sound of a block breaking. Needs block ID as additional info.
|
||||
+ * Sound of a block breaking. Needs {@link org.bukkit.block.data.BlockData} as additional info.
|
||||
*/
|
||||
- STEP_SOUND(2001, Type.SOUND, Material.class),
|
||||
+ STEP_SOUND(2001, Type.SOUND, org.bukkit.block.data.BlockData.class, Material.class), // Paper - block data is more correct, but the impl of the mtehods will still work with Material
|
||||
/**
|
||||
- * Visual effect of a splash potion breaking. Needs potion data value as
|
||||
+ * Visual effect of a splash potion breaking. Needs color data value as
|
||||
+ * Visual effect of a splash potion breaking. Needs {@link Color} data value as
|
||||
* additional info.
|
||||
*/
|
||||
POTION_BREAK(2002, Type.VISUAL, Color.class),
|
||||
/**
|
||||
- * Visual effect of an instant splash potion breaking. Needs color data
|
||||
+ * Visual effect of an instant splash potion breaking. Needs {@link Color} data
|
||||
* value as additional info.
|
||||
*/
|
||||
INSTANT_POTION_BREAK(2007, Type.VISUAL, Color.class),
|
||||
@@ -168,7 +168,9 @@ public enum Effect {
|
||||
PORTAL_TRAVEL(1032, Type.SOUND),
|
||||
/**
|
||||
@ -41,7 +64,16 @@ index fd9cf25f2fdef5ee3b7143f27e5f43dfe3f21a38..f0e595c754afbbf2729ff093262459ac
|
||||
VILLAGER_PLANT_GROW(2005, Type.VISUAL, Integer.class),
|
||||
/**
|
||||
* The sound/particles used by the enderdragon's breath
|
||||
@@ -336,21 +340,121 @@ public enum Effect {
|
||||
@@ -319,7 +323,7 @@ public enum Effect {
|
||||
* The particles shown when a lightning hits a lightning rod or oxidized
|
||||
* copper.
|
||||
*
|
||||
- * Data is the axis at which the particle should be shown. If no data is
|
||||
+ * Data is the {@link Axis} at which the particle should be shown. If no data is
|
||||
* provided it will show the particles at the block faces.
|
||||
*/
|
||||
ELECTRIC_SPARK(3002, Type.VISUAL, Axis.class),
|
||||
@@ -336,21 +340,124 @@ public enum Effect {
|
||||
* block.
|
||||
*/
|
||||
OXIDISED_COPPER_SCRAPE(3005, Type.VISUAL),
|
||||
@ -89,6 +121,9 @@ index fd9cf25f2fdef5ee3b7143f27e5f43dfe3f21a38..f0e595c754afbbf2729ff093262459ac
|
||||
+
|
||||
+ PARTICLES_SCULK_SHRIEK(3007, Type.SOUND),
|
||||
+
|
||||
+ /**
|
||||
+ * Requires a {@link org.bukkit.block.data.BlockData} param
|
||||
+ */
|
||||
+ PARTICLES_AND_SOUND_BRUSH_BLOCK_COMPLETE(3008, Type.VISUAL, org.bukkit.block.data.BlockData.class),
|
||||
+
|
||||
+ PARTICLES_EGG_CRACK(3009, Type.VISUAL),
|
||||
@ -167,7 +202,7 @@ index fd9cf25f2fdef5ee3b7143f27e5f43dfe3f21a38..f0e595c754afbbf2729ff093262459ac
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -366,8 +470,10 @@ public enum Effect {
|
||||
@@ -366,8 +473,10 @@ public enum Effect {
|
||||
|
||||
/**
|
||||
* @return The type of the effect.
|
||||
@ -178,7 +213,7 @@ index fd9cf25f2fdef5ee3b7143f27e5f43dfe3f21a38..f0e595c754afbbf2729ff093262459ac
|
||||
public Type getType() {
|
||||
return this.type;
|
||||
}
|
||||
@@ -378,8 +484,15 @@ public enum Effect {
|
||||
@@ -378,8 +487,15 @@ public enum Effect {
|
||||
*/
|
||||
@Nullable
|
||||
public Class<?> getData() {
|
||||
@ -195,7 +230,7 @@ index fd9cf25f2fdef5ee3b7143f27e5f43dfe3f21a38..f0e595c754afbbf2729ff093262459ac
|
||||
|
||||
/**
|
||||
* Gets the Effect associated with the given ID.
|
||||
@@ -396,12 +509,26 @@ public enum Effect {
|
||||
@@ -396,12 +512,26 @@ public enum Effect {
|
||||
|
||||
static {
|
||||
for (Effect effect : values()) {
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren