mirror of
https://github.com/TotalFreedomMC/TF-ProjectKorra.git
synced 2025-02-11 11:40:40 +00:00
Disabled bending in spectator mode.
This commit is contained in:
parent
eeae6d217b
commit
5b7edaeb00
1 changed files with 3 additions and 0 deletions
|
@ -32,6 +32,7 @@ import java.util.concurrent.ConcurrentHashMap;
|
|||
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.ChatColor;
|
||||
import org.bukkit.GameMode;
|
||||
import org.bukkit.Location;
|
||||
import org.bukkit.Material;
|
||||
import org.bukkit.OfflinePlayer;
|
||||
|
@ -285,6 +286,8 @@ public class GeneralMethods {
|
|||
return false;
|
||||
if (p == null)
|
||||
return false;
|
||||
if (p.getGameMode() == GameMode.SPECTATOR)
|
||||
return false;
|
||||
if (cooldowns.containsKey(p.getName())) {
|
||||
if (cooldowns.get(p.getName()) + ProjectKorra.plugin.getConfig().getLong("Properties.GlobalCooldown") >= System.currentTimeMillis()) {
|
||||
return false;
|
||||
|
|
Loading…
Reference in a new issue