提问人:potatoplugin 提问时间:11/16/2023 更新时间:11/16/2023 访问量:27
我不明白为什么我不能将 Public void onEnable() 放在 public static void main 中;如果没有它,我无法运行插件 [关闭]
I don't understand why i can't put the Public void onEnable() in public static void main; I cannot run the plugin without that [closed]
问:
这是我的代码(有点)
public class Plugin extends JavaPlugin
{
public static void main(String[] args){
private static final Logger LOGGER=Logger.getLogger("customweapons");
public void onEnable()
{
LOGGER.info("customweapons enabled");
}
public void onDisable()
{
LOGGER.info("customweapons disabled");
}
}
}
为什么公共空白在那里不起作用,我如何运行代码以查看插件是否有效。
我尝试运行它,但没有任何反应或收到错误消息
答: 暂无答案
评论