This commit is contained in:
DBotThePony 2022-09-28 12:36:22 +07:00
parent 5f652e7714
commit 5d8147a8f9
Signed by: DBot
GPG Key ID: DCC23B5715498507

View File

@ -27,7 +27,7 @@ private val preServerTickTimers = TimerQueue()
private val postServerTickTimers = TimerQueue()
fun addPreTickTimer(inTicks: Int, callback: Runnable): TimerQueue.Timer? {
if (SERVER_IS_LIVE) {
if (!SERVER_IS_LIVE) {
LOGGER.error("Refusing to add timer $callback in ticks $inTicks while server is dying", IllegalStateException("Server is stopping"))
return null
}
@ -36,7 +36,7 @@ fun addPreTickTimer(inTicks: Int, callback: Runnable): TimerQueue.Timer? {
}
fun addPostTickTimer(inTicks: Int, callback: Runnable): TimerQueue.Timer? {
if (SERVER_IS_LIVE) {
if (!SERVER_IS_LIVE) {
LOGGER.error("Refusing to add ticker $callback in ticks $inTicks while server is dying", IllegalStateException("Server is stopping"))
return null
}