mirror of
https://e.coding.net/circlecloud/Yum.git
synced 2024-11-22 14:28:46 +00:00
feat: 使用新的处理库
Signed-off-by: 502647092 <admin@yumc.pw>
This commit is contained in:
parent
bc20088f0f
commit
04e3e58c2f
4
pom.xml
4
pom.xml
@ -40,6 +40,10 @@
|
|||||||
<pattern>cn.citycraft.PluginHelper</pattern>
|
<pattern>cn.citycraft.PluginHelper</pattern>
|
||||||
<shadedPattern>${project.groupId}.${project.artifactId}</shadedPattern>
|
<shadedPattern>${project.groupId}.${project.artifactId}</shadedPattern>
|
||||||
</relocation>
|
</relocation>
|
||||||
|
<relocation>
|
||||||
|
<pattern>pw.yumc.PluginHelper</pattern>
|
||||||
|
<shadedPattern>${project.groupId}.${project.artifactId}</shadedPattern>
|
||||||
|
</relocation>
|
||||||
</relocations>
|
</relocations>
|
||||||
</configuration>
|
</configuration>
|
||||||
<executions>
|
<executions>
|
||||||
|
@ -6,7 +6,7 @@ import org.bukkit.event.Listener;
|
|||||||
import org.bukkit.event.server.PluginDisableEvent;
|
import org.bukkit.event.server.PluginDisableEvent;
|
||||||
import org.bukkit.event.server.PluginEnableEvent;
|
import org.bukkit.event.server.PluginEnableEvent;
|
||||||
|
|
||||||
import cn.citycraft.PluginHelper.kit.PKit;
|
import cn.citycraft.PluginHelper.bukkit.P;
|
||||||
import cn.citycraft.PluginHelper.kit.PluginKit;
|
import cn.citycraft.PluginHelper.kit.PluginKit;
|
||||||
import pw.yumc.Yum.api.YumAPI;
|
import pw.yumc.Yum.api.YumAPI;
|
||||||
import pw.yumc.Yum.managers.MonitorManager;
|
import pw.yumc.Yum.managers.MonitorManager;
|
||||||
@ -19,7 +19,7 @@ import pw.yumc.Yum.managers.MonitorManager;
|
|||||||
public class PluginListener implements Listener {
|
public class PluginListener implements Listener {
|
||||||
|
|
||||||
public PluginListener() {
|
public PluginListener() {
|
||||||
Bukkit.getPluginManager().registerEvents(this, PKit.i());
|
Bukkit.getPluginManager().registerEvents(this, P.instance);
|
||||||
PluginKit.scp("§a性能监控系统已启用...");
|
PluginKit.scp("§a性能监控系统已启用...");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -4,15 +4,15 @@ import java.util.List;
|
|||||||
|
|
||||||
import org.bukkit.plugin.java.JavaPlugin;
|
import org.bukkit.plugin.java.JavaPlugin;
|
||||||
|
|
||||||
|
import cn.citycraft.PluginHelper.bukkit.P;
|
||||||
import cn.citycraft.PluginHelper.config.FileConfig;
|
import cn.citycraft.PluginHelper.config.FileConfig;
|
||||||
import cn.citycraft.PluginHelper.kit.PKit;
|
|
||||||
|
|
||||||
public class ConfigManager {
|
public class ConfigManager {
|
||||||
public final static String ENABLE = "Enable";
|
public final static String ENABLE = "Enable";
|
||||||
public final static String BLACK = "Black";
|
public final static String BLACK = "Black";
|
||||||
public final static String IGNORE = "Ignore";
|
public final static String IGNORE = "Ignore";
|
||||||
|
|
||||||
private final static ConfigManager i = new ConfigManager(PKit.i());
|
private final static ConfigManager i = new ConfigManager(P.instance);
|
||||||
|
|
||||||
public final FileConfig config;
|
public final FileConfig config;
|
||||||
public final FileConfig setop;
|
public final FileConfig setop;
|
||||||
|
@ -6,7 +6,7 @@ import org.bukkit.Bukkit;
|
|||||||
import org.bukkit.command.CommandSender;
|
import org.bukkit.command.CommandSender;
|
||||||
|
|
||||||
import cn.citycraft.PluginHelper.PluginHelperLogger;
|
import cn.citycraft.PluginHelper.PluginHelperLogger;
|
||||||
import cn.citycraft.PluginHelper.kit.PKit;
|
import cn.citycraft.PluginHelper.bukkit.Log;
|
||||||
import cn.citycraft.PluginHelper.utils.IOUtil;
|
import cn.citycraft.PluginHelper.utils.IOUtil;
|
||||||
import pw.yumc.Yum.models.RepoSerialization.Plugin;
|
import pw.yumc.Yum.models.RepoSerialization.Plugin;
|
||||||
import pw.yumc.Yum.models.RepoSerialization.TagInfo;
|
import pw.yumc.Yum.models.RepoSerialization.TagInfo;
|
||||||
@ -19,7 +19,7 @@ public class PluginInfo implements Serializable {
|
|||||||
try {
|
try {
|
||||||
NMSVersion = Bukkit.getServer().getClass().getPackage().getName().split("\\.")[3];
|
NMSVersion = Bukkit.getServer().getClass().getPackage().getName().split("\\.")[3];
|
||||||
} catch (final Exception e) {
|
} catch (final Exception e) {
|
||||||
PKit.i().getLogger().warning("服务器NMS解析失败: " + Bukkit.getServer().getClass().getPackage().getName());
|
Log.warning("服务器NMS解析失败: " + Bukkit.getServer().getClass().getPackage().getName());
|
||||||
NMSVersion = "NONMS";
|
NMSVersion = "NONMS";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user