diff --git a/vConsole.java b/vConsole.java deleted file mode 100644 index a955e0999..000000000 --- a/vConsole.java +++ /dev/null @@ -1,19 +0,0 @@ -public class vConsole extends PluginListener { -public boolean onConsoleCommand(String[] split) { - String args = etc.combineSplit(1, split, ""); - //Return true if you don't want the server command to be parsed by the server. - String server = Colors.LightGreen + "[Server] " + Colors.DarkPurple; - if(split[0].equalsIgnoreCase("stop")){ - vChat.gmsg(server + "Rebooting the server"); - return false; - } - //Make say nicer - if(split[0].equalsIgnoreCase("say")) - { - //Send out the message - vChat.gmsg(server + args); - return true; - } - return false; - } -} \ No newline at end of file diff --git a/vListener.java b/vListener.java index 0e5917450..1a9b48c64 100644 --- a/vListener.java +++ b/vListener.java @@ -6,24 +6,21 @@ import java.util.logging.Logger; //Author: nossr50, TrapAlice, cerevisiae //===================================================================== public class vListener extends PluginListener { - protected static final Logger log = Logger.getLogger("Minecraft"); + protected static final Logger log = Logger.getLogger("Minecraft"); //On console stuff public boolean onConsoleCommand(String[] split) { - String args = etc.combineSplit(1, split, ""); - //Return true if you don't want the server command to be parsed by the server. - String server = Colors.LightGreen + "[Server] " + Colors.DarkPurple; - if(split[0].equalsIgnoreCase("stop")){ - vChat.gmsg(server + "Rebooting the server"); - return false; - } - //Make say nicer + String server = Colors.LightGreen + "[Server]" + Colors.DarkPurple; if(split[0].equalsIgnoreCase("say")) { - //Send out the message + if(split.length > 1){ + String args = " " + etc.combineSplit(1, split, " "); vChat.gmsg(server + args); return true; + } + return false; } - log.log(Level.INFO, split.toString()); + if(split[0].equalsIgnoreCase("stop")) + vChat.gmsg(server + "shutting down the server"); return false; }