Signed-off-by: yoyosource <yoyosource@nidido.de>
Dieser Commit ist enthalten in:
Ursprung
def07fe50c
Commit
c7b21bfc74
@ -49,22 +49,20 @@ import java.util.function.Predicate;
|
||||
public enum LinkageType {
|
||||
|
||||
// NORMAL
|
||||
COMMAND(-1, false, SWCommand.class::isAssignableFrom, o -> ((SWCommand) o).setMessage(BauSystem.MESSAGE)),
|
||||
ENABLE_LINK(0, false, Enable.class::isAssignableFrom, o -> ((Enable) o).enable()),
|
||||
DISABLE_LINK(0, true, Disable.class::isAssignableFrom, o -> ((Disable) o).disable()),
|
||||
PLAIN(1, false, clazz -> true),
|
||||
LISTENER(2, false, Listener.class::isAssignableFrom, o -> Bukkit.getPluginManager().registerEvents((Listener) o, BauSystem.getInstance())),
|
||||
UNLINK_LISTENER(2, true, Listener.class::isAssignableFrom, o -> HandlerList.unregisterAll((Listener) o)),
|
||||
COMMAND(false, SWCommand.class::isAssignableFrom, o -> ((SWCommand) o).setMessage(BauSystem.MESSAGE)),
|
||||
ENABLE_LINK(false, Enable.class::isAssignableFrom, o -> ((Enable) o).enable()),
|
||||
DISABLE_LINK(true, Disable.class::isAssignableFrom, o -> ((Disable) o).disable()),
|
||||
PLAIN(false, clazz -> true),
|
||||
LISTENER(false, Listener.class::isAssignableFrom, o -> Bukkit.getPluginManager().registerEvents((Listener) o, BauSystem.getInstance())),
|
||||
UNLINK_LISTENER(true, Listener.class::isAssignableFrom, o -> HandlerList.unregisterAll((Listener) o)),
|
||||
|
||||
// SPECIFIC
|
||||
BAU_GUI_ITEM(3, false, BauGuiItem.class::isAssignableFrom, o -> BauGUI.addItem((BauGuiItem) o)),
|
||||
SCRIPT_COMMAND(4, false, SpecialCommand.class::isAssignableFrom, o -> ScriptExecutor.SPECIAL_COMMANDS.add((SpecialCommand) o)),
|
||||
CONFIG_CONVERTER(5, false, ConfigConverter.class::isAssignableFrom, o -> Config.addConfigConverter((ConfigConverter) o)),
|
||||
SCOREBOARD(6, false, ScoreboardItem.class::isAssignableFrom, o -> {}),
|
||||
PANZERN(7, false, PanzernAlgorithm.class::isAssignableFrom, o -> PanzernAlgorithmLazyInit.add((PanzernAlgorithm) o)),
|
||||
SMART_PLACE(8, false, SmartPlaceBehaviour.class::isAssignableFrom, o -> SmartPlaceListener.add((SmartPlaceBehaviour) o));
|
||||
|
||||
private final int order;
|
||||
BAU_GUI_ITEM(false, BauGuiItem.class::isAssignableFrom, o -> BauGUI.addItem((BauGuiItem) o)),
|
||||
SCRIPT_COMMAND(false, SpecialCommand.class::isAssignableFrom, o -> ScriptExecutor.SPECIAL_COMMANDS.add((SpecialCommand) o)),
|
||||
CONFIG_CONVERTER(false, ConfigConverter.class::isAssignableFrom, o -> Config.addConfigConverter((ConfigConverter) o)),
|
||||
SCOREBOARD(false, ScoreboardItem.class::isAssignableFrom, o -> {}),
|
||||
PANZERN(false, PanzernAlgorithm.class::isAssignableFrom, o -> PanzernAlgorithmLazyInit.add((PanzernAlgorithm) o)),
|
||||
SMART_PLACE(false, SmartPlaceBehaviour.class::isAssignableFrom, o -> SmartPlaceListener.add((SmartPlaceBehaviour) o));
|
||||
|
||||
private final boolean unlink;
|
||||
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren