mirror of
https://github.com/LordBoos/boosCooldowns.git
synced 2024-11-01 08:20:32 +01:00
Formated source code
This commit is contained in:
parent
746c901825
commit
3f16d593d0
@ -38,9 +38,11 @@ public class boosConfigManager {
|
||||
conf.setProperty("commands.options.unit_seconds", "seconds");
|
||||
conf.setProperty("commands.options.unit_minutes", "minutes");
|
||||
conf.setProperty("commands.options.unit_hours", "hours");
|
||||
conf.setProperty("commands.options.message_warmup_cancelled_by_damage",
|
||||
conf.setProperty(
|
||||
"commands.options.message_warmup_cancelled_by_damage",
|
||||
"&6Warm-ups have been cancelled due to receiving damage.&f");
|
||||
conf.setProperty("commands.options.message_warmup_cancelled_by_move",
|
||||
conf.setProperty(
|
||||
"commands.options.message_warmup_cancelled_by_move",
|
||||
"&6Warm-ups have been cancelled due to moving.&f");
|
||||
conf.setProperty("commands.options.message_cooldown",
|
||||
"&6Wait&e &seconds& &unit&&6 before you can use command&e &command& &6again.&f");
|
||||
@ -82,12 +84,14 @@ public class boosConfigManager {
|
||||
}
|
||||
|
||||
static String getWarmUpCancelledByMoveMessage() {
|
||||
return conf.getString("commands.options.message_warmup_cancelled_by_move",
|
||||
return conf.getString(
|
||||
"commands.options.message_warmup_cancelled_by_move",
|
||||
"&6Warm-ups have been cancelled due to moving.&f");
|
||||
}
|
||||
|
||||
|
||||
static String getWarmUpCancelledByDamageMessage() {
|
||||
return conf.getString("commands.options.message_warmup_cancelled_by_damage",
|
||||
return conf.getString(
|
||||
"commands.options.message_warmup_cancelled_by_damage",
|
||||
"&6Warm-ups have been cancelled due to receiving damage.&f");
|
||||
}
|
||||
|
||||
|
@ -47,7 +47,8 @@ public class boosCoolDown extends JavaPlugin {
|
||||
Event.Priority.Normal, this);
|
||||
}
|
||||
if (boosConfigManager.getCancelWarmupOnMove()) {
|
||||
pm.registerEvent(Event.Type.PLAYER_MOVE, playerListener, Event.Priority.Normal, this);
|
||||
pm.registerEvent(Event.Type.PLAYER_MOVE, playerListener,
|
||||
Event.Priority.Normal, this);
|
||||
}
|
||||
if (boosConfigManager.getClearOnRestart() == true) {
|
||||
boosCoolDownManager.clear();
|
||||
|
@ -25,8 +25,8 @@ public class boosCoolDownEntityListener extends EntityListener {
|
||||
Player player = (Player) entity;
|
||||
if (player != null) {
|
||||
if (boosWarmUpManager.hasWarmUps(player)) {
|
||||
boosChat.sendMessageToPlayer(player,
|
||||
boosConfigManager.getWarmUpCancelledByDamageMessage());
|
||||
boosChat.sendMessageToPlayer(player, boosConfigManager
|
||||
.getWarmUpCancelledByDamageMessage());
|
||||
boosWarmUpManager.cancelWarmUps(player);
|
||||
}
|
||||
|
||||
|
@ -48,8 +48,6 @@ public class boosWarmUpManager {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
public static boolean isWarmUpProcess(Player player, String pre,
|
||||
String message) {
|
||||
pre = pre.toLowerCase();
|
||||
|
@ -25,7 +25,7 @@ public class boosWarmUpTimer extends TimerTask {
|
||||
|
||||
@Override
|
||||
public void run() {
|
||||
if (player.isOnline() && boosWarmUpManager.hasWarmUps(player)==true) {
|
||||
if (player.isOnline() && boosWarmUpManager.hasWarmUps(player) == true) {
|
||||
boosCoolDownManager.setWarmUpOK(player, pre, message);
|
||||
boosWarmUpManager.removeWarmUpProcess(this.player.getName() + "@"
|
||||
+ pre);
|
||||
|
Loading…
Reference in New Issue
Block a user