34 lines
1.3 KiB
Diff
34 lines
1.3 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: William Blake Galbreath <blake.galbreath@gmail.com>
|
|
Date: Sun, 5 May 2019 12:58:19 -0500
|
|
Subject: [PATCH] LivingEntity safeFallDistance
|
|
|
|
Original code by PurpurMC, licensed under MIT
|
|
You can find the original code on https://github.com/PurpurMC/Purpur
|
|
|
|
diff --git a/src/main/java/org/bukkit/entity/LivingEntity.java b/src/main/java/org/bukkit/entity/LivingEntity.java
|
|
index 31353bd20404a8c2acf6bf0df524dc3cae324272..e532430b7444cef4e383b3afb637cc6060d8686a 100644
|
|
--- a/src/main/java/org/bukkit/entity/LivingEntity.java
|
|
+++ b/src/main/java/org/bukkit/entity/LivingEntity.java
|
|
@@ -910,4 +910,20 @@ public interface LivingEntity extends Attributable, Damageable, ProjectileSource
|
|
*/
|
|
void setHurtDirection(float hurtDirection);
|
|
// Paper end
|
|
+
|
|
+ // Purpur start
|
|
+ /**
|
|
+ * Gets the distance (in blocks) this entity can safely fall without taking damage
|
|
+ *
|
|
+ * @return Safe fall distance
|
|
+ */
|
|
+ float getSafeFallDistance();
|
|
+
|
|
+ /**
|
|
+ * Set the distance (in blocks) this entity can safely fall without taking damage
|
|
+ *
|
|
+ * @param safeFallDistance Safe fall distance
|
|
+ */
|
|
+ void setSafeFallDistance(float safeFallDistance);
|
|
+ // Purpur end
|
|
}
|