API to check if the server is sleeping

This commit is contained in:
Abel
2024-11-10 16:32:34 +01:00
parent 7b83e91bb7
commit b4c394a1c6
2 changed files with 36 additions and 25 deletions

View File

@ -3258,4 +3258,11 @@ public final class CraftServer implements Server {
return this.potionBrewer;
}
// Paper end
// Paper start - API to check if the server is sleeping
@Override
public boolean isPaused() {
return this.console.isTickPaused();
}
// Paper end - API to check if the server is sleeping
}