I'm trying to log into using MinecraftServer.logInfo(), but I get a nosuchmethod exception.
server.logInfo("Example message");
I'm getting the instance of MinecraftServer in the server starting event.
MinecraftServer server = event.getServer();
The log() method of Logger is used to Log a message. If the logger is currently enabled for the given message level which is passed as parameter then a corresponding LogRecord is created and forwarded to all the registered Output Handler objects.
An option for a fully fledged logger is
Logger logger = LogManager.getLogger(YourMod.MODID);
I'm pretty sure a simple
System.out.println("Information!");
Should do in forge.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With