mirror of
https://e.coding.net/circlecloud/Residence.git
synced 2025-11-24 21:46:16 +00:00
@@ -88,8 +88,7 @@ public class ResidenceMain extends JavaPlugin {
|
||||
public static float bukkitver;
|
||||
|
||||
public final static int saveVersion = 1;
|
||||
public final static String[] validLanguages = { "English",
|
||||
"Chinese" };
|
||||
public final static String[] validLanguages = { "English", "Chinese" };
|
||||
public final static Pattern VER_REGEX = Pattern.compile("(\\d+)\\.(\\d+)\\.(\\d+)");
|
||||
protected static ResidenceMain instance;
|
||||
protected DataBackup backup;
|
||||
@@ -505,17 +504,17 @@ public class ResidenceMain extends JavaPlugin {
|
||||
|
||||
int autosaveInt = cmanager.getAutoSaveInterval();
|
||||
autosaveInt = autosaveInt < 1 ? 1 : autosaveInt * 60 * 20;
|
||||
taskmanager.add(this.getServer().getScheduler().runTaskTimer(this, new AutoSaveTask(this), autosaveInt, autosaveInt));
|
||||
taskmanager.add(this.getServer().getScheduler().runTaskTimerAsynchronously(this, new AutoSaveTask(this), autosaveInt, autosaveInt));
|
||||
|
||||
if (cmanager.useLeases()) {
|
||||
int leaseInterval = cmanager.getLeaseCheckInterval();
|
||||
leaseInterval = leaseInterval < 1 ? 1 : leaseInterval * 60 * 20;
|
||||
taskmanager.add(this.getServer().getScheduler().runTaskTimer(this, new LeaseTask(this), leaseInterval, leaseInterval));
|
||||
taskmanager.add(this.getServer().getScheduler().runTaskTimerAsynchronously(this, new LeaseTask(this), leaseInterval, leaseInterval));
|
||||
}
|
||||
if (cmanager.enabledRentSystem()) {
|
||||
int rentint = cmanager.getRentCheckInterval();
|
||||
rentint = rentint < 1 ? 1 : rentint * 60 * 20;
|
||||
taskmanager.add(this.getServer().getScheduler().runTaskTimer(this, new RentTask(this), rentint, rentint));
|
||||
taskmanager.add(this.getServer().getScheduler().runTaskTimerAsynchronously(this, new RentTask(this), rentint, rentint));
|
||||
}
|
||||
for (final Player player : Bukkit.getServer().getOnlinePlayers()) {
|
||||
if (this.getPermissionManager().isResidenceAdmin(player)) {
|
||||
|
||||
Reference in New Issue
Block a user