Open Pyario opened 4 months ago
Are you using some kind of Command API?
How Command API? I use the normal Spigot API
My onEnable when its help. :)
@Override
public void onEnable() {
jobAPI = new JobAPI(this);
jobGUI = new JobGUI(jobAPI, this);
jobTopGUI = new JobTopGUI(jobAPI);
bossBarManager = new BossBarManager(this, jobAPI);
instance = this;
setupEconomy();
//Register Configs
setupBlocksConfig();
//Register Events
getServer().getPluginManager().registerEvents(this, this);
getServer().getPluginManager().registerEvents(new JobBreakEvent(jobAPI, bossBarManager), this);
getServer().getPluginManager().registerEvents(new JobsKillEvent(jobAPI, bossBarManager), this);
getServer().getPluginManager().registerEvents(new JobFishingEvent(jobAPI, bossBarManager), this);
getServer().getPluginManager().registerEvents(new JoinEvent(), this);
getServer().getPluginManager().registerEvents(new JobGUI(jobAPI, this), this);
getServer().getPluginManager().registerEvents(new JobTopGUI(jobAPI), this);
getCommand("job").setExecutor(new JobCommand(jobAPI, jobGUI, jobTopGUI));
getCommand("job").setTabCompleter(new JobCommand(jobAPI, jobGUI, jobTopGUI));
getCommand("jobs").setExecutor(new JobCommand(jobAPI, jobGUI, jobTopGUI));
getCommand("jobs").setTabCompleter(new JobCommand(jobAPI, jobGUI, jobTopGUI));
jobAPI.loadXPAndLevels();
for(Player all : Bukkit.getOnlinePlayers()){
if(!JobConfig.cfg.isSet("Jobs." + all.getPlayer().getUniqueId() + ".canHaveJobs")){
JobConfig.cfg.set("Jobs." + all.getPlayer().getUniqueId() + ".canHaveJobs", 3);
JobConfig.save();
}
}
}
Same problem here I use the new paper brigardier api. But I think it has something to do with the whole rewrite of command system by paper
This is a Paper issue, and it's also not something that prevents your plugin from loading/reloading, so ¯\_(ツ)_/¯
Can't use plugman anymore to reload plugins in 1.21 too :cry:
ETA on fix?
514 / 5.000 Hello, since I've been using 1.20.6 and Java 21 and reloading my own plugins, I've been getting a strange error that I didn't have before when I was using 1.20.4 and Java 17. I can actually reload the plugin but this shouldn't really happen. I built my plugins with 1.20.6 and Java 21, of course! I think it's because of plugman but I'm not sure because I can't do anything with this error! I would be happy to receive an answer. The Plugman update 2.4.1 doesn't help either. :)
Error:
20:15:56 Xprotyl issued server command: /plugman reload JobSystemV2 [JobSystemV2]: Disabling JobSystemV2 v11.0 20:15:57 [PluginRemapper]: Remapping plugin 'plugins/JobsPluginV2.jar'... [PluginRemapper]: Done remapping plugin 'plugins/JobsPluginV2.jar' in 294ms. [JobSystemV2]: Loading server plugin JobSystemV2 v11.0 [JobSystemV2]: Enabling JobSystemV2 v11.0 ERROR20:15:57 Caught previously unhandled exception : Paper Async Command Builder Thread Pool - 0 <---- Why?? Console20:15:57 java.util.ConcurrentModificationException: null at java.base/java.util.LinkedHashMap$LinkedHashIterator.nextNode(LinkedHashMap.java:1023) ~[?:?] at java.base/java.util.LinkedHashMap$LinkedValueIterator.next(LinkedHashMap.java:1052) ~[?:?] at net.minecraft.commands.Commands.fillUsableCommands(Commands.java:552) ~[purpur-1.20.6.jar:1.20.6-2233-0d6766e] at net.minecraft.commands.Commands.sendAsync(Commands.java:515) ~[purpur-1.20.6.jar:1.20.6-2233-0d6766e] at net.minecraft.commands.Commands.lambda$sendCommands$5(Commands.java:488) ~[purpur-1.20.6.jar:1.20.6-2233-0d6766e] at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144) ~[?:?] at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642) ~[?:?] at java.base/java.lang.Thread.run(Thread.java:1583) ~[?:?]