Adds increased scrapper cost when used excessively
All checks were successful
EpicKnarvik97/Blacksmith/pipeline/head This commit looks good
All checks were successful
EpicKnarvik97/Blacksmith/pipeline/head This commit looks good
This commit is contained in:
@@ -20,6 +20,7 @@ import net.knarcraft.blacksmith.formatting.BlacksmithTranslatableMessage;
|
||||
import net.knarcraft.blacksmith.listener.NPCClickListener;
|
||||
import net.knarcraft.blacksmith.listener.PlayerListener;
|
||||
import net.knarcraft.blacksmith.manager.EconomyManager;
|
||||
import net.knarcraft.blacksmith.manager.PlayerUsageManager;
|
||||
import net.knarcraft.blacksmith.trait.BlacksmithTrait;
|
||||
import net.knarcraft.blacksmith.trait.ScrapperTrait;
|
||||
import net.knarcraft.blacksmith.util.ConfigHelper;
|
||||
@@ -27,6 +28,7 @@ import net.knarcraft.knarlib.formatting.StringFormatter;
|
||||
import net.knarcraft.knarlib.formatting.TranslatableTimeUnit;
|
||||
import net.knarcraft.knarlib.formatting.Translator;
|
||||
import net.knarcraft.knarlib.util.UpdateChecker;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.command.CommandExecutor;
|
||||
import org.bukkit.command.PluginCommand;
|
||||
import org.bukkit.command.TabCompleter;
|
||||
@@ -183,6 +185,10 @@ public class BlacksmithPlugin extends JavaPlugin {
|
||||
//Alert about an update in the console
|
||||
UpdateChecker.checkForUpdate(this, "https://api.spigotmc.org/legacy/update.php?resource=105938",
|
||||
() -> this.getDescription().getVersion(), null);
|
||||
|
||||
// Remove expired scrapper usage data
|
||||
Bukkit.getScheduler().scheduleSyncRepeatingTask(this, () -> PlayerUsageManager.removeExpiredData(
|
||||
System.currentTimeMillis() - 3600000), 36000, 36000);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
Reference in New Issue
Block a user