我的 JInput 代码工作正常,它只是在每次程序启动时将这些警告打印到控制台。我需要压制他们。
2017 年 11 月 29 日上午 8:59:55 net.java.games.input.DefaultControllerEnvironment getControllers 警告:发现未知 Windows 版本:Windows 10 2017 年 11 月 29 日上午 8:59:55 net.java.games.input.DefaultControllerEnvironment getControllers 警告: 尝试使用默认的 windows 插件。
编辑:我找到了一种方法,但这有点小技巧:System.err.close();
有没有办法让我暂时禁用System.err
?