mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-27 23:10:16 +01:00
API to allow/disallow tick sleeping
This commit is contained in:
parent
7c0d854ed3
commit
b9a4e9a745
1 changed files with 9 additions and 0 deletions
|
@ -2597,5 +2597,14 @@ public interface Server extends PluginMessageRecipient, net.kyori.adventure.audi
|
|||
* Returns whether the server is sleeping/paused.
|
||||
*/
|
||||
boolean isPaused();
|
||||
|
||||
/**
|
||||
* Allows or disallows the server to sleep/pause.
|
||||
* If any plugin disallows pausing, the server will never pause.
|
||||
*
|
||||
* @param plugin The {@link org.bukkit.plugin.Plugin} that's allowing or disallowing pausing.
|
||||
* @param value Whether to allow sleeping of the server (defaults to true).
|
||||
*/
|
||||
void allowPausing(@NotNull org.bukkit.plugin.Plugin plugin, boolean value);
|
||||
// Paper end - API to check if the server is sleeping
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue