From a0e46dd5a5ca5bc4d640e893c316e6a22550076e Mon Sep 17 00:00:00 2001 From: Luca Date: Mon, 22 Nov 2021 15:51:11 +0100 Subject: [PATCH] Update RespawnRunnable.java --- .../java/rip/tilly/bedwars/runnables/RespawnRunnable.java | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/main/java/rip/tilly/bedwars/runnables/RespawnRunnable.java b/src/main/java/rip/tilly/bedwars/runnables/RespawnRunnable.java index de5a807..afc3a80 100644 --- a/src/main/java/rip/tilly/bedwars/runnables/RespawnRunnable.java +++ b/src/main/java/rip/tilly/bedwars/runnables/RespawnRunnable.java @@ -25,13 +25,9 @@ public class RespawnRunnable extends BukkitRunnable { private final int startingTime; private int respawnTime; - private boolean isInGame(PlayerData playerData) { - return playerData.getPlayerState() == PlayerState.PLAYING; - } - @Override public void run() { - if (!this.isInGame(this.playerData)) { + if (!this.player.isOnline()) { cancel(); return; }