mirror of https://github.com/taoneill/war.git
Exemption by-permission for command warm-up
Permission node: war.warmupexempt
This commit is contained in:
parent
8bf6d6047d
commit
09e0919042
|
@ -39,7 +39,7 @@ public class WarhubCommand extends AbstractWarCommand {
|
|||
playerWarzone.handlePlayerLeave(player, War.war.getWarHub().getLocation(), true);
|
||||
}
|
||||
int warmup = War.war.getWarConfig().getInt(WarConfig.TPWARMUP);
|
||||
if (warmup > 0) {
|
||||
if (warmup > 0 && !player.hasPermission("war.warmupexempt")) {
|
||||
final int TICKS_PER_SECOND = 20;
|
||||
TeleportPlayerJob job = new TeleportPlayerJob(player, War.war.getWarHub().getLocation());
|
||||
job.runTaskLater(War.war, warmup);
|
||||
|
|
|
@ -35,7 +35,8 @@ public class WarzoneCommand extends AbstractWarCommand {
|
|||
int warmup = War.war.getWarConfig().getInt(WarConfig.TPWARMUP);
|
||||
if (playerWarzone != null) {
|
||||
playerWarzone.handlePlayerLeave(player, warzone.getTeleport(), true);
|
||||
} else if (warmup > 0) {
|
||||
}
|
||||
if (warmup > 0 && !player.hasPermission("war.warmupexempt")) {
|
||||
final int TICKS_PER_SECOND = 20;
|
||||
TeleportPlayerJob job = new TeleportPlayerJob(player, warzone.getTeleport());
|
||||
job.runTaskLater(War.war, warmup);
|
||||
|
|
Loading…
Reference in New Issue