Register a config command. Currently one subcommand: showfile, which

when passed a modid and a type (CLIENT, COMMON or SERVER) will display
a link in the caller's chat to open that file in the OS file viewer of choice.

Signed-off-by: cpw <[email protected]>
This commit is contained in:
cpw committed 2019-07-28 21:09:15 -04:00
1 parent cd826f7bcf
commit ae09fc6b6d
6 files changed
+146

No files matched your search

@@ -29,6 +29,7 @@ import net.minecraftforge.fml.event.lifecycle.InterModProcessEvent;
import net.minecraftforge.fml.event.server.FMLServerStartingEvent;
import net.minecraftforge.fml.event.server.FMLServerStoppingEvent;
import net.minecraftforge.fml.javafmlmod.FMLJavaModLoadingContext;
import net.minecraftforge.server.command.ConfigCommand;
import net.minecraftforge.server.command.ForgeCommand;
import net.minecraftforge.versions.forge.ForgeVersion;
import net.minecraftforge.versions.mcp.MCPVersion;
@@ -181,6 +182,7 @@ public class ForgeMod implements WorldPersistenceHooks.WorldPersistenceHook
public void serverStarting(FMLServerStartingEvent evt)
{
new ForgeCommand(evt.getCommandDispatcher());
ConfigCommand.register(evt.getCommandDispatcher());
}
public void serverStopping(FMLServerStoppingEvent evt)