Add Conduit API (#10195)
This commit is contained in:
parent
69b52b4d8e
commit
cbe62d91fb
2 changed files with 96 additions and 0 deletions
46
patches/api/0460-Conduit-API.patch
Normal file
46
patches/api/0460-Conduit-API.patch
Normal file
|
@ -0,0 +1,46 @@
|
|||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Tamion <70228790+notTamion@users.noreply.github.com>
|
||||
Date: Sat, 27 Jan 2024 20:46:29 +0100
|
||||
Subject: [PATCH] Conduit API
|
||||
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/block/Conduit.java b/src/main/java/org/bukkit/block/Conduit.java
|
||||
index 5543165536e84503c2d1476ee2001468cbb724f9..b3eec2eab586072598a40375a1c3e722ee3fa352 100644
|
||||
--- a/src/main/java/org/bukkit/block/Conduit.java
|
||||
+++ b/src/main/java/org/bukkit/block/Conduit.java
|
||||
@@ -3,4 +3,34 @@ package org.bukkit.block;
|
||||
/**
|
||||
* Represents a captured state of a conduit.
|
||||
*/
|
||||
-public interface Conduit extends TileState { }
|
||||
+public interface Conduit extends TileState {
|
||||
+
|
||||
+ // Paper start - Conduit API
|
||||
+
|
||||
+ /**
|
||||
+ * Gets if the conduit is currently active.
|
||||
+ * <p>
|
||||
+ * Requires the conduit to be placed in the world.
|
||||
+ *
|
||||
+ * @return if the conduit is active
|
||||
+ */
|
||||
+ boolean isActive();
|
||||
+
|
||||
+ /**
|
||||
+ * Gets the range in which the Conduit Power effect gets added to players.
|
||||
+ * <p>
|
||||
+ * Requires the conduit to be placed in the world.
|
||||
+ *
|
||||
+ * @return the range
|
||||
+ */
|
||||
+ int getRange();
|
||||
+
|
||||
+ /**
|
||||
+ * Gets the current target of the conduit.
|
||||
+ *
|
||||
+ * @return the current target
|
||||
+ */
|
||||
+ @org.jetbrains.annotations.Nullable
|
||||
+ org.bukkit.entity.LivingEntity getTarget();
|
||||
+ // Paper end - Conduit API
|
||||
+}
|
Loading…
Add table
Add a link
Reference in a new issue