Mods branch

This commit is contained in:
Anuken
2019-09-27 19:51:46 -04:00
parent f925ec8cbe
commit 70ab102d8c
6 changed files with 155 additions and 51 deletions

View File

@@ -1,28 +1,7 @@
package io.anuke.mindustry.plugin;
import io.anuke.arc.files.*;
import io.anuke.arc.util.*;
import io.anuke.mindustry.*;
import io.anuke.mindustry.mod.*;
public abstract class Plugin{
public abstract class Plugin extends Mod{
/** @return the config file for this plugin, as the file 'plugins/[plugin-name]/config.json'.*/
public FileHandle getConfig(){
return Vars.plugins.getConfig(this);
}
/** Called after all plugins have been created and commands have been registered.*/
public void init(){
}
/** Register any commands to be used on the server side, e.g. from the console. */
public void registerServerCommands(CommandHandler handler){
}
/** Register any commands to be used on the client side, e.g. sent from an in-game player.. */
public void registerClientCommands(CommandHandler handler){
}
}