Fixed FastCollatedDropQueueRunnable

This commit is contained in:
Auxilor
2021-01-19 13:58:57 +00:00
parent 50a506af62
commit e64510ebf5
3 changed files with 6 additions and 9 deletions

View File

@@ -1,6 +1,7 @@
package com.willfp.eco.spigot;
import com.willfp.eco.util.command.AbstractCommand;
import com.willfp.eco.util.drops.internal.FastCollatedDropQueue;
import com.willfp.eco.util.integrations.IntegrationLoader;
import com.willfp.eco.util.plugin.AbstractEcoPlugin;
import com.willfp.eco.util.protocollib.AbstractPacketAdapter;
@@ -19,7 +20,7 @@ public class EcoSpigotMain extends AbstractEcoPlugin {
@Override
public void enable() {
new FastCollatedDropQueue.CollatedRunnable(this);
}
@Override
@@ -34,7 +35,7 @@ public class EcoSpigotMain extends AbstractEcoPlugin {
@Override
public void onReload() {
new FastCollatedDropQueue.CollatedRunnable(this);
}
@Override

View File

@@ -124,13 +124,13 @@ public class StringUtils {
double gStep = Math.abs((double) (fromRGB.getGreen() - toRGB.getGreen()) / length);
double bStep = Math.abs((double) (fromRGB.getBlue() - toRGB.getBlue()) / length);
if (fromRGB.getRed() > toRGB.getRed()) {
rStep = -rStep; //200, 100
rStep = -rStep;
}
if (fromRGB.getGreen() > toRGB.getGreen()) {
gStep = -gStep; //200, 100
gStep = -gStep;
}
if (fromRGB.getBlue() > toRGB.getBlue()) {
bStep = -bStep; //200, 100
bStep = -bStep;
}
Color finalColor = new Color(fromRGB.getRGB());
msg = msg.replaceAll(GRADIENT_REGEX, "");

View File

@@ -15,7 +15,6 @@ import com.willfp.eco.util.command.AbstractCommand;
import com.willfp.eco.util.config.configs.Config;
import com.willfp.eco.util.config.configs.Lang;
import com.willfp.eco.util.config.updating.ConfigHandler;
import com.willfp.eco.util.drops.internal.FastCollatedDropQueue;
import com.willfp.eco.util.drops.telekinesis.EcoTelekinesisTests;
import com.willfp.eco.util.drops.telekinesis.TelekinesisTests;
import com.willfp.eco.util.events.armorequip.ArmorListener;
@@ -236,8 +235,6 @@ public abstract class AbstractEcoPlugin extends JavaPlugin {
this.getEventManager().registerListener(new EntityDeathByEntityListeners(this));
this.getEventManager().registerListener(new RecipeListener(this));
new FastCollatedDropQueue.CollatedRunnable(this);
new UpdateChecker(this).getVersion(version -> {
DefaultArtifactVersion currentVersion = new DefaultArtifactVersion(this.getDescription().getVersion());
DefaultArtifactVersion mostRecentVersion = new DefaultArtifactVersion(version);
@@ -363,7 +360,6 @@ public abstract class AbstractEcoPlugin extends JavaPlugin {
this.getConfigHandler().callUpdate();
this.getConfigHandler().callUpdate(); // Call twice to fix issues
this.getScheduler().cancelAll();
new FastCollatedDropQueue.CollatedRunnable(this);
this.onReload();
}