diff options
Diffstat (limited to 'src/main/java/org/bukkit')
-rw-r--r-- | src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java index 276939ca..d66e4eb2 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java @@ -212,4 +212,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player { public void updateInventory() { getHandle().m(); } + + public void setSleepingIgnored(boolean isSleeping) { + getHandle().fauxSleeping = isSleeping; + ((CraftWorld)getWorld()).getHandle().checkSleepStatus(); + } + + public boolean isSleepingIgnored() { + return getHandle().fauxSleeping; + } } |