mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-24 06:06:45 +01:00
Only run PartyAutoKickTask Task if Parties are enabled
This commit is contained in:
parent
33c467e7ce
commit
f6facbc08b
@ -671,14 +671,15 @@ public class mcMMO extends JavaPlugin {
|
||||
}
|
||||
|
||||
// Automatically remove old members from parties
|
||||
if(partyConfig.isPartyEnabled()) {
|
||||
long kickIntervalTicks = generalConfig.getAutoPartyKickInterval() * 60L * 60L * Misc.TICK_CONVERSION_FACTOR;
|
||||
|
||||
if (kickIntervalTicks == 0) {
|
||||
getFoliaLib().getImpl().runLater(new PartyAutoKickTask(), 2 * Misc.TICK_CONVERSION_FACTOR); // Start 2 seconds after startup.
|
||||
}
|
||||
else if (kickIntervalTicks > 0) {
|
||||
} else if (kickIntervalTicks > 0) {
|
||||
getFoliaLib().getImpl().runTimer(new PartyAutoKickTask(), kickIntervalTicks, kickIntervalTicks);
|
||||
}
|
||||
}
|
||||
|
||||
// Update power level tag scoreboards
|
||||
getFoliaLib().getImpl().runTimer(new PowerLevelUpdatingTask(), 2 * Misc.TICK_CONVERSION_FACTOR, 2 * Misc.TICK_CONVERSION_FACTOR);
|
||||
|
Loading…
Reference in New Issue
Block a user