Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-11-15 12:30:06 +01:00
2873869bb1
Signs no longer have a specific isEdiable state, the entire API in this regard needs updating/deprecation. The boolean field is completely gone, replaced by a uuid (which will need a new setEditingPlayer(UUID) method on the Sign interface), and the current upstream implementation of setEdiable simply flips the is_waxed state. This patch is hence not needed as it neither allows editing (which will be redone in a later patch) nor is required to copy the is_waxed boolean flag as it lives in the signs compound tag and is covered by applyTo.
25 Zeilen
978 B
Diff
25 Zeilen
978 B
Diff
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
|
|
index 15da552a8c085286fe412fffa654b338237ee3f4..48efd9277d9010df1206ccfac9623d66d8046825 100644
|
|
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
|
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
|
@@ -133,6 +133,13 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity {
|
|
}
|
|
// Paper end
|
|
|
|
+ // Paper start
|
|
+ @Override
|
|
+ public boolean isDeeplySleeping() {
|
|
+ return getHandle().isSleepingLongEnough();
|
|
+ }
|
|
+ // Paper end
|
|
+
|
|
@Override
|
|
public int getSleepTicks() {
|
|
return this.getHandle().sleepCounter;
|