changed gravity gauntlet to remove cooldown all together in creativemode
This commit is contained in:
parent
7f3f150e96
commit
00e502a746
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -37,6 +37,7 @@ public class GravityGauntlet implements Listener {
|
|||||||
event.setCancelled(true);
|
event.setCancelled(true);
|
||||||
|
|
||||||
// Cooldown check
|
// Cooldown check
|
||||||
|
if(player.getGameMode() != GameMode.CREATIVE) {
|
||||||
if (cooldowns.containsKey(player.getUniqueId())) {
|
if (cooldowns.containsKey(player.getUniqueId())) {
|
||||||
long timeLeft = (cooldowns.get(player.getUniqueId()) + COOLDOWN_TIME) - System.currentTimeMillis();
|
long timeLeft = (cooldowns.get(player.getUniqueId()) + COOLDOWN_TIME) - System.currentTimeMillis();
|
||||||
if (timeLeft > 0) {
|
if (timeLeft > 0) {
|
||||||
@ -44,6 +45,7 @@ public class GravityGauntlet implements Listener {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
cooldowns.put(player.getUniqueId(), System.currentTimeMillis());
|
cooldowns.put(player.getUniqueId(), System.currentTimeMillis());
|
||||||
|
|
||||||
// Shift-click = Throw away, Normal click = Pull in
|
// Shift-click = Throw away, Normal click = Pull in
|
||||||
|
Loading…
Reference in New Issue
Block a user