2021-06-11 12:02:28 +00:00
|
|
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
|
|
From: Jake Potrebic <jake.m.potrebic@gmail.com>
|
|
|
|
Date: Thu, 8 Apr 2021 17:36:10 -0700
|
|
|
|
Subject: [PATCH] add isDeeplySleeping to HumanEntity
|
|
|
|
|
|
|
|
|
|
|
|
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
2023-08-17 20:51:34 +00:00
|
|
|
index 8d1bbc1ac3dbc10e940a0715ebfa1d5a2674b303..3f64d57b7d92820226c323d1d560432f5c27e650 100644
|
2021-06-11 12:02:28 +00:00
|
|
|
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
|
|
|
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
2023-05-12 11:10:08 +00:00
|
|
|
@@ -133,6 +133,13 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity {
|
2021-06-11 12:02:28 +00:00
|
|
|
}
|
2023-03-14 22:13:41 +00:00
|
|
|
// Paper end
|
2021-06-11 12:02:28 +00:00
|
|
|
|
|
|
|
+ // Paper start
|
2023-03-14 23:10:18 +00:00
|
|
|
+ @Override
|
2021-06-11 12:02:28 +00:00
|
|
|
+ public boolean isDeeplySleeping() {
|
|
|
|
+ return getHandle().isSleepingLongEnough();
|
|
|
|
+ }
|
|
|
|
+ // Paper end
|
|
|
|
+
|
|
|
|
@Override
|
|
|
|
public int getSleepTicks() {
|
2021-06-15 02:59:31 +00:00
|
|
|
return this.getHandle().sleepCounter;
|