aboutsummaryrefslogtreecommitdiffhomepage
path: root/patches/api/0368-Block-Ticking-API.patch
diff options
context:
space:
mode:
Diffstat (limited to 'patches/api/0368-Block-Ticking-API.patch')
-rw-r--r--patches/api/0368-Block-Ticking-API.patch24
1 files changed, 22 insertions, 2 deletions
diff --git a/patches/api/0368-Block-Ticking-API.patch b/patches/api/0368-Block-Ticking-API.patch
index aba95a2d13..02fed74c9e 100644
--- a/patches/api/0368-Block-Ticking-API.patch
+++ b/patches/api/0368-Block-Ticking-API.patch
@@ -5,10 +5,10 @@ Subject: [PATCH] Block Ticking API
diff --git a/src/main/java/org/bukkit/block/Block.java b/src/main/java/org/bukkit/block/Block.java
-index cf9600c743e977312c0a15c455d602391797ef34..38cf77e32b76bc7d9db7523f7f21427ebb72f913 100644
+index cf9600c743e977312c0a15c455d602391797ef34..8a842840e1a2652a6356d4a56e4749a5ba36e902 100644
--- a/src/main/java/org/bukkit/block/Block.java
+++ b/src/main/java/org/bukkit/block/Block.java
-@@ -589,6 +589,21 @@ public interface Block extends Metadatable, Translatable, net.kyori.adventure.tr
+@@ -589,6 +589,41 @@ public interface Block extends Metadatable, Translatable, net.kyori.adventure.tr
* @return true if the block was destroyed
*/
boolean breakNaturally(@NotNull ItemStack tool, boolean triggerEffect, boolean dropExperience);
@@ -17,14 +17,34 @@ index cf9600c743e977312c0a15c455d602391797ef34..38cf77e32b76bc7d9db7523f7f21427e
+ * Causes the block to be ticked, this is different from {@link Block#randomTick()},
+ * in that it is usually scheduled to occur, for example
+ * redstone components being activated, sand falling, etc.
++ * <p>
++ * This method may directly fire events relating to block ticking.
++ *
++ * @see #fluidTick()
+ */
+ void tick();
+
+ /**
++ * Causes the fluid to be ticked, this is different from {@link Block#randomTick()},
++ * in that it is usually scheduled to occur, for example
++ * causing waterlogged blocks to spread.
++ * <p>
++ * This method may directly fire events relating to fluid ticking.
++ *
++ * @see #tick()
++ */
++ void fluidTick();
++
++ /**
+ * Causes the block to be ticked randomly.
+ * This has a chance to execute naturally if {@link BlockData#isRandomlyTicked()} is true.
+ * <p>
+ * For certain blocks, this behavior may be the same as {@link Block#tick()}.
++ * <p>
++ * This method may directly fire events relating to block random ticking.
++ *
++ * @see #tick()
++ * @see #fluidTick()
+ */
+ void randomTick();
// Paper end